This commit is contained in:
thewebartisan7 2024-12-18 05:13:21 +01:00
parent 7b3d625a22
commit a7f0f7eff2
4 changed files with 20 additions and 20 deletions

View File

@ -1,6 +1,6 @@
<script lang="ts" setup> <script lang="ts" setup>
import { Slot } from "radix-vue"; import { Slot } from 'radix-vue';
import { useFormField } from "./useFormField"; import { useFormField } from './useFormField';
const props = defineProps<{ const props = defineProps<{
label?: string; label?: string;

View File

@ -1,15 +1,15 @@
<script lang="ts" setup> <script lang="ts" setup>
import { cn } from "@/lib/utils"; import { cn } from '@/lib/utils'
import { useId } from "radix-vue"; import { useId } from 'radix-vue'
import { type HTMLAttributes, provide } from "vue"; import { type HTMLAttributes, provide } from 'vue'
import { FORM_ITEM_INJECTION_KEY } from "./injectionKeys"; import { FORM_ITEM_INJECTION_KEY } from './injectionKeys'
const props = defineProps<{ const props = defineProps<{
class?: HTMLAttributes["class"]; class?: HTMLAttributes['class']
}>(); }>()
const id = useId(); const id = useId()
provide(FORM_ITEM_INJECTION_KEY, id); provide(FORM_ITEM_INJECTION_KEY, id)
</script> </script>
<template> <template>

View File

@ -1,6 +1,6 @@
<script lang="ts" setup> <script lang="ts" setup>
import { Slot } from "radix-vue"; import { Slot } from 'radix-vue';
import { useFormField } from "./useFormField"; import { useFormField } from './useFormField';
const props = defineProps<{ const props = defineProps<{
label?: string; label?: string;

View File

@ -1,15 +1,15 @@
<script lang="ts" setup> <script lang="ts" setup>
import { cn } from "@/lib/utils"; import { cn } from '@/lib/utils'
import { useId } from "radix-vue"; import { useId } from 'radix-vue'
import { type HTMLAttributes, provide } from "vue"; import { type HTMLAttributes, provide } from 'vue'
import { FORM_ITEM_INJECTION_KEY } from "./injectionKeys"; import { FORM_ITEM_INJECTION_KEY } from './injectionKeys'
const props = defineProps<{ const props = defineProps<{
class?: HTMLAttributes["class"]; class?: HTMLAttributes['class']
}>(); }>()
const id = useId(); const id = useId()
provide(FORM_ITEM_INJECTION_KEY, id); provide(FORM_ITEM_INJECTION_KEY, id)
</script> </script>
<template> <template>