PromoCursed/node_modules/.cache/babel-loader/dbc38a93d043226b236248e3ca65f77df7775351259887f25e96785e8a7db1ac.json

1 line
34 KiB
JSON
Raw Normal View History

2024-08-20 23:25:37 +04:00
{"ast":null,"code":"import { unit } from '@ant-design/cssinjs';\nimport { genFocusOutline, resetComponent } from '../../style';\nimport { genStyleHooks, mergeToken } from '../../theme/internal';\nimport genStepsCustomIconStyle from './custom-icon';\nimport genStepsHorizontalStyle from './horizontal';\nimport genStepsInlineStyle from './inline';\nimport genStepsLabelPlacementStyle from './label-placement';\nimport genStepsNavStyle from './nav';\nimport genStepsProgressStyle from './progress';\nimport genStepsProgressDotStyle from './progress-dot';\nimport genStepsRTLStyle from './rtl';\nimport genStepsSmallStyle from './small';\nimport genStepsVerticalStyle from './vertical';\nconst STEP_ITEM_STATUS_WAIT = 'wait';\nconst STEP_ITEM_STATUS_PROCESS = 'process';\nconst STEP_ITEM_STATUS_FINISH = 'finish';\nconst STEP_ITEM_STATUS_ERROR = 'error';\nconst genStepsItemStatusStyle = (status, token) => {\n const prefix = `${token.componentCls}-item`;\n const iconColorKey = `${status}IconColor`;\n const titleColorKey = `${status}TitleColor`;\n const descriptionColorKey = `${status}DescriptionColor`;\n const tailColorKey = `${status}TailColor`;\n const iconBgColorKey = `${status}IconBgColor`;\n const iconBorderColorKey = `${status}IconBorderColor`;\n const dotColorKey = `${status}DotColor`;\n return {\n [`${prefix}-${status} ${prefix}-icon`]: {\n backgroundColor: token[iconBgColorKey],\n borderColor: token[iconBorderColorKey],\n [`> ${token.componentCls}-icon`]: {\n color: token[iconColorKey],\n [`${token.componentCls}-icon-dot`]: {\n background: token[dotColorKey]\n }\n }\n },\n [`${prefix}-${status}${prefix}-custom ${prefix}-icon`]: {\n [`> ${token.componentCls}-icon`]: {\n color: token[dotColorKey]\n }\n },\n [`${prefix}-${status} > ${prefix}-container > ${prefix}-content > ${prefix}-title`]: {\n color: token[titleColorKey],\n '&::after': {\n backgroundColor: token[tailColorKey]\n }\n },\n [`${prefix}-${status} > ${prefix}-container > ${prefix}-content > ${prefix}-description`]: {\n color: token[descriptionColorKey]\n },\n [`${prefix}-${status} > ${prefix}-container > ${prefix}-tail::after`]: {\n backgroundColor: token[tailColorKey]\n }\n };\n};\nconst genStepsItemStyle = token => {\n const {\n componentCls,\n motionDurationSlow\n } = token;\n const stepsItemCls = `${componentCls}-item`; // .ant-steps-item\n const stepItemIconCls = `${stepsItemCls}-icon`;\n return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({\n [stepsItemCls]: {\n position: 'relative',\n display: 'inline-block',\n flex: 1,\n overflow: 'hidden',\n verticalAlign: 'top',\n '&:last-child': {\n flex: 'none',\n [`> ${stepsItemCls}-container > ${stepsItemCls}-tail, > ${stepsItemCls}-container > ${stepsItemCls}-content > ${stepsItemCls}-title::after`]: {\n display: 'none'\n }\n }\n },\n [`${stepsItemCls}-container`]: {\n outline: 'none',\n '&:focus-visible': {\n [stepItemIconCls]: Object.assign({}, genFocusOutline(token))\n }\n },\n [`${stepItemIconCls}, ${stepsItemCls}-content`]: {\n display: 'inline-block',\n verticalAlign: 'top'\n },\n [stepItemIconCls]: {\n width: token.iconSize,\n height: token.iconSize,\n marginTop: 0,\n marginBottom: 0,\n marginInlineStart: 0,\n marginInlineEnd: token.marginXS,\n fontSize: token.iconFontSize,\n fontFamily: token.fontFamily,\n lineHeight: unit(token.iconSize),\n textAlign: 'center',\n borderRadius: token.iconSize,\n border: `${unit(token.lineWidth)} ${token.lineType} transparent`,\n transition: `background-color ${motionDurationSlow}, border-color ${motionDurationSlow}`,\n [`${componentCls}-icon`]: {\n position: 'relative',\n top: token.iconTop,\n color: token.colorPrimary,\n lineHeight: 1\n }\n },\n [`${stepsItemCls}-tail