1 line
14 KiB
JSON
1 line
14 KiB
JSON
{"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/no-array-index-key */\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { matchScreen } from '../_util/responsiveObserver';\nimport { ConfigContext } from '../config-provider';\nimport useSize from '../config-provider/hooks/useSize';\nimport useBreakpoint from '../grid/hooks/useBreakpoint';\nimport DEFAULT_COLUMN_MAP from './constant';\nimport DescriptionsContext from './DescriptionsContext';\nimport useItems from './hooks/useItems';\nimport useRow from './hooks/useRow';\nimport DescriptionsItem from './Item';\nimport Row from './Row';\nimport useStyle from './style';\nconst Descriptions = props => {\n const {\n prefixCls: customizePrefixCls,\n title,\n extra,\n column,\n colon = true,\n bordered,\n layout,\n children,\n className,\n rootClassName,\n style,\n size: customizeSize,\n labelStyle,\n contentStyle,\n items\n } = props,\n restProps = __rest(props, [\"prefixCls\", \"title\", \"extra\", \"column\", \"colon\", \"bordered\", \"layout\", \"children\", \"className\", \"rootClassName\", \"style\", \"size\", \"labelStyle\", \"contentStyle\", \"items\"]);\n const {\n getPrefixCls,\n direction,\n descriptions\n } = React.useContext(ConfigContext);\n const prefixCls = getPrefixCls('descriptions', customizePrefixCls);\n const screens = useBreakpoint();\n // Column count\n const mergedColumn = React.useMemo(() => {\n var _a;\n if (typeof column === 'number') {\n return column;\n }\n return (_a = matchScreen(screens, Object.assign(Object.assign({}, DEFAULT_COLUMN_MAP), column))) !== null && _a !== void 0 ? _a : 3;\n }, [screens, column]);\n // Items with responsive\n const mergedItems = useItems(screens, items, children);\n const mergedSize = useSize(customizeSize);\n const rows = useRow(mergedColumn, mergedItems);\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls);\n // ======================== Render ========================\n const contextValue = React.useMemo(() => ({\n labelStyle,\n contentStyle\n }), [labelStyle, contentStyle]);\n return wrapCSSVar( /*#__PURE__*/React.createElement(DescriptionsContext.Provider, {\n value: contextValue\n }, /*#__PURE__*/React.createElement(\"div\", Object.assign({\n className: classNames(prefixCls, descriptions === null || descriptions === void 0 ? void 0 : descriptions.className, {\n [`${prefixCls}-${mergedSize}`]: mergedSize && mergedSize !== 'default',\n [`${prefixCls}-bordered`]: !!bordered,\n [`${prefixCls}-rtl`]: direction === 'rtl'\n }, className, rootClassName, hashId, cssVarCls),\n style: Object.assign(Object.assign({}, descriptions === null || descriptions === void 0 ? void 0 : descriptions.style), style)\n }, restProps), (title || extra) && ( /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-header`\n }, title && /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-title`\n }, title), extra && /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-extra`\n }, extra))), /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-view`\n }, /*#__PURE__*/React.createElement(\"table\", null, /*#__PURE__*/React.createElement(\"tbody\", null, rows.map((row, index) => ( /*#__PURE__*/React.createElement(Row, {\n key: index,\n index: index,\n colon: colon,\n prefixCls: prefixCls,\n vertical: layout === 'vertical',\n bordered: bordered,\n row: row\n })))))))));\n};\nif (process.env.NODE_ENV !== 'production') {\n Descriptions.displayName = 'Descriptions';\n}\nexport { DescriptionsContext };\nDescriptions.Item = DescriptionsItem;\nexport default Descriptions;","map":{"version":3,"names":["__rest","s","e","t","p","Object","prototype","hasOwnProperty","call","indexOf","getOwnPropertySymbols","i","length","propertyIsEnumerable","React","classNames","matchScreen","ConfigContext","useSize","useBreakpoint","DEFAULT_COLUMN_MAP","DescriptionsContext","useItems","useRow","DescriptionsItem","Row","useStyle","Descriptions","props","prefixCls","customizePrefixCls","title","extra","column","colon","bordered","layout","children","className","rootClassName","style","size","customizeSize","labelStyle","contentStyle","items","restProps","getPrefixCls","direction","descriptions","useContext","screens","mergedColumn","useMemo","_a","assign","mergedItems","mergedSize","rows","wrapCSSVar","hashId","cssVarCls","contextValue","createElement","Provider","value","map","row","index","key","vertical","process","env","NODE_ENV","displayName","Item"],"sources":["C:/Users/Аришина)/source/repos/PromoCursed/node_modules/antd/es/descriptions/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};\n/* eslint-disable react/no-array-index-key */\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { matchScreen } from '../_util/responsiveObserver';\nimport { ConfigContext } from '../config-provider';\nimport useSize from '../config-provider/hooks/useSize';\nimport useBreakpoint from '../grid/hooks/useBreakpoint';\nimport DEFAULT_COLUMN_MAP from './constant';\nimport DescriptionsContext from './DescriptionsContext';\nimport useItems from './hooks/useItems';\nimport useRow from './hooks/useRow';\nimport DescriptionsItem from './Item';\nimport Row from './Row';\nimport useStyle from './style';\nconst Descriptions = props => {\n const {\n prefixCls: customizePrefixCls,\n title,\n extra,\n column,\n colon = true,\n bordered,\n layout,\n children,\n className,\n rootClassName,\n style,\n size: customizeSize,\n labelStyle,\n contentStyle,\n items\n } = props,\n restProps = __rest(props, [\"prefixCls\", \"title\", \"extra\", \"column\", \"colon\", \"bordered\", \"layout\", \"children\", \"className\", \"rootClassName\", \"style\", \"size\", \"labelStyle\", \"contentStyle\", \"items\"]);\n const {\n getPrefixCls,\n direction,\n descriptions\n } = React.useContext(ConfigContext);\n const prefixCls = getPrefixCls('descriptions', customizePrefixCls);\n const screens = useBreakpoint();\n // Column count\n const mergedColumn = React.useMemo(() => {\n var _a;\n if (typeof column === 'number') {\n return column;\n }\n return (_a = matchScreen(screens, Object.assign(Object.assign({}, DEFAULT_COLUMN_MAP), column))) !== null && _a !== void 0 ? _a : 3;\n }, [screens, column]);\n // Items with responsive\n const mergedItems = useItems(screens, items, children);\n const mergedSize = useSize(customizeSize);\n const rows = useRow(mergedColumn, mergedItems);\n const [wrapCSSVar, hashId, cssVarCls] = useStyle(prefixCls);\n // ======================== Render ========================\n const contextValue = React.useMemo(() => ({\n labelStyle,\n contentStyle\n }), [labelStyle, contentStyle]);\n return wrapCSSVar( /*#__PURE__*/React.createElement(DescriptionsContext.Provider, {\n value: contextValue\n }, /*#__PURE__*/React.createElement(\"div\", Object.assign({\n className: classNames(prefixCls, descriptions === null || descriptions === void 0 ? void 0 : descriptions.className, {\n [`${prefixCls}-${mergedSize}`]: mergedSize && mergedSize !== 'default',\n [`${prefixCls}-bordered`]: !!bordered,\n [`${prefixCls}-rtl`]: direction === 'rtl'\n }, className, rootClassName, hashId, cssVarCls),\n style: Object.assign(Object.assign({}, descriptions === null || descriptions === void 0 ? void 0 : descriptions.style), style)\n }, restProps), (title || extra) && ( /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-header`\n }, title && /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-title`\n }, title), extra && /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-extra`\n }, extra))), /*#__PURE__*/React.createElement(\"div\", {\n className: `${prefixCls}-view`\n }, /*#__PURE__*/React.createElement(\"table\", null, /*#__PURE__*/React.createElement(\"tbody\", null, rows.map((row, index) => ( /*#__PURE__*/React.createElement(Row, {\n key: index,\n index: index,\n colon: colon,\n prefixCls: prefixCls,\n vertical: layout === 'vertical',\n bordered: bordered,\n row: row\n })))))))));\n};\nif (process.env.NODE_ENV !== 'production') {\n Descriptions.displayName = 'Descriptions';\n}\nexport { DescriptionsContext };\nDescriptions.Item = DescriptionsItem;\nexport default Descriptions;"],"mappings":"AAAA,YAAY;;AAEZ,IAAIA,MAAM,GAAG,IAAI,IAAI,IAAI,CAACA,MAAM,IAAI,UAAUC,CAAC,EAAEC,CAAC,EAAE;EAClD,IAAIC,CAAC,GAAG,CAAC,CAAC;EACV,KAAK,IAAIC,CAAC,IAAIH,CAAC,EAAE,IAAII,MAAM,CAACC,SAAS,CAACC,cAAc,CAACC,IAAI,CAACP,CAAC,EAAEG,CAAC,CAAC,IAAIF,CAAC,CAACO,OAAO,CAACL,CAAC,CAAC,GAAG,CAAC,EAAED,CAAC,CAACC,CAAC,CAAC,GAAGH,CAAC,CAACG,CAAC,CAAC;EAChG,IAAIH,CAAC,IAAI,IAAI,IAAI,OAAOI,MAAM,CAACK,qBAAqB,KAAK,UAAU,EAAE,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEP,CAAC,GAAGC,MAAM,CAACK,qBAAqB,CAACT,CAAC,CAAC,EAAEU,CAAC,GAAGP,CAAC,CAACQ,MAAM,EAAED,CAAC,EAAE,EAAE;IAC3I,IAAIT,CAAC,CAACO,OAAO,CAACL,CAAC,CAACO,CAAC,CAAC,CAAC,GAAG,CAAC,IAAIN,MAAM,CAACC,SAAS,CAACO,oBAAoB,CAACL,IAAI,CAACP,CAAC,EAAEG,CAAC,CAACO,CAAC,CAAC,CAAC,EAAER,CAAC,CAACC,CAAC,CAACO,CAAC,CAAC,CAAC,GAAGV,CAAC,CAACG,CAAC,CAACO,CAAC,CAAC,CAAC;EACnG;EACA,OAAOR,CAAC;AACV,CAAC;AACD;AACA,OAAO,KAAKW,KAAK,MAAM,OAAO;AAC9B,OAAOC,UAAU,MAAM,YAAY;AACnC,SAASC,WAAW,QAAQ,6BAA6B;AACzD,SAASC,aAAa,QAAQ,oBAAoB;AAClD,OAAOC,OAAO,MAAM,kCAAkC;AACtD,OAAOC,aAAa,MAAM,6BAA6B;AACvD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