@vtx/modals2 2.10.21 → 2.10.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,3 +1,12 @@
|
|
|
1
|
+
.current-alarm {
|
|
2
|
+
display: -webkit-box;
|
|
3
|
+
display: -ms-flexbox;
|
|
4
|
+
display: flex;
|
|
5
|
+
-webkit-box-orient: vertical;
|
|
6
|
+
-webkit-box-direction: normal;
|
|
7
|
+
-ms-flex-direction: column;
|
|
8
|
+
flex-direction: column;
|
|
9
|
+
}
|
|
1
10
|
.current-alarm > div {
|
|
2
11
|
padding: 4px 20px;
|
|
3
12
|
color: #c2c2c2;
|
package/lib/vm-charts/Pie.js
CHANGED
package/lib/vm-charts/Pie.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Pie.js","names":["getOption","data","name","isDark","textColor","bgColor","borderColor","color","tooltip","trigger","backgroundColor","textStyle","legend","type","orient","top","right","itemWidth","itemHeight","grid","left","bottom","containLabel","series","radius","center","label","show","Pie","style","echartClick","exportShow","echarts_react","useRef","UseSettings","saveImage","_a","echartsInstance","current","getEchartsInstance","imgUrl","getDataURL","pixelRatio","excludeComponents","downloadFile","React","createElement","Fragment","className","onClick","ReactEcharts","ref","onEvents","click","option","notMerge","lazyUpdate","Object","assign","height"],"sources":["vm-charts/Pie.js"],"sourcesContent":["import React, { useRef } from 'react';\nimport ReactEcharts from 'echarts-for-react';\nimport UseSettings from '../vm-hooks/useSettings';\nimport { downloadFile } from \"@vtx/utils\";\nconst getOption = ({ data = [], name = '', isDark }) => {\n let textColor = isDark ? '#fff' : '#929292';\n let bgColor = isDark ? '#0C2A48' : '#fff';\n let borderColor = isDark ? '#1E4771' : '#fff';\n return {\n color: ['#0E85FF', '#49FF81', '#26D4FF', '#F5D629', '#C97CFF'],\n tooltip: {\n trigger: 'item',\n backgroundColor: bgColor,\n borderColor: borderColor,\n textStyle: {\n color: textColor,\n },\n },\n legend: {\n type: 'scroll',\n orient: 'vertical',\n top: 0,\n right: 10,\n itemWidth: 10,\n itemHeight: 10,\n textStyle: {\n color: textColor,\n },\n },\n grid: {\n top: 0,\n left: 0,\n right: 0,\n bottom: 0,\n containLabel: true,\n },\n series: [\n {\n name,\n type: 'pie',\n radius: '
|
|
1
|
+
{"version":3,"file":"Pie.js","names":["getOption","data","name","isDark","textColor","bgColor","borderColor","color","tooltip","trigger","backgroundColor","textStyle","legend","type","orient","top","right","itemWidth","itemHeight","grid","left","bottom","containLabel","series","radius","center","label","show","Pie","style","echartClick","exportShow","echarts_react","useRef","UseSettings","saveImage","_a","echartsInstance","current","getEchartsInstance","imgUrl","getDataURL","pixelRatio","excludeComponents","downloadFile","React","createElement","Fragment","className","onClick","ReactEcharts","ref","onEvents","click","option","notMerge","lazyUpdate","Object","assign","height"],"sources":["vm-charts/Pie.js"],"sourcesContent":["import React, { useRef } from 'react';\nimport ReactEcharts from 'echarts-for-react';\nimport UseSettings from '../vm-hooks/useSettings';\nimport { downloadFile } from \"@vtx/utils\";\nconst getOption = ({ data = [], name = '', isDark }) => {\n let textColor = isDark ? '#fff' : '#929292';\n let bgColor = isDark ? '#0C2A48' : '#fff';\n let borderColor = isDark ? '#1E4771' : '#fff';\n return {\n color: ['#0E85FF', '#49FF81', '#26D4FF', '#F5D629', '#C97CFF'],\n tooltip: {\n trigger: 'item',\n backgroundColor: bgColor,\n borderColor: borderColor,\n textStyle: {\n color: textColor,\n },\n },\n legend: {\n type: 'scroll',\n orient: 'vertical',\n top: 0,\n right: 10,\n itemWidth: 10,\n itemHeight: 10,\n textStyle: {\n color: textColor,\n },\n },\n grid: {\n top: 0,\n left: 0,\n right: 0,\n bottom: 0,\n containLabel: true,\n },\n series: [\n {\n name,\n type: 'pie',\n radius: '85%',\n center: ['26%', '50%'],\n data,\n label: {\n show: false,\n color: textColor,\n },\n },\n ],\n };\n};\nconst Pie = ({ data, name, style, echartClick, exportShow }) => {\n const echarts_react = useRef();\n const { isDark } = UseSettings();\n // 保存为图片\n const saveImage = () => {\n var _a;\n const echartsInstance = (_a = echarts_react === null || echarts_react === void 0 ? void 0 : echarts_react.current) === null || _a === void 0 ? void 0 : _a.getEchartsInstance();\n if (echartsInstance) {\n let imgUrl = echartsInstance.getDataURL({\n pixelRatio: 1,\n backgroundColor: '#fff',\n excludeComponents: [\n //保存图表时忽略的工具组件,默认忽略工具栏\n 'toolbox',\n ],\n type: 'png', //图片类型支持png和jpeg\n });\n downloadFile(imgUrl, '图片', 'blob');\n }\n };\n return (React.createElement(React.Fragment, null,\n exportShow && (React.createElement(\"div\", { className: \"btn-wrap\" },\n React.createElement(\"div\", { className: \"btn\", onClick: () => {\n saveImage();\n } }, \"\\u5BFC\\u51FA\\u56FE\\u7247\"))),\n React.createElement(ReactEcharts, { ref: echarts_react, onEvents: { click: echartClick }, option: getOption({ data, name, isDark }), notMerge: true, lazyUpdate: true, style: Object.assign({ height: '100%' }, style) })));\n};\nexport default Pie;\n"],"mappings":";;;;;;;AAAA;AACA;AACA;AACA;AAA0C;AAAA;AAAA;AAC1C,IAAMA,SAAS,GAAG,SAAZA,SAAS,OAAyC;EAAA,qBAAnCC,IAAI;IAAJA,IAAI,0BAAG,EAAE;IAAA,iBAAEC,IAAI;IAAJA,IAAI,0BAAG,EAAE;IAAEC,MAAM,QAANA,MAAM;EAC7C,IAAIC,SAAS,GAAGD,MAAM,GAAG,MAAM,GAAG,SAAS;EAC3C,IAAIE,OAAO,GAAGF,MAAM,GAAG,SAAS,GAAG,MAAM;EACzC,IAAIG,WAAW,GAAGH,MAAM,GAAG,SAAS,GAAG,MAAM;EAC7C,OAAO;IACHI,KAAK,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC;IAC9DC,OAAO,EAAE;MACLC,OAAO,EAAE,MAAM;MACfC,eAAe,EAAEL,OAAO;MACxBC,WAAW,EAAEA,WAAW;MACxBK,SAAS,EAAE;QACPJ,KAAK,EAAE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