mirror of
https://github.com/nuxt/ui.git
synced 2026-09-14 19:51:10 +08:00
c3ac4badbf
Co-authored-by: chenying <chenying@addcn.com>
16 lines
398 B
Vue
16 lines
398 B
Vue
<script setup lang="ts">
|
|
import { format } from 'date-fns'
|
|
|
|
const date = ref(new Date())
|
|
</script>
|
|
|
|
<template>
|
|
<UPopover :popper="{ placement: 'bottom-start' }">
|
|
<UButton icon="i-heroicons-calendar-days-20-solid" :label="format(date, 'd MMM, yyy')" />
|
|
|
|
<template #panel="{ close }">
|
|
<DatePicker v-model="date" is-required @close="close" />
|
|
</template>
|
|
</UPopover>
|
|
</template>
|