PromoCursed/node_modules/.cache/babel-loader/017c93eac72ab5ce6207f7dedd44c553d3ef58331a7e72ca2edeec389e9c9865.json
2024-08-20 23:25:37 +04:00

1 line
5.8 KiB
JSON

{"ast":null,"code":"\"use client\";\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { isPresetColor } from '../_util/colors';\nimport { ConfigContext } from '../config-provider';\nimport useStyle from './style/ribbon';\nconst Ribbon = props => {\n const {\n className,\n prefixCls: customizePrefixCls,\n style,\n color,\n children,\n text,\n placement = 'end',\n rootClassName\n } = props;\n const {\n getPrefixCls,\n direction\n } = React.useContext(ConfigContext);\n const prefixCls = getPrefixCls('ribbon', customizePrefixCls);\n const wrapperCls = `${prefixCls}-wrapper`;\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls, wrapperCls);\n const colorInPreset = isPresetColor(color, false);\n const ribbonCls = classNames(prefixCls, `${prefixCls}-placement-${placement}`, {\n [`${prefixCls}-rtl`]: direction === 'rtl',\n [`${prefixCls}-color-${color}`]: colorInPreset\n }, className);\n const colorStyle = {};\n const cornerColorStyle = {};\n if (color && !colorInPreset) {\n colorStyle.background = color;\n cornerColorStyle.color = color;\n }\n return wrapCSSVar( /*#__PURE__*/React.createElement(\"div\", {\n className: classNames(wrapperCls, rootClassName, hashId, cssVarCls)\n }, children, /*#__PURE__*/React.createElement(\"div\", {\n className: classNames(ribbonCls, hashId),\n style: Object.assign(Object.assign({}, colorStyle), style)\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: `${prefixCls}-text`\n }, text), /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-corner`,\n style: cornerColorStyle\n }))));\n};\nif (process.env.NODE_ENV !== 'production') {\n Ribbon.displayName = 'Ribbon';\n}\nexport default Ribbon;","map":{"version":3,"names":["React","classNames","isPresetColor","ConfigContext","useStyle","Ribbon","props","className","prefixCls","customizePrefixCls","style","color","children","text","placement","rootClassName","getPrefixCls","direction","useContext","wrapperCls","wrapCSSVar","hashId","cssVarCls","colorInPreset","ribbonCls","colorStyle","cornerColorStyle","background","createElement","Object","assign","process","env","NODE_ENV","displayName"],"sources":["C:/Users/Аришина)/source/repos/PromoCursed/node_modules/antd/es/badge/Ribbon.js"],"sourcesContent":["\"use client\";\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { isPresetColor } from '../_util/colors';\nimport { ConfigContext } from '../config-provider';\nimport useStyle from './style/ribbon';\nconst Ribbon = props => {\n const {\n className,\n prefixCls: customizePrefixCls,\n style,\n color,\n children,\n text,\n placement = 'end',\n rootClassName\n } = props;\n const {\n getPrefixCls,\n direction\n } = React.useContext(ConfigContext);\n const prefixCls = getPrefixCls('ribbon', customizePrefixCls);\n const wrapperCls = `${prefixCls}-wrapper`;\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls, wrapperCls);\n const colorInPreset = isPresetColor(color, false);\n const ribbonCls = classNames(prefixCls, `${prefixCls}-placement-${placement}`, {\n [`${prefixCls}-rtl`]: direction === 'rtl',\n [`${prefixCls}-color-${color}`]: colorInPreset\n }, className);\n const colorStyle = {};\n const cornerColorStyle = {};\n if (color && !colorInPreset) {\n colorStyle.background = color;\n cornerColorStyle.color = color;\n }\n return wrapCSSVar( /*#__PURE__*/React.createElement(\"div\", {\n className: classNames(wrapperCls, rootClassName, hashId, cssVarCls)\n }, children, /*#__PURE__*/React.createElement(\"div\", {\n className: classNames(ribbonCls, hashId),\n style: Object.assign(Object.assign({}, colorStyle), style)\n }, /*#__PURE__*/React.createElement(\"span\", {\n className: `${prefixCls}-text`\n }, text), /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-corner`,\n style: cornerColorStyle\n }))));\n};\nif (process.env.NODE_ENV !== 'production') {\n Ribbon.displayName = 'Ribbon';\n}\nexport default Ribbon;"],"mappings":"AAAA,YAAY;;AAEZ,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,OAAOC,UAAU,MAAM,YAAY;AACnC,SAASC,aAAa,QAAQ,iBAAiB;AAC/C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