PromoCursed/node_modules/.cache/babel-loader/3a2a6bf3a8e2ad1a3dc90457fac6e56e0306d9cf5831008792ea748c8f92dbc8.json

1 line
9.1 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};\n/* eslint-disable react/jsx-no-useless-fragment */\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { Panel } from 'rc-dialog';\nimport { withPureRenderTheme } from '../_util/PurePanel';\nimport { ConfigContext } from '../config-provider';\nimport useCSSVarCls from '../config-provider/hooks/useCSSVarCls';\nimport { ConfirmContent } from './ConfirmDialog';\nimport { Footer, renderCloseIcon } from './shared';\nimport useStyle from './style';\nconst PurePanel = props => {\n const {\n prefixCls: customizePrefixCls,\n className,\n closeIcon,\n closable,\n type,\n title,\n children,\n footer\n } = props,\n restProps = __rest(props, [\"prefixCls\", \"className\", \"closeIcon\", \"closable\", \"type\", \"title\", \"children\", \"footer\"]);\n const {\n getPrefixCls\n } = React.useContext(ConfigContext);\n const rootPrefixCls = getPrefixCls();\n const prefixCls = customizePrefixCls || getPrefixCls('modal');\n const rootCls = useCSSVarCls(rootPrefixCls);\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls, rootCls);\n const confirmPrefixCls = `${prefixCls}-confirm`;\n // Choose target props by confirm mark\n let additionalProps = {};\n if (type) {\n additionalProps = {\n closable: closable !== null && closable !== void 0 ? closable : false,\n title: '',\n footer: '',\n children: ( /*#__PURE__*/React.createElement(ConfirmContent, Object.assign({}, props, {\n prefixCls: prefixCls,\n confirmPrefixCls: confirmPrefixCls,\n rootPrefixCls: rootPrefixCls,\n content: children\n })))\n };\n } else {\n additionalProps = {\n closable: closable !== null && closable !== void 0 ? closable : true,\n title,\n footer: footer !== null && /*#__PURE__*/React.createElement(Footer, Object.assign({}, props)),\n children\n };\n }\n return wrapCSSVar( /*#__PURE__*/React.createElement(Panel, Object.assign({\n prefixCls: prefixCls,\n className: classNames(hashId, `${prefixCls}-pure-panel`, type && confirmPrefixCls, type && `${confirmPrefixCls}-${type}`, className, cssVarCls, rootCls)\n }, restProps, {\n closeIcon: renderCloseIcon(prefixCls, closeIcon),\n closable: closable\n }, additionalProps)));\n};\nexport default withPureRenderTheme(PurePanel);","map":{"version":3,"names":["__rest","s","e","t","p","Object","prototype","hasOwnProperty","call","indexOf","getOwnPropertySymbols","i","length","propertyIsEnumerable","React","classNames","Panel","withPureRenderTheme","ConfigContext","useCSSVarCls","ConfirmContent","Footer","renderCloseIcon","useStyle","PurePanel","props","prefixCls","customizePrefixCls","className","closeIcon","closable","type","title","children","footer","restProps","getPrefixCls","useContext","rootPrefixCls","rootCls","wrapCSSVar","hashId","cssVarCls","confirmPrefixCls","additionalProps","createElement","assign","content"],"sources":["C:/Users/Аришина)/Desktop/promo/node_modules/antd/es/modal/PurePanel.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};\n/* eslint-disable react/jsx-no-useless-fragment */\nimport * as React from 'react';