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

1 line
7.6 KiB
JSON
Raw Normal View History

2024-08-20 23:25:37 +04:00
{"ast":null,"code":"\"use client\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\nimport * as React from 'react';\nimport StarFilled from \"@ant-design/icons/es/icons/StarFilled\";\nimport classNames from 'classnames';\nimport RcRate from 'rc-rate';\nimport { ConfigContext } from '../config-provider';\nimport Tooltip from '../tooltip';\nimport useStyle from './style';\nconst Rate = /*#__PURE__*/React.forwardRef((props, ref) => {\n const {\n prefixCls,\n className,\n rootClassName,\n style,\n tooltips,\n character = /*#__PURE__*/React.createElement(StarFilled, null)\n } = props,\n rest = __rest(props, [\"prefixCls\", \"className\", \"rootClassName\", \"style\", \"tooltips\", \"character\"]);\n const characterRender = (node, _ref) => {\n let {\n index\n } = _ref;\n if (!tooltips) {\n return node;\n }\n return /*#__PURE__*/React.createElement(Tooltip, {\n title: tooltips[index]\n }, node);\n };\n const {\n getPrefixCls,\n direction,\n rate\n } = React.useContext(ConfigContext);\n const ratePrefixCls = getPrefixCls('rate', prefixCls);\n // Style\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(ratePrefixCls);\n const mergedStyle = Object.assign(Object.assign({}, rate === null || rate === void 0 ? void 0 : rate.style), style);\n return wrapCSSVar( /*#__PURE__*/React.createElement(RcRate, Object.assign({\n ref: ref,\n character: character,\n characterRender: characterRender\n }, rest, {\n className: classNames(className, rootClassName, hashId, cssVarCls, rate === null || rate === void 0 ? void 0 : rate.className),\n style: mergedStyle,\n prefixCls: ratePrefixCls,\n direction: direction\n })));\n});\nif (process.env.NODE_ENV !== 'production') {\n Rate.displayName = 'Rate';\n}\nexport default Rate;","map":{"version":3,"names":["__rest","s","e","t","p","Object","prototype","hasOwnProperty","call","indexOf","getOwnPropertySymbols","i","length","propertyIsEnumerable","React","StarFilled","classNames","RcRate","ConfigContext","Tooltip","useStyle","Rate","forwardRef","props","ref","prefixCls","className","rootClassName","style","tooltips","character","createElement","rest","characterRender","node","_ref","index","title","getPrefixCls","direction","rate","useContext","ratePrefixCls","wrapCSSVar","hashId","cssVarCls","mergedStyle","assign","process","env","NODE_ENV","displayName"],"sources":["C:/Users/Аришина)/source/repos/PromoCursed/node_modules/antd/es/rate/index.js"],"sourcesContent":["\"use client\";\n\nvar __rest = this && this.__rest || function (s, e) {\n var t = {};\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n }\n return t;\n};\nimport * as React from 'react';\nimport StarFilled from \"@ant-design/icons/es/icons/StarFilled\";\nimport classNames from 'classnames';\nimport RcRate from 'rc-rate';\nimport { ConfigContext } from '../config-provider';\nimport Tooltip from '../tooltip';\nimport useStyle from './style';\nconst Rate = /*#__PURE__*/React.forwardRef((props, ref) => {\n const {\n prefixCls,\n className,\n rootClassName,\n style,\n tooltips,\n character = /*#__PURE__*/React.createElement(StarFilled, null)\n } = props,\n rest = __rest(props, [\"prefixCls\", \"className\", \"rootClassName\", \"style\", \"tooltips\", \"character\"]);\n const characterRender = (node, _