mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 20:19:34 +01:00
17 lines
461 B
Vue
17 lines
461 B
Vue
<script setup>
|
|
const date = ref(new Date())
|
|
|
|
const label = computed(() => date.value.toLocaleDateString('en-us', { weekday: 'long', year: 'numeric', month: 'short', day: 'numeric' })
|
|
)
|
|
</script>
|
|
|
|
<template>
|
|
<UPopover :popper="{ placement: 'bottom-start' }">
|
|
<UButton icon="i-heroicons-calendar-days-20-solid" :label="label" />
|
|
|
|
<template #panel="{ close }">
|
|
<DatePicker v-model="date" @close="close" />
|
|
</template>
|
|
</UPopover>
|
|
</template>
|