<script setup lang="ts">
import Block from '~/components/pub/my-ui/form/block.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'

const props = defineProps<{ modelValue: any; items: any[] }>()
const emit = defineEmits(['update:modelValue', 'event'])

const data = computed({
  get: () => props.modelValue,
  set: (val) => emit('update:modelValue', val),
})
</script>

<template>
  <form id="entry-form">
    <div class="mb-5 border-b border-b-slate-300 text-lg xl:text-xl">
      <div class="flex flex-col justify-between">
        <Block>
          <FieldGroup :column="2">
            <Label>Nomor Induk Pegawai</Label>
            <Field>
              <Input v-model="data.number" />
            </Field>
          </FieldGroup>
          <FieldGroup :column="2">
            <Label>Status</Label>
            <Field>
              <Select v-model="data.type" :items="items" placeholder="Pilih jenis" />
            </Field>
          </FieldGroup>
          <FieldGroup :column="2">
            <Label>Position</Label>
            <Field>
              <Select v-model="data.type" :items="items" placeholder="Pilih jenis" />
            </Field>
          </FieldGroup>
          <FieldGroup :column="2">
            <Label>Divisi</Label>
            <Field>
              <Select v-model="data.type" :items="items" placeholder="Pilih jenis" />
            </Field>
          </FieldGroup>
        </Block>
      </div>
    </div>
  </form>
</template>
