{"version":3,"file":"radio2.mjs","sources":["../../../../../../../packages/components/radio/src/radio.ts"],"sourcesContent":["import { buildProps, isBoolean, isNumber, isString } from '@hd-front-end/utils'\nimport { CHANGE_EVENT, UPDATE_MODEL_EVENT } from '@hd-front-end/constants'\nimport { useSizeProp } from '@hd-front-end/hooks'\n\nimport type { ExtractPropTypes, __ExtractPublicPropTypes } from 'vue'\nimport type Radio from './radio.vue'\n\nexport const radioPropsBase = buildProps({\n  /**\n   * @description binding value\n   */\n  modelValue: {\n    type: [String, Number, Boolean],\n    default: undefined,\n  },\n  /**\n   * @description size of the Radio\n   */\n  size: useSizeProp,\n  /**\n   * @description whether Radio is disabled\n   */\n  disabled: Boolean,\n  /**\n   * @description the label of Radio\n   */\n  label: {\n    type: [String, Number, Boolean],\n    default: undefined,\n  },\n  /**\n   * @description the value of Radio\n   */\n  value: {\n    type: [String, Number, Boolean],\n    default: undefined,\n  },\n  /**\n   * @description native `name` attribute\n   */\n  name: {\n    type: String,\n    default: undefined,\n  },\n})\n\nexport const radioProps = buildProps({\n  ...radioPropsBase,\n  /**\n   * @description whether to add a border around Radio\n   */\n  border: Boolean,\n} as const)\n\nexport const radioEmits = {\n  [UPDATE_MODEL_EVENT]: (val: string | number | boolean | undefined) =>\n    isString(val) || isNumber(val) || isBoolean(val),\n  [CHANGE_EVENT]: (val: string | number | boolean | undefined) =>\n    isString(val) || isNumber(val) || isBoolean(val),\n}\n\nexport type RadioProps = ExtractPropTypes<typeof radioProps>\nexport type RadioPropsPublic = __ExtractPublicPropTypes<typeof radioProps>\nexport type RadioEmits = typeof radioEmits\nexport type RadioInstance = InstanceType<typeof Radio> & unknown\n"],"names":[],"mappings":";;;;;;AAOO,MAAM,iBAAiB,UAAW,CAAA;AAAA,EAIvC,UAAY,EAAA;AAAA,IACV,IAAM,EAAA,CAAC,MAAQ,EAAA,MAAA,EAAQ,OAAO,CAAA;AAAA,IAC9B,OAAS,EAAA,KAAA,CAAA;AAAA,GACX;AAAA,EAIA,IAAM,EAAA,WAAA;AAAA,EAIN,QAAU,EAAA,OAAA;AAAA,EAIV,KAAO,EAAA;AAAA,IACL,IAAM,EAAA,CAAC,MAAQ,EAAA,MAAA,EAAQ,OAAO,CAAA;AAAA,IAC9B,OAAS,EAAA,KAAA,CAAA;AAAA,GACX;AAAA,EAIA,KAAO,EAAA;AAAA,IACL,IAAM,EAAA,CAAC,MAAQ,EAAA,MAAA,EAAQ,OAAO,CAAA;AAAA,IAC9B,OAAS,EAAA,KAAA,CAAA;AAAA,GACX;AAAA,EAIA,IAAM,EAAA;AAAA,IACJ,IAAM,EAAA,MAAA;AAAA,IACN,OAAS,EAAA,KAAA,CAAA;AAAA,GACX;AACF,CAAC,EAAA;AAEM,MAAM,aAAa,UAAW,CAAA;AAAA,EACnC,GAAG,cAAA;AAAA,EAIH,MAAQ,EAAA,OAAA;AACV,CAAU,EAAA;AAEH,MAAM,UAAa,GAAA;AAAA,EACxB,CAAC,kBAAqB,GAAA,CAAC,GACrB,KAAA,QAAA,CAAS,GAAG,CAAA,IAAK,QAAS,CAAA,GAAG,CAAK,IAAA,SAAA,CAAU,GAAG,CAAA;AAAA,EACjD,CAAC,YAAe,GAAA,CAAC,GACf,KAAA,QAAA,CAAS,GAAG,CAAA,IAAK,QAAS,CAAA,GAAG,CAAK,IAAA,SAAA,CAAU,GAAG,CAAA;AACnD;;;;"}