{"version":3,"file":"props.mjs","sources":["../../../../../../packages/components/button/src/props.ts"],"sourcesContent":["import type { MouseEventHandler, SizeType } from '@antdv/types';\nimport type { ExtractPropTypes, PropType } from 'vue';\nimport type { ButtonHTMLType, ButtonShape, ButtonType } from './interface';\nimport { eventType, PropTypes } from '@antdv/utils';\n\nexport function buttonProps() {\n  return {\n    prefixCls: String,\n    type: String as PropType<ButtonType>,\n    htmlType: { type: String as PropType<ButtonHTMLType>, default: 'button' },\n    shape: { type: String as PropType<ButtonShape> },\n    size: {\n      type: String as PropType<SizeType | undefined>,\n    },\n    loading: {\n      type: [Boolean, Object] as PropType<boolean | { delay?: number }>,\n      default: (): boolean | { delay?: number } => false,\n    },\n    disabled: { type: Boolean, default: undefined },\n    ghost: { type: Boolean, default: undefined },\n    block: { type: Boolean, default: undefined },\n    danger: { type: Boolean, default: undefined },\n    success: { type: Boolean, default: undefined },\n    warning: { type: Boolean, default: undefined },\n    icon: PropTypes.any,\n    href: String,\n    target: String,\n    title: String,\n    onClick: eventType<MouseEventHandler>(),\n    onMousedown: eventType<MouseEventHandler>(),\n  };\n}\n\nexport function buttonGroupProps() {\n  return {\n    prefixCls: String,\n    size: {\n      type: String as PropType<SizeType>,\n    },\n  };\n}\n\nexport type ButtonProps = Partial<ExtractPropTypes<ReturnType<typeof buttonProps>>>;\n\nexport type ButtonGroupProps = Partial<ExtractPropTypes<ReturnType<typeof buttonGroupProps>>>;\n"],"names":[],"mappings":";;;;AAKO,SAAS,WAAc,GAAA;AAC5B,EAAO,OAAA;AAAA,IACL,SAAW,EAAA,MAAA;AAAA,IACX,IAAM,EAAA,MAAA;AAAA,IACN,QAAU,EAAA,EAAE,IAAM,EAAA,MAAA,EAAoC,SAAS,QAAS,EAAA;AAAA,IACxE,KAAA,EAAO,EAAE,IAAA,EAAM,MAAgC,EAAA;AAAA,IAC/C,IAAM,EAAA;AAAA,MACJ,IAAM,EAAA,MAAA;AAAA,KACR;AAAA,IACA,OAAS,EAAA;AAAA,MAC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