qauMaWeb/node_modules/.cache/babel-loader/c643a18d9b4321662563d1d6b61...

1 line
8.8 KiB
JSON

{"ast":null,"code":"import \"core-js/modules/es.array.concat.js\";\n\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\n/**\n * AUTO-GENERATED FILE. DO NOT MODIFY.\n */\n\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\nimport * as zrUtil from 'zrender/lib/core/util.js';\nimport { normalizeToArray } from '../../util/model.js';\nvar DEFAULT_TOOLBOX_BTNS = ['rect', 'polygon', 'keep', 'clear'];\nexport default function brushPreprocessor(option, isNew) {\n var brushComponents = normalizeToArray(option ? option.brush : []);\n\n if (!brushComponents.length) {\n return;\n }\n\n var brushComponentSpecifiedBtns = [];\n zrUtil.each(brushComponents, function (brushOpt) {\n var tbs = brushOpt.hasOwnProperty('toolbox') ? brushOpt.toolbox : [];\n\n if (tbs instanceof Array) {\n brushComponentSpecifiedBtns = brushComponentSpecifiedBtns.concat(tbs);\n }\n });\n var toolbox = option && option.toolbox;\n\n if (zrUtil.isArray(toolbox)) {\n toolbox = toolbox[0];\n }\n\n if (!toolbox) {\n toolbox = {\n feature: {}\n };\n option.toolbox = [toolbox];\n }\n\n var toolboxFeature = toolbox.feature || (toolbox.feature = {});\n var toolboxBrush = toolboxFeature.brush || (toolboxFeature.brush = {});\n var brushTypes = toolboxBrush.type || (toolboxBrush.type = []);\n brushTypes.push.apply(brushTypes, brushComponentSpecifiedBtns);\n removeDuplicate(brushTypes);\n\n if (isNew && !brushTypes.length) {\n brushTypes.push.apply(brushTypes, DEFAULT_TOOLBOX_BTNS);\n }\n}\n\nfunction removeDuplicate(arr) {\n var map = {};\n zrUtil.each(arr, function (val) {\n map[val] = 1;\n });\n arr.length = 0;\n zrUtil.each(map, function (flag, val) {\n arr.push(val);\n });\n}","map":{"version":3,"sources":["D:/Work/WorkSpace/GitWorkSpace/TenShop/resource/ElectronicMall/src/ElectronicMallVue/node_modules/echarts/lib/component/brush/preprocessor.js"],"names":["zrUtil","normalizeToArray","DEFAULT_TOOLBOX_BTNS","brushPreprocessor","option","isNew","brushComponents","brush","length","brushComponentSpecifiedBtns","each","brushOpt","tbs","hasOwnProperty","toolbox","Array","concat","isArray","feature","toolboxFeature","toolboxBrush","brushTypes","type","push","apply","removeDuplicate","arr","map","val","flag"],"mappings":";;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,KAAKA,MAAZ,MAAwB,0BAAxB;AACA,SAASC,gBAAT,QAAiC,qBAAjC;AACA,IAAIC,oBAAoB,GAAG,CAAC,MAAD,EAAS,SAAT,EAAoB,MAApB,EAA4B,OAA5B,CAA3B;AACA,eAAe,SAASC,iBAAT,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B,EAAAA,eAAe,CAACJ,UAAD,CAAf;;AAEA,MAAIhB,KAAK,IAAI,CAACgB,UAAU,CAACb,MAAzB,EAAiC;AAC/Ba,IAAAA,UAAU,CAACE,IAAX,CAAgBC,KAAhB,CAAsBH,UAAtB,EAAkCnB,oBAAlC;AACD;AACF;;AAED,SAASuB,eAAT,CAAyBC,GAAzB,EAA8B;AAC5B,MAAIC,GAAG,GAAG,EAAV;AACA3B,EAAAA,MAAM,CAACU,IAAP,CAAYgB,GAAZ,EAAiB,UAAUE,GAAV,EAAe;AAC9BD,IAAAA,GAAG,CAACC,GAAD,CAAH,GAAW,CAAX;AACD,GAFD;AAGAF,EAAAA,GAAG,CAAClB,MAAJ,GAAa,CAAb;AACAR,EAAAA,MAAM,CAACU,IAAP,CAAYiB,GAAZ,EAAiB,UAAUE,IAAV,EAAgBD,GAAhB,EAAqB;AACpCF,IAAAA,GAAG,CAACH,IAAJ,CAASK,GAAT;AACD,GAFD;AAGD","sourcesContent":["\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\n\n/**\n * AUTO-GENERATED FILE. DO NOT MODIFY.\n */\n\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\nimport * as zrUtil from 'zrender/lib/core/util.js';\nimport { normalizeToArray } from '../../util/model.js';\nvar DEFAULT_TOOLBOX_BTNS = ['rect', 'polygon', 'keep', 'clear'];\nexport default function brushPreprocessor(option, isNew) {\n var brushComponents = normalizeToArray(option ? option.brush : []);\n\n if (!brushComponents.length) {\n return;\n }\n\n var brushComponentSpecifiedBtns = [];\n zrUtil.each(brushComponents, function (brushOpt) {\n var tbs = brushOpt.hasOwnProperty('toolbox') ? brushOpt.toolbox : [];\n\n if (tbs instanceof Array) {\n brushComponentSpecifiedBtns = brushComponentSpecifiedBtns.concat(tbs);\n }\n });\n var toolbox = option && option.toolbox;\n\n if (zrUtil.isArray(toolbox)) {\n toolbox = toolbox[0];\n }\n\n if (!toolbox) {\n toolbox = {\n feature: {}\n };\n option.toolbox = [toolbox];\n }\n\n var toolboxFeature = toolbox.feature || (toolbox.feature = {});\n var toolboxBrush = toolboxFeature.brush || (toolboxFeature.brush = {});\n var brushTypes = toolboxBrush.type || (toolboxBrush.type = []);\n brushTypes.push.apply(brushTypes, brushComponentSpecifiedBtns);\n removeDuplicate(brushTypes);\n\n if (isNew && !brushTypes.length) {\n brushTypes.push.apply(brushTypes, DEFAULT_TOOLBOX_BTNS);\n }\n}\n\nfunction removeDuplicate(arr) {\n var map = {};\n zrUtil.each(arr, function (val) {\n map[val] = 1;\n });\n arr.length = 0;\n zrUtil.each(map, function (flag, val) {\n arr.push(val);\n });\n}"]},"metadata":{},"sourceType":"module"}