UNPKG

element-plus

Version:

A Component Library for Vue 3

1 lines 2.72 kB
{"version":3,"file":"steps.mjs","sources":["../../../../../../packages/components/steps/src/steps.ts"],"sourcesContent":["import { CHANGE_EVENT } from '@element-plus/constants'\nimport { buildProps, isNumber } from '@element-plus/utils'\n\nimport type Steps from './steps.vue'\nimport type { ExtractPropTypes, ExtractPublicPropTypes } from 'vue'\n\nexport const stepsProps = buildProps({\n /**\n * @description the spacing of each step, will be responsive if omitted. Supports percentage.\n */\n space: {\n type: [Number, String],\n default: '',\n },\n /**\n * @description current activation step\n */\n active: {\n type: Number,\n default: 0,\n },\n /**\n * @description display direction\n */\n direction: {\n type: String,\n default: 'horizontal',\n values: ['horizontal', 'vertical'],\n },\n /**\n * @description center title and description\n */\n alignCenter: {\n type: Boolean,\n },\n /**\n * @description whether to apply simple theme\n */\n simple: {\n type: Boolean,\n },\n /**\n * @description status of end step\n */\n finishStatus: {\n type: String,\n values: ['wait', 'process', 'finish', 'error', 'success'],\n default: 'finish',\n },\n /**\n * @description status of current step\n */\n processStatus: {\n type: String,\n values: ['wait', 'process', 'finish', 'error', 'success'],\n default: 'process',\n },\n} as const)\nexport type StepsProps = ExtractPropTypes<typeof stepsProps>\nexport type StepsPropsPublic = ExtractPublicPropTypes<typeof stepsProps>\n\nexport const stepsEmits = {\n [CHANGE_EVENT]: (newVal: number, oldVal: number) =>\n [newVal, oldVal].every(isNumber),\n}\nexport type StepsEmits = typeof stepsEmits\n\nexport type StepsInstance = InstanceType<typeof Steps> & unknown\n"],"names":[],"mappings":";;;;AAMO,MAAM,aAAa,UAAW,CAAA;AAAA,EAInC,KAAO,EAAA;AAAA,IACL,IAAA,EAAM,CAAC,MAAA,EAAQ,MAAM,CAAA;AAAA,IACrB,OAAS,EAAA,EAAA;AAAA,GACX;AAAA,EAIA,MAAQ,EAAA;AAAA,IACN,IAAM,EAAA,MAAA;AAAA,IACN,OAAS,EAAA,CAAA;AAAA,GACX;AAAA,EAIA,SAAW,EAAA;AAAA,IACT,IAAM,EAAA,MAAA;AAAA,IACN,OAAS,EAAA,YAAA;AAAA,IACT,MAAA,EAAQ,CAAC,YAAA,EAAc,UAAU,CAAA;AAAA,GACnC;AAAA,EAIA,WAAa,EAAA;AAAA,IACX,IAAM,EAAA,OAAA;AAAA,GACR;AAAA,EAIA,MAAQ,EAAA;AAAA,IACN,IAAM,EAAA,OAAA;AAAA,GACR;AAAA,EAIA,YAAc,EAAA;AAAA,IACZ,IAAM,EAAA,MAAA;AAAA,IACN,QAAQ,CAAC,MAAA,EAAQ,SAAW,EAAA,QAAA,EAAU,SAAS,SAAS,CAAA;AAAA,IACxD,OAAS,EAAA,QAAA;AAAA,GACX;AAAA,EAIA,aAAe,EAAA;AAAA,IACb,IAAM,EAAA,MAAA;AAAA,IACN,QAAQ,CAAC,MAAA,EAAQ,SAAW,EAAA,QAAA,EAAU,SAAS,SAAS,CAAA;AAAA,IACxD,OAAS,EAAA,SAAA;AAAA,GACX;AACF,CAAU,EAAA;AAIH,MAAM,UAAa,GAAA;AAAA,EACxB,CAAC,YAAe,GAAA,CAAC,MAAgB,EAAA,MAAA,KAC/B,CAAC,MAAQ,EAAA,MAAM,CAAE,CAAA,KAAA,CAAM,QAAQ,CAAA;AACnC;;;;"}