57fc378ac10aff45f7756da188c6e1ec.json
1.64 KB
{"ast":null,"code":"import * as React from 'react';\nvar isValidElement = React.isValidElement;\nexport { isValidElement };\nexport function replaceElement(element, replacement, props) {\n if (!isValidElement(element)) return replacement;\n return /*#__PURE__*/React.cloneElement(element, typeof props === 'function' ? props(element.props || {}) : props);\n}\nexport function cloneElement(element, props) {\n return replaceElement(element, element, props);\n}","map":{"version":3,"sources":["C:/Users/kkwan_000/Desktop/git/2017110269/minsung/node_modules/antd/es/_util/reactNode.js"],"names":["React","isValidElement","replaceElement","element","replacement","props","cloneElement"],"mappings":"AAAA,OAAO,KAAKA,KAAZ,MAAuB,OAAvB;AACA,IAAIC,cAAc,GAAGD,KAAK,CAACC,cAA3B;AACA,SAASA,cAAT;AACA,OAAO,SAASC,cAAT,CAAwBC,OAAxB,EAAiCC,WAAjC,EAA8CC,KAA9C,EAAqD;AAC1D,MAAI,CAACJ,cAAc,CAACE,OAAD,CAAnB,EAA8B,OAAOC,WAAP;AAC9B,SAAO,aAAaJ,KAAK,CAACM,YAAN,CAAmBH,OAAnB,EAA4B,OAAOE,KAAP,KAAiB,UAAjB,GAA8BA,KAAK,CAACF,OAAO,CAACE,KAAR,IAAiB,EAAlB,CAAnC,GAA2DA,KAAvF,CAApB;AACD;AACD,OAAO,SAASC,YAAT,CAAsBH,OAAtB,EAA+BE,KAA/B,EAAsC;AAC3C,SAAOH,cAAc,CAACC,OAAD,EAAUA,OAAV,EAAmBE,KAAnB,CAArB;AACD","sourcesContent":["import * as React from 'react';\nvar isValidElement = React.isValidElement;\nexport { isValidElement };\nexport function replaceElement(element, replacement, props) {\n if (!isValidElement(element)) return replacement;\n return /*#__PURE__*/React.cloneElement(element, typeof props === 'function' ? props(element.props || {}) : props);\n}\nexport function cloneElement(element, props) {\n return replaceElement(element, element, props);\n}"]},"metadata":{},"sourceType":"module"}