@semcore/d3-chart 2.4.6 → 2.4.7

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.
@@ -40,12 +40,12 @@ var styles = (
40
40
  /*__reshadow_css_start__*/
41
41
  _core.sstyled.insert(
42
42
  /*__inner_css_start__*/
43
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SPlotA11yModule_16aif_gg_ {\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n pointer-events: none;\n opacity: 0;\n}\n\n.___SPlotA11yModule_16aif_gg_:focus {\n -webkit-user-select: all;\n -moz-user-select: all;\n user-select: all;\n pointer-events: all;\n opacity: 1;\n}\n"
43
+ ".___SPlotA11yModule_sviuq_gg_{-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none;opacity:0}.___SPlotA11yModule_sviuq_gg_:focus{-webkit-user-select:all;-moz-user-select:all;user-select:all;pointer-events:all;opacity:1}"
44
44
  /*__inner_css_end__*/
45
- , "16aif_gg_")
45
+ , "sviuq_gg_")
46
46
  /*__reshadow_css_end__*/
47
47
  , {
48
- "__SPlotA11yModule": "___SPlotA11yModule_16aif_gg_"
48
+ "__SPlotA11yModule": "___SPlotA11yModule_sviuq_gg_"
49
49
  });
50
50
  var globalWasFocused = false;
51
51
  var globalNavWithKeyboard = false;
@@ -44,13 +44,13 @@ var styles = (
44
44
  /*__reshadow_css_start__*/
45
45
  _core.sstyled.insert(
46
46
  /*__inner_css_start__*/
47
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SPlotA11yView_c8om4_gg_ {\n -webkit-user-select: none;\n -moz-user-select: none;\n user-select: none;\n pointer-events: none;\n opacity: 0;\n background-color: white;\n color: black;\n border: 3px solid black;\n font-size: 10px;\n padding: 2px;\n width: 200px;\n height: 200px;\n max-width: 80%;\n max-height: 80%;\n overflow: auto;\n}\n\n.___SPlotA11yView_c8om4_gg_.__focus-within_c8om4_gg_,\n.___SPlotA11yView_c8om4_gg_:focus {\n -webkit-user-select: all;\n -moz-user-select: all;\n user-select: all;\n pointer-events: all;\n opacity: 1;\n z-index: 100;\n position: relative;\n display: block;\n}\n\n.___SPlotA11yView_c8om4_gg_:focus-within,\n.___SPlotA11yView_c8om4_gg_:focus {\n -webkit-user-select: all;\n -moz-user-select: all;\n user-select: all;\n pointer-events: all;\n opacity: 1;\n z-index: 100;\n position: relative;\n display: block;\n}\n\n.___SPlotA11yView_c8om4_gg_ a {\n cursor: pointer;\n text-decoration: underline;\n margin-bottom: 8px;\n display: block;\n}\n\n.___SPlotA11yView_c8om4_gg_ table,\n.___SPlotA11yView_c8om4_gg_ td,\n.___SPlotA11yView_c8om4_gg_ th {\n border: 1px solid black;\n}\n"
47
+ ".___SPlotA11yView_p7ja3_gg_{-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none;opacity:0;background-color:#fff;color:#000;border:3px solid #000;font-size:10px;padding:2px;width:200px;height:200px;max-width:80%;max-height:80%;overflow:auto}.___SPlotA11yView_p7ja3_gg_:focus,.___SPlotA11yView_p7ja3_gg_.__focus-within_p7ja3_gg_{-webkit-user-select:all;-moz-user-select:all;user-select:all;pointer-events:all;opacity:1;z-index:100;position:relative;display:block}.___SPlotA11yView_p7ja3_gg_:focus,.___SPlotA11yView_p7ja3_gg_:focus-within{-webkit-user-select:all;-moz-user-select:all;user-select:all;pointer-events:all;opacity:1;z-index:100;position:relative;display:block}.___SPlotA11yView_p7ja3_gg_ a{cursor:pointer;text-decoration:underline;margin-bottom:8px;display:block}.___SPlotA11yView_p7ja3_gg_ table,.___SPlotA11yView_p7ja3_gg_ td,.___SPlotA11yView_p7ja3_gg_ th{border:1px solid #000}"
48
48
  /*__inner_css_end__*/
49
- , "c8om4_gg_")
49
+ , "p7ja3_gg_")
50
50
  /*__reshadow_css_end__*/
51
51
  , {
52
- "__SPlotA11yView": "___SPlotA11yView_c8om4_gg_",
53
- "_focus-within": "__focus-within_c8om4_gg_"
52
+ "__SPlotA11yView": "___SPlotA11yView_p7ja3_gg_",
53
+ "_focus-within": "__focus-within_p7ja3_gg_"
54
54
  });
55
55
 
56
56
  var PlotA11yView = function PlotA11yView(_ref3) {
package/lib/es6/Area.js CHANGED
@@ -26,18 +26,18 @@ var style = (
26
26
  /*__reshadow_css_start__*/
27
27
  _sstyled.insert(
28
28
  /*__inner_css_start__*/
29
- ".___SArea_glm2i_gg_ {\n fill: #2bb3ff;\n fill-opacity: 0.2;\n}\n\n.___SArea_glm2i_gg_.__color_glm2i_gg_ {\n fill: var(--color_glm2i);\n}\n\n.___SAreaLine_glm2i_gg_ {\n stroke: #2bb3ff;\n stroke-width: 3;\n fill: transparent;\n}\n\n.___SAreaLine_glm2i_gg_.__color_glm2i_gg_ {\n stroke: var(--color_glm2i);\n}\n\n.___SArea_glm2i_gg_,\n.___SAreaLine_glm2i_gg_ {\n transition-property: d;\n transition-duration: var(--duration_glm2i);\n transition-timing-function: ease-in-out;\n}\n\n.___SNull_glm2i_gg_ {\n fill: transparent;\n stroke: #8a8e9b;\n stroke-dasharray: 4;\n}\n\n.___SNull_glm2i_gg_.__hide_glm2i_gg_ {\n display: none;\n}\n"
29
+ ".___SArea_5d4tg_gg_{fill:#2bb3ff;fill-opacity:.2}.___SArea_5d4tg_gg_.__color_5d4tg_gg_{fill:var(--color_5d4tg)}.___SAreaLine_5d4tg_gg_{stroke:#2bb3ff;stroke-width:3;fill:transparent}.___SAreaLine_5d4tg_gg_.__color_5d4tg_gg_{stroke:var(--color_5d4tg)}.___SArea_5d4tg_gg_,.___SAreaLine_5d4tg_gg_{transition-property:d;transition-duration:var(--duration_5d4tg);transition-timing-function:ease-in-out}.___SNull_5d4tg_gg_{fill:transparent;stroke:#8a8e9b;stroke-dasharray:4}.___SNull_5d4tg_gg_.__hide_5d4tg_gg_{display:none}"
30
30
  /*__inner_css_end__*/
31
- , "glm2i_gg_")
31
+ , "5d4tg_gg_")
32
32
  /*__reshadow_css_end__*/
33
33
  , {
34
- "__SArea": "___SArea_glm2i_gg_",
35
- "_color": "__color_glm2i_gg_",
36
- "--color": "--color_glm2i",
37
- "__SAreaLine": "___SAreaLine_glm2i_gg_",
38
- "--duration": "--duration_glm2i",
39
- "__SNull": "___SNull_glm2i_gg_",
40
- "_hide": "__hide_glm2i_gg_"
34
+ "__SArea": "___SArea_5d4tg_gg_",
35
+ "_color": "__color_5d4tg_gg_",
36
+ "--color": "--color_5d4tg",
37
+ "__SAreaLine": "___SAreaLine_5d4tg_gg_",
38
+ "--duration": "--duration_5d4tg",
39
+ "__SNull": "___SNull_5d4tg_gg_",
40
+ "_hide": "__hide_5d4tg_gg_"
41
41
  });
42
42
 
