c37e0b20a4d21cd3ce217ec541a7300e.json
9.26 KB
{"ast":null,"code":"\"use strict\";\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _slicedToArray2 = _interopRequireDefault(require(\"@babel/runtime/helpers/slicedToArray\"));\n\nvar _defineProperty2 = _interopRequireDefault(require(\"@babel/runtime/helpers/defineProperty\"));\n\nvar _objectWithoutProperties2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectWithoutProperties\"));\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _classnames = _interopRequireDefault(require(\"classnames\"));\n\nvar _IconBase = _interopRequireDefault(require(\"./IconBase\"));\n\nvar _twoTonePrimaryColor = require(\"./twoTonePrimaryColor\");\n\nvar _utils = require(\"../utils\"); // Initial setting\n// should move it to antd main repo?\n\n\n(0, _twoTonePrimaryColor.setTwoToneColor)('#1890ff');\nvar Icon = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var className = props.className,\n icon = props.icon,\n spin = props.spin,\n rotate = props.rotate,\n tabIndex = props.tabIndex,\n onClick = props.onClick,\n twoToneColor = props.twoToneColor,\n restProps = (0, _objectWithoutProperties2.default)(props, [\"className\", \"icon\", \"spin\", \"rotate\", \"tabIndex\", \"onClick\", \"twoToneColor\"]);\n var classString = (0, _classnames.default)('anticon', (0, _defineProperty2.default)({}, \"anticon-\".concat(icon.name), Boolean(icon.name)), {\n 'anticon-spin': !!spin || icon.name === 'loading'\n }, className);\n var iconTabIndex = tabIndex;\n\n if (iconTabIndex === undefined && onClick) {\n iconTabIndex = -1;\n }\n\n var svgStyle = rotate ? {\n msTransform: \"rotate(\".concat(rotate, \"deg)\"),\n transform: \"rotate(\".concat(rotate, \"deg)\")\n } : undefined;\n\n var _normalizeTwoToneColo = (0, _utils.normalizeTwoToneColors)(twoToneColor),\n _normalizeTwoToneColo2 = (0, _slicedToArray2.default)(_normalizeTwoToneColo, 2),\n primaryColor = _normalizeTwoToneColo2[0],\n secondaryColor = _normalizeTwoToneColo2[1];\n\n return /*#__PURE__*/React.createElement(\"span\", Object.assign({\n role: \"img\",\n \"aria-label\": icon.name\n }, restProps, {\n ref: ref,\n tabIndex: iconTabIndex,\n onClick: onClick,\n className: classString\n }), /*#__PURE__*/React.createElement(_IconBase.default, {\n icon: icon,\n primaryColor: primaryColor,\n secondaryColor: secondaryColor,\n style: svgStyle\n }));\n});\nIcon.displayName = 'AntdIcon';\nIcon.getTwoToneColor = _twoTonePrimaryColor.getTwoToneColor;\nIcon.setTwoToneColor = _twoTonePrimaryColor.setTwoToneColor;\nvar _default = Icon;\nexports.default = _default;","map":{"version":3,"sources":["C:/Users/kkwan_000/Desktop/git/2017110269/minsung/node_modules/@ant-design/icons/lib/components/AntdIcon.js"],"names":["_interopRequireWildcard","require","_interopRequireDefault","Object","defineProperty","exports","value","default","_slicedToArray2","_defineProperty2","_objectWithoutProperties2","React","_classnames","_IconBase","_twoTonePrimaryColor","_utils","setTwoToneColor","Icon","forwardRef","props","ref","className","icon","spin","rotate","tabIndex","onClick","twoToneColor","restProps","classString","concat","name","Boolean","iconTabIndex","undefined","svgStyle","msTransform","transform","_normalizeTwoToneColo","normalizeTwoToneColors","_normalizeTwoToneColo2","primaryColor","secondaryColor","createElement","assign","role","style","displayName","getTwoToneColor","_default"],"mappings":"AAAA;;AAEA,IAAIA,uBAAuB,GAAGC,OAAO,CAAC,+CAAD,CAArC;;AAEA,IAAIC,sBAAsB,GAAGD,OAAO,CAAC,8CAAD,CAApC;;AAEAE,MAAM,CAACC,cAAP,CAAsBC,OAAtB,EAA+B,YAA/B,EAA6C;AAC3CC,EAAAA,KAAK,EAAE;AADoC,CAA7C;AAGAD,OAAO,CAACE,OAAR,GAAkB,KAAK,CAAvB;;AAEA,IAAIC,eAAe,GAAGN,sBAAsB,CAACD,OAAO,CAAC,sCA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SAAS,EAAEQ;AAJC,GAHkC,CAA5B,EAQhB,aAAalB,KAAK,CAACgC,aAAN,CAAoB9B,SAAS,CAACN,OAA9B,EAAuC;AACtDe,IAAAA,IAAI,EAAEA,IADgD;AAEtDmB,IAAAA,YAAY,EAAEA,YAFwC;AAGtDC,IAAAA,cAAc,EAAEA,cAHsC;AAItDI,IAAAA,KAAK,EAAEX;AAJ+C,GAAvC,CARG,CAApB;AAcD,CA1CuB,CAAxB;AA2CAlB,IAAI,CAAC8B,WAAL,GAAmB,UAAnB;AACA9B,IAAI,CAAC+B,eAAL,GAAuBlC,oBAAoB,CAACkC,eAA5C;AACA/B,IAAI,CAACD,eAAL,GAAuBF,oBAAoB,CAACE,eAA5C;AACA,IAAIiC,QAAQ,GAAGhC,IAAf;AACAZ,OAAO,CAACE,OAAR,GAAkB0C,QAAlB","sourcesContent":["\"use strict\";\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar _slicedToArray2 = _interopRequireDefault(require(\"@babel/runtime/helpers/slicedToArray\"));\n\nvar _defineProperty2 = _interopRequireDefault(require(\"@babel/runtime/helpers/defineProperty\"));\n\nvar _objectWithoutProperties2 = _interopRequireDefault(require(\"@babel/runtime/helpers/objectWithoutProperties\"));\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _classnames = _interopRequireDefault(require(\"classnames\"));\n\nvar _IconBase = _interopRequireDefault(require(\"./IconBase\"));\n\nvar _twoTonePrimaryColor = require(\"./twoTonePrimaryColor\");\n\nvar _utils = require(\"../utils\");\n\n// Initial setting\n// should move it to antd main repo?\n(0, _twoTonePrimaryColor.setTwoToneColor)('#1890ff');\nvar Icon = /*#__PURE__*/React.forwardRef(function (props, ref) {\n var className = props.className,\n icon = props.icon,\n spin = props.spin,\n rotate = props.rotate,\n tabIndex = props.tabIndex,\n onClick = props.onClick,\n twoToneColor = props.twoToneColor,\n restProps = (0, _objectWithoutProperties2.default)(props, [\"className\", \"icon\", \"spin\", \"rotate\", \"tabIndex\", \"onClick\", \"twoToneColor\"]);\n var classString = (0, _classnames.default)('anticon', (0, _defineProperty2.default)({}, \"anticon-\".concat(icon.name), Boolean(icon.name)), {\n 'anticon-spin': !!spin || icon.name === 'loading'\n }, className);\n var iconTabIndex = tabIndex;\n\n if (iconTabIndex === undefined && onClick) {\n iconTabIndex = -1;\n }\n\n var svgStyle = rotate ? {\n msTransform: \"rotate(\".concat(rotate, \"deg)\"),\n transform: \"rotate(\".concat(rotate, \"deg)\")\n } : undefined;\n\n var _normalizeTwoToneColo = (0, _utils.normalizeTwoToneColors)(twoToneColor),\n _normalizeTwoToneColo2 = (0, _slicedToArray2.default)(_normalizeTwoToneColo, 2),\n primaryColor = _normalizeTwoToneColo2[0],\n secondaryColor = _normalizeTwoToneColo2[1];\n\n return /*#__PURE__*/React.createElement(\"span\", Object.assign({\n role: \"img\",\n \"aria-label\": icon.name\n }, restProps, {\n ref: ref,\n tabIndex: iconTabIndex,\n onClick: onClick,\n className: classString\n }), /*#__PURE__*/React.createElement(_IconBase.default, {\n icon: icon,\n primaryColor: primaryColor,\n secondaryColor: secondaryColor,\n style: svgStyle\n }));\n});\nIcon.displayName = 'AntdIcon';\nIcon.getTwoToneColor = _twoTonePrimaryColor.getTwoToneColor;\nIcon.setTwoToneColor = _twoTonePrimaryColor.setTwoToneColor;\nvar _default = Icon;\nexports.default = _default;"]},"metadata":{},"sourceType":"script"}