element-plus
Version:
A Component Library for Vue 3
1 lines • 1.6 kB
Source Map (JSON)
{"version":3,"file":"icon.mjs","sources":["../../../../../packages/utils/vue/icon.ts"],"sourcesContent":["import {\n CircleCheck,\n CircleClose,\n CircleCloseFilled,\n Close,\n InfoFilled,\n Loading,\n SuccessFilled,\n WarningFilled,\n} from '@element-plus/icons-vue'\nimport { definePropType } from './props'\n\nimport type { Component } from 'vue'\n\nexport type IconPropType = string | Component\n\nexport const iconPropType = definePropType<string | Component>([\n String,\n Object,\n Function,\n])\n\nexport const CloseComponents = {\n Close,\n}\n\nexport const TypeComponents = {\n Close,\n SuccessFilled,\n InfoFilled,\n WarningFilled,\n CircleCloseFilled,\n}\n\nexport const TypeComponentsMap = {\n primary: InfoFilled,\n success: SuccessFilled,\n warning: WarningFilled,\n error: CircleCloseFilled,\n info: InfoFilled,\n}\n\nexport const ValidateComponentsMap = {\n validating: Loading,\n success: CircleCheck,\n error: CircleClose,\n}\n\n// All icon components have the same type, so we can pick any one of them to get the type\nexport type IconComponent = typeof Loading\n"],"names":[],"mappings":";;;AAgBO,MAAM,eAAe,cAAA,CAAmC;AAAA,EAC7D,MAAA;AAAA,EACA,MAAA;AAAA,EACA;AACF,CAAC;AAEM,MAAM,eAAA,GAAkB;AAAA,EAC7B;AACF;AAEO,MAAM,cAAA,GAAiB;AAAA,EAC5B,KAAA;AAAA,EACA,aAAA;AAAA,EACA,UAAA;AAAA,EACA,aAAA;AAAA,EACA;AACF;AAEO,MAAM,iBAAA,GAAoB;AAAA,EAC/B,OAAA,EAAS,UAAA;AAAA,EACT,OAAA,EAAS,aAAA;AAAA,EACT,OAAA,EAAS,aAAA;AAAA,EACT,KAAA,EAAO,iBAAA;AAAA,EACP,IAAA,EAAM;AACR;AAEO,MAAM,qBAAA,GAAwB;AAAA,EACnC,UAAA,EAAY,OAAA;AAAA,EACZ,OAAA,EAAS,WAAA;AAAA,EACT,KAAA,EAAO;AACT;;;;"}