43
43
  var AreaRoot = /*#__PURE__*/function (_Component) {
package/lib/es6/Axis.js CHANGED
@@ -27,23 +27,23 @@ var style = (
27
27
  /*__reshadow_css_start__*/
28
28
  _sstyled.insert(
29
29
  /*__inner_css_start__*/
30
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SAxis_haesk_gg_ {\n stroke: #c4c7cf;\n}\n\n.___SAxis_haesk_gg_.__hide_haesk_gg_ {\n display: none;\n}\n\n.___STick_haesk_gg_ {\n font-size: 12px;\n fill: #6c6e79;\n}\n\n.___STick_haesk_gg_.__hide_haesk_gg_ {\n display: none;\n}\n\n.___SGrid_haesk_gg_ {\n fill: transparent;\n stroke: #e0e1e9;\n}\n\n.___STitle_haesk_gg_ {\n font-size: 12px;\n fill: #6c6e79;\n transform-origin: var(--transform-origin_haesk);\n}\n\n.___STitle_haesk_gg_._position_top_haesk_gg_ {\n text-anchor: middle;\n}\n\n.___STitle_haesk_gg_._position_bottom_haesk_gg_ {\n text-anchor: middle;\n alignment-baseline: hanging;\n}\n\n.___STitle_haesk_gg_._position_right_haesk_gg_ {\n transform: rotate(-90deg);\n alignment-baseline: middle;\n text-anchor: middle;\n}\n\n.___STitle_haesk_gg_._position_left_haesk_gg_ {\n transform: rotate(-90deg);\n text-anchor: middle;\n alignment-baseline: middle;\n}\n\n.___STick_haesk_gg_._position_top_haesk_gg_ {\n transform: translateY(-12px);\n text-anchor: middle;\n}\n\n.___STick_haesk_gg_._position_bottom_haesk_gg_ {\n transform: translateY(12px);\n text-anchor: middle;\n alignment-baseline: hanging;\n}\n\n.___STick_haesk_gg_._position_right_haesk_gg_ {\n transform: translateX(16px);\n text-anchor: start;\n alignment-baseline: middle;\n}\n\n.___STick_haesk_gg_._position_left_haesk_gg_ {\n transform: translateX(-16px);\n text-anchor: end;\n alignment-baseline: middle;\n}\n\n.___STick_haesk_gg_._position_custom_0_haesk_gg_ {\n transform: translateY(12px);\n text-anchor: middle;\n alignment-baseline: hanging;\n}\n\n.___STick_haesk_gg_._position_custom_1_haesk_gg_ {\n transform: translateX(-16px);\n text-anchor: end;\n alignment-baseline: middle;\n}\n"
30
+ ".___SAxis_130py_gg_{stroke:#c4c7cf}.___SAxis_130py_gg_.__hide_130py_gg_{display:none}.___STick_130py_gg_{font-size:12px;fill:#6c6e79}.___STick_130py_gg_.__hide_130py_gg_{display:none}.___SGrid_130py_gg_{fill:transparent;stroke:#e0e1e9}.___STitle_130py_gg_{font-size:12px;fill:#6c6e79;transform-origin:var(--transform-origin_130py)}.___STitle_130py_gg_._position_top_130py_gg_{text-anchor:middle}.___STitle_130py_gg_._position_bottom_130py_gg_{text-anchor:middle;alignment-baseline:hanging}.___STitle_130py_gg_._position_right_130py_gg_{transform:rotate(-90deg);alignment-baseline:middle;text-anchor:middle}.___STitle_130py_gg_._position_left_130py_gg_{transform:rotate(-90deg);text-anchor:middle;alignment-baseline:middle}.___STick_130py_gg_._position_top_130py_gg_{transform:translateY(-12px);text-anchor:middle}.___STick_130py_gg_._position_bottom_130py_gg_{transform:translateY(12px);text-anchor:middle;alignment-baseline:hanging}.___STick_130py_gg_._position_right_130py_gg_{transform:translateX(16px);text-anchor:start;alignment-baseline:middle}.___STick_130py_gg_._position_left_130py_gg_{transform:translateX(-16px);text-anchor:end;alignment-baseline:middle}.___STick_130py_gg_._position_custom_0_130py_gg_{transform:translateY(12px);text-anchor:middle;alignment-baseline:hanging}.___STick_130py_gg_._position_custom_1_130py_gg_{transform:translateX(-16px);text-anchor:end;alignment-baseline:middle}"
31
31
  /*__inner_css_end__*/
32
- , "haesk_gg_")
32
+ , "130py_gg_")
33
33
  /*__reshadow_css_end__*/
34
34
  , {
35
- "__SAxis": "___SAxis_haesk_gg_",
36
- "_hide": "__hide_haesk_gg_",
37
- "__STick": "___STick_haesk_gg_",
38
- "__SGrid": "___SGrid_haesk_gg_",
39
- "__STitle": "___STitle_haesk_gg_",
40
- "--transform-origin": "--transform-origin_haesk",
41
- "_position_top": "_position_top_haesk_gg_",
42
- "_position_bottom": "_position_bottom_haesk_gg_",
43
- "_position_right": "_position_right_haesk_gg_",
44
- "_position_left": "_position_left_haesk_gg_",
45
- "_position_custom_0": "_position_custom_0_haesk_gg_",
46
- "_position_custom_1": "_position_custom_1_haesk_gg_"
35
+ "__SAxis": "___SAxis_130py_gg_",
36
+ "_hide": "__hide_130py_gg_",
37
+ "__STick": "___STick_130py_gg_",
38
+ "__SGrid": "___SGrid_130py_gg_",
39
+ "__STitle": "___STitle_130py_gg_",
40
+ "--transform-origin": "--transform-origin_130py",
41
+ "_position_top": "_position_top_130py_gg_",
42
+ "_position_bottom": "_position_bottom_130py_gg_",
43
+ "_position_right": "_position_right_130py_gg_",
44
+ "_position_left": "_position_left_130py_gg_",
45
+ "_position_custom_0": "_position_custom_0_130py_gg_",
46
+ "_position_custom_1": "_position_custom_1_130py_gg_"
47
47
  });
48
48
  var CUSTOM_0 = Symbol('custom_0');
49
49
  var CUSTOM_1 = Symbol('custom_1');
package/lib/es6/Bar.js CHANGED
@@ -24,17 +24,17 @@ var style = (
24
24
  /*__reshadow_css_start__*/
25
25
  _sstyled.insert(
26
26
  /*__inner_css_start__*/
27
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SBar_1vizy_gg_ {\n fill: #2bb3ff;\n transition-property: height, width, y;\n transition-duration: var(--duration_1vizy);\n transition-timing-function: ease-in-out;\n}\n\n.___SBar_1vizy_gg_.__color_1vizy_gg_ {\n fill: var(--color_1vizy);\n}\n\n.___SBar_1vizy_gg_.__hide_1vizy_gg_ {\n display: none;\n}\n\n.___SBackground_1vizy_gg_ {\n fill: #c4c7cf;\n}\n"
27
+ ".___SBar_10ufx_gg_{fill:#2bb3ff;transition-property:height,width,y;transition-duration:var(--duration_10ufx);transition-timing-function:ease-in-out}.___SBar_10ufx_gg_.__color_10ufx_gg_{fill:var(--color_10ufx)}.___SBar_10ufx_gg_.__hide_10ufx_gg_{display:none}.___SBackground_10ufx_gg_{fill:#c4c7cf}"
28
28
  /*__inner_css_end__*/
29
- , "1vizy_gg_")
29
+ , "10ufx_gg_")
30
30
  /*__reshadow_css_end__*/
31
31
  , {
32
- "__SBar": "___SBar_1vizy_gg_",
33
- "--duration": "--duration_1vizy",
34
- "_color": "__color_1vizy_gg_",
35
- "--color": "--color_1vizy",
36
- "_hide": "__hide_1vizy_gg_",
37
- "__SBackground": "___SBackground_1vizy_gg_"
32
+ "__SBar": "___SBar_10ufx_gg_",
33
+ "--duration": "--duration_10ufx",
34
+ "_color": "__color_10ufx_gg_",
35
+ "--color": "--color_10ufx",
36
+ "_hide": "__hide_10ufx_gg_",
37
+ "__SBackground": "___SBackground_10ufx_gg_"
38
38
  });
39
39
 
40
40
  var BarRoot = /*#__PURE__*/function (_Component) {
package/lib/es6/Bubble.js CHANGED
@@ -32,19 +32,19 @@ var style = (
32
32
  /*__reshadow_css_start__*/
33
33
  _sstyled.insert(
34
34
  /*__inner_css_start__*/
35
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SBubble_132zu_gg_ {\n fill: #2bb3ff;\n stroke: #fff;\n stroke-width: 2px;\n transition-property: cx, cy;\n transition-duration: var(--duration_132zu);\n transition-timing-function: ease-in-out;\n opacity: 0.5\n}\n\n.___SBubble_132zu_gg_:hover {\n opacity: 0.8;\n }\n\n.___SBubble_132zu_gg_.__color_132zu_gg_ {\n fill: var(--color_132zu);\n}\n\n.___SCenter_132zu_gg_ {\n text-anchor: middle;\n font-size: 11px;\n stroke: #2bb3ff;\n}\n\n.___SCenter_132zu_gg_.__color_132zu_gg_ {\n stroke: var(--color_132zu);\n}\n\n.___SLabel_132zu_gg_ {\n fill: #2bb3ff;\n}\n\n.___SLabel_132zu_gg_._position_right_132zu_gg_ {\n text-anchor: end;\n}\n\n.___SLabel_132zu_gg_._position_left_132zu_gg_ {\n text-anchor: start;\n}\n\n.___SLabel_132zu_gg_.__color_132zu_gg_ {\n fill: var(--color_132zu);\n}\n"
35
+ ".___SBubble_u3846_gg_{fill:#2bb3ff;stroke:#fff;stroke-width:2px;transition-property:cx,cy;transition-duration:var(--duration_u3846);transition-timing-function:ease-in-out;opacity:.5}.___SBubble_u3846_gg_:hover{opacity:.8}.___SBubble_u3846_gg_.__color_u3846_gg_{fill:var(--color_u3846)}.___SCenter_u3846_gg_{text-anchor:middle;font-size:11px;stroke:#2bb3ff}.___SCenter_u3846_gg_.__color_u3846_gg_{stroke:var(--color_u3846)}.___SLabel_u3846_gg_{fill:#2bb3ff}.___SLabel_u3846_gg_._position_right_u3846_gg_{text-anchor:end}.___SLabel_u3846_gg_._position_left_u3846_gg_{text-anchor:start}.___SLabel_u3846_gg_.__color_u3846_gg_{fill:var(--color_u3846)}"
36
36
  /*__inner_css_end__*/
37
- , "132zu_gg_")
37
+ , "u3846_gg_")
38
38
  /*__reshadow_css_end__*/
39
39
  , {
40
- "__SBubble": "___SBubble_132zu_gg_",
41
- "--duration": "--duration_132zu",
42
- "_color": "__color_132zu_gg_",
43
- "--color": "--color_132zu",
44
- "__SCenter": "___SCenter_132zu_gg_",
45
- "__SLabel": "___SLabel_132zu_gg_",
46
- "_position_right": "_position_right_132zu_gg_",
47
- "_position_left": "_position_left_132zu_gg_"
40
+ "__SBubble": "___SBubble_u3846_gg_",
41
+ "--duration": "--duration_u3846",
42
+ "_color": "__color_u3846_gg_",
43
+ "--color": "--color_u3846",
44
+ "__SCenter": "___SCenter_u3846_gg_",
45
+ "__SLabel": "___SLabel_u3846_gg_",
46
+ "_position_right": "_position_right_u3846_gg_",
47
+ "_position_left": "_position_left_u3846_gg_"
48
48
  });
49
49
 
50
50
  var BubbleRoot = /*#__PURE__*/function (_Component) {
package/lib/es6/Donut.js CHANGED
@@ -34,16 +34,16 @@ var style = (
34
34
  /*__reshadow_css_start__*/
35
35
  _sstyled.insert(
36
36
  /*__inner_css_start__*/
37
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SPie_ncixh_gg_ {\n stroke: #ffffff;\n fill: #2bb3ff;\n}\n\n.___SPie_ncixh_gg_.__color_ncixh_gg_ {\n fill: var(--color_ncixh);\n}\n\n.___SEmptyData_ncixh_gg_ {\n fill: #e0e1e9;\n}\n\n.___SEmptyData_ncixh_gg_.__color_ncixh_gg_ {\n fill: var(--color_ncixh);\n}\n\n.___SLabel_ncixh_gg_ {\n text-anchor: middle;\n vertical-anchor: middle;\n}\n"
37
+ ".___SPie_141mu_gg_{stroke:#fff;fill:#2bb3ff}.___SPie_141mu_gg_.__color_141mu_gg_{fill:var(--color_141mu)}.___SEmptyData_141mu_gg_{fill:#e0e1e9}.___SEmptyData_141mu_gg_.__color_141mu_gg_{fill:var(--color_141mu)}.___SLabel_141mu_gg_{text-anchor:middle;vertical-anchor:middle}"
38
38
  /*__inner_css_end__*/
39
- , "ncixh_gg_")
39
+ , "141mu_gg_")
40
40
  /*__reshadow_css_end__*/
41
41
  , {
42
- "__SPie": "___SPie_ncixh_gg_",
43
- "_color": "__color_ncixh_gg_",
44
- "--color": "--color_ncixh",
45
- "__SEmptyData": "___SEmptyData_ncixh_gg_",
46
- "__SLabel": "___SLabel_ncixh_gg_"
42
+ "__SPie": "___SPie_141mu_gg_",
43
+ "_color": "__color_141mu_gg_",
44
+ "--color": "--color_141mu",
45
+ "__SEmptyData": "___SEmptyData_141mu_gg_",
46
+ "__SLabel": "___SLabel_141mu_gg_"
47
47
  });
48
48
  var DEFAULT_INSTANCE = Symbol('DEFAULT_INSTANCE');
49
49
 
@@ -391,12 +391,12 @@ _defineProperty(DonutRoot, "defaultProps", function (_ref18) {
391
391
  size: size,
392
392
  halfsize: halfsize,
393
393
  outerRadius: outerRadius
394
- })).innerRadius(innerRadius > increaseFactor ? innerRadius - increaseFactor : innerRadius);
394
+ })).innerRadius(innerRadius);
395
395
  var d3ArcOut = arc().outerRadius(getOuterRadius({
396
396
  size: size,
397
397
  halfsize: halfsize,
398
398
  outerRadius: outerRadius
399
- }) + increaseFactor).innerRadius(innerRadius > increaseFactor ? innerRadius - increaseFactor : innerRadius);
399
+ }) + increaseFactor).innerRadius(innerRadius);
400
400
  var d3Pie = pie().sort(null).value(function (_ref19) {
401
401
  var _ref20 = _slicedToArray(_ref19, 2),
402
402
  value = _ref20[1];
@@ -1 +1 @@
1
- {"version":3,"file":"Donut.js","names":["React","useEffect","useState","arc","pie","interpolate","transition","Component","sstyled","canUseDOM","getOriginChildren","uniqueIDEnhancement","createElement","CONSTANT","DEFAULT_INSTANCE","Symbol","animationInitialPie","halfsize","d3Arc","d3ArcOut","arcs","activeIndexPie","_","ind","d","iStart","Math","PI","startAngle","iEnd","endAngle","t","animationUpdatePie","_current","i","animationHoverPie","selector","duration","innerRadius","outerRadius","selection","select","attrTween","min","max","increaseFactor","getOuterRadius","size","width","height","minORmax","DonutRoot","document","undefined","visible","props","x","clientX","y","clientY","eventEmitter","asProps","virtualElement","getBoundingClientRect","generateGetBoundingClientRect","VIRTUAL_ELEMENT","emit","active","data","id","uid","top","right","bottom","left","Children","d3Pie","pieData","Object","entries","keys","toArray","reduce","acc","child","isValidElement","type","Donut","Pie","push","dataKey","filter","key","includes","sort","a","b","indexOf","minValue","cur","map","find","$animationActivePie","animationActivePie","onMouseMove","bindHandlerTooltip","onMouseLeave","onMouseOver","e","target","getAttribute","onMouseOut","prevProps","$rootProps","selectAll","each","dataHintsHandler","establishDataType","Element","k","getArcs","style","value","SPie","styles","color","name","other","isMount","setIsMount","describeValueEntity","EmptyData","SEmptyData","Label","SLabel","children","setTitle"],"sources":["../../src/Donut.jsx"],"sourcesContent":["import React, { useEffect, useState } from 'react';\nimport { arc, pie } from 'd3-shape';\nimport { interpolate } from 'd3-interpolate';\nimport { transition } from 'd3-transition';\nimport { Component, sstyled } from '@semcore/core';\nimport canUseDOM from '@semcore/utils/lib/canUseDOM';\nimport getOriginChildren from '@semcore/utils/lib/getOriginChildren';\nimport uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';\nimport createElement from './createElement';\nimport { CONSTANT } from './utils';\n\nimport style from './style/donut.shadow.css';\n\nconst DEFAULT_INSTANCE = Symbol('DEFAULT_INSTANCE');\n\nfunction animationInitialPie({ halfsize, d3Arc, d3ArcOut, arcs, activeIndexPie }) {\n return function (_, ind) {\n const d = arcs[ind];\n if (!d) return () => '';\n const iStart = interpolate(halfsize ? -Math.PI / 2 : 0, d.startAngle);\n const iEnd = interpolate(halfsize ? -Math.PI / 2 : 0, d.endAngle);\n return function (t) {\n d.startAngle = iStart(t);\n d.endAngle = iEnd(t);\n return ind === activeIndexPie ? d3ArcOut(d) : d3Arc(d);\n };\n };\n}\n\nfunction animationUpdatePie({ halfsize, arcs, d3Arc }) {\n return function (_, ind) {\n const d = arcs[ind];\n if (this._current) {\n const i = interpolate(this._current, d);\n this._current = i(0);\n return function (t) {\n return d3Arc(i(t));\n };\n } else {\n this._current = d;\n return animationInitialPie({ halfsize, arcs, d3Arc })(_, ind);\n }\n };\n}\n\nfunction animationHoverPie({ d, selector, duration, innerRadius, outerRadius }) {\n if (duration > 0) {\n transition()\n .selection()\n .select(selector)\n .transition()\n .duration(duration)\n .attrTween('d', function () {\n if (!d) return () => '';\n const [min, max] = outerRadius;\n const i = interpolate(min, max);\n return function (t) {\n const d3ArcOut = arc().innerRadius(innerRadius).outerRadius(i(t));\n return d3ArcOut(d);\n };\n });\n }\n}\n\nconst increaseFactor = 8;\n\nfunction getOuterRadius({ size, halfsize, outerRadius }) {\n const [width, height] = size;\n const minORmax = halfsize ? Math.max : Math.min;\n return outerRadius || minORmax(width - increaseFactor * 2, height - increaseFactor * 2) / 2;\n}\n\nclass DonutRoot extends Component {\n static displayName = 'Donut';\n static style = style;\n static enhance = [uniqueIDEnhancement()];\n\n static defaultProps = ({\n innerRadius = 0,\n outerRadius,\n halfsize = false,\n $rootProps: { size },\n }) => {\n const d3Arc = arc()\n .outerRadius(getOuterRadius({ size, halfsize, outerRadius }))\n .innerRadius(innerRadius > increaseFactor ? innerRadius - increaseFactor : innerRadius);\n\n const d3ArcOut = arc()\n .outerRadius(getOuterRadius({ size, halfsize, outerRadius }) + increaseFactor)\n .innerRadius(innerRadius > increaseFactor ? innerRadius - increaseFactor : innerRadius);\n\n let d3Pie = pie()\n .sort(null)\n .value(([, value]) => value);\n d3Pie[DEFAULT_INSTANCE] = true;\n\n if (halfsize) {\n d3Pie = d3Pie.startAngle(-Math.PI / 2).endAngle(Math.PI / 2);\n }\n return {\n d3Pie,\n d3Arc,\n d3ArcOut,\n duration: 500,\n };\n };\n\n get id() {\n const { uid, id } = this.asProps;\n return id || uid;\n }\n\n virtualElement = canUseDOM() ? document.createElement('div') : {};\n activeIndexPie = undefined;\n\n generateGetBoundingClientRect(x = 0, y = 0) {\n return () => ({ width: 0, height: 0, top: y, right: x, bottom: y, left: x });\n }\n\n getArcs() {\n const { Children, data, d3Pie } = this.asProps;\n let pieData = Object.entries(data);\n\n if (d3Pie[DEFAULT_INSTANCE]) {\n const keys = React.Children.toArray(getOriginChildren(Children)).reduce((acc, child) => {\n if (React.isValidElement(child) && child.type === Donut.Pie) {\n acc.push(child.props.dataKey);\n }\n return acc;\n }, []);\n pieData = Object.entries(data)\n .filter(([key]) => keys.includes(key))\n .sort(([a], [b]) => (keys.indexOf(a) > keys.indexOf(b) ? 1 : -1));\n }\n const minValue =\n pieData.reduce((acc, cur) => {\n if (cur[1]) acc += cur[1];\n return acc;\n }, 0) / 100;\n pieData = pieData.map((d) => {\n if (d[1] && d[1] < minValue) d[1] = minValue;\n return d;\n });\n return d3Pie(pieData);\n }\n\n bindHandlerTooltip =\n (visible, props) =>\n ({ clientX: x, clientY: y }) => {\n const { eventEmitter } = this.asProps;\n this.virtualElement.getBoundingClientRect = this.generateGetBoundingClientRect(x, y);\n this.virtualElement[CONSTANT.VIRTUAL_ELEMENT] = true;\n eventEmitter.emit('onTooltipVisible', visible, props, this.virtualElement);\n };\n\n animationActivePie = (props) => {\n let { duration, innerRadius } = this.asProps;\n const { active, data, selector } = props;\n innerRadius = innerRadius > increaseFactor ? innerRadius - increaseFactor : innerRadius;\n const outerRadius = getOuterRadius(this.asProps);\n active\n ? animationHoverPie({\n d: data,\n selector: `#${this.id} ${selector}`,\n duration: duration === 0 ? 0 : 300,\n innerRadius,\n outerRadius: [outerRadius, outerRadius + increaseFactor],\n })\n : animationHoverPie({\n d: data,\n selector: `#${this.id} ${selector}`,\n duration: duration === 0 ? 0 : 300,\n innerRadius,\n outerRadius: [outerRadius + increaseFactor, outerRadius],\n });\n };\n\n getPieProps(props, ind) {\n const { d3Arc, d3ArcOut } = this.asProps;\n const { active } = props;\n const data = this.arcs.find((arc) => arc.data[0] === props.dataKey);\n if (active) {\n this.activeIndexPie = ind;\n }\n\n return {\n data,\n d3Arc,\n d3ArcOut,\n $animationActivePie: this.animationActivePie,\n onMouseMove: this.bindHandlerTooltip(true, props),\n onMouseLeave: this.bindHandlerTooltip(false, props),\n onMouseOver: (e) => {\n !active &&\n this.animationActivePie({\n active: true,\n data,\n selector: `[d=\"${e.target.getAttribute('d')}\"]`,\n });\n },\n onMouseOut: (e) => {\n !active &&\n this.animationActivePie({\n active: false,\n data,\n selector: `[d=\"${e.target.getAttribute('d')}\"]`,\n });\n },\n };\n }\n\n getEmptyDataProps() {\n const { d3Arc } = this.asProps;\n return {\n d3Arc,\n };\n }\n\n componentDidUpdate(prevProps) {\n const { data, duration, d3Arc, halfsize } = this.asProps;\n const arcs = this.arcs;\n if (prevProps.$rootProps.data !== data && duration > 0) {\n transition()\n .selection()\n .selectAll(`#${this.id} [data-ui-name=\"Donut.Pie\"]`)\n .transition()\n .duration(duration)\n .attrTween('d', animationUpdatePie({ d3Arc, arcs, halfsize }));\n }\n }\n\n componentDidMount() {\n const { duration, d3Arc, halfsize, d3ArcOut } = this.asProps;\n const arcs = this.arcs;\n\n if (duration > 0) {\n transition()\n .selection()\n .selectAll(`#${this.id} [data-ui-name=\"Donut.Pie\"]`)\n .each(function (_, ind) {\n this._current = arcs[ind];\n })\n .transition()\n .duration(duration)\n .attrTween(\n 'd',\n animationInitialPie({\n halfsize,\n d3Arc,\n d3ArcOut,\n arcs,\n activeIndexPie: this.activeIndexPie,\n }),\n );\n }\n }\n\n render() {\n const { halfsize, size } = this.asProps;\n this.asProps.dataHintsHandler.establishDataType('values-set');\n const [width, height] = size;\n const Element = this.Element;\n const k = halfsize ? 1 : 2;\n this.arcs = this.getArcs();\n return (\n <Element\n aria-hidden\n id={this.id}\n render=\"g\"\n childrenPosition=\"inside\"\n transform={`translate(${width / 2},${height / k})`}\n />\n );\n }\n}\n\nfunction Pie({\n Element: SPie,\n styles,\n d3Arc,\n data,\n color,\n $animationActivePie,\n active,\n d3ArcOut,\n name,\n dataKey,\n dataHintsHandler,\n ...other\n}) {\n const [isMount, setIsMount] = useState(false);\n\n useEffect(() => {\n // do not run animation on first render\n if (!isMount) {\n setIsMount(true);\n return;\n }\n if (active !== undefined && active !== null) {\n $animationActivePie({ ...other, active, data, selector: `[name=\"${other.name}\"]` });\n }\n }, [active]);\n\n dataHintsHandler.establishDataType('values-set');\n dataHintsHandler.describeValueEntity(dataKey, name);\n\n return sstyled(styles)(\n <SPie render=\"path\" color={color} d={active ? d3ArcOut(data) : d3Arc(data)} />,\n );\n}\n\nfunction EmptyData({ Element: SEmptyData, styles, d3Arc, color }) {\n return sstyled(styles)(\n <SEmptyData render=\"path\" color={color} d={d3Arc({ endAngle: Math.PI * 2, startAngle: 0 })} />,\n );\n}\n\nfunction Label({ Element: SLabel, styles, Children, children, dataHintsHandler }) {\n dataHintsHandler.setTitle('vertical', children);\n\n return sstyled(styles)(\n <SLabel render=\"text\" x=\"0\" y=\"0\" aria-hidden>\n <Children />\n </SLabel>,\n );\n}\n\nconst Donut = createElement(DonutRoot, { Pie, Label, EmptyData });\n\nexport default Donut;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,OAAOA,KAAP,IAAgBC,SAAhB,EAA2BC,QAA3B,QAA2C,OAA3C;AACA,SAASC,GAAT,EAAcC,GAAd,QAAyB,UAAzB;AACA,SAASC,WAAT,QAA4B,gBAA5B;AACA,SAASC,UAAT,QAA2B,eAA3B;AACA,SAASC,SAAT,EAAoBC,OAApB,QAAmC,eAAnC;AACA,OAAOC,SAAP,MAAsB,8BAAtB;AACA,OAAOC,iBAAP,MAA8B,sCAA9B;AACA,OAAOC,mBAAP,MAAgC,6BAAhC;AACA,OAAOC,aAAP,MAA0B,iBAA1B;AACA,SAASC,QAAT,QAAyB,SAAzB;;;;;;;;;;;;;;;;;;AAIA,IAAMC,gBAAgB,GAAGC,MAAM,CAAC,kBAAD,CAA/B;;AAEA,SAASC,mBAAT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EAAA,IAAxBM,MAAwB,UAAxBA,MAAwB;EAAA,IAAhB1G,KAAgB,UAAhBA,KAAgB;EAAA,IAAT2G,KAAS,UAATA,KAAS;EAChE,eAAOrH,OAAO,CAACoH,MAAD,CAAd,eACE,oBAAC,UAAD;IAAA,UAAmB,MAAnB;IAAA,SAAiCC,KAAjC;IAAA,KAA2C3G,KAAK,CAAC;MAAEY,QAAQ,EAAEJ,IAAI,CAACC,EAAL,GAAU,CAAtB;MAAyBC,UAAU,EAAE;IAArC,CAAD;EAAhD,GADF;AAGD;;AAED,SAASyG,KAAT,SAAkF;EAAA;;EAAA,IAAxDC,MAAwD,UAAjEhB,OAAiE;EAAA,IAAhDM,MAAgD,UAAhDA,MAAgD;EAAA,IAAxCjD,QAAwC,UAAxCA,QAAwC;EAAA,IAA9B4D,QAA8B,UAA9BA,QAA8B;EAAA,IAApBnB,gBAAoB,UAApBA,gBAAoB;EAChFA,gBAAgB,CAACoB,QAAjB,CAA0B,UAA1B,EAAsCD,QAAtC;EAEA,eAAO/H,OAAO,CAACoH,MAAD,CAAd,eACE,oBAAC,MAAD;IAAA,UAAe,MAAf;IAAA,KAAwB,GAAxB;IAAA,KAA8B,GAA9B;IAAA;EAAA,iBACE,oBAAC,QAAD,2BADF,CADF;AAKD;;AAED,IAAMrC,KAAK,GAAG3E,aAAa,CAACuC,SAAD,EAAY;EAAEqC,GAAG,EAAHA,GAAF;EAAO6C,KAAK,EAALA,KAAP;EAAcF,SAAS,EAATA;AAAd,CAAZ,CAA3B;AAEA,eAAe5C,KAAf"}
1
+ {"version":3,"file":"Donut.js","names":["React","useEffect","useState","arc","pie","interpolate","transition","Component","sstyled","canUseDOM","getOriginChildren","uniqueIDEnhancement","createElement","CONSTANT","DEFAULT_INSTANCE","Symbol","animationInitialPie","halfsize","d3Arc","d3ArcOut","arcs","activeIndexPie","_","ind","d","iStart","Math","PI","startAngle","iEnd","endAngle","t","animationUpdatePie","_current","i","animationHoverPie","selector","duration","innerRadius","outerRadius","selection","select","attrTween","min","max","increaseFactor","getOuterRadius","size","width","height","minORmax","DonutRoot","document","undefined","visible","props","x","clientX","y","clientY","eventEmitter","asProps","virtualElement","getBoundingClientRect","generateGetBoundingClientRect","VIRTUAL_ELEMENT","emit","active","data","id","uid","top","right","bottom","left","Children","d3Pie","pieData","Object","entries","keys","toArray","reduce","acc","child","isValidElement","type","Donut","Pie","push","dataKey","filter","key","includes","sort","a","b","indexOf","minValue","cur","map","find","$animationActivePie","animationActivePie","onMouseMove","bindHandlerTooltip","onMouseLeave","onMouseOver","e","target","getAttribute","onMouseOut","prevProps","$rootProps","selectAll","each","dataHintsHandler","establishDataType","Element","k","getArcs","style","value","SPie","styles","color","name","other","isMount","setIsMount","describeValueEntity","EmptyData","SEmptyData","Label","SLabel","children","setTitle"],"sources":["../../src/Donut.jsx"],"sourcesContent":["import React, { useEffect, useState } from 'react';\nimport { arc, pie } from 'd3-shape';\nimport { interpolate } from 'd3-interpolate';\nimport { transition } from 'd3-transition';\nimport { Component, sstyled } from '@semcore/core';\nimport canUseDOM from '@semcore/utils/lib/canUseDOM';\nimport getOriginChildren from '@semcore/utils/lib/getOriginChildren';\nimport uniqueIDEnhancement from '@semcore/utils/lib/uniqueID';\nimport createElement from './createElement';\nimport { CONSTANT } from './utils';\n\nimport style from './style/donut.shadow.css';\n\nconst DEFAULT_INSTANCE = Symbol('DEFAULT_INSTANCE');\n\nfunction animationInitialPie({ halfsize, d3Arc, d3ArcOut, arcs, activeIndexPie }) {\n return function (_, ind) {\n const d = arcs[ind];\n if (!d) return () => '';\n const iStart = interpolate(halfsize ? -Math.PI / 2 : 0, d.startAngle);\n const iEnd = interpolate(halfsize ? -Math.PI / 2 : 0, d.endAngle);\n return function (t) {\n d.startAngle = iStart(t);\n d.endAngle = iEnd(t);\n return ind === activeIndexPie ? d3ArcOut(d) : d3Arc(d);\n };\n };\n}\n\nfunction animationUpdatePie({ halfsize, arcs, d3Arc }) {\n return function (_, ind) {\n const d = arcs[ind];\n if (this._current) {\n const i = interpolate(this._current, d);\n this._current = i(0);\n return function (t) {\n return d3Arc(i(t));\n };\n } else {\n this._current = d;\n return animationInitialPie({ halfsize, arcs, d3Arc })(_, ind);\n }\n };\n}\n\nfunction animationHoverPie({ d, selector, duration, innerRadius, outerRadius }) {\n if (duration > 0) {\n transition()\n .selection()\n .select(selector)\n .transition()\n .duration(duration)\n .attrTween('d', function () {\n if (!d) return () => '';\n const [min, max] = outerRadius;\n const i = interpolate(min, max);\n return function (t) {\n const d3ArcOut = arc().innerRadius(innerRadius).outerRadius(i(t));\n return d3ArcOut(d);\n };\n });\n }\n}\n\nconst increaseFactor = 8;\n\nfunction getOuterRadius({ size, halfsize, outerRadius }) {\n const [width, height] = size;\n const minORmax = halfsize ? Math.max : Math.min;\n return outerRadius || minORmax(width - increaseFactor * 2, height - increaseFactor * 2) / 2;\n}\n\nclass DonutRoot extends Component {\n static displayName = 'Donut';\n static style = style;\n static enhance = [uniqueIDEnhancement()];\n\n static defaultProps = ({\n innerRadius = 0,\n outerRadius,\n halfsize = false,\n $rootProps: { size },\n }) => {\n const d3Arc = arc()\n .outerRadius(getOuterRadius({ size, halfsize, outerRadius }))\n .innerRadius(innerRadius);\n\n const d3ArcOut = arc()\n .outerRadius(getOuterRadius({ size, halfsize, outerRadius }) + increaseFactor)\n .innerRadius(innerRadius);\n\n let d3Pie = pie()\n .sort(null)\n .value(([, value]) => value);\n d3Pie[DEFAULT_INSTANCE] = true;\n\n if (halfsize) {\n d3Pie = d3Pie.startAngle(-Math.PI / 2).endAngle(Math.PI / 2);\n }\n return {\n d3Pie,\n d3Arc,\n d3ArcOut,\n duration: 500,\n };\n };\n\n get id() {\n const { uid, id } = this.asProps;\n return id || uid;\n }\n\n virtualElement = canUseDOM() ? document.createElement('div') : {};\n activeIndexPie = undefined;\n\n generateGetBoundingClientRect(x = 0, y = 0) {\n return () => ({ width: 0, height: 0, top: y, right: x, bottom: y, left: x });\n }\n\n getArcs() {\n const { Children, data, d3Pie } = this.asProps;\n let pieData = Object.entries(data);\n\n if (d3Pie[DEFAULT_INSTANCE]) {\n const keys = React.Children.toArray(getOriginChildren(Children)).reduce((acc, child) => {\n if (React.isValidElement(child) && child.type === Donut.Pie) {\n acc.push(child.props.dataKey);\n }\n return acc;\n }, []);\n pieData = Object.entries(data)\n .filter(([key]) => keys.includes(key))\n .sort(([a], [b]) => (keys.indexOf(a) > keys.indexOf(b) ? 1 : -1));\n }\n const minValue =\n pieData.reduce((acc, cur) => {\n if (cur[1]) acc += cur[1];\n return acc;\n }, 0) / 100;\n pieData = pieData.map((d) => {\n if (d[1] && d[1] < minValue) d[1] = minValue;\n return d;\n });\n return d3Pie(pieData);\n }\n\n bindHandlerTooltip =\n (visible, props) =>\n ({ clientX: x, clientY: y }) => {\n const { eventEmitter } = this.asProps;\n this.virtualElement.getBoundingClientRect = this.generateGetBoundingClientRect(x, y);\n this.virtualElement[CONSTANT.VIRTUAL_ELEMENT] = true;\n eventEmitter.emit('onTooltipVisible', visible, props, this.virtualElement);\n };\n\n animationActivePie = (props) => {\n let { duration, innerRadius } = this.asProps;\n const { active, data, selector } = props;\n innerRadius = innerRadius > increaseFactor ? innerRadius - increaseFactor : innerRadius;\n const outerRadius = getOuterRadius(this.asProps);\n active\n ? animationHoverPie({\n d: data,\n selector: `#${this.id} ${selector}`,\n duration: duration === 0 ? 0 : 300,\n innerRadius,\n outerRadius: [outerRadius, outerRadius + increaseFactor],\n })\n : animationHoverPie({\n d: data,\n selector: `#${this.id} ${selector}`,\n duration: duration === 0 ? 0 : 300,\n innerRadius,\n outerRadius: [outerRadius + increaseFactor, outerRadius],\n });\n };\n\n getPieProps(props, ind) {\n const { d3Arc, d3ArcOut } = this.asProps;\n const { active } = props;\n const data = this.arcs.find((arc) => arc.data[0] === props.dataKey);\n if (active) {\n this.activeIndexPie = ind;\n }\n\n return {\n data,\n d3Arc,\n d3ArcOut,\n $animationActivePie: this.animationActivePie,\n onMouseMove: this.bindHandlerTooltip(true, props),\n onMouseLeave: this.bindHandlerTooltip(false, props),\n onMouseOver: (e) => {\n !active &&\n this.animationActivePie({\n active: true,\n data,\n selector: `[d=\"${e.target.getAttribute('d')}\"]`,\n });\n },\n onMouseOut: (e) => {\n !active &&\n this.animationActivePie({\n active: false,\n data,\n selector: `[d=\"${e.target.getAttribute('d')}\"]`,\n });\n },\n };\n }\n\n getEmptyDataProps() {\n const { d3Arc } = this.asProps;\n return {\n d3Arc,\n };\n }\n\n componentDidUpdate(prevProps) {\n const { data, duration, d3Arc, halfsize } = this.asProps;\n const arcs = this.arcs;\n if (prevProps.$rootProps.data !== data && duration > 0) {\n transition()\n .selection()\n .selectAll(`#${this.id} [data-ui-name=\"Donut.Pie\"]`)\n .transition()\n .duration(duration)\n .attrTween('d', animationUpdatePie({ d3Arc, arcs, halfsize }));\n }\n }\n\n componentDidMount() {\n const { duration, d3Arc, halfsize, d3ArcOut } = this.asProps;\n const arcs = this.arcs;\n\n if (duration > 0) {\n transition()\n .selection()\n .selectAll(`#${this.id} [data-ui-name=\"Donut.Pie\"]`)\n .each(function (_, ind) {\n this._current = arcs[ind];\n })\n .transition()\n .duration(duration)\n .attrTween(\n 'd',\n animationInitialPie({\n halfsize,\n d3Arc,\n d3ArcOut,\n arcs,\n activeIndexPie: this.activeIndexPie,\n }),\n );\n }\n }\n\n render() {\n const { halfsize, size } = this.asProps;\n this.asProps.dataHintsHandler.establishDataType('values-set');\n const [width, height] = size;\n const Element = this.Element;\n const k = halfsize ? 1 : 2;\n this.arcs = this.getArcs();\n return (\n <Element\n aria-hidden\n id={this.id}\n render=\"g\"\n childrenPosition=\"inside\"\n transform={`translate(${width / 2},${height / k})`}\n />\n );\n }\n}\n\nfunction Pie({\n Element: SPie,\n styles,\n d3Arc,\n data,\n color,\n $animationActivePie,\n active,\n d3ArcOut,\n name,\n dataKey,\n dataHintsHandler,\n ...other\n}) {\n const [isMount, setIsMount] = useState(false);\n\n useEffect(() => {\n // do not run animation on first render\n if (!isMount) {\n setIsMount(true);\n return;\n }\n if (active !== undefined && active !== null) {\n $animationActivePie({ ...other, active, data, selector: `[name=\"${other.name}\"]` });\n }\n }, [active]);\n\n dataHintsHandler.establishDataType('values-set');\n dataHintsHandler.describeValueEntity(dataKey, name);\n\n return sstyled(styles)(\n <SPie render=\"path\" color={color} d={active ? d3ArcOut(data) : d3Arc(data)} />,\n );\n}\n\nfunction EmptyData({ Element: SEmptyData, styles, d3Arc, color }) {\n return sstyled(styles)(\n <SEmptyData render=\"path\" color={color} d={d3Arc({ endAngle: Math.PI * 2, startAngle: 0 })} />,\n );\n}\n\nfunction Label({ Element: SLabel, styles, Children, children, dataHintsHandler }) {\n dataHintsHandler.setTitle('vertical', children);\n\n return sstyled(styles)(\n <SLabel render=\"text\" x=\"0\" y=\"0\" aria-hidden>\n <Children />\n </SLabel>,\n );\n}\n\nconst Donut = createElement(DonutRoot, { Pie, Label, EmptyData });\n\nexport default Donut;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,OAAOA,KAAP,IAAgBC,SAAhB,EAA2BC,QAA3B,QAA2C,OAA3C;AACA,SAASC,GAAT,EAAcC,GAAd,QAAyB,UAAzB;AACA,SAASC,WAAT,QAA4B,gBAA5B;AACA,SAASC,UAAT,QAA2B,eAA3B;AACA,SAASC,SAAT,EAAoBC,OAApB,QAAmC,eAAnC;AACA,OAAOC,SAAP,MAAsB,8BAAtB;AACA,OAAOC,iBAAP,MAA8B,sCAA9B;AACA,OAAOC,mBAAP,MAAgC,6BAAhC;AACA,OAAOC,aAAP,MAA0B,iBAA1B;AACA,SAASC,QAAT,QAAyB,SAAzB;;;;;;;;;;;;;;;;;;AAIA,IAAMC,gBAAgB,GAAGC,MAAM,CAAC,kBAAD,CAA/B;;AAEA,SAASC,mBAAT,QAAkF;EAAA,IAAnDC,QAAmD,SAAnDA,QAAmD;EAAA,IAAzCC,KAAyC,SAAzCA,KAAyC;EAAA,IAAlCC,QAAkC,SAAlCA,QAAkC;EAAA,IAAxBC,IAAwB,SAAxBA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CAACC,EAAL,GAAU,CAAtB;MAAyBC,UAAU,EAAE;IAArC,CAAD;EAAhD,GADF;AAGD;;AAED,SAASyG,KAAT,SAAkF;EAAA;;EAAA,IAAxDC,MAAwD,UAAjEhB,OAAiE;EAAA,IAAhDM,MAAgD,UAAhDA,MAAgD;EAAA,IAAxCjD,QAAwC,UAAxCA,QAAwC;EAAA,IAA9B4D,QAA8B,UAA9BA,QAA8B;EAAA,IAApBnB,gBAAoB,UAApBA,gBAAoB;EAChFA,gBAAgB,CAACoB,QAAjB,CAA0B,UAA1B,EAAsCD,QAAtC;EAEA,eAAO/H,OAAO,CAACoH,MAAD,CAAd,eACE,oBAAC,MAAD;IAAA,UAAe,MAAf;IAAA,KAAwB,GAAxB;IAAA,KAA8B,GAA9B;IAAA;EAAA,iBACE,oBAAC,QAAD,2BADF,CADF;AAKD;;AAED,IAAMrC,KAAK,GAAG3E,aAAa,CAACuC,SAAD,EAAY;EAAEqC,GAAG,EAAHA,GAAF;EAAO6C,KAAK,EAALA,KAAP;EAAcF,SAAS,EAATA;AAAd,CAAZ,CAA3B;AAEA,eAAe5C,KAAf"}
package/lib/es6/Dots.js CHANGED
@@ -12,18 +12,18 @@ var style = (
12
12
  /*__reshadow_css_start__*/
13
13
  _sstyled.insert(
14
14
  /*__inner_css_start__*/
15
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SDots_1g138_gg_ .___SDot_1g138_gg_ {\n transition-duration: var(--duration_1g138);\n }\n\n.___SDot_1g138_gg_ {\n stroke-width: 2px;\n stroke: #fff;\n r: 6px;\n fill: #2bb3ff;\n transition-property: cx, cy;\n transition-timing-function: ease-in-out;\n}\n\n.___SDot_1g138_gg_.__hide_1g138_gg_ {\n display: none;\n}\n\n.___SDot_1g138_gg_.__active_1g138_gg_ {\n r: 8px;\n}\n\n.___SDot_1g138_gg_.__color_1g138_gg_ {\n fill: var(--color_1g138);\n}\n"
15
+ ".___SDots_1cixh_gg_ .___SDot_1cixh_gg_{transition-duration:var(--duration_1cixh)}.___SDot_1cixh_gg_{stroke-width:2px;stroke:#fff;r:6px;fill:#2bb3ff;transition-property:cx,cy;transition-timing-function:ease-in-out}.___SDot_1cixh_gg_.__hide_1cixh_gg_{display:none}.___SDot_1cixh_gg_.__active_1cixh_gg_{r:8px}.___SDot_1cixh_gg_.__color_1cixh_gg_{fill:var(--color_1cixh)}"
16
16
  /*__inner_css_end__*/
17
- , "1g138_gg_")
17
+ , "1cixh_gg_")
18
18
  /*__reshadow_css_end__*/
19
19
  , {
20
- "__SDots": "___SDots_1g138_gg_",
21
- "__SDot": "___SDot_1g138_gg_",
22
- "--duration": "--duration_1g138",
23
- "_hide": "__hide_1g138_gg_",
24
- "_active": "__active_1g138_gg_",
25
- "_color": "__color_1g138_gg_",
26
- "--color": "--color_1g138"
20
+ "__SDots": "___SDots_1cixh_gg_",
21
+ "__SDot": "___SDot_1cixh_gg_",
22
+ "--duration": "--duration_1cixh",
23
+ "_hide": "__hide_1cixh_gg_",
24
+ "_active": "__active_1cixh_gg_",
25
+ "_color": "__color_1cixh_gg_",
26
+ "--color": "--color_1cixh"
27
27
  });
28
28
  var EXCLUDE_PROPS = ['data', 'scale', 'value', 'display'];
29
29
 
@@ -23,17 +23,17 @@ var style = (
23
23
  /*__reshadow_css_start__*/
24
24
  _sstyled.insert(
25
25
  /*__inner_css_start__*/
26
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SBar_1vizy_gg_ {\n fill: #2bb3ff;\n transition-property: height, width, y;\n transition-duration: var(--duration_1vizy);\n transition-timing-function: ease-in-out;\n}\n\n.___SBar_1vizy_gg_.__color_1vizy_gg_ {\n fill: var(--color_1vizy);\n}\n\n.___SBar_1vizy_gg_.__hide_1vizy_gg_ {\n display: none;\n}\n\n.___SBackground_1vizy_gg_ {\n fill: #c4c7cf;\n}\n"
26
+ ".___SBar_10ufx_gg_{fill:#2bb3ff;transition-property:height,width,y;transition-duration:var(--duration_10ufx);transition-timing-function:ease-in-out}.___SBar_10ufx_gg_.__color_10ufx_gg_{fill:var(--color_10ufx)}.___SBar_10ufx_gg_.__hide_10ufx_gg_{display:none}.___SBackground_10ufx_gg_{fill:#c4c7cf}"
27
27
  /*__inner_css_end__*/
28
- , "1vizy_gg_")
28
+ , "10ufx_gg_")
29
29
  /*__reshadow_css_end__*/
30
30
  , {
31
- "__SBar": "___SBar_1vizy_gg_",
32
- "--duration": "--duration_1vizy",
33
- "_color": "__color_1vizy_gg_",
34
- "--color": "--color_1vizy",
35
- "_hide": "__hide_1vizy_gg_",
36
- "__SBackground": "___SBackground_1vizy_gg_"
31
+ "__SBar": "___SBar_10ufx_gg_",
32
+ "--duration": "--duration_10ufx",
33
+ "_color": "__color_10ufx_gg_",
34
+ "--color": "--color_10ufx",
35
+ "_hide": "__hide_10ufx_gg_",
36
+ "__SBackground": "___SBackground_10ufx_gg_"
37
37
  });
38
38
 
39
39
  var HorizontalBarRoot = /*#__PURE__*/function (_Component) {
package/lib/es6/Hover.js CHANGED
@@ -24,13 +24,13 @@ var style = (
24
24
  /*__reshadow_css_start__*/
25
25
  _sstyled.insert(
26
26
  /*__inner_css_start__*/
27
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SHoverLine_zcouu_gg_ {\n stroke: #a9abb6;\n}\n\n.___SHoverRect_zcouu_gg_ {\n fill: rgba(196, 199, 207, 0.3);\n}\n"
27
+ ".___SHoverLine_1tplg_gg_{stroke:#a9abb6}.___SHoverRect_1tplg_gg_{fill:rgba(196,199,207,.3)}"
28
28
  /*__inner_css_end__*/
29
- , "zcouu_gg_")
29
+ , "1tplg_gg_")
30
30
  /*__reshadow_css_end__*/
31
31
  , {
32
- "__SHoverLine": "___SHoverLine_zcouu_gg_",
33
- "__SHoverRect": "___SHoverRect_zcouu_gg_"
32
+ "__SHoverLine": "___SHoverLine_1tplg_gg_",
33
+ "__SHoverRect": "___SHoverRect_1tplg_gg_"
34
34
  });
35
35
 
36
36
  var Hover = /*#__PURE__*/function (_Component) {
package/lib/es6/Line.js CHANGED
@@ -25,17 +25,17 @@ var style = (
25
25
  /*__reshadow_css_start__*/
26
26
  _sstyled.insert(
27
27
  /*__inner_css_start__*/
28
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SLine_1pg54_gg_ {\n fill: transparent;\n stroke-width: 3;\n stroke: #2bb3ff;\n transition-property: d;\n transition-duration: var(--duration_1pg54);\n transition-timing-function: ease-in-out;\n}\n\n.___SLine_1pg54_gg_.__color_1pg54_gg_ {\n stroke: var(--color_1pg54);\n}\n\n.___SLine_1pg54_gg_.__hide_1pg54_gg_ {\n display: none;\n}\n\n.___SNull_1pg54_gg_ {\n fill: transparent;\n stroke: #c4c7cf;\n stroke-dasharray: 4;\n}\n\n.___SNull_1pg54_gg_.__hide_1pg54_gg_ {\n display: none;\n}\n"
28
+ ".___SLine_5w2vj_gg_{fill:transparent;stroke-width:3;stroke:#2bb3ff;transition-property:d;transition-duration:var(--duration_5w2vj);transition-timing-function:ease-in-out}.___SLine_5w2vj_gg_.__color_5w2vj_gg_{stroke:var(--color_5w2vj)}.___SLine_5w2vj_gg_.__hide_5w2vj_gg_{display:none}.___SNull_5w2vj_gg_{fill:transparent;stroke:#c4c7cf;stroke-dasharray:4}.___SNull_5w2vj_gg_.__hide_5w2vj_gg_{display:none}"
29
29
  /*__inner_css_end__*/
30
- , "1pg54_gg_")
30
+ , "5w2vj_gg_")
31
31
  /*__reshadow_css_end__*/
32
32
  , {
33
- "__SLine": "___SLine_1pg54_gg_",
34
- "--duration": "--duration_1pg54",
35
- "_color": "__color_1pg54_gg_",
36
- "--color": "--color_1pg54",
37
- "_hide": "__hide_1pg54_gg_",
38
- "__SNull": "___SNull_1pg54_gg_"
33
+ "__SLine": "___SLine_5w2vj_gg_",
34
+ "--duration": "--duration_5w2vj",
35
+ "_color": "__color_5w2vj_gg_",
36
+ "--color": "--color_5w2vj",
37
+ "_hide": "__hide_5w2vj_gg_",
38
+ "__SNull": "___SNull_5w2vj_gg_"
39
39
  });
40
40
 
41
41
  var LineRoot = /*#__PURE__*/function (_Component) {
package/lib/es6/Plot.js CHANGED
@@ -31,13 +31,13 @@ var style = (
31
31
  /*__reshadow_css_start__*/
32
32
  _sstyled.insert(
33
33
  /*__inner_css_start__*/
34
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SPlot_yjcvy_gg_ {\n overflow: hidden;\n}\n\n.___SPlot_yjcvy_gg_:active,\n.___SPlot_yjcvy_gg_:focus {\n outline: 0;\n text-decoration: none;\n}\n\nforeignObject[data-aria-only] {\n pointer-events: none;\n}\n\n.___SPlot_yjcvy_gg_.__keyboardFocused_yjcvy_gg_ {\n border: 1px solid #008ff8;\n box-shadow: 0 0 0 3px rgba(0, 143, 248, 0.2);\n}\n"
34
+ ".___SPlot_lq6m7_gg_{overflow:hidden}.___SPlot_lq6m7_gg_:active,.___SPlot_lq6m7_gg_:focus{outline:0;text-decoration:none}foreignObject[data-aria-only]{pointer-events:none}.___SPlot_lq6m7_gg_.__keyboardFocused_lq6m7_gg_{border:1px solid #008ff8;box-shadow:0 0 0 3px rgba(0, 143, 248, 0.2)}"
35
35
  /*__inner_css_end__*/
36
- , "yjcvy_gg_")
36
+ , "lq6m7_gg_")
37
37
  /*__reshadow_css_end__*/
38
38
  , {
39
- "__SPlot": "___SPlot_yjcvy_gg_",
40
- "_keyboardFocused": "__keyboardFocused_yjcvy_gg_"
39
+ "__SPlot": "___SPlot_lq6m7_gg_",
40
+ "_keyboardFocused": "__keyboardFocused_lq6m7_gg_"
41
41
  });
42
42
 
43
43
  var PlotRoot = /*#__PURE__*/function (_Component) {
@@ -34,20 +34,20 @@ var style = (
34
34
  /*__reshadow_css_start__*/
35
35
  _sstyled.insert(
36
36
  /*__inner_css_start__*/
37
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SRadian_4yuoa_gg_ {\n cursor: pointer;\n fill: #008ff8;\n}\n\n.___SLine_4yuoa_gg_ {\n stroke: #008ff8;\n}\n\n.___SLine_4yuoa_gg_.__color_4yuoa_gg_ {\n stroke: var(--color_4yuoa);\n}\n\n.___SCap_4yuoa_gg_ {\n transition: r 0.1s;\n}\n\n.___SLabel_4yuoa_gg_ {\n fill: var(--color_4yuoa);\n cursor: var(--text-cursor_4yuoa);\n}\n\n.___SRadian_4yuoa_gg_:hover .___SLabel_4yuoa_gg_ {\n fill: var(--color-hovered_4yuoa);\n}\n\n@media (prefers-reduced-motion) {\n .___SLineCap_4yuoa_gg_ {\n transition: none;\n }\n}\n"
37
+ ".___SRadian_snqov_gg_{cursor:pointer;fill:#008ff8}.___SLine_snqov_gg_{stroke:#008ff8}.___SLine_snqov_gg_.__color_snqov_gg_{stroke:var(--color_snqov)}.___SCap_snqov_gg_{transition:r .1s}.___SLabel_snqov_gg_{fill:var(--color_snqov);cursor:var(--text-cursor_snqov)}.___SRadian_snqov_gg_:hover .___SLabel_snqov_gg_{fill:var(--color-hovered_snqov)}@media (prefers-reduced-motion){.___SLineCap_snqov_gg_{transition:none}}"
38
38
  /*__inner_css_end__*/
39
- , "4yuoa_gg_")
39
+ , "snqov_gg_")
40
40
  /*__reshadow_css_end__*/
41
41
  , {
42
- "__SRadian": "___SRadian_4yuoa_gg_",
43
- "__SLine": "___SLine_4yuoa_gg_",
44
- "_color": "__color_4yuoa_gg_",
45
- "--color": "--color_4yuoa",
46
- "__SCap": "___SCap_4yuoa_gg_",
47
- "__SLabel": "___SLabel_4yuoa_gg_",
48
- "--text-cursor": "--text-cursor_4yuoa",
49
- "--color-hovered": "--color-hovered_4yuoa",
50
- "__SLineCap": "___SLineCap_4yuoa_gg_"
42
+ "__SRadian": "___SRadian_snqov_gg_",
43
+ "__SLine": "___SLine_snqov_gg_",
44
+ "_color": "__color_snqov_gg_",
45
+ "--color": "--color_snqov",
46
+ "__SCap": "___SCap_snqov_gg_",
47
+ "__SLabel": "___SLabel_snqov_gg_",
48
+ "--text-cursor": "--text-cursor_snqov",
49
+ "--color-hovered": "--color-hovered_snqov",
50
+ "__SLineCap": "___SLineCap_snqov_gg_"
51
51
  });
52
52
  var baseAngle = -Math.PI / 2; // The top vertical line
53
53
 
@@ -25,19 +25,19 @@ var style = (
25
25
  /*__reshadow_css_start__*/
26
26
  _sstyled.insert(
27
27
  /*__inner_css_start__*/
28
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SReferenceLine_p6rco_gg_ {\n fill: none;\n stroke: #a9abb6;\n}\n\n.___STitle_p6rco_gg_ {\n font-size: 12px;\n fill: #6c6e79;\n transform-origin: var(--transform-origin_p6rco);\n}\n\n.___STitle_p6rco_gg_._position_top_p6rco_gg_ {\n text-anchor: middle;\n}\n\n.___STitle_p6rco_gg_._position_bottom_p6rco_gg_ {\n text-anchor: middle;\n alignment-baseline: hanging;\n}\n\n.___STitle_p6rco_gg_._position_right_p6rco_gg_ {\n transform: rotate(-90deg);\n alignment-baseline: middle;\n text-anchor: middle;\n}\n\n.___STitle_p6rco_gg_._position_left_p6rco_gg_ {\n transform: rotate(-90deg);\n text-anchor: middle;\n alignment-baseline: middle;\n}\n\n.___SBackground_p6rco_gg_ {\n fill: rgba(196, 199, 207, 0.2);\n}\n"
28
+ ".___SReferenceLine_1co9s_gg_{fill:none;stroke:#a9abb6}.___STitle_1co9s_gg_{font-size:12px;fill:#6c6e79;transform-origin:var(--transform-origin_1co9s)}.___STitle_1co9s_gg_._position_top_1co9s_gg_{text-anchor:middle}.___STitle_1co9s_gg_._position_bottom_1co9s_gg_{text-anchor:middle;alignment-baseline:hanging}.___STitle_1co9s_gg_._position_right_1co9s_gg_{transform:rotate(-90deg);alignment-baseline:middle;text-anchor:middle}.___STitle_1co9s_gg_._position_left_1co9s_gg_{transform:rotate(-90deg);text-anchor:middle;alignment-baseline:middle}.___SBackground_1co9s_gg_{fill:rgba(196,199,207,.2)}"
29
29
  /*__inner_css_end__*/
30
- , "p6rco_gg_")
30
+ , "1co9s_gg_")
31
31
  /*__reshadow_css_end__*/
32
32
  , {
33
- "__SReferenceLine": "___SReferenceLine_p6rco_gg_",
34
- "__STitle": "___STitle_p6rco_gg_",
35
- "--transform-origin": "--transform-origin_p6rco",
36
- "_position_top": "_position_top_p6rco_gg_",
37
- "_position_bottom": "_position_bottom_p6rco_gg_",
38
- "_position_right": "_position_right_p6rco_gg_",
39
- "_position_left": "_position_left_p6rco_gg_",
40
- "__SBackground": "___SBackground_p6rco_gg_"
33
+ "__SReferenceLine": "___SReferenceLine_1co9s_gg_",
34
+ "__STitle": "___STitle_1co9s_gg_",
35
+ "--transform-origin": "--transform-origin_1co9s",
36
+ "_position_top": "_position_top_1co9s_gg_",
37
+ "_position_bottom": "_position_bottom_1co9s_gg_",
38
+ "_position_right": "_position_right_1co9s_gg_",
39
+ "_position_left": "_position_left_1co9s_gg_",
40
+ "__SBackground": "___SBackground_1co9s_gg_"
41
41
  });
42
42
  var side2direction = {
43
43
  left: 'vertical',
@@ -30,16 +30,16 @@ var style = (
30
30
  /*__reshadow_css_start__*/
31
31
  _sstyled.insert(
32
32
  /*__inner_css_start__*/
33
- ":root {\n\n /* DEPRECATED START\n Deprecated variables should never be used in\n components styles but preserved for backward\n compatibility if they used in projects\n like `<Badge bg=\"red\">alpha</Badge>`\n */\n /* DEPRECATED END */\n}\n\n.___SScatterPlot_1nqtm_gg_ {\n fill: #2bb3ff;\n transition-property: cx, cy;\n transition-duration: var(--duration_1nqtm);\n transition-timing-function: ease-in-out;\n opacity: 0.5\n}\n\n.___SScatterPlot_1nqtm_gg_:hover {\n opacity: 0.8;\n }\n\n.___SScatterPlot_1nqtm_gg_.__color_1nqtm_gg_ {\n fill: var(--color_1nqtm);\n}\n\n.___SValue_1nqtm_gg_ {\n text-anchor: middle;\n font-size: 10px;\n stroke: #008ff8;\n}\n\n.___SValue_1nqtm_gg_.__color_1nqtm_gg_ {\n stroke: var(--color_1nqtm);\n}\n"
33
+ ".___SScatterPlot_1mawy_gg_{fill:#2bb3ff;transition-property:cx,cy;transition-duration:var(--duration_1mawy);transition-timing-function:ease-in-out;opacity:.5}.___SScatterPlot_1mawy_gg_:hover{opacity:.8}.___SScatterPlot_1mawy_gg_.__color_1mawy_gg_{fill:var(--color_1mawy)}.___SValue_1mawy_gg_{text-anchor:middle;font-size:10px;stroke:#008ff8}.___SValue_1mawy_gg_.__color_1mawy_gg_{stroke:var(--color_1mawy)}"
34
34
  /*__inner_css_end__*/
35
- , "1nqtm_gg_")
35
+ , "1mawy_gg_")
36
36
  /*__reshadow_css_end__*/
37
37
  , {
38
- "__SScatterPlot": "___SScatterPlot_1nqtm_gg_",
39
- "--duration": "--duration_1nqtm",
40
- "_color": "__color_1nqtm_gg_",
41
- "--color": "--color_1nqtm",
42
- "__SValue": "___SValue_1nqtm_gg_"
38
+ "__SScatterPlot": "___SScatterPlot_1mawy_gg_",
39
+ "--duration": "--duration_1mawy",
40
+ "_color": "__color_1mawy_gg_",
41
+ "--color": "--color_1mawy",
42
+ "__SValue": "___SValue_1mawy_gg_"
43
43
  });
44
44
 
45
45
  var ScatterPlotRoot = /*#__PURE__*/function (_Component) {