@semcore/d3-chart 3.5.0 → 3.6.0-test.0
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.
- package/CHANGELOG.md +7 -1
- package/lib/cjs/Area.js +9 -9
- package/lib/cjs/Axis.js +14 -14
- package/lib/cjs/Bar.js +8 -8
- package/lib/cjs/Bubble.js +10 -10
- package/lib/cjs/Donut.js +23 -14
- package/lib/cjs/Donut.js.map +1 -1
- package/lib/cjs/Dots.js +9 -9
- package/lib/cjs/HorizontalBar.js +8 -8
- package/lib/cjs/Hover.js +3 -3
- package/lib/cjs/Line.js +8 -8
- package/lib/cjs/Plot.js +3 -3
- package/lib/cjs/Radar.js +17 -17
- package/lib/cjs/RadialTree.js +12 -12
- package/lib/cjs/ReferenceLine.js +9 -9
- package/lib/cjs/ScatterPlot.js +7 -7
- package/lib/cjs/Tooltip.js +8 -8
- package/lib/cjs/Venn.js +7 -7
- package/lib/cjs/a11y/PlotA11yModule.js +2 -2
- package/lib/cjs/a11y/PlotA11yView.js +3 -3
- package/lib/cjs/a11y/translations/view/de.json +1 -1
- package/lib/cjs/a11y/translations/view/en.csv +1 -0
- package/lib/cjs/a11y/translations/view/es.json +1 -1
- package/lib/cjs/a11y/translations/view/it.json +1 -1
- package/lib/cjs/a11y/translations/view/pl.json +1 -1
- package/lib/cjs/a11y/translations/view/pt.json +1 -1
- package/lib/cjs/a11y/translations/view/zh.json +1 -1
- package/lib/cjs/types/Donut.d.js.map +1 -1
- package/lib/es6/Area.js +9 -9
- package/lib/es6/Axis.js +14 -14
- package/lib/es6/Bar.js +8 -8
- package/lib/es6/Bubble.js +10 -10
- package/lib/es6/Donut.js +23 -14
- package/lib/es6/Donut.js.map +1 -1
- package/lib/es6/Dots.js +9 -9
- package/lib/es6/HorizontalBar.js +8 -8
- package/lib/es6/Hover.js +3 -3
- package/lib/es6/Line.js +8 -8
- package/lib/es6/Plot.js +3 -3
- package/lib/es6/Radar.js +17 -17
- package/lib/es6/RadialTree.js +12 -12
- package/lib/es6/ReferenceLine.js +9 -9
- package/lib/es6/ScatterPlot.js +7 -7
- package/lib/es6/Tooltip.js +8 -8
- package/lib/es6/Venn.js +7 -7
- package/lib/es6/a11y/PlotA11yModule.js +2 -2
- package/lib/es6/a11y/PlotA11yView.js +3 -3
- package/lib/es6/a11y/translations/view/de.json +1 -1
- package/lib/es6/a11y/translations/view/en.csv +1 -0
- package/lib/es6/a11y/translations/view/es.json +1 -1
- package/lib/es6/a11y/translations/view/it.json +1 -1
- package/lib/es6/a11y/translations/view/pl.json +1 -1
- package/lib/es6/a11y/translations/view/pt.json +1 -1
- package/lib/es6/a11y/translations/view/zh.json +1 -1
- package/lib/es6/types/Donut.d.js.map +1 -1
- package/lib/types/Donut.d.ts +4 -0
- package/package.json +6 -6
package/lib/cjs/RadialTree.js
CHANGED
|
@@ -27,18 +27,18 @@ var _createElement = _interopRequireDefault(require("./createElement"));
|
|
|
27
27
|
var _utils = require("./utils");
|
|
28
28
|
var _excluded = ["data"];
|
|
29
29
|
/*__reshadow-styles__:"./style/radial-tree.shadow.css"*/
|
|
30
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
31
|
-
"__SRadian": "
|
|
32
|
-
"__SLine": "
|
|
33
|
-
"_color": "
|
|
34
|
-
"--color": "--
|
|
35
|
-
"_transparent": "
|
|
36
|
-
"__SCap": "
|
|
37
|
-
"__SIcon": "
|
|
38
|
-
"__SLabel": "
|
|
39
|
-
"--text-cursor": "--text-
|
|
40
|
-
"--color-hovered": "--color-
|
|
41
|
-
"__SLineCap": "
|
|
30
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SRadian_oo8lm_gg_{cursor:pointer;fill:var(--intergalactic-chart-palette-order-9, #008ff8)}.___SLine_oo8lm_gg_{stroke:var(--intergalactic-chart-palette-order-9, #008ff8)}.___SLine_oo8lm_gg_.__color_oo8lm_gg_{stroke:var(--color_oo8lm)}.___SCap_oo8lm_gg_.__transparent_oo8lm_gg_,.___SIcon_oo8lm_gg_.__transparent_oo8lm_gg_,.___SLabel_oo8lm_gg_.__transparent_oo8lm_gg_,.___SLine_oo8lm_gg_.__transparent_oo8lm_gg_{opacity:.3}.___SCap_oo8lm_gg_{transition:r .1s}.___SLabel_oo8lm_gg_{fill:var(--color_oo8lm);cursor:var(--text-cursor_oo8lm)}@media (hover:hover){.___SRadian_oo8lm_gg_:hover .___SLabel_oo8lm_gg_{fill:var(--color-hovered_oo8lm)}}@media (prefers-reduced-motion){.___SLineCap_oo8lm_gg_{transition:none}}" /*__inner_css_end__*/, "oo8lm_gg_") /*__reshadow_css_end__*/, {
|
|
31
|
+
"__SRadian": "___SRadian_oo8lm_gg_",
|
|
32
|
+
"__SLine": "___SLine_oo8lm_gg_",
|
|
33
|
+
"_color": "__color_oo8lm_gg_",
|
|
34
|
+
"--color": "--color_oo8lm",
|
|
35
|
+
"_transparent": "__transparent_oo8lm_gg_",
|
|
36
|
+
"__SCap": "___SCap_oo8lm_gg_",
|
|
37
|
+
"__SIcon": "___SIcon_oo8lm_gg_",
|
|
38
|
+
"__SLabel": "___SLabel_oo8lm_gg_",
|
|
39
|
+
"--text-cursor": "--text-cursor_oo8lm",
|
|
40
|
+
"--color-hovered": "--color-hovered_oo8lm",
|
|
41
|
+
"__SLineCap": "___SLineCap_oo8lm_gg_"
|
|
42
42
|
});
|
|
43
43
|
var baseAngle = -Math.PI / 2; // The top vertical line
|
|
44
44
|
var RadialTreeBase = /*#__PURE__*/function (_Component) {
|
package/lib/cjs/ReferenceLine.js
CHANGED
|
@@ -17,15 +17,15 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
17
17
|
var _createElement = _interopRequireDefault(require("./createElement"));
|
|
18
18
|
var _utils = require("./utils");
|
|
19
19
|
/*__reshadow-styles__:"./style/reference-line.shadow.css"*/
|
|
20
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
21
|
-
"__SReferenceLine": "
|
|
22
|
-
"__STitle": "
|
|
23
|
-
"--transform-origin": "--transform-
|
|
24
|
-
"_position_top": "
|
|
25
|
-
"_position_bottom": "
|
|
26
|
-
"_position_right": "
|
|
27
|
-
"_position_left": "
|
|
28
|
-
"__SBackground": "
|
|
20
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SReferenceLine_gs0xf_gg_{fill:none;stroke:var(--intergalactic-chart-grid-x-axis, #c4c7cf)}.___STitle_gs0xf_gg_{font-size:var(--intergalactic-fs-100, 12px);fill:var(--intergalactic-chart-grid-text-label, #6c6e79);transform-origin:var(--transform-origin_gs0xf)}.___STitle_gs0xf_gg_._position_top_gs0xf_gg_{text-anchor:middle}.___STitle_gs0xf_gg_._position_bottom_gs0xf_gg_{text-anchor:middle;alignment-baseline:hanging}.___STitle_gs0xf_gg_._position_left_gs0xf_gg_,.___STitle_gs0xf_gg_._position_right_gs0xf_gg_{transform:rotate(-90deg);text-anchor:middle;alignment-baseline:middle}.___SBackground_gs0xf_gg_{fill:var(--intergalactic-chart-grid-period-bg, rgba(196, 199, 207, 0.2))}" /*__inner_css_end__*/, "gs0xf_gg_") /*__reshadow_css_end__*/, {
|
|
21
|
+
"__SReferenceLine": "___SReferenceLine_gs0xf_gg_",
|
|
22
|
+
"__STitle": "___STitle_gs0xf_gg_",
|
|
23
|
+
"--transform-origin": "--transform-origin_gs0xf",
|
|
24
|
+
"_position_top": "_position_top_gs0xf_gg_",
|
|
25
|
+
"_position_bottom": "_position_bottom_gs0xf_gg_",
|
|
26
|
+
"_position_right": "_position_right_gs0xf_gg_",
|
|
27
|
+
"_position_left": "_position_left_gs0xf_gg_",
|
|
28
|
+
"__SBackground": "___SBackground_gs0xf_gg_"
|
|
29
29
|
});
|
|
30
30
|
var side2direction = {
|
|
31
31
|
left: 'vertical',
|
package/lib/cjs/ScatterPlot.js
CHANGED
|
@@ -23,13 +23,13 @@ var _utils = require("./utils");
|
|
|
23
23
|
var _ClipPath = _interopRequireDefault(require("./ClipPath"));
|
|
24
24
|
var _Tooltip = _interopRequireDefault(require("./Tooltip"));
|
|
25
25
|
/*__reshadow-styles__:"./style/scatterplot.shadow.css"*/
|
|
26
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
27
|
-
"__SScatterPlot": "
|
|
28
|
-
"--duration": "--
|
|
29
|
-
"_color": "
|
|
30
|
-
"--color": "--
|
|
31
|
-
"_transparent": "
|
|
32
|
-
"__SValue": "
|
|
26
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SScatterPlot_o9a0v_gg_{fill:var(--intergalactic-chart-palette-order-1, #2bb3ff);transition-property:cx,cy;transition-duration:var(--duration_o9a0v);transition-timing-function:ease-in-out;opacity:.5}@media (hover:hover){.___SScatterPlot_o9a0v_gg_:hover{opacity:.8}}.___SScatterPlot_o9a0v_gg_.__color_o9a0v_gg_{fill:var(--color_o9a0v)}.___SScatterPlot_o9a0v_gg_.__transparent_o9a0v_gg_{opacity:.3}.___SValue_o9a0v_gg_{text-anchor:middle;font-size:var(--intergalactic-fs-50, 10px);stroke:var(--intergalactic-chart-palette-order-9, #008ff8)}.___SValue_o9a0v_gg_.__color_o9a0v_gg_{stroke:var(--color_o9a0v)}.___SValue_o9a0v_gg_.__transparent_o9a0v_gg_{opacity:.3}" /*__inner_css_end__*/, "o9a0v_gg_") /*__reshadow_css_end__*/, {
|
|
27
|
+
"__SScatterPlot": "___SScatterPlot_o9a0v_gg_",
|
|
28
|
+
"--duration": "--duration_o9a0v",
|
|
29
|
+
"_color": "__color_o9a0v_gg_",
|
|
30
|
+
"--color": "--color_o9a0v",
|
|
31
|
+
"_transparent": "__transparent_o9a0v_gg_",
|
|
32
|
+
"__SValue": "___SValue_o9a0v_gg_"
|
|
33
33
|
});
|
|
34
34
|
var ScatterPlotRoot = /*#__PURE__*/function (_Component) {
|
|
35
35
|
(0, _inherits2["default"])(ScatterPlotRoot, _Component);
|
package/lib/cjs/Tooltip.js
CHANGED
|
@@ -24,14 +24,14 @@ var _createElement = _interopRequireDefault(require("./createElement"));
|
|
|
24
24
|
var _utils = require("./utils");
|
|
25
25
|
var _excluded = ["Children", "children", "tag"];
|
|
26
26
|
/*__reshadow-styles__:"./style/tooltip.shadow.css"*/
|
|
27
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
28
|
-
"__STooltip": "
|
|
29
|
-
"__STitle": "
|
|
30
|
-
"__SDotGroup": "
|
|
31
|
-
"__SDot": "
|
|
32
|
-
"_color": "
|
|
33
|
-
"--color": "--
|
|
34
|
-
"__SFooter": "
|
|
27
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___STooltip_lj6ve_gg_{font-size:var(--intergalactic-fs-100, 12px);line-height:var(--intergalactic-lh-100, 133%);position:relative;background-color:var(--intergalactic-bg-primary-neutral, #ffffff);border-radius:var(--intergalactic-popper-rounded, 6px);border:1px solid var(--intergalactic-border-secondary, #e0e1e9);box-sizing:border-box;box-shadow:var(--intergalactic-box-shadow-popper, 0px 1px 12px 0px rgba(25, 27, 35, 0.15));padding:var(--intergalactic-spacing-3x, 12px)}.___STitle_lj6ve_gg_{color:var(--intergalactic-text-secondary, #6c6e79);margin-bottom:var(--intergalactic-spacing-2x, 8px)}.___SDotGroup_lj6ve_gg_{display:flex;align-items:center}.___SDot_lj6ve_gg_{width:8px;height:8px;border-radius:50%;margin-right:var(--intergalactic-spacing-2x, 8px);background:var(--intergalactic-icon-secondary-info, #2bb3ff)}.___SDot_lj6ve_gg_.__color_lj6ve_gg_{background:var(--color_lj6ve)}.___SFooter_lj6ve_gg_{background:var(--intergalactic-bg-secondary-neutral, #f4f5f9);padding:var(--intergalactic-spacing-1x, 4px) var(--intergalactic-spacing-3x, 12px);border-radius:0 0 var(--intergalactic-rounded-medium, 6px) var(--intergalactic-rounded-medium, 6px);margin:var(--intergalactic-spacing-3x, 12px) calc(-1*var(--intergalactic-spacing-3x, 12px)) calc(-1*var(--intergalactic-spacing-3x, 12px))}" /*__inner_css_end__*/, "lj6ve_gg_") /*__reshadow_css_end__*/, {
|
|
28
|
+
"__STooltip": "___STooltip_lj6ve_gg_",
|
|
29
|
+
"__STitle": "___STitle_lj6ve_gg_",
|
|
30
|
+
"__SDotGroup": "___SDotGroup_lj6ve_gg_",
|
|
31
|
+
"__SDot": "___SDot_lj6ve_gg_",
|
|
32
|
+
"_color": "__color_lj6ve_gg_",
|
|
33
|
+
"--color": "--color_lj6ve",
|
|
34
|
+
"__SFooter": "___SFooter_lj6ve_gg_"
|
|
35
35
|
});
|
|
36
36
|
var TooltipRoot = /*#__PURE__*/function (_Component) {
|
|
37
37
|
(0, _inherits2["default"])(TooltipRoot, _Component);
|
package/lib/cjs/Venn.js
CHANGED
|
@@ -23,13 +23,13 @@ var _createElement = _interopRequireDefault(require("./createElement"));
|
|
|
23
23
|
var _utils = require("./utils");
|
|
24
24
|
var _Tooltip = _interopRequireDefault(require("./Tooltip"));
|
|
25
25
|
/*__reshadow-styles__:"./style/venn.shadow.css"*/
|
|
26
|
-
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
27
|
-
"__SCircle": "
|
|
28
|
-
"--duration": "--
|
|
29
|
-
"_color": "
|
|
30
|
-
"--color": "--
|
|
31
|
-
"_transparent": "
|
|
32
|
-
"__SIntersection": "
|
|
26
|
+
var style = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SCircle_1y7dg_gg_,.___SIntersection_1y7dg_gg_{stroke:var(--intergalactic-chart-grid-border, #ffffff);stroke-width:2px}.___SCircle_1y7dg_gg_{fill:var(--intergalactic-chart-palette-order-2, #59ddaa);fill-opacity:.5;transition-property:cx,cy;transition-duration:var(--duration_1y7dg);transition-timing-function:ease-in-out}@media (hover:hover){.___SCircle_1y7dg_gg_:hover{fill-opacity:.7}}.___SCircle_1y7dg_gg_.__color_1y7dg_gg_{fill:var(--color_1y7dg)}.___SCircle_1y7dg_gg_.__transparent_1y7dg_gg_{opacity:.3}.___SIntersection_1y7dg_gg_{fill-opacity:0}@media (hover:hover){.___SIntersection_1y7dg_gg_:hover{fill-opacity:.1}}.___SIntersection_1y7dg_gg_.__transparent_1y7dg_gg_{opacity:.3}" /*__inner_css_end__*/, "1y7dg_gg_") /*__reshadow_css_end__*/, {
|
|
27
|
+
"__SCircle": "___SCircle_1y7dg_gg_",
|
|
28
|
+
"--duration": "--duration_1y7dg",
|
|
29
|
+
"_color": "__color_1y7dg_gg_",
|
|
30
|
+
"--color": "--color_1y7dg",
|
|
31
|
+
"_transparent": "__transparent_1y7dg_gg_",
|
|
32
|
+
"__SIntersection": "___SIntersection_1y7dg_gg_"
|
|
33
33
|
});
|
|
34
34
|
var VennRoot = /*#__PURE__*/function (_Component) {
|
|
35
35
|
(0, _inherits2["default"])(VennRoot, _Component);
|
|
@@ -16,8 +16,8 @@ var _intergalacticDynamicLocales = require("./translations/module/__intergalacti
|
|
|
16
16
|
var _WithI18n = require("@semcore/utils/lib/enhances/WithI18n");
|
|
17
17
|
var _flexBox = require("@semcore/flex-box");
|
|
18
18
|
/*__reshadow-styles__:"../style/plotA11yModule.shadow.css"*/
|
|
19
|
-
var styles = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
20
|
-
"__SPlotA11yModule": "
|
|
19
|
+
var styles = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SPlotA11yModule_x9j8u_gg_{-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none;opacity:0}.___SPlotA11yModule_x9j8u_gg_:focus{-webkit-user-select:all;-moz-user-select:all;user-select:all;pointer-events:all;opacity:1}" /*__inner_css_end__*/, "x9j8u_gg_") /*__reshadow_css_end__*/, {
|
|
20
|
+
"__SPlotA11yModule": "___SPlotA11yModule_x9j8u_gg_"
|
|
21
21
|
});
|
|
22
22
|
var globalWasFocused = false;
|
|
23
23
|
var globalNavWithKeyboard = false;
|
|
@@ -21,9 +21,9 @@ var _flexBox = require("@semcore/flex-box");
|
|
|
21
21
|
var _i18nEnhance = require("@semcore/utils/lib/enhances/i18nEnhance");
|
|
22
22
|
var _intergalacticDynamicLocales = require("./translations/view/__intergalactic-dynamic-locales");
|
|
23
23
|
/*__reshadow-styles__:"../style/plotA11yView.shadow.css"*/
|
|
24
|
-
var styles = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".
|
|
25
|
-
"__SPlotA11yView": "
|
|
26
|
-
"_focus-within": "__focus-
|
|
24
|
+
var styles = ( /*__reshadow_css_start__*/_core.sstyled.insert( /*__inner_css_start__*/".___SPlotA11yView_1hwt9_gg_{-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none;opacity:0;background-color:var(--intergalactic-bg-primary-neutral, #ffffff);color:var(--intergalactic-text-primary, #191b23);border:3px solid var(--intergalactic-border-primary, #c4c7cf);font-size:var(--intergalactic-fs-50, 10px);padding:2px;width:200px;height:200px;max-width:80%;max-height:80%;overflow:auto}.___SPlotA11yView_1hwt9_gg_.__focus-within_1hwt9_gg_,.___SPlotA11yView_1hwt9_gg_:focus{-webkit-user-select:all;-moz-user-select:all;user-select:all;pointer-events:all;opacity:1;z-index:var(--intergalactic-z-index-overlay, 500);position:relative;display:block}.___SPlotA11yView_1hwt9_gg_:focus,.___SPlotA11yView_1hwt9_gg_:focus-within{-webkit-user-select:all;-moz-user-select:all;user-select:all;pointer-events:all;opacity:1;z-index:var(--intergalactic-z-index-overlay, 500);position:relative;display:block}.___SPlotA11yView_1hwt9_gg_ a{cursor:pointer;text-decoration:underline;margin-bottom:var(--intergalactic-spacing-2x, 8px);display:block}.___SPlotA11yView_1hwt9_gg_ table,.___SPlotA11yView_1hwt9_gg_ td,.___SPlotA11yView_1hwt9_gg_ th{border:1px solid var(--intergalactic-border-primary, #c4c7cf)}" /*__inner_css_end__*/, "1hwt9_gg_") /*__reshadow_css_end__*/, {
|
|
25
|
+
"__SPlotA11yView": "___SPlotA11yView_1hwt9_gg_",
|
|
26
|
+
"_focus-within": "__focus-within_1hwt9_gg_"
|
|
27
27
|
});
|
|
28
28
|
var PlotA11yView = function PlotA11yView(_ref3) {
|
|
29
29
|
var _ref = arguments[0],
|
|
@@ -39,3 +39,4 @@ identifier,source_phrase,context,translation
|
|
|
39
39
|
"view-data-summary","Data summary","Label for block of text that contains text summary of data table (like trends or clusters)",""
|
|
40
40
|
"view-summary-placeholder","Generating chart data summary","Placeholder for chart data summary that is displayed while summary being generated",""
|
|
41
41
|
"view-table","Data table","Label for table that contains all data that was provided for chart",""
|
|
42
|
+
"data-not-available","n/a","Short phrase or abbreviation that exaplains that data (abstract) is not available",""
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Donut.d.js","names":[],"sources":["../../../src/types/Donut.d.ts"],"sourcesContent":["import { UnknownProperties } from '@semcore/core';\nimport { Context } from './context';\nimport { TooltipType } from './Tooltip';\nimport { IntergalacticD3Component } from './Plot';\n\n/** @deprecated */\nexport interface IDonutProps extends DonutProps, UnknownProperties {}\nexport type DonutProps = Context & {\n /** Inner radius\n * @default 0\n * */\n innerRadius?: number;\n /** Outer radius\n * @default calculated by the formula from width, height\n * */\n outerRadius?: number;\n /** Semi donut */\n halfsize?: boolean;\n /** Animation duration in ms. Set `0` to disable animation.\n * @default 500\n */\n duration?: number;\n};\n\n/** @deprecated */\nexport interface IPieProps extends PieProps, UnknownProperties {}\nexport type PieProps = Context & {\n /**\n * Name of the field in the data\n * */\n dataKey: string;\n /**\n * Human readable name of the segment\n * */\n name: string;\n /** Color pie\n @default #50aef4\n **/\n color?: string;\n /**\n * Active sector\n * */\n active?: boolean;\n /** Enables element transparency */\n transparent?: boolean;\n};\n\n/** @deprecated */\nexport interface IEmptyDataProps extends EmptyDataProps, UnknownProperties {}\nexport type EmptyDataProps = Context & {};\n\n/** @deprecated */\nexport interface ILabelProps extends LabelProps, UnknownProperties {}\nexport type LabelProps = Context & {\n label?: string;\n};\n\ndeclare const Donut: IntergalacticD3Component<'g', DonutProps> & {\n Pie: IntergalacticD3Component<'path', PieProps>;\n EmptyData: IntergalacticD3Component<'path', EmptyDataProps>;\n Label: IntergalacticD3Component<'text', LabelProps>;\n Tooltip: TooltipType<PieProps>;\n};\n\nexport default Donut;\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"Donut.d.js","names":[],"sources":["../../../src/types/Donut.d.ts"],"sourcesContent":["import { UnknownProperties } from '@semcore/core';\nimport { Context } from './context';\nimport { TooltipType } from './Tooltip';\nimport { IntergalacticD3Component } from './Plot';\n\n/** @deprecated */\nexport interface IDonutProps extends DonutProps, UnknownProperties {}\nexport type DonutProps = Context & {\n /** Inner radius\n * @default 0\n * */\n innerRadius?: number;\n /** Outer radius\n * @default calculated by the formula from width, height\n * */\n outerRadius?: number;\n /** Semi donut */\n halfsize?: boolean;\n /** Animation duration in ms. Set `0` to disable animation.\n * @default 500\n */\n duration?: number;\n /** Additional padding between segments in radians.\n * @default 0\n */\n paddingAngle?: number;\n};\n\n/** @deprecated */\nexport interface IPieProps extends PieProps, UnknownProperties {}\nexport type PieProps = Context & {\n /**\n * Name of the field in the data\n * */\n dataKey: string;\n /**\n * Human readable name of the segment\n * */\n name: string;\n /** Color pie\n @default #50aef4\n **/\n color?: string;\n /**\n * Active sector\n * */\n active?: boolean;\n /** Enables element transparency */\n transparent?: boolean;\n};\n\n/** @deprecated */\nexport interface IEmptyDataProps extends EmptyDataProps, UnknownProperties {}\nexport type EmptyDataProps = Context & {};\n\n/** @deprecated */\nexport interface ILabelProps extends LabelProps, UnknownProperties {}\nexport type LabelProps = Context & {\n label?: string;\n};\n\ndeclare const Donut: IntergalacticD3Component<'g', DonutProps> & {\n Pie: IntergalacticD3Component<'path', PieProps>;\n EmptyData: IntergalacticD3Component<'path', EmptyDataProps>;\n Label: IntergalacticD3Component<'text', LabelProps>;\n Tooltip: TooltipType<PieProps>;\n};\n\nexport default Donut;\n"],"mappings":""}
|
package/lib/es6/Area.js
CHANGED
|
@@ -15,15 +15,15 @@ import createElement from './createElement';
|
|
|
15
15
|
import { definedData, scaleOfBandwidth, getNullData, definedNullData, interpolateValue } from './utils';
|
|
16
16
|
import ClipPath from './ClipPath';
|
|
17
17
|
/*__reshadow-styles__:"./style/area.shadow.css"*/
|
|
18
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
|
19
|
-
"__SArea": "
|
|
20
|
-
"_color": "
|
|
21
|
-
"--color": "--
|
|
22
|
-
"_transparent": "
|
|
23
|
-
"__SAreaLine": "
|
|
24
|
-
"--duration": "--
|
|
25
|
-
"__SNull": "
|
|
26
|
-
"_hide": "
|
|
18
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SArea_1py9q_gg_{fill:var(--intergalactic-chart-palette-order-1, #2bb3ff);fill-opacity:.2}.___SArea_1py9q_gg_.__color_1py9q_gg_{fill:var(--color_1py9q)}.___SArea_1py9q_gg_.__transparent_1py9q_gg_{opacity:.3}.___SAreaLine_1py9q_gg_{stroke:var(--intergalactic-chart-palette-order-1, #2bb3ff);stroke-width:3;fill:transparent}.___SAreaLine_1py9q_gg_.__color_1py9q_gg_{stroke:var(--color_1py9q)}.___SAreaLine_1py9q_gg_.__transparent_1py9q_gg_{opacity:.3}.___SAreaLine_1py9q_gg_,.___SArea_1py9q_gg_{transition-property:d;transition-duration:var(--duration_1py9q);transition-timing-function:ease-in-out}.___SNull_1py9q_gg_{fill:transparent;stroke:var(--intergalactic-chart-grid-x-axis, #c4c7cf);stroke-dasharray:4}.___SNull_1py9q_gg_.__hide_1py9q_gg_{display:none}" /*__inner_css_end__*/, "1py9q_gg_") /*__reshadow_css_end__*/, {
|
|
19
|
+
"__SArea": "___SArea_1py9q_gg_",
|
|
20
|
+
"_color": "__color_1py9q_gg_",
|
|
21
|
+
"--color": "--color_1py9q",
|
|
22
|
+
"_transparent": "__transparent_1py9q_gg_",
|
|
23
|
+
"__SAreaLine": "___SAreaLine_1py9q_gg_",
|
|
24
|
+
"--duration": "--duration_1py9q",
|
|
25
|
+
"__SNull": "___SNull_1py9q_gg_",
|
|
26
|
+
"_hide": "__hide_1py9q_gg_"
|
|
27
27
|
});
|
|
28
28
|
var AreaRoot = /*#__PURE__*/function (_Component) {
|
|
29
29
|
_inherits(AreaRoot, _Component);
|
package/lib/es6/Axis.js
CHANGED
|
@@ -12,20 +12,20 @@ import { Component, sstyled } from '@semcore/core';
|
|
|
12
12
|
import createElement from './createElement';
|
|
13
13
|
import { scaleOfBandwidth } from './utils';
|
|
14
14
|
/*__reshadow-styles__:"./style/axis.shadow.css"*/
|
|
15
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
|
16
|
-
"__SAxis": "
|
|
17
|
-
"_hide": "
|
|
18
|
-
"__STick": "
|
|
19
|
-
"__SGrid": "
|
|
20
|
-
"__STitle": "
|
|
21
|
-
"--transform-origin": "--transform-
|
|
22
|
-
"_position_top": "
|
|
23
|
-
"_position_bottom": "
|
|
24
|
-
"_position_right": "
|
|
25
|
-
"_position_left": "
|
|
26
|
-
"_verticalWritingMode": "
|
|
27
|
-
"_position_custom_0": "
|
|
28
|
-
"_position_custom_1": "
|
|
15
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SAxis_1mwa2_gg_{stroke:var(--intergalactic-chart-grid-x-axis, #c4c7cf)}.___SAxis_1mwa2_gg_.__hide_1mwa2_gg_,.___STick_1mwa2_gg_.__hide_1mwa2_gg_{display:none}.___STick_1mwa2_gg_{font-size:var(--intergalactic-fs-100, 12px);fill:var(--intergalactic-chart-grid-text-label, #6c6e79)}.___SGrid_1mwa2_gg_{fill:transparent;stroke:var(--intergalactic-border-secondary, #e0e1e9)}.___STitle_1mwa2_gg_{font-size:var(--intergalactic-fs-100, 12px);fill:var(--intergalactic-text-hint, #6c6e79);transform-origin:var(--transform-origin_1mwa2)}.___STitle_1mwa2_gg_._position_top_1mwa2_gg_{text-anchor:middle}.___STitle_1mwa2_gg_._position_bottom_1mwa2_gg_{text-anchor:middle;alignment-baseline:hanging}.___STitle_1mwa2_gg_._position_left_1mwa2_gg_,.___STitle_1mwa2_gg_._position_right_1mwa2_gg_{transform:rotate(-90deg);text-anchor:middle;alignment-baseline:middle}.___STitle_1mwa2_gg_._position_left_1mwa2_gg_.__verticalWritingMode_1mwa2_gg_,.___STitle_1mwa2_gg_._position_right_1mwa2_gg_.__verticalWritingMode_1mwa2_gg_{writing-mode:vertical-rl;transform:none}.___STick_1mwa2_gg_._position_top_1mwa2_gg_{transform:translateY(-12px);text-anchor:middle}.___STick_1mwa2_gg_._position_bottom_1mwa2_gg_{transform:translateY(12px);text-anchor:middle;alignment-baseline:hanging}.___STick_1mwa2_gg_._position_right_1mwa2_gg_{transform:translateX(16px);text-anchor:start;alignment-baseline:middle}.___STick_1mwa2_gg_._position_left_1mwa2_gg_{transform:translateX(-16px);text-anchor:end;alignment-baseline:middle}.___STick_1mwa2_gg_._position_custom_0_1mwa2_gg_{transform:translateY(12px);text-anchor:middle;alignment-baseline:hanging}.___STick_1mwa2_gg_._position_custom_1_1mwa2_gg_{transform:translateX(-16px);text-anchor:end;alignment-baseline:middle}" /*__inner_css_end__*/, "1mwa2_gg_") /*__reshadow_css_end__*/, {
|
|
16
|
+
"__SAxis": "___SAxis_1mwa2_gg_",
|
|
17
|
+
"_hide": "__hide_1mwa2_gg_",
|
|
18
|
+
"__STick": "___STick_1mwa2_gg_",
|
|
19
|
+
"__SGrid": "___SGrid_1mwa2_gg_",
|
|
20
|
+
"__STitle": "___STitle_1mwa2_gg_",
|
|
21
|
+
"--transform-origin": "--transform-origin_1mwa2",
|
|
22
|
+
"_position_top": "_position_top_1mwa2_gg_",
|
|
23
|
+
"_position_bottom": "_position_bottom_1mwa2_gg_",
|
|
24
|
+
"_position_right": "_position_right_1mwa2_gg_",
|
|
25
|
+
"_position_left": "_position_left_1mwa2_gg_",
|
|
26
|
+
"_verticalWritingMode": "__verticalWritingMode_1mwa2_gg_",
|
|
27
|
+
"_position_custom_0": "_position_custom_0_1mwa2_gg_",
|
|
28
|
+
"_position_custom_1": "_position_custom_1_1mwa2_gg_"
|
|
29
29
|
});
|
|
30
30
|
var CUSTOM_0 = Symbol('custom_0');
|
|
31
31
|
var CUSTOM_1 = Symbol('custom_1');
|
package/lib/es6/Bar.js
CHANGED
|
@@ -13,14 +13,14 @@ import createElement from './createElement';
|
|
|
13
13
|
import ClipPath from './ClipPath';
|
|
14
14
|
import { scaleToBand, roundedPath } from './utils';
|
|
15
15
|
/*__reshadow-styles__:"./style/bar.shadow.css"*/
|
|
16
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
|
17
|
-
"__SBar": "
|
|
18
|
-
"--duration": "--
|
|
19
|
-
"_color": "
|
|
20
|
-
"--color": "--
|
|
21
|
-
"_hide": "
|
|
22
|
-
"_transparent": "
|
|
23
|
-
"__SBackground": "
|
|
16
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SBar_ofx46_gg_{fill:var(--intergalactic-chart-palette-order-1, #2bb3ff);transition-property:height,width,y;transition-duration:var(--duration_ofx46);transition-timing-function:ease-in-out}.___SBar_ofx46_gg_.__color_ofx46_gg_{fill:var(--color_ofx46)}.___SBar_ofx46_gg_.__hide_ofx46_gg_{display:none}.___SBar_ofx46_gg_.__transparent_ofx46_gg_{opacity:.3}.___SBackground_ofx46_gg_{fill:var(--intergalactic-chart-palette-order-other-data, #c4c7cf)}" /*__inner_css_end__*/, "ofx46_gg_") /*__reshadow_css_end__*/, {
|
|
17
|
+
"__SBar": "___SBar_ofx46_gg_",
|
|
18
|
+
"--duration": "--duration_ofx46",
|
|
19
|
+
"_color": "__color_ofx46_gg_",
|
|
20
|
+
"--color": "--color_ofx46",
|
|
21
|
+
"_hide": "__hide_ofx46_gg_",
|
|
22
|
+
"_transparent": "__transparent_ofx46_gg_",
|
|
23
|
+
"__SBackground": "___SBackground_ofx46_gg_"
|
|
24
24
|
});
|
|
25
25
|
export var MIN_HEIGHT = 2;
|
|
26
26
|
var calcPartBarY = function calcPartBarY(y, minHeight, height) {
|
package/lib/es6/Bubble.js
CHANGED
|
@@ -20,16 +20,16 @@ import ClipPath from './ClipPath';
|
|
|
20
20
|
import { CONSTANT, measureText } from './utils';
|
|
21
21
|
import Tooltip from './Tooltip';
|
|
22
22
|
/*__reshadow-styles__:"./style/bubble.shadow.css"*/
|
|
23
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
|
24
|
-
"__SBubble": "
|
|
25
|
-
"--duration": "--
|
|
26
|
-
"_color": "
|
|
27
|
-
"--color": "--
|
|
28
|
-
"_transparent": "
|
|
29
|
-
"__SCenter": "
|
|
30
|
-
"__SLabel": "
|
|
31
|
-
"_position_right": "
|
|
32
|
-
"_position_left": "
|
|
23
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SBubble_436fq_gg_{fill:var(--intergalactic-chart-palette-order-1, #2bb3ff);stroke:var(--intergalactic-chart-grid-border, #ffffff);stroke-width:2px;transition-property:cx,cy;transition-duration:var(--duration_436fq);transition-timing-function:ease-in-out;opacity:.5}@media (hover:hover){.___SBubble_436fq_gg_:hover{opacity:.8}}.___SBubble_436fq_gg_.__color_436fq_gg_{fill:var(--color_436fq)}.___SBubble_436fq_gg_.__transparent_436fq_gg_{opacity:.3}.___SCenter_436fq_gg_{text-anchor:middle;font-size:calc(var(--intergalactic-fs-100, 12px) - 1px);stroke:var(--intergalactic-chart-palette-order-1, #2bb3ff)}.___SCenter_436fq_gg_.__color_436fq_gg_{stroke:var(--color_436fq)}.___SCenter_436fq_gg_.__transparent_436fq_gg_{opacity:.3}.___SLabel_436fq_gg_{fill:var(--intergalactic-chart-palette-order-1, #2bb3ff)}.___SLabel_436fq_gg_._position_right_436fq_gg_{text-anchor:end}.___SLabel_436fq_gg_._position_left_436fq_gg_{text-anchor:start}.___SLabel_436fq_gg_.__color_436fq_gg_{fill:var(--color_436fq)}.___SLabel_436fq_gg_.__transparent_436fq_gg_{opacity:.3}" /*__inner_css_end__*/, "436fq_gg_") /*__reshadow_css_end__*/, {
|
|
24
|
+
"__SBubble": "___SBubble_436fq_gg_",
|
|
25
|
+
"--duration": "--duration_436fq",
|
|
26
|
+
"_color": "__color_436fq_gg_",
|
|
27
|
+
"--color": "--color_436fq",
|
|
28
|
+
"_transparent": "__transparent_436fq_gg_",
|
|
29
|
+
"__SCenter": "___SCenter_436fq_gg_",
|
|
30
|
+
"__SLabel": "___SLabel_436fq_gg_",
|
|
31
|
+
"_position_right": "_position_right_436fq_gg_",
|
|
32
|
+
"_position_left": "_position_left_436fq_gg_"
|
|
33
33
|
});
|
|
34
34
|
var BubbleRoot = /*#__PURE__*/function (_Component) {
|
|
35
35
|
_inherits(BubbleRoot, _Component);
|
package/lib/es6/Donut.js
CHANGED
|
@@ -22,13 +22,13 @@ import createElement from './createElement';
|
|
|
22
22
|
import { CONSTANT } from './utils';
|
|
23
23
|
import Tooltip from './Tooltip';
|
|
24
24
|
/*__reshadow-styles__:"./style/donut.shadow.css"*/
|
|
25
|
-
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".
|
|
26
|
-
"__SPie": "
|
|
27
|
-
"_color": "
|
|
28
|
-
"--color": "--
|
|
29
|
-
"_transparent": "
|
|
30
|
-
"__SEmptyData": "
|
|
31
|
-
"__SLabel": "
|
|
25
|
+
var style = ( /*__reshadow_css_start__*/_sstyled.insert( /*__inner_css_start__*/".___SPie_1idt3_gg_{stroke:var(--intergalactic-chart-grid-border, #ffffff);fill:var(--intergalactic-chart-palette-order-1, #2bb3ff)}.___SPie_1idt3_gg_.__color_1idt3_gg_{fill:var(--color_1idt3)}.___SPie_1idt3_gg_.__transparent_1idt3_gg_{opacity:.3}.___SEmptyData_1idt3_gg_{fill:var(--intergalactic-chart-palette-order-null, #e0e1e9)}.___SEmptyData_1idt3_gg_.__color_1idt3_gg_{fill:var(--color_1idt3)}.___SLabel_1idt3_gg_{text-anchor:middle;vertical-anchor:middle}" /*__inner_css_end__*/, "1idt3_gg_") /*__reshadow_css_end__*/, {
|
|
26
|
+
"__SPie": "___SPie_1idt3_gg_",
|
|
27
|
+
"_color": "__color_1idt3_gg_",
|
|
28
|
+
"--color": "--color_1idt3",
|
|
29
|
+
"_transparent": "__transparent_1idt3_gg_",
|
|
30
|
+
"__SEmptyData": "___SEmptyData_1idt3_gg_",
|
|
31
|
+
"__SLabel": "___SLabel_1idt3_gg_"
|
|
32
32
|
});
|
|
33
33
|
var DEFAULT_INSTANCE = Symbol('DEFAULT_INSTANCE');
|
|
34
34
|
function transitionAnglePie(_ref6) {
|
|
@@ -68,7 +68,8 @@ function transitionRadiusPie(_ref7) {
|
|
|
68
68
|
element = _ref7.element,
|
|
69
69
|
duration = _ref7.duration,
|
|
70
70
|
innerRadius = _ref7.innerRadius,
|
|
71
|
-
outerRadiusStartEnd = _ref7.outerRadiusStartEnd
|
|
71
|
+
outerRadiusStartEnd = _ref7.outerRadiusStartEnd,
|
|
72
|
+
paddingAngle = _ref7.paddingAngle;
|
|
72
73
|
return transition().selection().select(selector).interrupt().transition().duration(duration).attrTween('d', function () {
|
|
73
74
|
var _outerRadiusStartEnd = _slicedToArray(outerRadiusStartEnd, 2),
|
|
74
75
|
start = _outerRadiusStartEnd[0],
|
|
@@ -77,7 +78,7 @@ function transitionRadiusPie(_ref7) {
|
|
|
77
78
|
return function (t) {
|
|
78
79
|
var outerRadiusPX = iOuterRadius(t);
|
|
79
80
|
element.dataset['currentRadius'] = outerRadiusPX;
|
|
80
|
-
var d3ArcOut = arc().innerRadius(innerRadius).outerRadius(outerRadiusPX);
|
|
81
|
+
var d3ArcOut = arc().innerRadius(innerRadius).outerRadius(outerRadiusPX).padAngle(paddingAngle);
|
|
81
82
|
return d3ArcOut(data);
|
|
82
83
|
};
|
|
83
84
|
});
|
|
@@ -92,6 +93,9 @@ function getOuterRadius(_ref8) {
|
|
|
92
93
|
var minORmax = halfsize ? Math.max : Math.min;
|
|
93
94
|
return minORmax(width - increaseFactor * 2, height - increaseFactor * 2) / 2;
|
|
94
95
|
}
|
|
96
|
+
var gradToRad = function gradToRad(grad) {
|
|
97
|
+
return grad * Math.PI / 180;
|
|
98
|
+
};
|
|
95
99
|
var DonutRoot = /*#__PURE__*/function (_Component) {
|
|
96
100
|
_inherits(DonutRoot, _Component);
|
|
97
101
|
var _super = _createSuper(DonutRoot);
|
|
@@ -123,7 +127,8 @@ var DonutRoot = /*#__PURE__*/function (_Component) {
|
|
|
123
127
|
var _this$asProps = _this.asProps,
|
|
124
128
|
duration = _this$asProps.duration,
|
|
125
129
|
innerRadius = _this$asProps.innerRadius,
|
|
126
|
-
d3Arc = _this$asProps.d3Arc
|
|
130
|
+
d3Arc = _this$asProps.d3Arc,
|
|
131
|
+
paddingAngle = _this$asProps.paddingAngle;
|
|
127
132
|
var outerRadius = d3Arc.outerRadius()();
|
|
128
133
|
var outerRadiusStartEnd = active ? [+element.dataset['currentRadius'] || outerRadius, outerRadius + increaseFactor] : [+element.dataset['currentRadius'] || outerRadius, outerRadius];
|
|
129
134
|
if (_this.canAnimatedHover && duration > 0) {
|
|
@@ -133,7 +138,8 @@ var DonutRoot = /*#__PURE__*/function (_Component) {
|
|
|
133
138
|
element: element,
|
|
134
139
|
duration: duration === 0 ? 0 : 300,
|
|
135
140
|
innerRadius: innerRadius,
|
|
136
|
-
outerRadiusStartEnd: outerRadiusStartEnd
|
|
141
|
+
outerRadiusStartEnd: outerRadiusStartEnd,
|
|
142
|
+
paddingAngle: paddingAngle
|
|
137
143
|
});
|
|
138
144
|
}
|
|
139
145
|
});
|
|
@@ -330,6 +336,8 @@ _defineProperty(DonutRoot, "enhance", [uniqueIDEnhancement()]);
|
|
|
330
336
|
_defineProperty(DonutRoot, "defaultProps", function (_ref20) {
|
|
331
337
|
var _ref20$innerRadius = _ref20.innerRadius,
|
|
332
338
|
innerRadius = _ref20$innerRadius === void 0 ? 0 : _ref20$innerRadius,
|
|
339
|
+
_ref20$paddingAngle = _ref20.paddingAngle,
|
|
340
|
+
paddingAngle = _ref20$paddingAngle === void 0 ? 0 : _ref20$paddingAngle,
|
|
333
341
|
outerRadius = _ref20.outerRadius,
|
|
334
342
|
_ref20$halfsize = _ref20.halfsize,
|
|
335
343
|
halfsize = _ref20$halfsize === void 0 ? false : _ref20$halfsize,
|
|
@@ -338,11 +346,11 @@ _defineProperty(DonutRoot, "defaultProps", function (_ref20) {
|
|
|
338
346
|
size: size,
|
|
339
347
|
halfsize: halfsize,
|
|
340
348
|
outerRadius: outerRadius
|
|
341
|
-
})).innerRadius(innerRadius);
|
|
349
|
+
})).innerRadius(innerRadius).padAngle(paddingAngle);
|
|
342
350
|
var d3ArcOut = arc().outerRadius((outerRadius || getOuterRadius({
|
|
343
351
|
size: size,
|
|
344
352
|
halfsize: halfsize
|
|
345
|
-
})) + increaseFactor).innerRadius(innerRadius);
|
|
353
|
+
})) + increaseFactor).innerRadius(innerRadius).padAngle(paddingAngle);
|
|
346
354
|
var d3Pie = pie().sort(null).value(function (_ref21) {
|
|
347
355
|
var _ref22 = _slicedToArray(_ref21, 2),
|
|
348
356
|
value = _ref22[1];
|
|
@@ -356,7 +364,8 @@ _defineProperty(DonutRoot, "defaultProps", function (_ref20) {
|
|
|
356
364
|
d3Pie: d3Pie,
|
|
357
365
|
d3Arc: d3Arc,
|
|
358
366
|
d3ArcOut: d3ArcOut,
|
|
359
|
-
duration: 500
|
|
367
|
+
duration: 500,
|
|
368
|
+
paddingAngle: paddingAngle
|
|
360
369
|
};
|
|
361
370
|
});
|
|
362
371
|
function Pie(_ref17) {
|