@semcore/d3-chart 3.60.2 → 16.0.0-prerelease.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 +6 -0
- package/lib/cjs/AnimatedClipPath.js +3 -4
- package/lib/cjs/AnimatedClipPath.js.map +1 -1
- package/lib/cjs/Area.js +14 -15
- package/lib/cjs/Area.js.map +1 -1
- package/lib/cjs/Axis.js +15 -16
- package/lib/cjs/Axis.js.map +1 -1
- package/lib/cjs/Bar.js +18 -19
- package/lib/cjs/Bar.js.map +1 -1
- package/lib/cjs/Bubble.js +13 -14
- package/lib/cjs/Bubble.js.map +1 -1
- package/lib/cjs/CompactHorizontalBar.js +20 -21
- package/lib/cjs/CompactHorizontalBar.js.map +1 -1
- package/lib/cjs/Donut.js +12 -13
- package/lib/cjs/Donut.js.map +1 -1
- package/lib/cjs/Dots.js +10 -11
- package/lib/cjs/Dots.js.map +1 -1
- package/lib/cjs/GroupBar.js +2 -2
- package/lib/cjs/GroupBar.js.map +1 -1
- package/lib/cjs/HorizontalBar.js +18 -19
- package/lib/cjs/HorizontalBar.js.map +1 -1
- package/lib/cjs/Hover.js +5 -6
- package/lib/cjs/Hover.js.map +1 -1
- package/lib/cjs/Line.js +11 -12
- package/lib/cjs/Line.js.map +1 -1
- package/lib/cjs/Pattern.js +1 -1
- package/lib/cjs/Pattern.js.map +1 -1
- package/lib/cjs/Plot.js +9 -11
- package/lib/cjs/Plot.js.map +1 -1
- package/lib/cjs/Radar.js +23 -24
- package/lib/cjs/Radar.js.map +1 -1
- package/lib/cjs/RadialTree.js +17 -18
- package/lib/cjs/RadialTree.js.map +1 -1
- package/lib/cjs/Reference.js +14 -15
- package/lib/cjs/Reference.js.map +1 -1
- package/lib/cjs/ResponsiveContainer.js +6 -7
- package/lib/cjs/ResponsiveContainer.js.map +1 -1
- package/lib/cjs/ScatterPlot.js +11 -12
- package/lib/cjs/ScatterPlot.js.map +1 -1
- package/lib/cjs/StackBar.js +1 -1
- package/lib/cjs/StackBar.js.map +1 -1
- package/lib/cjs/StackedArea.js +1 -1
- package/lib/cjs/StackedArea.js.map +1 -1
- package/lib/cjs/Tooltip.js +11 -12
- package/lib/cjs/Tooltip.js.map +1 -1
- package/lib/cjs/Venn.js +11 -12
- package/lib/cjs/Venn.js.map +1 -1
- package/lib/cjs/a11y/PlotA11yModule.js +3 -4
- package/lib/cjs/a11y/PlotA11yModule.js.map +1 -1
- package/lib/cjs/a11y/PlotA11yView.js +3 -4
- package/lib/cjs/a11y/PlotA11yView.js.map +1 -1
- package/lib/cjs/a11y/focus.js +1 -1
- package/lib/cjs/a11y/focus.js.map +1 -1
- package/lib/cjs/a11y/hints.js +1 -1
- package/lib/cjs/a11y/hints.js.map +1 -1
- package/lib/cjs/component/Chart/AbstractChart.js +2 -2
- package/lib/cjs/component/Chart/AbstractChart.js.map +1 -1
- package/lib/cjs/component/Chart/AbstractChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/AreaChart.js +3 -3
- package/lib/cjs/component/Chart/AreaChart.js.map +1 -1
- package/lib/cjs/component/Chart/BarChart.js +3 -3
- package/lib/cjs/component/Chart/BarChart.js.map +1 -1
- package/lib/cjs/component/Chart/BubbleChart.js +3 -3
- package/lib/cjs/component/Chart/BubbleChart.js.map +1 -1
- package/lib/cjs/component/Chart/CigaretteChart.js +5 -6
- package/lib/cjs/component/Chart/CigaretteChart.js.map +1 -1
- package/lib/cjs/component/Chart/CompactHorizontalBarChart.js +3 -3
- package/lib/cjs/component/Chart/CompactHorizontalBarChart.js.map +1 -1
- package/lib/cjs/component/Chart/DonutChart.js +3 -3
- package/lib/cjs/component/Chart/DonutChart.js.map +1 -1
- package/lib/cjs/component/Chart/HistogramChart.js +3 -3
- package/lib/cjs/component/Chart/HistogramChart.js.map +1 -1
- package/lib/cjs/component/Chart/LineChart.js +3 -3
- package/lib/cjs/component/Chart/LineChart.js.map +1 -1
- package/lib/cjs/component/Chart/RadarChart.js +3 -3
- package/lib/cjs/component/Chart/RadarChart.js.map +1 -1
- package/lib/cjs/component/Chart/ScatterPlotChart.js +3 -3
- package/lib/cjs/component/Chart/ScatterPlotChart.js.map +1 -1
- package/lib/cjs/component/Chart/VennChart.js +3 -3
- package/lib/cjs/component/Chart/VennChart.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendFlex/LegendFlex.js +7 -9
- package/lib/cjs/component/ChartLegend/LegendFlex/LegendFlex.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js +21 -23
- package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js +8 -10
- package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js.map +1 -1
- package/lib/cjs/component/Cigarette/Cigarette.js +2 -2
- package/lib/cjs/component/Cigarette/Cigarette.js.map +1 -1
- package/lib/cjs/createElement.js +6 -7
- package/lib/cjs/createElement.js.map +1 -1
- package/lib/cjs/style/hover.shadow.css +2 -2
- package/lib/cjs/utils.js +1 -1
- package/lib/cjs/utils.js.map +1 -1
- package/lib/es6/AnimatedClipPath.js +2 -2
- package/lib/es6/AnimatedClipPath.js.map +1 -1
- package/lib/es6/Area.js +14 -14
- package/lib/es6/Area.js.map +1 -1
- package/lib/es6/Axis.js +15 -15
- package/lib/es6/Bar.js +18 -18
- package/lib/es6/Bar.js.map +1 -1
- package/lib/es6/Bubble.js +14 -14
- package/lib/es6/Bubble.js.map +1 -1
- package/lib/es6/CompactHorizontalBar.js +21 -21
- package/lib/es6/CompactHorizontalBar.js.map +1 -1
- package/lib/es6/Donut.js +13 -13
- package/lib/es6/Donut.js.map +1 -1
- package/lib/es6/Dots.js +10 -10
- package/lib/es6/Dots.js.map +1 -1
- package/lib/es6/GroupBar.js +2 -2
- package/lib/es6/GroupBar.js.map +1 -1
- package/lib/es6/HorizontalBar.js +18 -18
- package/lib/es6/HorizontalBar.js.map +1 -1
- package/lib/es6/Hover.js +6 -6
- package/lib/es6/Hover.js.map +1 -1
- package/lib/es6/Line.js +11 -11
- package/lib/es6/Line.js.map +1 -1
- package/lib/es6/Pattern.js +1 -1
- package/lib/es6/Pattern.js.map +1 -1
- package/lib/es6/Plot.js +9 -9
- package/lib/es6/Plot.js.map +1 -1
- package/lib/es6/Radar.js +24 -24
- package/lib/es6/Radar.js.map +1 -1
- package/lib/es6/RadialTree.js +17 -17
- package/lib/es6/RadialTree.js.map +1 -1
- package/lib/es6/Reference.js +14 -14
- package/lib/es6/Reference.js.map +1 -1
- package/lib/es6/ResponsiveContainer.js +5 -5
- package/lib/es6/ResponsiveContainer.js.map +1 -1
- package/lib/es6/ScatterPlot.js +12 -12
- package/lib/es6/ScatterPlot.js.map +1 -1
- package/lib/es6/StackBar.js +1 -1
- package/lib/es6/StackBar.js.map +1 -1
- package/lib/es6/StackedArea.js +1 -1
- package/lib/es6/StackedArea.js.map +1 -1
- package/lib/es6/Tooltip.js +12 -12
- package/lib/es6/Tooltip.js.map +1 -1
- package/lib/es6/Venn.js +12 -12
- package/lib/es6/Venn.js.map +1 -1
- package/lib/es6/a11y/PlotA11yModule.js +4 -4
- package/lib/es6/a11y/PlotA11yModule.js.map +1 -1
- package/lib/es6/a11y/PlotA11yView.js +4 -4
- package/lib/es6/a11y/PlotA11yView.js.map +1 -1
- package/lib/es6/a11y/focus.js +1 -1
- package/lib/es6/a11y/focus.js.map +1 -1
- package/lib/es6/a11y/hints.js +1 -1
- package/lib/es6/a11y/hints.js.map +1 -1
- package/lib/es6/component/Chart/AbstractChart.js +2 -2
- package/lib/es6/component/Chart/AbstractChart.js.map +1 -1
- package/lib/es6/component/Chart/AbstractChart.type.js.map +1 -1
- package/lib/es6/component/Chart/AreaChart.js +2 -2
- package/lib/es6/component/Chart/AreaChart.js.map +1 -1
- package/lib/es6/component/Chart/BarChart.js +2 -2
- package/lib/es6/component/Chart/BarChart.js.map +1 -1
- package/lib/es6/component/Chart/BubbleChart.js +2 -2
- package/lib/es6/component/Chart/BubbleChart.js.map +1 -1
- package/lib/es6/component/Chart/CigaretteChart.js +4 -4
- package/lib/es6/component/Chart/CigaretteChart.js.map +1 -1
- package/lib/es6/component/Chart/CompactHorizontalBarChart.js +2 -2
- package/lib/es6/component/Chart/CompactHorizontalBarChart.js.map +1 -1
- package/lib/es6/component/Chart/DonutChart.js +2 -2
- package/lib/es6/component/Chart/DonutChart.js.map +1 -1
- package/lib/es6/component/Chart/HistogramChart.js +2 -2
- package/lib/es6/component/Chart/HistogramChart.js.map +1 -1
- package/lib/es6/component/Chart/LineChart.js +2 -2
- package/lib/es6/component/Chart/LineChart.js.map +1 -1
- package/lib/es6/component/Chart/RadarChart.js +2 -2
- package/lib/es6/component/Chart/RadarChart.js.map +1 -1
- package/lib/es6/component/Chart/ScatterPlotChart.js +2 -2
- package/lib/es6/component/Chart/ScatterPlotChart.js.map +1 -1
- package/lib/es6/component/Chart/VennChart.js +2 -2
- package/lib/es6/component/Chart/VennChart.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendFlex/LegendFlex.js +7 -7
- package/lib/es6/component/ChartLegend/LegendFlex/LegendFlex.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendItem/LegendItem.js +21 -21
- package/lib/es6/component/ChartLegend/LegendItem/LegendItem.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendTable/LegendTable.js +8 -8
- package/lib/es6/component/ChartLegend/LegendTable/LegendTable.js.map +1 -1
- package/lib/es6/component/Cigarette/Cigarette.js +2 -2
- package/lib/es6/component/Cigarette/Cigarette.js.map +1 -1
- package/lib/es6/createElement.js +5 -5
- package/lib/es6/createElement.js.map +1 -1
- package/lib/es6/style/hover.shadow.css +2 -2
- package/lib/es6/utils.js +1 -1
- package/lib/es6/utils.js.map +1 -1
- package/lib/esm/AnimatedClipPath.mjs +2 -2
- package/lib/esm/Area.mjs +18 -19
- package/lib/esm/Axis.mjs +21 -22
- package/lib/esm/Bar.mjs +21 -22
- package/lib/esm/Bubble.mjs +17 -18
- package/lib/esm/CompactHorizontalBar.mjs +31 -32
- package/lib/esm/Donut.mjs +18 -19
- package/lib/esm/Dots.mjs +14 -15
- package/lib/esm/GroupBar.mjs +1 -1
- package/lib/esm/HorizontalBar.mjs +21 -22
- package/lib/esm/Hover.mjs +11 -12
- package/lib/esm/Line.mjs +15 -16
- package/lib/esm/Pattern.mjs +1 -1
- package/lib/esm/Plot.mjs +10 -11
- package/lib/esm/Radar.mjs +37 -38
- package/lib/esm/RadialTree.mjs +28 -29
- package/lib/esm/Reference.mjs +20 -21
- package/lib/esm/ResponsiveContainer.mjs +5 -5
- package/lib/esm/ScatterPlot.mjs +15 -16
- package/lib/esm/StackBar.mjs +1 -1
- package/lib/esm/StackedArea.mjs +1 -1
- package/lib/esm/Tooltip.mjs +17 -18
- package/lib/esm/Venn.mjs +16 -17
- package/lib/esm/a11y/PlotA11yModule.mjs +9 -10
- package/lib/esm/a11y/PlotA11yView.mjs +6 -7
- package/lib/esm/a11y/focus.mjs +1 -1
- package/lib/esm/a11y/hints.mjs +1 -1
- package/lib/esm/component/Chart/AbstractChart.mjs +2 -2
- package/lib/esm/component/Chart/AreaChart.mjs +2 -2
- package/lib/esm/component/Chart/BarChart.mjs +2 -2
- package/lib/esm/component/Chart/BubbleChart.mjs +2 -2
- package/lib/esm/component/Chart/CigaretteChart.mjs +4 -4
- package/lib/esm/component/Chart/CompactHorizontalBarChart.mjs +2 -2
- package/lib/esm/component/Chart/DonutChart.mjs +2 -2
- package/lib/esm/component/Chart/HistogramChart.mjs +2 -2
- package/lib/esm/component/Chart/LineChart.mjs +2 -2
- package/lib/esm/component/Chart/RadarChart.mjs +2 -2
- package/lib/esm/component/Chart/ScatterPlotChart.mjs +2 -2
- package/lib/esm/component/Chart/VennChart.mjs +2 -2
- package/lib/esm/component/ChartLegend/LegendFlex/LegendFlex.mjs +8 -9
- package/lib/esm/component/ChartLegend/LegendItem/LegendItem.mjs +29 -30
- package/lib/esm/component/ChartLegend/LegendTable/LegendTable.mjs +10 -11
- package/lib/esm/component/Cigarette/Cigarette.mjs +2 -2
- package/lib/esm/createElement.mjs +5 -5
- package/lib/esm/style/hover.shadow.css +2 -2
- package/lib/esm/utils.mjs +1 -1
- package/lib/types/component/Chart/AbstractChart.type.d.ts +1 -1
- package/lib/types/utils.d.ts +1 -1
- package/package.json +11 -14
|
@@ -5,15 +5,14 @@ import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
|
5
5
|
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
6
|
import _createSuper from "@babel/runtime/helpers/esm/createSuper";
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
8
|
-
import { sstyled } from "@semcore/
|
|
9
|
-
import createComponent, { sstyled as sstyled$1, assignProps, Component } from "@semcore/core";
|
|
8
|
+
import { sstyled, createComponent, assignProps, Component } from "@semcore/core";
|
|
10
9
|
import React from "react";
|
|
11
10
|
import { Box, Flex } from "@semcore/flex-box";
|
|
12
11
|
import Checkbox from "@semcore/checkbox";
|
|
13
12
|
import { Text } from "@semcore/typography";
|
|
14
13
|
import { StaticShapes } from "./LegendItem.type.mjs";
|
|
15
|
-
import resolveColorEnhance from "@semcore/
|
|
16
|
-
import uniqueIDEnhancement from "@semcore/
|
|
14
|
+
import resolveColorEnhance from "@semcore/core/lib/utils/enhances/resolveColorEnhance";
|
|
15
|
+
import uniqueIDEnhancement from "@semcore/core/lib/utils/uniqueID";
|
|
17
16
|
import { PatternSymbol } from "../../../Pattern.mjs";
|
|
18
17
|
import { getChartDefaultColorName } from "../../../utils.mjs";
|
|
19
18
|
var _excluded = ["id", "checked", "color", "onChangeLegendItem", "shape"];
|
|
@@ -22,27 +21,27 @@ var style = (
|
|
|
22
21
|
/*__reshadow_css_start__*/
|
|
23
22
|
(sstyled.insert(
|
|
24
23
|
/*__inner_css_start__*/
|
|
25
|
-
'.
|
|
24
|
+
'.___SLegendItem_13lto_gg_{min-width:0;align-items:flex-start}@media (hover:hover){.___SLegendItem_13lto_gg_:hover{cursor:pointer}.___SLegendItem_13lto_gg_.__disabled_13lto_gg_:hover{cursor:default}}.___SPointShape_13lto_gg_.__color_13lto_gg_{background-color:var(--color_13lto);margin-right:8px;flex-shrink:0}.___SPointShape_13lto_gg_._shape_Circle_13lto_gg_._size_l_13lto_gg_{width:16px;height:16px;border-radius:8px;margin-top:4px}.___SPointShape_13lto_gg_._shape_Circle_13lto_gg_._size_m_13lto_gg_{width:12px;height:12px;border-radius:6px;margin-top:4px}.___SPointShape_13lto_gg_._shape_Line_13lto_gg_._size_l_13lto_gg_{width:16px;height:4px;border-radius:3px;margin-top:9px}.___SPointShape_13lto_gg_._shape_Line_13lto_gg_._size_m_13lto_gg_{width:12px;height:4px;border-radius:3px;margin-top:8px}.___SPointShape_13lto_gg_._shape_Square_13lto_gg_._size_l_13lto_gg_{width:16px;height:16px;border-radius:2px;margin-top:4px}.___SPointShape_13lto_gg_._shape_Square_13lto_gg_._size_m_13lto_gg_{width:12px;height:12px;border-radius:2px;margin-top:4px}.___SPointShape_13lto_gg_._shape_Pattern_13lto_gg_{background-color:transparent;margin-right:4px}.___SIcon_13lto_gg_{line-height:0;margin-right:4px}.___SIcon_13lto_gg_._size_l_13lto_gg_{margin-top:4px}.___SIcon_13lto_gg_._size_m_13lto_gg_{margin-top:2px}.___SLabel_13lto_gg_{min-width:0}.___SAdditionalLabel_13lto_gg_._size_l_13lto_gg_,.___SCount_13lto_gg_._size_l_13lto_gg_,.___SLabel_13lto_gg_._size_l_13lto_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%)}.___SAdditionalLabel_13lto_gg_._size_m_13lto_gg_,.___SCount_13lto_gg_._size_m_13lto_gg_,.___SLabel_13lto_gg_._size_m_13lto_gg_{font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%)}.___SAdditionalLabel_13lto_gg_,.___SCount_13lto_gg_{margin-left:4px}.___SAdditionalLabel_13lto_gg_{white-space:nowrap;display:flex;align-items:flex-start}.___SAdditionalLabel_13lto_gg_::before{content:"";display:inline-block;background-color:var(--intergalactic-text-secondary, #6c6e79);height:4px;width:4px;border-radius:2px;margin-right:4px}.___SAdditionalLabel_13lto_gg_._size_l_13lto_gg_::before{margin-top:10px}.___SAdditionalLabel_13lto_gg_._size_m_13lto_gg_::before{margin-top:8px}.___SPatternSymbol_13lto_gg_{transform:scale(.8)}',
|
|
26
25
|
/*__inner_css_end__*/
|
|
27
|
-
"
|
|
26
|
+
"13lto_gg_"
|
|
28
27
|
), /*__reshadow_css_end__*/
|
|
29
28
|
{
|
|
30
|
-
"__SLegendItem": "
|
|
31
|
-
"_disabled": "
|
|
32
|
-
"__SPointShape": "
|
|
33
|
-
"_color": "
|
|
34
|
-
"--color": "--
|
|
35
|
-
"_shape_Circle": "
|
|
36
|
-
"_size_l": "
|
|
37
|
-
"_size_m": "
|
|
38
|
-
"_shape_Line": "
|
|
39
|
-
"_shape_Square": "
|
|
40
|
-
"_shape_Pattern": "
|
|
41
|
-
"__SIcon": "
|
|
42
|
-
"__SLabel": "
|
|
43
|
-
"__SAdditionalLabel": "
|
|
44
|
-
"__SCount": "
|
|
45
|
-
"__SPatternSymbol": "
|
|
29
|
+
"__SLegendItem": "___SLegendItem_13lto_gg_",
|
|
30
|
+
"_disabled": "__disabled_13lto_gg_",
|
|
31
|
+
"__SPointShape": "___SPointShape_13lto_gg_",
|
|
32
|
+
"_color": "__color_13lto_gg_",
|
|
33
|
+
"--color": "--color_13lto",
|
|
34
|
+
"_shape_Circle": "_shape_Circle_13lto_gg_",
|
|
35
|
+
"_size_l": "_size_l_13lto_gg_",
|
|
36
|
+
"_size_m": "_size_m_13lto_gg_",
|
|
37
|
+
"_shape_Line": "_shape_Line_13lto_gg_",
|
|
38
|
+
"_shape_Square": "_shape_Square_13lto_gg_",
|
|
39
|
+
"_shape_Pattern": "_shape_Pattern_13lto_gg_",
|
|
40
|
+
"__SIcon": "___SIcon_13lto_gg_",
|
|
41
|
+
"__SLabel": "___SLabel_13lto_gg_",
|
|
42
|
+
"__SAdditionalLabel": "___SAdditionalLabel_13lto_gg_",
|
|
43
|
+
"__SCount": "___SCount_13lto_gg_",
|
|
44
|
+
"__SPatternSymbol": "___SPatternSymbol_13lto_gg_"
|
|
46
45
|
})
|
|
47
46
|
);
|
|
48
47
|
var enhance = [resolveColorEnhance(), uniqueIDEnhancement()];
|
|
@@ -127,7 +126,7 @@ var LegendItemRoot = /* @__PURE__ */ function(_Component) {
|
|
|
127
126
|
var SLegendItem = Flex;
|
|
128
127
|
var _this$asProps3 = this.asProps, styles = _this$asProps3.styles, Children = _this$asProps3.Children, shape = _this$asProps3.shape;
|
|
129
128
|
var disabled = StaticShapes.includes(shape);
|
|
130
|
-
return _ref7 = sstyled
|
|
129
|
+
return _ref7 = sstyled(styles), /* @__PURE__ */ React.createElement(SLegendItem, _ref7.cn("SLegendItem", _objectSpread({}, assignProps({
|
|
131
130
|
"disabled": disabled,
|
|
132
131
|
"__excludeProps": ["id"]
|
|
133
132
|
}, _ref))), /* @__PURE__ */ React.createElement(Children, _ref7.cn("Children", {})));
|
|
@@ -153,7 +152,7 @@ function Shape(props) {
|
|
|
153
152
|
}
|
|
154
153
|
if (shape === "Pattern") {
|
|
155
154
|
var _ref8;
|
|
156
|
-
return _ref8 = sstyled
|
|
155
|
+
return _ref8 = sstyled(styles), /* @__PURE__ */ React.createElement(Box, _ref8.cn("Box", {
|
|
157
156
|
"mr": 1
|
|
158
157
|
}), /* @__PURE__ */ React.createElement(SPatternSymbol, _ref8.cn("SPatternSymbol", {
|
|
159
158
|
"color": color,
|
|
@@ -163,7 +162,7 @@ function Shape(props) {
|
|
|
163
162
|
}
|
|
164
163
|
if (shape === "Checkbox") {
|
|
165
164
|
var _ref9;
|
|
166
|
-
return _ref9 = sstyled
|
|
165
|
+
return _ref9 = sstyled(styles), /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Checkbox, _ref9.cn("Checkbox", {
|
|
167
166
|
"size": size,
|
|
168
167
|
"checked": checked,
|
|
169
168
|
"theme": checked ? color : void 0,
|
|
@@ -178,7 +177,7 @@ function Shape(props) {
|
|
|
178
177
|
"aria-hidden": true
|
|
179
178
|
}))));
|
|
180
179
|
}
|
|
181
|
-
return _ref10 = sstyled
|
|
180
|
+
return _ref10 = sstyled(styles), /* @__PURE__ */ React.createElement(SPointShape, _ref10.cn("SPointShape", _objectSpread({}, assignProps({}, _ref2))), /* @__PURE__ */ React.createElement(Children, _ref10.cn("Children", {})));
|
|
182
181
|
}
|
|
183
182
|
function Icon(_ref15) {
|
|
184
183
|
var _ref3 = arguments[0], _ref11;
|
|
@@ -187,7 +186,7 @@ function Icon(_ref15) {
|
|
|
187
186
|
if (!hasChildren) {
|
|
188
187
|
return null;
|
|
189
188
|
}
|
|
190
|
-
return _ref11 = sstyled
|
|
189
|
+
return _ref11 = sstyled(styles), /* @__PURE__ */ React.createElement(SIcon, _ref11.cn("SIcon", _objectSpread({}, assignProps({
|
|
191
190
|
"tag": "span"
|
|
192
191
|
}, _ref3))), /* @__PURE__ */ React.createElement(Children, _ref11.cn("Children", {})));
|
|
193
192
|
}
|
|
@@ -199,7 +198,7 @@ function Label(_ref16) {
|
|
|
199
198
|
if (!hasChildren) {
|
|
200
199
|
return null;
|
|
201
200
|
}
|
|
202
|
-
return _ref12 = sstyled
|
|
201
|
+
return _ref12 = sstyled(styles), /* @__PURE__ */ React.createElement(SLabel, _ref12.cn("SLabel", _objectSpread({}, assignProps({
|
|
203
202
|
"use": "primary"
|
|
204
203
|
}, _ref4))), /* @__PURE__ */ React.createElement(Children, _ref12.cn("Children", {})));
|
|
205
204
|
}
|
|
@@ -211,7 +210,7 @@ function AdditionalLabel(_ref17) {
|
|
|
211
210
|
if (!hasChildren) {
|
|
212
211
|
return null;
|
|
213
212
|
}
|
|
214
|
-
return _ref13 = sstyled
|
|
213
|
+
return _ref13 = sstyled(styles), /* @__PURE__ */ React.createElement(SAdditionalLabel, _ref13.cn("SAdditionalLabel", _objectSpread({}, assignProps({
|
|
215
214
|
"use": "secondary"
|
|
216
215
|
}, _ref5))), /* @__PURE__ */ React.createElement(Children, _ref13.cn("Children", {})));
|
|
217
216
|
}
|
|
@@ -223,7 +222,7 @@ function Count(_ref18) {
|
|
|
223
222
|
if (!hasChildren) {
|
|
224
223
|
return null;
|
|
225
224
|
}
|
|
226
|
-
return _ref14 = sstyled
|
|
225
|
+
return _ref14 = sstyled(styles), /* @__PURE__ */ React.createElement(SCount, _ref14.cn("SCount", _objectSpread({}, assignProps({
|
|
227
226
|
"use": "secondary"
|
|
228
227
|
}, _ref6))), /* @__PURE__ */ React.createElement(Children, _ref14.cn("Children", {})));
|
|
229
228
|
}
|
|
@@ -4,8 +4,7 @@ import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
|
4
4
|
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
5
5
|
import _createSuper from "@babel/runtime/helpers/esm/createSuper";
|
|
6
6
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
7
|
-
import { sstyled } from "@semcore/
|
|
8
|
-
import createComponent, { sstyled as sstyled$1, assignProps } from "@semcore/core";
|
|
7
|
+
import { sstyled, createComponent, assignProps } from "@semcore/core";
|
|
9
8
|
import React from "react";
|
|
10
9
|
import { Box } from "@semcore/flex-box";
|
|
11
10
|
import { LegendItemComponent } from "../LegendItem/LegendItem.mjs";
|
|
@@ -15,16 +14,16 @@ var style = (
|
|
|
15
14
|
/*__reshadow_css_start__*/
|
|
16
15
|
(sstyled.insert(
|
|
17
16
|
/*__inner_css_start__*/
|
|
18
|
-
'.
|
|
17
|
+
'.___SLegendTable_1a40m_gg_.__columns-count_1a40m_gg_{font-feature-settings:"tnum";font-variant-numeric:tabular-nums;display:grid;grid-template-columns:auto .2fr;align-items:center;height:-moz-fit-content;height:fit-content;grid-column-gap:16px;grid-row-gap:8px}.___SColumnItem_1a40m_gg_._size_l_1a40m_gg_{font-size:var(--intergalactic-fs-300, 16px);text-align:right}.___SColumnItem_1a40m_gg_._size_m_1a40m_gg_{font-size:var(--intergalactic-fs-200, 14px);text-align:right}',
|
|
19
18
|
/*__inner_css_end__*/
|
|
20
|
-
"
|
|
19
|
+
"1a40m_gg_"
|
|
21
20
|
), /*__reshadow_css_end__*/
|
|
22
21
|
{
|
|
23
|
-
"__SLegendTable": "
|
|
24
|
-
"_columns-count": "__columns-
|
|
25
|
-
"__SColumnItem": "
|
|
26
|
-
"_size_l": "
|
|
27
|
-
"_size_m": "
|
|
22
|
+
"__SLegendTable": "___SLegendTable_1a40m_gg_",
|
|
23
|
+
"_columns-count": "__columns-count_1a40m_gg_",
|
|
24
|
+
"__SColumnItem": "___SColumnItem_1a40m_gg_",
|
|
25
|
+
"_size_l": "_size_l_1a40m_gg_",
|
|
26
|
+
"_size_m": "_size_m_1a40m_gg_"
|
|
28
27
|
})
|
|
29
28
|
);
|
|
30
29
|
var LegendTableRoot = /* @__PURE__ */ function(_BaseLegend) {
|
|
@@ -41,7 +40,7 @@ var LegendTableRoot = /* @__PURE__ */ function(_BaseLegend) {
|
|
|
41
40
|
var SLegendTable = Box;
|
|
42
41
|
var _this$asProps = this.asProps, styles = _this$asProps.styles, Children = _this$asProps.Children, _this$asProps$size = _this$asProps.size, size = _this$asProps$size === void 0 ? "m" : _this$asProps$size, items = _this$asProps.items;
|
|
43
42
|
var columnsCount = (_items$ = items[0]) === null || _items$ === void 0 ? void 0 : _items$.columns.length;
|
|
44
|
-
return _ref3 = sstyled
|
|
43
|
+
return _ref3 = sstyled(styles), /* @__PURE__ */ React.createElement(SLegendTable, _ref3.cn("SLegendTable", _objectSpread({}, assignProps({
|
|
45
44
|
"columns-count": columnsCount + 1,
|
|
46
45
|
"role": "group"
|
|
47
46
|
}, _ref))), items.map(function(_ref5, index) {
|
|
@@ -73,7 +72,7 @@ function ColumnComponent(props) {
|
|
|
73
72
|
var _ref2 = arguments[0], _ref4;
|
|
74
73
|
var SColumnItem = Box;
|
|
75
74
|
var styles = props.styles, index = props.index, size = props.size, Children = props.Children;
|
|
76
|
-
return _ref4 = sstyled
|
|
75
|
+
return _ref4 = sstyled(styles), /* @__PURE__ */ React.createElement(SColumnItem, _ref4.cn("SColumnItem", _objectSpread({}, assignProps({
|
|
77
76
|
"style": {
|
|
78
77
|
gridColumnStart: "".concat(index + 2),
|
|
79
78
|
gridColumnEnd: "".concat(index + 3)
|
|
@@ -6,11 +6,11 @@ import _createSuper from "@babel/runtime/helpers/esm/createSuper";
|
|
|
6
6
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
7
7
|
import React from "react";
|
|
8
8
|
import { sstyled, Component } from "@semcore/core";
|
|
9
|
-
import uniqueIDEnhancement from "@semcore/
|
|
9
|
+
import uniqueIDEnhancement from "@semcore/core/lib/utils/uniqueID";
|
|
10
10
|
import createElement from "../../createElement.mjs";
|
|
11
11
|
import { roundedPath } from "../../utils.mjs";
|
|
12
12
|
import { PatternFill } from "../../Pattern.mjs";
|
|
13
|
-
import { callAllEventHandlers } from "@semcore/
|
|
13
|
+
import { callAllEventHandlers } from "@semcore/core/lib/utils/assignProps";
|
|
14
14
|
var CigaretteBarRoot = /* @__PURE__ */ function(_Component) {
|
|
15
15
|
_inherits(CigaretteBarRoot2, _Component);
|
|
16
16
|
var _super = _createSuper(CigaretteBarRoot2);
|
|
@@ -3,11 +3,11 @@ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
4
|
import React from "react";
|
|
5
5
|
import hoistNonReactStatics from "hoist-non-react-statics";
|
|
6
|
-
import createComponent,
|
|
7
|
-
import assignProps from "@semcore/
|
|
8
|
-
import { useForkRef } from "@semcore/
|
|
9
|
-
import propsForElement from "@semcore/
|
|
10
|
-
import getOriginChildren from "@semcore/
|
|
6
|
+
import { createComponent, createBaseComponent, CONTEXT_COMPONENT } from "@semcore/core";
|
|
7
|
+
import assignProps from "@semcore/core/lib/utils/assignProps";
|
|
8
|
+
import { useForkRef } from "@semcore/core/lib/utils/ref";
|
|
9
|
+
import propsForElement from "@semcore/core/lib/utils/propsForElement";
|
|
10
|
+
import getOriginChildren from "@semcore/core/lib/utils/getOriginChildren";
|
|
11
11
|
import Plot from "./Plot.mjs";
|
|
12
12
|
var _excluded = ["render", "childrenPosition", "x", "y"], _excluded2 = ["forwardRef", "children", "Children", "x", "y"], _excluded3 = ["$rootProps"];
|
|
13
13
|
var EXCLUDE_PROPS = ["data", "scale"];
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
SHoverLine {
|
|
1
|
+
SHoverLine, SHoverLine:focus-visible {
|
|
2
2
|
outline: none;
|
|
3
3
|
stroke: var(--intergalactic-chart-grid-x-axis, #c4c7cf);
|
|
4
4
|
}
|
|
5
5
|
|
|
6
|
-
SHoverRect {
|
|
6
|
+
SHoverRect, SHoverRect:focus-visible {
|
|
7
7
|
outline: none;
|
|
8
8
|
fill: var(--intergalactic-chart-grid-bar-chart-hover, rgba(196, 199, 207, 0.3));
|
|
9
9
|
}
|
package/lib/esm/utils.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
|
|
|
3
3
|
import _createForOfIteratorHelper from "@babel/runtime/helpers/esm/createForOfIteratorHelper";
|
|
4
4
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
5
5
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
6
|
-
import EventEmitter from "@semcore/
|
|
6
|
+
import EventEmitter from "@semcore/core/lib/utils/eventEmitter";
|
|
7
7
|
import { extent, bisector } from "d3-array";
|
|
8
8
|
import { scaleSqrt, scaleQuantize, scaleBand } from "d3-scale";
|
|
9
9
|
var eventToPoint = function eventToPoint2(event, svgRoot) {
|
|
@@ -6,7 +6,7 @@ import { BaseChartLegendProps } from '../ChartLegend/BaseLegend.type';
|
|
|
6
6
|
import { TrendProps } from '../ChartLegend/LegendFlex/LegendFlex.type';
|
|
7
7
|
import { PatternsConfig } from '../../Pattern';
|
|
8
8
|
import { PlotSummarizerConfig } from '../../Plot';
|
|
9
|
-
import { Intergalactic } from '@semcore/
|
|
9
|
+
import { Intergalactic } from '@semcore/core';
|
|
10
10
|
export type BaseLegendProps = BaseChartLegendProps & {
|
|
11
11
|
/**
|
|
12
12
|
* Disable hover (for transition items legend of each not hovered)
|
package/lib/types/utils.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import EventEmitter from '@semcore/
|
|
1
|
+
import EventEmitter from '@semcore/core/lib/utils/eventEmitter';
|
|
2
2
|
import { Numeric } from 'd3-array';
|
|
3
3
|
import { ScaleIdentity, ScaleTime, ScaleContinuousNumeric, ScaleBand, ScalePoint } from 'd3-scale';
|
|
4
4
|
import React from 'react';
|
package/package.json
CHANGED
|
@@ -1,28 +1,27 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@semcore/d3-chart",
|
|
3
3
|
"description": "Semrush D3 Chart Component",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "16.0.0-prerelease.0",
|
|
5
5
|
"main": "lib/cjs/index.js",
|
|
6
|
-
"module": "lib/
|
|
6
|
+
"module": "lib/es6/index.js",
|
|
7
7
|
"typings": "lib/types/index.d.ts",
|
|
8
8
|
"sideEffects": false,
|
|
9
9
|
"author": "UI-kit team <ui-kit-team@semrush.com>",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"exports": {
|
|
12
12
|
"require": "./lib/cjs/index.js",
|
|
13
|
-
"import": "./lib/
|
|
13
|
+
"import": "./lib/es6/index.js",
|
|
14
14
|
"types": "./lib/types/index.d.ts"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
17
|
"@formatjs/intl": "2.3.0",
|
|
18
|
-
"@semcore/
|
|
19
|
-
"@semcore/
|
|
20
|
-
"@semcore/
|
|
21
|
-
"@semcore/flex-box": "
|
|
22
|
-
"@semcore/popper": "
|
|
23
|
-
"@semcore/
|
|
24
|
-
"@semcore/typography": "
|
|
25
|
-
"@semcore/icon": "4.62.1",
|
|
18
|
+
"@semcore/divider": "16.0.0-prerelease.0",
|
|
19
|
+
"@semcore/animation": "16.0.0-prerelease.0",
|
|
20
|
+
"@semcore/checkbox": "16.0.0-prerelease.0",
|
|
21
|
+
"@semcore/flex-box": "16.0.0-prerelease.0",
|
|
22
|
+
"@semcore/popper": "16.0.0-prerelease.0",
|
|
23
|
+
"@semcore/icon": "16.0.0-prerelease.0",
|
|
24
|
+
"@semcore/typography": "16.0.0-prerelease.0",
|
|
26
25
|
"@types/d3-shape": "^3.1.0",
|
|
27
26
|
"@upsetjs/venn.js": "1.4.2",
|
|
28
27
|
"d3-array": "3.1.6",
|
|
@@ -36,9 +35,7 @@
|
|
|
36
35
|
"hoist-non-react-statics": "3.3.2"
|
|
37
36
|
},
|
|
38
37
|
"peerDependencies": {
|
|
39
|
-
"@semcore/
|
|
40
|
-
"react": "16.8 - 18",
|
|
41
|
-
"react-dom": "16.8 - 18"
|
|
38
|
+
"@semcore/base-components": "^16.0.0-prerelease.0"
|
|
42
39
|
},
|
|
43
40
|
"repository": {
|
|
44
41
|
"type": "git",
|