PromoCursed/node_modules/.cache/babel-loader/37924f18ec9f4b78442dada6b72f0f3046191d9d1666b800cb9d2b48257deb7c.json

1 line
5.5 KiB
JSON
Raw Normal View History

2024-08-20 23:25:37 +04:00
{"ast":null,"code":"\"use client\";\n\nimport * as React from 'react';\nimport { createContext, useContext, useMemo } from 'react';\nimport { FormProvider as RcFormProvider } from 'rc-field-form';\nimport omit from \"rc-util/es/omit\";\nexport const FormContext = /*#__PURE__*/React.createContext({\n labelAlign: 'right',\n vertical: false,\n itemRef: () => {}\n});\nexport const NoStyleItemContext = /*#__PURE__*/React.createContext(null);\nexport const FormProvider = props => {\n const providerProps = omit(props, ['prefixCls']);\n return /*#__PURE__*/React.createElement(RcFormProvider, Object.assign({}, providerProps));\n};\nexport const FormItemPrefixContext = /*#__PURE__*/React.createContext({\n prefixCls: ''\n});\nexport const FormItemInputContext = /*#__PURE__*/React.createContext({});\nif (process.env.NODE_ENV !== 'production') {\n FormItemInputContext.displayName = 'FormItemInputContext';\n}\nexport const NoFormStyle = _ref => {\n let {\n children,\n status,\n override\n } = _ref;\n const formItemInputContext = useContext(FormItemInputContext);\n const newFormItemInputContext = useMemo(() => {\n const newContext = Object.assign({}, formItemInputContext);\n if (override) {\n delete newContext.isFormItemInput;\n }\n if (status) {\n delete newContext.status;\n delete newContext.hasFeedback;\n delete newContext.feedbackIcon;\n }\n return newContext;\n }, [status, override, formItemInputContext]);\n return /*#__PURE__*/React.createElement(FormItemInputContext.Provider, {\n value: newFormItemInputContext\n }, children);\n};\nexport const VariantContext = /*#__PURE__*/createContext(undefined);","map":{"version":3,"names":["React","createContext","useContext","useMemo","FormProvider","RcFormProvider","omit","FormContext","labelAlign","vertical","itemRef","NoStyleItemContext","props","providerProps","createElement","Object","assign","FormItemPrefixContext","prefixCls","FormItemInputContext","process","env","NODE_ENV","displayName","NoFormStyle","_ref","children","status","override","formItemInputContext","newFormItemInputContext","newContext","isFormItemInput","hasFeedback","feedbackIcon","Provider","value","VariantContext","undefined"],"sources":["C:/Users/Аришина)/Desktop/promo/node_modules/antd/es/form/context.js"],"sourcesContent":["\"use client\";\n\nimport * as React from 'react';\nimport { createContext, useContext, useMemo } from 'react';\nimport { FormProvider as RcFormProvider } from 'rc-field-form';\nimport omit from \"rc-util/es/omit\";\nexport const FormContext = /*#__PURE__*/React.createContext({\n labelAlign: 'right',\n vertical: false,\n itemRef: () => {}\n});\nexport const NoStyleItemContext = /*#__PURE__*/React.createContext(null);\nexport const FormProvider = props => {\n const providerProps = omit(props, ['prefixCls']);\n return /*#__PURE__*/React.createElement(RcFormProvider, Object.assign({}, providerProps));\n};\nexport const FormItemPrefixContext = /*#__PURE__*/React.createContext({\n prefixCls: ''\n});\nexport const FormItemInputContext = /*#__PURE__*/React.createContext({});\nif (process.env.NODE_ENV !== 'production') {\n FormItemInputContext.displayName = 'FormItemInputContext';\n}\nexport const NoFormStyle = _ref => {\n let {\n children,\n status,\n override\n } = _ref;\n const formItemInputContext = useContext(FormItemInputContext);\n const newFormItemInputContext = useMemo(() => {\n const newContext = Object.assign({}, formItemInputContext);\n if (override) {\n delete newContext.isFormItemInput;\n }\n if (status) {\n delete newContext.status;\n delete newContext.hasFeedback;\n delete newContext.feedbackIcon;\n }\n return newContext;\n }, [status, override, formItemInputContext]);\n return /*#__PURE__*/React.createElement(FormItemInputContext.Provider, {\n value: newFormItemInputContext\n }, children);\n};\nexport const VariantContext = /*#__PURE__*/createContext(undefined);"],"mappings":"AAAA,YAAY;;AAEZ,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,aAAa,EAAEC,UAAU,EAAEC,