1 line
7.0 KiB
JSON
1 line
7.0 KiB
JSON
{"ast":null,"code":"import { genStyleHooks, mergeToken } from '../../theme/internal';\nimport { alignItemsValues, flexWrapValues, justifyContentValues } from '../utils';\nconst genFlexStyle = token => {\n const {\n componentCls\n } = token;\n return {\n [componentCls]: {\n display: 'flex',\n '&-vertical': {\n flexDirection: 'column'\n },\n '&-rtl': {\n direction: 'rtl'\n },\n '&:empty': {\n display: 'none'\n }\n }\n };\n};\nconst genFlexGapStyle = token => {\n const {\n componentCls\n } = token;\n return {\n [componentCls]: {\n '&-gap-small': {\n gap: token.flexGapSM\n },\n '&-gap-middle': {\n gap: token.flexGap\n },\n '&-gap-large': {\n gap: token.flexGapLG\n }\n }\n };\n};\nconst genFlexWrapStyle = token => {\n const {\n componentCls\n } = token;\n const wrapStyle = {};\n flexWrapValues.forEach(value => {\n wrapStyle[`${componentCls}-wrap-${value}`] = {\n flexWrap: value\n };\n });\n return wrapStyle;\n};\nconst genAlignItemsStyle = token => {\n const {\n componentCls\n } = token;\n const alignStyle = {};\n alignItemsValues.forEach(value => {\n alignStyle[`${componentCls}-align-${value}`] = {\n alignItems: value\n };\n });\n return alignStyle;\n};\nconst genJustifyContentStyle = token => {\n const {\n componentCls\n } = token;\n const justifyStyle = {};\n justifyContentValues.forEach(value => {\n justifyStyle[`${componentCls}-justify-${value}`] = {\n justifyContent: value\n };\n });\n return justifyStyle;\n};\nexport const prepareComponentToken = () => ({});\nexport default genStyleHooks('Flex', token => {\n const {\n paddingXS,\n padding,\n paddingLG\n } = token;\n const flexToken = mergeToken(token, {\n flexGapSM: paddingXS,\n flexGap: padding,\n flexGapLG: paddingLG\n });\n return [genFlexStyle(flexToken), genFlexGapStyle(flexToken), genFlexWrapStyle(flexToken), genAlignItemsStyle(flexToken), genJustifyContentStyle(flexToken)];\n}, prepareComponentToken, {\n // Flex component don't apply extra font style\n // https://github.com/ant-design/ant-design/issues/46403\n resetStyle: false\n});","map":{"version":3,"names":["genStyleHooks","mergeToken","alignItemsValues","flexWrapValues","justifyContentValues","genFlexStyle","token","componentCls","display","flexDirection","direction","genFlexGapStyle","gap","flexGapSM","flexGap","flexGapLG","genFlexWrapStyle","wrapStyle","forEach","value","flexWrap","genAlignItemsStyle","alignStyle","alignItems","genJustifyContentStyle","justifyStyle","justifyContent","prepareComponentToken","paddingXS","padding","paddingLG","flexToken","resetStyle"],"sources":["C:/Users/Аришина)/source/repos/PromoCursed/node_modules/antd/es/flex/style/index.js"],"sourcesContent":["import { genStyleHooks, mergeToken } from '../../theme/internal';\nimport { alignItemsValues, flexWrapValues, justifyContentValues } from '../utils';\nconst genFlexStyle = token => {\n const {\n componentCls\n } = token;\n return {\n [componentCls]: {\n display: 'flex',\n '&-vertical': {\n flexDirection: 'column'\n },\n '&-rtl': {\n direction: 'rtl'\n },\n '&:empty': {\n display: 'none'\n }\n }\n };\n};\nconst genFlexGapStyle = token => {\n const {\n componentCls\n } = token;\n return {\n [componentCls]: {\n '&-gap-small': {\n gap: token.flexGapSM\n },\n '&-gap-middle': {\n gap: token.flexGap\n },\n '&-gap-large': {\n gap: token.flexGapLG\n }\n }\n };\n};\nconst genFlexWrapStyle = token => {\n const {\n componentCls\n } = token;\n const wrapStyle = {};\n flexWrapValues.forEach(value => {\n wrapStyle[`${componentCls}-wrap-${value}`] = {\n flexWrap: value\n };\n });\n return wrapStyle;\n};\nconst genAlignItemsStyle = token => {\n const {\n componentCls\n } = token;\n const alignStyle = {};\n alignItemsValues.forEach(value => {\n alignStyle[`${componentCls}-align-${value}`] = {\n alignItems: value\n };\n });\n return alignStyle;\n};\nconst genJustifyContentStyle = token => {\n const {\n componentCls\n } = token;\n const justifyStyle = {};\n justifyContentValues.forEach(value => {\n justifyStyle[`${componentCls}-justify-${value}`] = {\n justifyContent: value\n };\n });\n return justifyStyle;\n};\nexport const prepareComponentToken = () => ({});\nexport default genStyleHooks('Flex', token => {\n const {\n paddingXS,\n padding,\n paddingLG\n } = token;\n const flexToken = mergeToken(token, {\n flexGapSM: paddingXS,\n flexGap: padding,\n flexGapLG: paddingLG\n });\n return [genFlexStyle(flexToken), genFlexGapStyle(flexToken), genFlexWrapStyle(flexToken), genAlignItemsStyle(flexToken), genJustifyContentStyle(flexToken)];\n}, prepareComponentToken, {\n // Flex component don't apply extra font style\n // https://github.com/ant-design/ant-design/issues/46403\n resetStyle: false\n});"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ,sBAAsB;AAChE,SAASC,gBAAgB,EAAEC,cAAc,EAAEC,oBAAoB,QAAQ,UAAU;AACjF,MAAMC,YAAY,GAAGC,KAAK,IAAI;EAC5B,MAAM;IACJC;EACF,CAAC,GAAGD,KAAK;EACT,OAAO;IACL,CAACC,YAAY,GAAG;MACdC,OAAO,EAAE,MAAM;MACf,YAAY,EAAE;QACZC,aAAa,EAAE;MACjB,CAAC;MACD,OAAO,EAAE;QACPC,SAAS,EAAE;MACb,CAAC;MACD,SAAS,EAAE;QACTF,OAAO,EAAE;MACX;IACF;EACF,CAAC;AACH,CAAC;AACD,MAAMG,eAAe,GAAGL,KAAK,IAAI;EAC/B,MAAM;IACJC;EACF,CAAC,GAAGD,KAAK;EACT,OAAO;IACL,CAACC,YAAY,GAAG;MACd,aAAa,EAAE;QACbK,GAAG,EAAEN,KAAK,CAACO;MACb,CAAC;MACD,cAAc,EAAE;QACdD,GAAG,EAAEN,KAAK,CAACQ;MACb,CAAC;MACD,aAAa,EAAE;QACbF,GAAG,EAAEN,KAAK,CAACS;MACb;IACF;EACF,CAAC;AACH,CAAC;AACD,MAAMC,gBAAgB,GAAGV,KAAK,IAAI;EAChC,MAAM;IACJC;EACF,CAAC,GAAGD,KAAK;EACT,MAAMW,SAAS,GAAG,CAAC,CAAC;EACpBd,cAAc,CAACe,OAAO,CAACC,KAAK,IAAI;IAC9BF,SAAS,CAAC,GAAGV,YAAY,SAASY,KAAK,EAAE,CAAC,GAAG;MAC3CC,QAAQ,EAAED;IACZ,CAAC;EACH,CAAC,CAAC;EACF,OAAO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