<template>
  <div style="overflow-y: auto">
    <h1>number</h1>
    <div>
      参数：input1，值：{{form.input1}}
      <CusFormColumn
          link="number"
          label="默认整数"
          v-model:param="form.input1"/>
    </div>
    <div>
      参数：input1，值：{{form.input1}}
      <CusFormColumn
          link="number"
          label="最值"
          :max="87"
          :min="-55"
          v-model:param="form.input1"/>
    </div>
    <div>
      参数：input1，值：{{form.input1}}
      <CusFormColumn
          link="number"
          label="小数"
          :decimal="3"
          v-model:param="form.input1"/>
    </div>
    <div>
      参数：input1，值：{{form.input1}}
      <CusFormColumn
          link="number"
          label="小数最值"
          :decimal="3"
          :max="87"
          :min="-16.22"
          v-model:param="form.input1"/>
    </div>

    <h2>插槽</h2>
    <div>
      <CusFormColumn link="number" v-model:param="form.input1">
        <template #prefix>prefix</template>
      </CusFormColumn>
      <CusFormColumn link="number" v-model:param="form.input1">
        <template #suffix>suffix</template>
      </CusFormColumn>
      <CusFormColumn link="number" v-model:param="form.input1">
        <template #prepend>prepend</template>
      </CusFormColumn>
      <CusFormColumn link="number" v-model:param="form.input1">
        <template #append>append</template>
      </CusFormColumn>
    </div>
  </div>
</template>

<script lang="ts">
import {
  defineComponent,
  computed,
  onMounted,
  ref,
  reactive,
  watch,
  getCurrentInstance,
  ComponentInternalInstance,
  toRefs,
  nextTick
} from 'vue'
import {useStore} from 'vuex'
import {useRouter, useRoute} from 'vue-router'

export default defineComponent({
  name: '',
  components: {},
  setup() {
    const store = useStore();
    const router = useRouter();
    const route = useRoute();
    const that = (getCurrentInstance() as ComponentInternalInstance).appContext.config.globalProperties
    const state = reactive({
      form: {
        input1: null,
        input2: null,
      }
    })
    return {
      ...toRefs(state)
    }
  },
})
</script>

<style scoped lang="scss">
</style>
