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

1 line
15 KiB
JSON

{"ast":null,"code":"\"use client\";\n\nimport * as React from 'react';\nimport RightOutlined from \"@ant-design/icons/es/icons/RightOutlined\";\nimport classNames from 'classnames';\nimport RcCollapse from 'rc-collapse';\nimport toArray from \"rc-util/es/Children/toArray\";\nimport omit from \"rc-util/es/omit\";\nimport initCollapseMotion from '../_util/motion';\nimport { cloneElement } from '../_util/reactNode';\nimport { devUseWarning } from '../_util/warning';\nimport { ConfigContext } from '../config-provider';\nimport useSize from '../config-provider/hooks/useSize';\nimport CollapsePanel from './CollapsePanel';\nimport useStyle from './style';\nconst Collapse = /*#__PURE__*/React.forwardRef((props, ref) => {\n const {\n getPrefixCls,\n direction,\n collapse\n } = React.useContext(ConfigContext);\n const {\n prefixCls: customizePrefixCls,\n className,\n rootClassName,\n style,\n bordered = true,\n ghost,\n size: customizeSize,\n expandIconPosition = 'start',\n children,\n expandIcon\n } = props;\n const mergedSize = useSize(ctx => {\n var _a;\n return (_a = customizeSize !== null && customizeSize !== void 0 ? customizeSize : ctx) !== null && _a !== void 0 ? _a : 'middle';\n });\n const prefixCls = getPrefixCls('collapse', customizePrefixCls);\n const rootPrefixCls = getPrefixCls();\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls);\n if (process.env.NODE_ENV !== 'production') {\n const warning = devUseWarning('Collapse');\n // Warning if use legacy type `expandIconPosition`\n process.env.NODE_ENV !== \"production\" ? warning(expandIconPosition !== 'left' && expandIconPosition !== 'right', 'deprecated', '`expandIconPosition` with `left` or `right` is deprecated. Please use `start` or `end` instead.') : void 0;\n }\n // Align with logic position\n const mergedExpandIconPosition = React.useMemo(() => {\n if (expandIconPosition === 'left') {\n return 'start';\n }\n return expandIconPosition === 'right' ? 'end' : expandIconPosition;\n }, [expandIconPosition]);\n const mergedExpandIcon = expandIcon !== null && expandIcon !== void 0 ? expandIcon : collapse === null || collapse === void 0 ? void 0 : collapse.expandIcon;\n const renderExpandIcon = React.useCallback(function () {\n let panelProps = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n const icon = typeof mergedExpandIcon === 'function' ? mergedExpandIcon(panelProps) : ( /*#__PURE__*/React.createElement(RightOutlined, {\n rotate: panelProps.isActive ? 90 : undefined,\n \"aria-label\": panelProps.isActive ? 'expanded' : 'collapsed'\n }));\n return cloneElement(icon, () => {\n var _a;\n return {\n className: classNames((_a = icon === null || icon === void 0 ? void 0 : icon.props) === null || _a === void 0 ? void 0 : _a.className, `${prefixCls}-arrow`)\n };\n });\n }, [mergedExpandIcon, prefixCls]);\n const collapseClassName = classNames(`${prefixCls}-icon-position-${mergedExpandIconPosition}`, {\n [`${prefixCls}-borderless`]: !bordered,\n [`${prefixCls}-rtl`]: direction === 'rtl',\n [`${prefixCls}-ghost`]: !!ghost,\n [`${prefixCls}-${mergedSize}`]: mergedSize !== 'middle'\n }, collapse === null || collapse === void 0 ? void 0 : collapse.className, className, rootClassName, hashId, cssVarCls);\n const openMotion = Object.assign(Object.assign({}, initCollapseMotion(rootPrefixCls)), {\n motionAppear: false,\n leavedClassName: `${prefixCls}-content-hidden`\n });\n const items = React.useMemo(() => children ? toArray(children).map((child, index) => {\n var _a, _b;\n if ((_a = child.props) === null || _a === void 0 ? void 0 : _a.disabled) {\n const key = (_b = child.key) !== null && _b !== void 0 ? _b : String(index);\n const {\n disabled,\n collapsible\n } = child.props;\n const childProps = Object.assign(Object.assign({}, omit(child.props, ['disabled'])), {\n key,\n collapsible: collapsible !== null && collapsible !== void 0 ? collapsible : disabled ? 'disabled' : undefined\n });\n return cloneElement(child, childProps);\n }\n return child;\n }) : null, [children]);\n return wrapCSSVar( /*#__PURE__*/\n // @ts-ignore\n React.createElement(RcCollapse, Object.assign({\n ref: ref,\n openMotion: openMotion\n }, omit(props, ['rootClassName']), {\n expandIcon: renderExpandIcon,\n prefixCls: prefixCls,\n className: collapseClassName,\n style: Object.assign(Object.assign({}, collapse === null || collapse === void 0 ? void 0 : collapse.style), style)\n }), items));\n});\nif (process.env.NODE_ENV !== 'production') {\n Collapse.displayName = 'Collapse';\n}\nexport default Object.assign(Collapse, {\n Panel: CollapsePanel\n});","map":{"version":3,"names":["React","RightOutlined","classNames","RcCollapse","toArray","omit","initCollapseMotion","cloneElement","devUseWarning","ConfigContext","useSize","CollapsePanel","useStyle","Collapse","forwardRef","props","ref","getPrefixCls","direction","collapse","useContext","prefixCls","customizePrefixCls","className","rootClassName","style","bordered","ghost","size","customizeSize","expandIconPosition","children","expandIcon","mergedSize","ctx","_a","rootPrefixCls","wrapCSSVar","hashId","cssVarCls","process","env","NODE_ENV","warning","mergedExpandIconPosition","useMemo","mergedExpandIcon","renderExpandIcon","useCallback","panelProps","arguments","length","undefined","icon","createElement","rotate","isActive","collapseClassName","openMotion","Object","assign","motionAppear","leavedClassName","items","map","child","index","_b","disabled","key","String","collapsible","childProps","displayName","Panel"],"sources":["C:/Users/Аришина)/Desktop/promo/node_modules/antd/es/collapse/Collapse.js"],"sourcesContent":["\"use client\";\n\nimport * as React from 'react';\nimport RightOutlined from \"@ant-design/icons/es/icons/RightOutlined\";\nimport classNames from 'classnames';\nimport RcCollapse from 'rc-collapse';\nimport toArray from \"rc-util/es/Children/toArray\";\nimport omit from \"rc-util/es/omit\";\nimport initCollapseMotion from '../_util/motion';\nimport { cloneElement } from '../_util/reactNode';\nimport { devUseWarning } from '../_util/warning';\nimport { ConfigContext } from '../config-provider';\nimport useSize from '../config-provider/hooks/useSize';\nimport CollapsePanel from './CollapsePanel';\nimport useStyle from './style';\nconst Collapse = /*#__PURE__*/React.forwardRef((props, ref) => {\n const {\n getPrefixCls,\n direction,\n collapse\n } = React.useContext(ConfigContext);\n const {\n prefixCls: customizePrefixCls,\n className,\n rootClassName,\n style,\n bordered = true,\n ghost,\n size: customizeSize,\n expandIconPosition = 'start',\n children,\n expandIcon\n } = props;\n const mergedSize = useSize(ctx => {\n var _a;\n return (_a = customizeSize !== null && customizeSize !== void 0 ? customizeSize : ctx) !== null && _a !== void 0 ? _a : 'middle';\n });\n const prefixCls = getPrefixCls('collapse', customizePrefixCls);\n const rootPrefixCls = getPrefixCls();\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls);\n if (process.env.NODE_ENV !== 'production') {\n const warning = devUseWarning('Collapse');\n // Warning if use legacy type `expandIconPosition`\n process.env.NODE_ENV !== \"production\" ? warning(expandIconPosition !== 'left' && expandIconPosition !== 'right', 'deprecated', '`expandIconPosition` with `left` or `right` is deprecated. Please use `start` or `end` instead.') : void 0;\n }\n // Align with logic position\n const mergedExpandIconPosition = React.useMemo(() => {\n if (expandIconPosition === 'left') {\n return 'start';\n }\n return expandIconPosition === 'right' ? 'end' : expandIconPosition;\n }, [expandIconPosition]);\n const mergedExpandIcon = expandIcon !== null && expandIcon !== void 0 ? expandIcon : collapse === null || collapse === void 0 ? void 0 : collapse.expandIcon;\n const renderExpandIcon = React.useCallback(function () {\n let panelProps = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n const icon = typeof mergedExpandIcon === 'function' ? mergedExpandIcon(panelProps) : ( /*#__PURE__*/React.createElement(RightOutlined, {\n rotate: panelProps.isActive ? 90 : undefined,\n \"aria-label\": panelProps.isActive ? 'expanded' : 'collapsed'\n }));\n return cloneElement(icon, () => {\n var _a;\n return {\n className: classNames((_a = icon === null || icon === void 0 ? void 0 : icon.props) === null || _a === void 0 ? void 0 : _a.className, `${prefixCls}-arrow`)\n };\n });\n }, [mergedExpandIcon, prefixCls]);\n const collapseClassName = classNames(`${prefixCls}-icon-position-${mergedExpandIconPosition}`, {\n [`${prefixCls}-borderless`]: !bordered,\n [`${prefixCls}-rtl`]: direction === 'rtl',\n [`${prefixCls}-ghost`]: !!ghost,\n [`${prefixCls}-${mergedSize}`]: mergedSize !== 'middle'\n }, collapse === null || collapse === void 0 ? void 0 : collapse.className, className, rootClassName, hashId, cssVarCls);\n const openMotion = Object.assign(Object.assign({}, initCollapseMotion(rootPrefixCls)), {\n motionAppear: false,\n leavedClassName: `${prefixCls}-content-hidden`\n });\n const items = React.useMemo(() => children ? toArray(children).map((child, index) => {\n var _a, _b;\n if ((_a = child.props) === null || _a === void 0 ? void 0 : _a.disabled) {\n const key = (_b = child.key) !== null && _b !== void 0 ? _b : String(index);\n const {\n disabled,\n collapsible\n } = child.props;\n const childProps = Object.assign(Object.assign({}, omit(child.props, ['disabled'])), {\n key,\n collapsible: collapsible !== null && collapsible !== void 0 ? collapsible : disabled ? 'disabled' : undefined\n });\n return cloneElement(child, childProps);\n }\n return child;\n }) : null, [children]);\n return wrapCSSVar(\n /*#__PURE__*/\n // @ts-ignore\n React.createElement(RcCollapse, Object.assign({\n ref: ref,\n openMotion: openMotion\n }, omit(props, ['rootClassName']), {\n expandIcon: renderExpandIcon,\n prefixCls: prefixCls,\n className: collapseClassName,\n style: Object.assign(Object.assign({}, collapse === null || collapse === void 0 ? void 0 : collapse.style), style)\n }), items));\n});\nif (process.env.NODE_ENV !== 'production') {\n Collapse.displayName = 'Collapse';\n}\nexport default Object.assign(Collapse, {\n Panel: CollapsePanel\n});"],"mappings":"AAAA,YAAY;;AAEZ,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,OAAOC,aAAa,MAAM,0CAA0C;AACpE,OAAOC,UAAU,MAAM,YAAY;AACnC,OAAOC,UAAU,MAAM,aAAa;AACpC,OAAOC,OAAO,MAAM,6BAA6B;AACjD,OAAOC,IAAI,MAAM,iBAAiB;AAClC,OAAOC,kBAAkB,MAAM,iBAAiB;AAChD,SAASC,YAAY,QAAQ,oBAAoB;AACjD,SAASC,aAAa,QAAQ,kBAAkB;AAChD,SAASC,aAAa,QAAQ,oBAAoB;AAClD,OAAOC,OAAO,MAAM,kCAAkC;AACtD,OAAOC,aAAa,MAAM,iBAAiB;AAC3C,OAAOC,QAAQ,MAAM,SAAS;AAC9B,MAAMC,QAAQ,GAAG,aAAab,KAAK,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