adrema/resources/js/views/formtemplate/Asideform.vue

32 lines
939 B
Vue
Raw Permalink Normal View History

2023-12-26 00:44:49 +01:00
<template>
<ui-box class="relative" :heading="heading" container-class="grid gap-3">
<slot></slot>
<template #in-title>
<div class="flex ml-3 space-x-3 absolute right-0 top-0 mr-4 mt-4">
2023-12-28 00:32:41 +01:00
<a v-if="storeable" href="#" @click.prevent="$emit('submit')">
2023-12-26 00:44:49 +01:00
<ui-sprite src="save" class="text-zinc-400 w-4 h-4"></ui-sprite>
</a>
2023-12-28 00:32:41 +01:00
<a v-if="closeable" href="#" @click.prevent="$emit('close')">
2023-12-26 00:44:49 +01:00
<ui-sprite src="close" class="text-zinc-400 w-4 h-4"></ui-sprite>
</a>
</div>
</template>
</ui-box>
</template>
2024-07-03 16:37:58 +02:00
<script lang="js" setup>
2023-12-26 00:44:49 +01:00
const emit = defineEmits(['close', 'submit']);
const props = defineProps({
heading: {},
2023-12-28 00:32:41 +01:00
closeable: {
default: () => true,
type: Boolean,
},
storeable: {
default: () => true,
type: Boolean,
},
2023-12-26 00:44:49 +01:00
});
</script>