feat: migrate DateField and shared date input group
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
<script setup lang="ts">
|
||||
import {
|
||||
DateField,
|
||||
DateFieldGroup,
|
||||
DateFieldInput,
|
||||
DateFieldSegment,
|
||||
DateFieldPrefix,
|
||||
DateFieldSuffix,
|
||||
Label,
|
||||
} from "@heroui-vue/components";
|
||||
import { IconCalendar, IconChevronDown } from "@tabler/icons-vue";
|
||||
</script>
|
||||
<template>
|
||||
<div class="w-[400px] max-w-full space-y-4">
|
||||
<DateField full-width name="date">
|
||||
<Label>日期</Label>
|
||||
<DateFieldGroup>
|
||||
<DateFieldInput v-slot="{ segment }">
|
||||
<DateFieldSegment :segment="segment" />
|
||||
</DateFieldInput>
|
||||
</DateFieldGroup>
|
||||
</DateField>
|
||||
<DateField full-width name="date-icons">
|
||||
<Label>日期</Label>
|
||||
<DateFieldGroup>
|
||||
<DateFieldPrefix>
|
||||
<IconCalendar class="size-4 text-muted" />
|
||||
</DateFieldPrefix>
|
||||
<DateFieldInput v-slot="{ segment }">
|
||||
<DateFieldSegment :segment="segment" />
|
||||
</DateFieldInput>
|
||||
<DateFieldSuffix>
|
||||
<IconChevronDown class="size-4 text-muted" />
|
||||
</DateFieldSuffix>
|
||||
</DateFieldGroup>
|
||||
</DateField>
|
||||
</div>
|
||||
</template>
|
||||
Reference in New Issue
Block a user