element-plus
Version:
A Component Library for Vue 3
1 lines • 1.39 kB
Source Map (JSON)
{"version":3,"file":"icon.mjs","names":[],"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"],"mappings":";;;;AAgBA,MAAa,eAAe,eAAmC;CAC7D;CACA;CACA;CACD,CAAC;AAEF,MAAa,kBAAkB,EAC7B,OACD;AAED,MAAa,iBAAiB;CAC5B;CACA;CACA;CACA;CACA;CACD;AAED,MAAa,oBAAoB;CAC/B,SAAS;CACT,SAAS;CACT,SAAS;CACT,OAAO;CACP,MAAM;CACP;AAED,MAAa,wBAAwB;CACnC,YAAY;CACZ,SAAS;CACT,OAAO;CACR"}