mv person common to fields

This commit is contained in:
Khafid Prayoga
2025-11-21 16:56:14 +07:00
parent 2138ffcb9d
commit 6c37f226e9
4 changed files with 17 additions and 7 deletions
+2 -1
View File
@@ -6,7 +6,8 @@ import { Form } from '~/components/pub/ui/form'
// components
import InputBase from '~/components/pub/my-ui/form/input-base.vue'
import FileUpload from '~/components/pub/my-ui/form/file-field.vue'
import SelectBirthPlace from '~/components/app/person/_common/select-birth-place.vue'
import { SelectBirthPlace } from '~/components/app/person/fields'
import {
InputName,
RadioCommunicationBarrier,
@@ -0,0 +1,2 @@
export { default as RadioParentsInput } from './radio-parents-input.vue'
export { default as SelectBirthPlace } from './select-birth-place.vue'
@@ -1,9 +1,6 @@
<script setup lang="ts">
import type { FormErrors } from '~/types/error'
import Combobox from '~/components/pub/my-ui/combobox/combobox.vue'
import FieldGroup from '~/components/pub/my-ui/form/field-group.vue'
import Field from '~/components/pub/my-ui/form/field.vue'
import Label from '~/components/pub/my-ui/form/label.vue'
import { cn } from '~/lib/utils'
import * as DE from '~/components/pub/my-ui/doc-entry'
@@ -52,11 +49,21 @@ onMounted(() => {
<template>
<DE.Cell :class="cn('select-field-group', fieldGroupClass, containerClass)">
<DE.Label :label-for="fieldName" :is-required="isRequired">
<DE.Label
:label-for="fieldName"
:is-required="isRequired"
>
Tempat Lahir
</DE.Label>
<DE.Field :id="fieldName" :errors="errors" :class="cn('select-field-wrapper')">
<FormField v-slot="{ componentField }" :name="fieldName">
<DE.Field
:id="fieldName"
:errors="errors"
:class="cn('select-field-wrapper')"
>
<FormField
v-slot="{ componentField }"
:name="fieldName"
>
<FormItem>
<FormControl>
<Combobox