{"ast":null,"code":"import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport toArray from \"rc-util/es/Children/toArray\";\nimport * as React from 'react';\nexport function parseChildren(children, keyPath) {\n return toArray(children).map(function (child, index) {\n if ( /*#__PURE__*/React.isValidElement(child)) {\n var _eventKey, _child$props;\n var key = child.key;\n var eventKey = (_eventKey = (_child$props = child.props) === null || _child$props === void 0 ? void 0 : _child$props.eventKey) !== null && _eventKey !== void 0 ? _eventKey : key;\n var emptyKey = eventKey === null || eventKey === undefined;\n if (emptyKey) {\n eventKey = \"tmp_key-\".concat([].concat(_toConsumableArray(keyPath), [index]).join('-'));\n }\n var cloneProps = {\n key: eventKey,\n eventKey: eventKey\n };\n if (process.env.NODE_ENV !== 'production' && emptyKey) {\n cloneProps.warnKey = true;\n }\n return /*#__PURE__*/React.cloneElement(child, cloneProps);\n }\n return child;\n });\n}","map":{"version":3,"names":["_toConsumableArray","toArray","React","parseChildren","children","keyPath","map","child","index","isValidElement","_eventKey","_child$props","key","eventKey","props","emptyKey","undefined","concat","join","cloneProps","process","env","NODE_ENV","warnKey","cloneElement"],"sources":["C:/Users/Аришина)/Desktop/promo/node_modules/rc-menu/es/utils/commonUtil.js"],"sourcesContent":["import _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport toArray from \"rc-util/es/Children/toArray\";\nimport * as React from 'react';\nexport function parseChildren(children, keyPath) {\n return toArray(children).map(function (child, index) {\n if ( /*#__PURE__*/React.isValidElement(child)) {\n var _eventKey, _child$props;\n var key = child.key;\n var eventKey = (_eventKey = (_child$props = child.props) === null || _child$props === void 0 ? void 0 : _child$props.eventKey) !== null && _eventKey !== void 0 ? _eventKey : key;\n var emptyKey = eventKey === null || eventKey === undefined;\n if (emptyKey) {\n eventKey = \"tmp_key-\".concat([].concat(_toConsumableArray(keyPath), [index]).join('-'));\n }\n var cloneProps = {\n key: eventKey,\n eventKey: eventKey\n };\n if (process.env.NODE_ENV !== 'production' && emptyKey) {\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