@semcore/d3-chart 16.5.0 → 17.0.0-prerelease.9
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 +10 -0
- package/lib/cjs/AnimatedClipPath.js +28 -41
- package/lib/cjs/AnimatedClipPath.js.map +1 -1
- package/lib/cjs/Area.js +187 -223
- package/lib/cjs/Area.js.map +1 -1
- package/lib/cjs/Axis.js +248 -327
- package/lib/cjs/Axis.js.map +1 -1
- package/lib/cjs/Bar.js +162 -185
- package/lib/cjs/Bar.js.map +1 -1
- package/lib/cjs/Bubble.js +219 -248
- package/lib/cjs/Bubble.js.map +1 -1
- package/lib/cjs/CompactHorizontalBar.js +448 -482
- package/lib/cjs/CompactHorizontalBar.js.map +1 -1
- package/lib/cjs/Donut.js +349 -396
- package/lib/cjs/Donut.js.map +1 -1
- package/lib/cjs/Dots.js +67 -86
- package/lib/cjs/Dots.js.map +1 -1
- package/lib/cjs/GroupBar.js +78 -93
- package/lib/cjs/GroupBar.js.map +1 -1
- package/lib/cjs/HorizontalBar.js +149 -167
- package/lib/cjs/HorizontalBar.js.map +1 -1
- package/lib/cjs/Hover.js +178 -207
- package/lib/cjs/Hover.js.map +1 -1
- package/lib/cjs/Line.js +182 -222
- package/lib/cjs/Line.js.map +1 -1
- package/lib/cjs/Pattern.js +124 -126
- package/lib/cjs/Pattern.js.map +1 -1
- package/lib/cjs/Plot.js +100 -126
- package/lib/cjs/Plot.js.map +1 -1
- package/lib/cjs/Radar.js +576 -681
- package/lib/cjs/Radar.js.map +1 -1
- package/lib/cjs/RadialTree.js +518 -571
- package/lib/cjs/RadialTree.js.map +1 -1
- package/lib/cjs/Reference.js +147 -178
- package/lib/cjs/Reference.js.map +1 -1
- package/lib/cjs/ResponsiveContainer.js +64 -82
- package/lib/cjs/ResponsiveContainer.js.map +1 -1
- package/lib/cjs/ScatterPlot.js +169 -199
- package/lib/cjs/ScatterPlot.js.map +1 -1
- package/lib/cjs/StackBar.js +135 -177
- package/lib/cjs/StackBar.js.map +1 -1
- package/lib/cjs/StackedArea.js +60 -73
- package/lib/cjs/StackedArea.js.map +1 -1
- package/lib/cjs/Tooltip.js +193 -208
- package/lib/cjs/Tooltip.js.map +1 -1
- package/lib/cjs/Venn.js +182 -217
- package/lib/cjs/Venn.js.map +1 -1
- package/lib/cjs/a11y/DataAccessibilityTable.js +45 -83
- package/lib/cjs/a11y/DataAccessibilityTable.js.map +1 -1
- package/lib/cjs/a11y/PlotA11yModule.js +37 -97
- package/lib/cjs/a11y/PlotA11yModule.js.map +1 -1
- package/lib/cjs/a11y/PlotA11yView.js +97 -91
- package/lib/cjs/a11y/PlotA11yView.js.map +1 -1
- package/lib/cjs/a11y/bezier.js +17 -23
- package/lib/cjs/a11y/bezier.js.map +1 -1
- package/lib/cjs/a11y/focus.js +16 -16
- package/lib/cjs/a11y/focus.js.map +1 -1
- package/lib/cjs/a11y/hints.js +72 -75
- package/lib/cjs/a11y/hints.js.map +1 -1
- package/lib/cjs/a11y/insights.js +354 -525
- package/lib/cjs/a11y/insights.js.map +1 -1
- package/lib/cjs/a11y/intl.js +5 -5
- package/lib/cjs/a11y/intl.js.map +1 -1
- package/lib/cjs/a11y/locale.js +12 -19
- package/lib/cjs/a11y/locale.js.map +1 -1
- package/lib/cjs/a11y/serialize.js +164 -203
- package/lib/cjs/a11y/serialize.js.map +1 -1
- package/lib/cjs/a11y/summarize.js +7 -6
- package/lib/cjs/a11y/summarize.js.map +1 -1
- package/lib/cjs/a11y/translations/module/__intergalactic-dynamic-locales.js +16 -16
- package/lib/cjs/a11y/translations/module/__intergalactic-dynamic-locales.js.map +1 -1
- package/lib/cjs/a11y/translations/module/de.json +2 -2
- package/lib/cjs/a11y/translations/module/en.json +2 -2
- package/lib/cjs/a11y/translations/module/es.json +2 -2
- package/lib/cjs/a11y/translations/module/fr.json +2 -2
- package/lib/cjs/a11y/translations/module/it.json +2 -2
- package/lib/cjs/a11y/translations/module/ja.json +2 -2
- package/lib/cjs/a11y/translations/module/ko.json +2 -2
- package/lib/cjs/a11y/translations/module/nl.json +2 -2
- package/lib/cjs/a11y/translations/module/pl.json +2 -2
- package/lib/cjs/a11y/translations/module/pt.json +2 -2
- package/lib/cjs/a11y/translations/module/sv.json +2 -2
- package/lib/cjs/a11y/translations/module/tr.json +2 -2
- package/lib/cjs/a11y/translations/module/vi.json +2 -2
- package/lib/cjs/a11y/translations/module/zh.json +2 -2
- package/lib/cjs/a11y/translations/view/__intergalactic-dynamic-locales.js +16 -16
- package/lib/cjs/a11y/translations/view/__intergalactic-dynamic-locales.js.map +1 -1
- package/lib/cjs/color.js +1 -1
- package/lib/cjs/color.js.map +1 -1
- package/lib/cjs/component/Chart/AbstractChart.js +421 -466
- 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 +97 -115
- package/lib/cjs/component/Chart/AreaChart.js.map +1 -1
- package/lib/cjs/component/Chart/AreaChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/BarChart.js +229 -216
- package/lib/cjs/component/Chart/BarChart.js.map +1 -1
- package/lib/cjs/component/Chart/BarChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/BubbleChart.js +114 -136
- package/lib/cjs/component/Chart/BubbleChart.js.map +1 -1
- package/lib/cjs/component/Chart/BubbleChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/CigaretteChart.js +280 -305
- package/lib/cjs/component/Chart/CigaretteChart.js.map +1 -1
- package/lib/cjs/component/Chart/CompactHorizontalBarChart.js +76 -108
- package/lib/cjs/component/Chart/CompactHorizontalBarChart.js.map +1 -1
- package/lib/cjs/component/Chart/CompactHorizontalBarChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/DonutChart.js +80 -95
- package/lib/cjs/component/Chart/DonutChart.js.map +1 -1
- package/lib/cjs/component/Chart/DonutChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/HistogramChart.js +126 -148
- package/lib/cjs/component/Chart/HistogramChart.js.map +1 -1
- package/lib/cjs/component/Chart/HistogramChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/LineChart.js +95 -113
- package/lib/cjs/component/Chart/LineChart.js.map +1 -1
- package/lib/cjs/component/Chart/LineChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/RadarChart.js +84 -110
- package/lib/cjs/component/Chart/RadarChart.js.map +1 -1
- package/lib/cjs/component/Chart/RadarChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/ScatterPlotChart.js +119 -143
- package/lib/cjs/component/Chart/ScatterPlotChart.js.map +1 -1
- package/lib/cjs/component/Chart/ScatterPlotChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/VennChart.js +103 -122
- package/lib/cjs/component/Chart/VennChart.js.map +1 -1
- package/lib/cjs/component/Chart/VennChart.type.js.map +1 -1
- package/lib/cjs/component/Chart/index.js +2 -2
- package/lib/cjs/component/Chart/index.js.map +1 -1
- package/lib/cjs/component/ChartLegend/BaseLegend.js +72 -105
- package/lib/cjs/component/ChartLegend/BaseLegend.js.map +1 -1
- package/lib/cjs/component/ChartLegend/BaseLegend.type.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendFlex/LegendFlex.js +58 -70
- package/lib/cjs/component/ChartLegend/LegendFlex/LegendFlex.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendFlex/LegendFlex.type.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js +208 -221
- package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.type.js +1 -1
- package/lib/cjs/component/ChartLegend/LegendItem/LegendItem.type.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js +63 -73
- package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.js.map +1 -1
- package/lib/cjs/component/ChartLegend/LegendTable/LegendTable.type.js.map +1 -1
- package/lib/cjs/component/ChartLegend/index.js +4 -4
- package/lib/cjs/component/ChartLegend/index.js.map +1 -1
- package/lib/cjs/component/Cigarette/Cigarette.js +115 -129
- package/lib/cjs/component/Cigarette/Cigarette.js.map +1 -1
- package/lib/cjs/component/StackGroupBar/StackGroupBar.js +107 -137
- package/lib/cjs/component/StackGroupBar/StackGroupBar.js.map +1 -1
- package/lib/cjs/component/SvgElement.js +7 -7
- package/lib/cjs/component/SvgElement.js.map +1 -1
- package/lib/cjs/createElement.js +66 -65
- package/lib/cjs/createElement.js.map +1 -1
- package/lib/cjs/index.js +62 -62
- package/lib/cjs/style/axis.shadow.css +3 -0
- package/lib/cjs/style/plot.shadow.css +1 -3
- package/lib/cjs/style/plotA11yModule.shadow.css +10 -11
- package/lib/cjs/style/plotA11yView.shadow.css +13 -26
- package/lib/cjs/translations/__intergalactic-dynamic-locales.js +15 -15
- package/lib/cjs/translations/__intergalactic-dynamic-locales.js.map +1 -1
- package/lib/cjs/types/Axis.d.js.map +1 -1
- package/lib/cjs/types/CompactHorizontalBar.d.js.map +1 -1
- package/lib/cjs/types/Hover.d.js.map +1 -1
- package/lib/cjs/types/Line.d.js.map +1 -1
- package/lib/cjs/types/Plot.d.js.map +1 -1
- package/lib/cjs/types/Radar.d.js.map +1 -1
- package/lib/cjs/types/ResponsiveContainer.d.js.map +1 -1
- package/lib/cjs/types/Tooltip.d.js.map +1 -1
- package/lib/cjs/types/Venn.d.js.map +1 -1
- package/lib/cjs/types/index.d.js +80 -80
- package/lib/cjs/types/index.d.js.map +1 -1
- package/lib/cjs/utils.js +122 -145
- package/lib/cjs/utils.js.map +1 -1
- package/lib/es6/AnimatedClipPath.js +24 -37
- package/lib/es6/AnimatedClipPath.js.map +1 -1
- package/lib/es6/Area.js +179 -215
- package/lib/es6/Area.js.map +1 -1
- package/lib/es6/Axis.js +242 -321
- package/lib/es6/Axis.js.map +1 -1
- package/lib/es6/Bar.js +154 -177
- package/lib/es6/Bar.js.map +1 -1
- package/lib/es6/Bubble.js +206 -235
- package/lib/es6/Bubble.js.map +1 -1
- package/lib/es6/CompactHorizontalBar.js +433 -467
- package/lib/es6/CompactHorizontalBar.js.map +1 -1
- package/lib/es6/Donut.js +337 -384
- package/lib/es6/Donut.js.map +1 -1
- package/lib/es6/Dots.js +60 -79
- package/lib/es6/Dots.js.map +1 -1
- package/lib/es6/GroupBar.js +74 -89
- package/lib/es6/GroupBar.js.map +1 -1
- package/lib/es6/HorizontalBar.js +141 -159
- package/lib/es6/HorizontalBar.js.map +1 -1
- package/lib/es6/Hover.js +174 -203
- package/lib/es6/Hover.js.map +1 -1
- package/lib/es6/Line.js +173 -213
- package/lib/es6/Line.js.map +1 -1
- package/lib/es6/Pattern.js +68 -74
- package/lib/es6/Pattern.js.map +1 -1
- package/lib/es6/Plot.js +95 -121
- package/lib/es6/Plot.js.map +1 -1
- package/lib/es6/Radar.js +554 -659
- package/lib/es6/Radar.js.map +1 -1
- package/lib/es6/RadialTree.js +500 -553
- package/lib/es6/RadialTree.js.map +1 -1
- package/lib/es6/Reference.js +140 -171
- package/lib/es6/Reference.js.map +1 -1
- package/lib/es6/ResponsiveContainer.js +58 -76
- package/lib/es6/ResponsiveContainer.js.map +1 -1
- package/lib/es6/ScatterPlot.js +161 -191
- package/lib/es6/ScatterPlot.js.map +1 -1
- package/lib/es6/StackBar.js +130 -172
- package/lib/es6/StackBar.js.map +1 -1
- package/lib/es6/StackedArea.js +56 -69
- package/lib/es6/StackedArea.js.map +1 -1
- package/lib/es6/Tooltip.js +183 -198
- package/lib/es6/Tooltip.js.map +1 -1
- package/lib/es6/Venn.js +169 -204
- package/lib/es6/Venn.js.map +1 -1
- package/lib/es6/a11y/DataAccessibilityTable.js +41 -80
- package/lib/es6/a11y/DataAccessibilityTable.js.map +1 -1
- package/lib/es6/a11y/PlotA11yModule.js +35 -95
- package/lib/es6/a11y/PlotA11yModule.js.map +1 -1
- package/lib/es6/a11y/PlotA11yView.js +89 -84
- package/lib/es6/a11y/PlotA11yView.js.map +1 -1
- package/lib/es6/a11y/bezier.js +16 -23
- package/lib/es6/a11y/bezier.js.map +1 -1
- package/lib/es6/a11y/focus.js +15 -16
- package/lib/es6/a11y/focus.js.map +1 -1
- package/lib/es6/a11y/hints.js +67 -73
- package/lib/es6/a11y/hints.js.map +1 -1
- package/lib/es6/a11y/insights.js +353 -524
- package/lib/es6/a11y/insights.js.map +1 -1
- package/lib/es6/a11y/intl.js +4 -5
- package/lib/es6/a11y/intl.js.map +1 -1
- package/lib/es6/a11y/locale.js +11 -18
- package/lib/es6/a11y/locale.js.map +1 -1
- package/lib/es6/a11y/serialize.js +162 -203
- package/lib/es6/a11y/serialize.js.map +1 -1
- package/lib/es6/a11y/summarize.js +6 -6
- package/lib/es6/a11y/summarize.js.map +1 -1
- package/lib/es6/a11y/translations/module/__intergalactic-dynamic-locales.js +15 -15
- package/lib/es6/a11y/translations/module/__intergalactic-dynamic-locales.js.map +1 -1
- package/lib/es6/a11y/translations/module/de.json +2 -2
- package/lib/es6/a11y/translations/module/en.json +2 -2
- package/lib/es6/a11y/translations/module/es.json +2 -2
- package/lib/es6/a11y/translations/module/fr.json +2 -2
- package/lib/es6/a11y/translations/module/it.json +2 -2
- package/lib/es6/a11y/translations/module/ja.json +2 -2
- package/lib/es6/a11y/translations/module/ko.json +2 -2
- package/lib/es6/a11y/translations/module/nl.json +2 -2
- package/lib/es6/a11y/translations/module/pl.json +2 -2
- package/lib/es6/a11y/translations/module/pt.json +2 -2
- package/lib/es6/a11y/translations/module/sv.json +2 -2
- package/lib/es6/a11y/translations/module/tr.json +2 -2
- package/lib/es6/a11y/translations/module/vi.json +2 -2
- package/lib/es6/a11y/translations/module/zh.json +2 -2
- package/lib/es6/a11y/translations/view/__intergalactic-dynamic-locales.js +15 -15
- package/lib/es6/a11y/translations/view/__intergalactic-dynamic-locales.js.map +1 -1
- package/lib/es6/color.js +1 -1
- package/lib/es6/color.js.map +1 -1
- package/lib/es6/component/Chart/AbstractChart.js +416 -462
- 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 +92 -111
- package/lib/es6/component/Chart/AreaChart.js.map +1 -1
- package/lib/es6/component/Chart/AreaChart.type.js.map +1 -1
- package/lib/es6/component/Chart/BarChart.js +225 -213
- package/lib/es6/component/Chart/BarChart.js.map +1 -1
- package/lib/es6/component/Chart/BarChart.type.js.map +1 -1
- package/lib/es6/component/Chart/BubbleChart.js +109 -132
- package/lib/es6/component/Chart/BubbleChart.js.map +1 -1
- package/lib/es6/component/Chart/BubbleChart.type.js.map +1 -1
- package/lib/es6/component/Chart/CigaretteChart.js +276 -301
- package/lib/es6/component/Chart/CigaretteChart.js.map +1 -1
- package/lib/es6/component/Chart/CompactHorizontalBarChart.js +70 -103
- package/lib/es6/component/Chart/CompactHorizontalBarChart.js.map +1 -1
- package/lib/es6/component/Chart/CompactHorizontalBarChart.type.js.map +1 -1
- package/lib/es6/component/Chart/DonutChart.js +74 -90
- package/lib/es6/component/Chart/DonutChart.js.map +1 -1
- package/lib/es6/component/Chart/DonutChart.type.js.map +1 -1
- package/lib/es6/component/Chart/HistogramChart.js +121 -144
- package/lib/es6/component/Chart/HistogramChart.js.map +1 -1
- package/lib/es6/component/Chart/HistogramChart.type.js.map +1 -1
- package/lib/es6/component/Chart/LineChart.js +90 -109
- package/lib/es6/component/Chart/LineChart.js.map +1 -1
- package/lib/es6/component/Chart/LineChart.type.js.map +1 -1
- package/lib/es6/component/Chart/RadarChart.js +80 -107
- package/lib/es6/component/Chart/RadarChart.js.map +1 -1
- package/lib/es6/component/Chart/RadarChart.type.js.map +1 -1
- package/lib/es6/component/Chart/ScatterPlotChart.js +113 -138
- package/lib/es6/component/Chart/ScatterPlotChart.js.map +1 -1
- package/lib/es6/component/Chart/ScatterPlotChart.type.js.map +1 -1
- package/lib/es6/component/Chart/VennChart.js +97 -117
- package/lib/es6/component/Chart/VennChart.js.map +1 -1
- package/lib/es6/component/Chart/VennChart.type.js.map +1 -1
- package/lib/es6/component/ChartLegend/BaseLegend.js +70 -104
- package/lib/es6/component/ChartLegend/BaseLegend.js.map +1 -1
- package/lib/es6/component/ChartLegend/BaseLegend.type.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendFlex/LegendFlex.js +53 -65
- package/lib/es6/component/ChartLegend/LegendFlex/LegendFlex.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendFlex/LegendFlex.type.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendItem/LegendItem.js +198 -211
- package/lib/es6/component/ChartLegend/LegendItem/LegendItem.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendItem/LegendItem.type.js +1 -1
- package/lib/es6/component/ChartLegend/LegendItem/LegendItem.type.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendTable/LegendTable.js +58 -68
- package/lib/es6/component/ChartLegend/LegendTable/LegendTable.js.map +1 -1
- package/lib/es6/component/ChartLegend/LegendTable/LegendTable.type.js.map +1 -1
- package/lib/es6/component/Cigarette/Cigarette.js +108 -122
- package/lib/es6/component/Cigarette/Cigarette.js.map +1 -1
- package/lib/es6/component/StackGroupBar/StackGroupBar.js +100 -130
- package/lib/es6/component/StackGroupBar/StackGroupBar.js.map +1 -1
- package/lib/es6/component/SvgElement.js +4 -5
- package/lib/es6/component/SvgElement.js.map +1 -1
- package/lib/es6/createElement.js +55 -54
- package/lib/es6/createElement.js.map +1 -1
- package/lib/es6/style/axis.shadow.css +3 -0
- package/lib/es6/style/plot.shadow.css +1 -3
- package/lib/es6/style/plotA11yModule.shadow.css +10 -11
- package/lib/es6/style/plotA11yView.shadow.css +13 -26
- package/lib/es6/translations/__intergalactic-dynamic-locales.js +14 -14
- package/lib/es6/translations/__intergalactic-dynamic-locales.js.map +1 -1
- package/lib/es6/types/Axis.d.js.map +1 -1
- package/lib/es6/types/CompactHorizontalBar.d.js.map +1 -1
- package/lib/es6/types/Hover.d.js.map +1 -1
- package/lib/es6/types/Line.d.js.map +1 -1
- package/lib/es6/types/Plot.d.js.map +1 -1
- package/lib/es6/types/Radar.d.js.map +1 -1
- package/lib/es6/types/ResponsiveContainer.d.js.map +1 -1
- package/lib/es6/types/Tooltip.d.js.map +1 -1
- package/lib/es6/types/Venn.d.js.map +1 -1
- package/lib/es6/utils.js +105 -144
- package/lib/es6/utils.js.map +1 -1
- package/lib/esm/AnimatedClipPath.mjs +24 -36
- package/lib/esm/Area.mjs +178 -149
- package/lib/esm/Axis.mjs +241 -242
- package/lib/esm/Bar.mjs +155 -137
- package/lib/esm/Bubble.mjs +205 -171
- package/lib/esm/CompactHorizontalBar.mjs +428 -383
- package/lib/esm/Donut.mjs +315 -266
- package/lib/esm/Dots.mjs +60 -49
- package/lib/esm/GroupBar.mjs +71 -75
- package/lib/esm/HorizontalBar.mjs +142 -120
- package/lib/esm/Hover.mjs +173 -163
- package/lib/esm/Line.mjs +174 -145
- package/lib/esm/Pattern.mjs +67 -63
- package/lib/esm/Plot.mjs +98 -95
- package/lib/esm/Radar.mjs +550 -498
- package/lib/esm/RadialTree.mjs +512 -416
- package/lib/esm/Reference.mjs +137 -122
- package/lib/esm/ResponsiveContainer.mjs +58 -69
- package/lib/esm/ScatterPlot.mjs +163 -162
- package/lib/esm/StackBar.mjs +126 -147
- package/lib/esm/StackedArea.mjs +53 -61
- package/lib/esm/Tooltip.mjs +185 -175
- package/lib/esm/Venn.mjs +170 -170
- package/lib/esm/a11y/DataAccessibilityTable.mjs +46 -73
- package/lib/esm/a11y/PlotA11yModule.mjs +37 -80
- package/lib/esm/a11y/PlotA11yView.mjs +99 -74
- package/lib/esm/a11y/bezier.mjs +16 -23
- package/lib/esm/a11y/focus.mjs +15 -16
- package/lib/esm/a11y/hints.mjs +65 -71
- package/lib/esm/a11y/insights.mjs +347 -495
- package/lib/esm/a11y/intl.mjs +4 -5
- package/lib/esm/a11y/locale.mjs +12 -14
- package/lib/esm/a11y/serialize.mjs +139 -152
- package/lib/esm/a11y/summarize.mjs +3 -3
- package/lib/esm/a11y/translations/module/__intergalactic-dynamic-locales.mjs +1 -1
- package/lib/esm/a11y/translations/module/de.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/en.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/es.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/fr.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/it.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/ja.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/ko.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/nl.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/pl.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/pt.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/sv.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/tr.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/vi.json.mjs +2 -4
- package/lib/esm/a11y/translations/module/zh.json.mjs +2 -4
- package/lib/esm/a11y/translations/view/__intergalactic-dynamic-locales.mjs +1 -1
- package/lib/esm/color.mjs +1 -1
- package/lib/esm/component/Chart/AbstractChart.mjs +422 -415
- package/lib/esm/component/Chart/AreaChart.mjs +92 -91
- package/lib/esm/component/Chart/BarChart.mjs +225 -177
- package/lib/esm/component/Chart/BubbleChart.mjs +110 -118
- package/lib/esm/component/Chart/CigaretteChart.mjs +277 -268
- package/lib/esm/component/Chart/CompactHorizontalBarChart.mjs +70 -87
- package/lib/esm/component/Chart/DonutChart.mjs +74 -84
- package/lib/esm/component/Chart/HistogramChart.mjs +121 -117
- package/lib/esm/component/Chart/LineChart.mjs +90 -89
- package/lib/esm/component/Chart/RadarChart.mjs +81 -97
- package/lib/esm/component/Chart/ScatterPlotChart.mjs +113 -111
- package/lib/esm/component/Chart/VennChart.mjs +98 -111
- package/lib/esm/component/ChartLegend/BaseLegend.mjs +75 -97
- package/lib/esm/component/ChartLegend/LegendFlex/LegendFlex.mjs +54 -55
- package/lib/esm/component/ChartLegend/LegendItem/LegendItem.mjs +194 -165
- package/lib/esm/component/ChartLegend/LegendItem/LegendItem.type.mjs +1 -1
- package/lib/esm/component/ChartLegend/LegendTable/LegendTable.mjs +60 -58
- package/lib/esm/component/Cigarette/Cigarette.mjs +109 -99
- package/lib/esm/component/StackGroupBar/StackGroupBar.mjs +97 -111
- package/lib/esm/component/SvgElement.mjs +4 -4
- package/lib/esm/createElement.mjs +54 -37
- package/lib/esm/style/axis.shadow.css +3 -0
- package/lib/esm/style/plot.shadow.css +1 -3
- package/lib/esm/style/plotA11yModule.shadow.css +10 -11
- package/lib/esm/style/plotA11yView.shadow.css +13 -26
- package/lib/esm/translations/__intergalactic-dynamic-locales.mjs +1 -1
- package/lib/esm/utils.mjs +103 -138
- package/lib/types/Axis.d.ts +4 -0
- package/lib/types/CompactHorizontalBar.d.ts +1 -1
- package/lib/types/Hover.d.ts +1 -1
- package/lib/types/Line.d.ts +1 -1
- package/lib/types/Plot.d.ts +1 -1
- package/lib/types/Radar.d.ts +1 -1
- package/lib/types/ResponsiveContainer.d.ts +1 -1
- package/lib/types/Tooltip.d.ts +1 -3
- package/lib/types/Venn.d.ts +1 -1
- package/lib/types/a11y/PlotA11yModule.d.ts +4 -11
- package/lib/types/a11y/PlotA11yView.d.ts +12 -1
- package/lib/types/a11y/translations/module/__intergalactic-dynamic-locales.d.ts +14 -14
- package/lib/types/component/Chart/AbstractChart.d.ts +1 -1
- package/lib/types/component/Chart/AbstractChart.type.d.ts +1 -1
- package/lib/types/component/Chart/AreaChart.type.d.ts +1 -1
- package/lib/types/component/Chart/BarChart.type.d.ts +1 -1
- package/lib/types/component/Chart/BubbleChart.type.d.ts +1 -1
- package/lib/types/component/Chart/CompactHorizontalBarChart.type.d.ts +1 -1
- package/lib/types/component/Chart/DonutChart.type.d.ts +1 -1
- package/lib/types/component/Chart/HistogramChart.type.d.ts +1 -1
- package/lib/types/component/Chart/LineChart.type.d.ts +1 -1
- package/lib/types/component/Chart/RadarChart.type.d.ts +1 -1
- package/lib/types/component/Chart/ScatterPlotChart.type.d.ts +1 -1
- package/lib/types/component/Chart/VennChart.type.d.ts +1 -1
- package/lib/types/component/ChartLegend/BaseLegend.d.ts +1 -1
- package/lib/types/component/ChartLegend/BaseLegend.type.d.ts +1 -1
- package/lib/types/component/ChartLegend/LegendFlex/LegendFlex.type.d.ts +1 -1
- package/lib/types/component/ChartLegend/LegendItem/LegendItem.type.d.ts +1 -1
- package/lib/types/component/ChartLegend/LegendTable/LegendTable.type.d.ts +1 -1
- package/lib/types/utils.d.ts +10 -10
- package/package.json +9 -12
|
@@ -1,165 +1,174 @@
|
|
|
1
|
-
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
|
-
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
-
import _callSuper from "@babel/runtime/helpers/esm/callSuper";
|
|
6
|
-
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
7
1
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
8
|
-
import { createComponent, sstyled, assignProps
|
|
2
|
+
import { createComponent, Component, sstyled, assignProps } from "@semcore/core";
|
|
3
|
+
import { Flex, Box } from "@semcore/base-components";
|
|
9
4
|
import Checkbox from "@semcore/checkbox";
|
|
10
5
|
import resolveColorEnhance from "@semcore/core/lib/utils/enhances/resolveColorEnhance";
|
|
11
6
|
import uniqueIDEnhancement from "@semcore/core/lib/utils/uniqueID";
|
|
12
|
-
import { Flex, Box } from "@semcore/flex-box";
|
|
13
7
|
import { Text } from "@semcore/typography";
|
|
14
8
|
import React from "react";
|
|
15
9
|
import { StaticShapes } from "./LegendItem.type.mjs";
|
|
16
10
|
import { PatternSymbol } from "../../../Pattern.mjs";
|
|
17
11
|
import { getChartDefaultColorName } from "../../../utils.mjs";
|
|
18
|
-
var _excluded = ["id", "checked", "color", "onChangeLegendItem", "shape"];
|
|
19
12
|
/*!__reshadow-styles__:"./legend-item.shadow.css"*/
|
|
20
|
-
|
|
13
|
+
const style = (
|
|
21
14
|
/*__reshadow_css_start__*/
|
|
22
15
|
(sstyled.insert(
|
|
23
16
|
/*__inner_css_start__*/
|
|
24
|
-
'.
|
|
17
|
+
'.___SLegendItem_30ip2_gg_{min-width:0;align-items:flex-start}@media (hover:hover){.___SLegendItem_30ip2_gg_:hover{cursor:pointer}.___SLegendItem_30ip2_gg_.__disabled_30ip2_gg_:hover{cursor:default}}.___SPointShape_30ip2_gg_.__color_30ip2_gg_{background-color:var(--color_30ip2);margin-right:8px;flex-shrink:0}.___SPointShape_30ip2_gg_._shape_Circle_30ip2_gg_._size_l_30ip2_gg_{width:16px;height:16px;border-radius:8px;margin-top:4px}.___SPointShape_30ip2_gg_._shape_Circle_30ip2_gg_._size_m_30ip2_gg_{width:12px;height:12px;border-radius:6px;margin-top:4px}.___SPointShape_30ip2_gg_._shape_Line_30ip2_gg_._size_l_30ip2_gg_{width:16px;height:4px;border-radius:3px;margin-top:9px}.___SPointShape_30ip2_gg_._shape_Line_30ip2_gg_._size_m_30ip2_gg_{width:12px;height:4px;border-radius:3px;margin-top:8px}.___SPointShape_30ip2_gg_._shape_Square_30ip2_gg_._size_l_30ip2_gg_{width:16px;height:16px;border-radius:2px;margin-top:4px}.___SPointShape_30ip2_gg_._shape_Square_30ip2_gg_._size_m_30ip2_gg_{width:12px;height:12px;border-radius:2px;margin-top:4px}.___SPointShape_30ip2_gg_._shape_Pattern_30ip2_gg_{background-color:transparent;margin-right:4px}.___SIcon_30ip2_gg_{line-height:0;margin-right:4px}.___SIcon_30ip2_gg_._size_l_30ip2_gg_{margin-top:4px}.___SIcon_30ip2_gg_._size_m_30ip2_gg_{margin-top:2px}.___SLabel_30ip2_gg_{min-width:0}.___SAdditionalLabel_30ip2_gg_._size_l_30ip2_gg_,.___SCount_30ip2_gg_._size_l_30ip2_gg_,.___SLabel_30ip2_gg_._size_l_30ip2_gg_{font-size:var(--intergalactic-fs-300, 16px);line-height:var(--intergalactic-lh-300, 150%)}.___SAdditionalLabel_30ip2_gg_._size_m_30ip2_gg_,.___SCount_30ip2_gg_._size_m_30ip2_gg_,.___SLabel_30ip2_gg_._size_m_30ip2_gg_{font-size:var(--intergalactic-fs-200, 14px);line-height:var(--intergalactic-lh-200, 142%)}.___SAdditionalLabel_30ip2_gg_,.___SCount_30ip2_gg_{margin-left:4px}.___SAdditionalLabel_30ip2_gg_{white-space:nowrap;display:flex;align-items:flex-start}.___SAdditionalLabel_30ip2_gg_::before{content:"";display:inline-block;background-color:var(--intergalactic-text-secondary, #6c6e79);height:4px;width:4px;border-radius:2px;margin-right:4px}.___SAdditionalLabel_30ip2_gg_._size_l_30ip2_gg_::before{margin-top:10px}.___SAdditionalLabel_30ip2_gg_._size_m_30ip2_gg_::before{margin-top:8px}.___SPatternSymbol_30ip2_gg_{transform:scale(.8)}',
|
|
25
18
|
/*__inner_css_end__*/
|
|
26
|
-
"
|
|
19
|
+
"30ip2_gg_"
|
|
27
20
|
), /*__reshadow_css_end__*/
|
|
28
21
|
{
|
|
29
|
-
"__SLegendItem": "
|
|
30
|
-
"_disabled": "
|
|
31
|
-
"__SPointShape": "
|
|
32
|
-
"_color": "
|
|
33
|
-
"--color": "--
|
|
34
|
-
"_shape_Circle": "
|
|
35
|
-
"_size_l": "
|
|
36
|
-
"_size_m": "
|
|
37
|
-
"_shape_Line": "
|
|
38
|
-
"_shape_Square": "
|
|
39
|
-
"_shape_Pattern": "
|
|
40
|
-
"__SIcon": "
|
|
41
|
-
"__SLabel": "
|
|
42
|
-
"__SAdditionalLabel": "
|
|
43
|
-
"__SCount": "
|
|
44
|
-
"__SPatternSymbol": "
|
|
22
|
+
"__SLegendItem": "___SLegendItem_30ip2_gg_",
|
|
23
|
+
"_disabled": "__disabled_30ip2_gg_",
|
|
24
|
+
"__SPointShape": "___SPointShape_30ip2_gg_",
|
|
25
|
+
"_color": "__color_30ip2_gg_",
|
|
26
|
+
"--color": "--color_30ip2",
|
|
27
|
+
"_shape_Circle": "_shape_Circle_30ip2_gg_",
|
|
28
|
+
"_size_l": "_size_l_30ip2_gg_",
|
|
29
|
+
"_size_m": "_size_m_30ip2_gg_",
|
|
30
|
+
"_shape_Line": "_shape_Line_30ip2_gg_",
|
|
31
|
+
"_shape_Square": "_shape_Square_30ip2_gg_",
|
|
32
|
+
"_shape_Pattern": "_shape_Pattern_30ip2_gg_",
|
|
33
|
+
"__SIcon": "___SIcon_30ip2_gg_",
|
|
34
|
+
"__SLabel": "___SLabel_30ip2_gg_",
|
|
35
|
+
"__SAdditionalLabel": "___SAdditionalLabel_30ip2_gg_",
|
|
36
|
+
"__SCount": "___SCount_30ip2_gg_",
|
|
37
|
+
"__SPatternSymbol": "___SPatternSymbol_30ip2_gg_"
|
|
45
38
|
})
|
|
46
39
|
);
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
40
|
+
const enhance = [resolveColorEnhance(), uniqueIDEnhancement()];
|
|
41
|
+
class LegendItemRoot extends Component {
|
|
42
|
+
getUniqueID() {
|
|
43
|
+
const {
|
|
44
|
+
uid
|
|
45
|
+
} = this.asProps;
|
|
46
|
+
return `chart-legend-item-${uid}`;
|
|
52
47
|
}
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
48
|
+
getShapeProps() {
|
|
49
|
+
const {
|
|
50
|
+
checked,
|
|
51
|
+
color,
|
|
52
|
+
shape,
|
|
53
|
+
label,
|
|
54
|
+
id,
|
|
55
|
+
size,
|
|
56
|
+
resolveColor,
|
|
57
|
+
patterns,
|
|
58
|
+
onChangeLegendItem,
|
|
59
|
+
onFocusLegendItem,
|
|
60
|
+
onBlurLegendItem
|
|
61
|
+
} = this.asProps;
|
|
62
|
+
return {
|
|
63
|
+
label,
|
|
64
|
+
shape,
|
|
65
|
+
checked,
|
|
66
|
+
"color": resolveColor(color),
|
|
67
|
+
"patternKey": color,
|
|
68
|
+
patterns,
|
|
69
|
+
size,
|
|
70
|
+
"onChange": (value) => {
|
|
71
|
+
onChangeLegendItem(id, value);
|
|
72
|
+
},
|
|
73
|
+
"onFocus": () => onFocusLegendItem(id),
|
|
74
|
+
"onBlur": () => onBlurLegendItem(id),
|
|
75
|
+
"aria-labelledby": shape === "Checkbox" ? this.getUniqueID() : null
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
getIconProps() {
|
|
79
|
+
const props = this.asProps;
|
|
80
|
+
return {
|
|
81
|
+
...props,
|
|
82
|
+
children: props.icon,
|
|
83
|
+
onClick: () => props.onChangeLegendItem(props.id, !props.checked)
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
getLabelProps() {
|
|
87
|
+
const {
|
|
88
|
+
id,
|
|
89
|
+
checked,
|
|
90
|
+
color: _color,
|
|
91
|
+
onChangeLegendItem,
|
|
92
|
+
shape: _shape,
|
|
93
|
+
...props
|
|
94
|
+
} = this.asProps;
|
|
95
|
+
return {
|
|
96
|
+
...props,
|
|
97
|
+
id: this.getUniqueID(),
|
|
98
|
+
checked,
|
|
99
|
+
onClick: () => onChangeLegendItem(id, !checked),
|
|
100
|
+
children: props.label
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
getAdditionalLabelProps() {
|
|
104
|
+
const props = this.asProps;
|
|
105
|
+
const {
|
|
106
|
+
additionalInfo,
|
|
107
|
+
onChangeLegendItem,
|
|
108
|
+
id,
|
|
109
|
+
checked
|
|
110
|
+
} = props;
|
|
111
|
+
return {
|
|
112
|
+
...props,
|
|
113
|
+
children: additionalInfo && "label" in additionalInfo ? `${additionalInfo.label}` : void 0,
|
|
114
|
+
onClick: () => onChangeLegendItem(id, !checked)
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
getCountProps() {
|
|
118
|
+
const props = this.asProps;
|
|
119
|
+
const {
|
|
120
|
+
additionalInfo,
|
|
121
|
+
onChangeLegendItem,
|
|
122
|
+
id,
|
|
123
|
+
checked
|
|
124
|
+
} = props;
|
|
125
|
+
return {
|
|
126
|
+
...props,
|
|
127
|
+
children: additionalInfo && "count" in additionalInfo ? `(${additionalInfo.count})` : void 0,
|
|
128
|
+
onClick: () => onChangeLegendItem(id, !checked)
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
render() {
|
|
132
|
+
var _ref = this.asProps, _ref7;
|
|
133
|
+
const SLegendItem = Flex;
|
|
134
|
+
const {
|
|
135
|
+
styles,
|
|
136
|
+
Children,
|
|
137
|
+
shape
|
|
138
|
+
} = this.asProps;
|
|
139
|
+
const disabled = StaticShapes.includes(shape) || shape === void 0;
|
|
140
|
+
return _ref7 = sstyled(styles), /* @__PURE__ */ React.createElement(SLegendItem, _ref7.cn("SLegendItem", {
|
|
141
|
+
...assignProps({
|
|
144
142
|
"disabled": disabled,
|
|
145
143
|
"__excludeProps": ["id"]
|
|
146
|
-
}, _ref)
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
}
|
|
144
|
+
}, _ref)
|
|
145
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref7.cn("Children", {})));
|
|
146
|
+
}
|
|
147
|
+
}
|
|
150
148
|
_defineProperty(LegendItemRoot, "displayName", "LegendItem");
|
|
151
149
|
_defineProperty(LegendItemRoot, "style", style);
|
|
152
150
|
_defineProperty(LegendItemRoot, "enhance", enhance);
|
|
153
|
-
_defineProperty(LegendItemRoot, "defaultProps",
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
};
|
|
157
|
-
});
|
|
151
|
+
_defineProperty(LegendItemRoot, "defaultProps", () => ({
|
|
152
|
+
children: /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(LegendItemComponent.Shape, null), /* @__PURE__ */ React.createElement(LegendItemComponent.Icon, null), /* @__PURE__ */ React.createElement(LegendItemComponent.Label, null), /* @__PURE__ */ React.createElement(LegendItemComponent.AdditionalLabel, null), /* @__PURE__ */ React.createElement(LegendItemComponent.Count, null))
|
|
153
|
+
}));
|
|
158
154
|
function Shape(props) {
|
|
159
155
|
var _ref2 = arguments[0], _ref0;
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
156
|
+
const SPointShape = Box;
|
|
157
|
+
const SPatternSymbol = PatternSymbol;
|
|
158
|
+
const {
|
|
159
|
+
styles,
|
|
160
|
+
size,
|
|
161
|
+
shape,
|
|
162
|
+
checked,
|
|
163
|
+
color,
|
|
164
|
+
patternKey = getChartDefaultColorName(0),
|
|
165
|
+
Children,
|
|
166
|
+
children: hasChildren,
|
|
167
|
+
patterns,
|
|
168
|
+
onChange,
|
|
169
|
+
onFocus,
|
|
170
|
+
onBlur
|
|
171
|
+
} = props;
|
|
163
172
|
if (hasChildren) {
|
|
164
173
|
return /* @__PURE__ */ React.createElement(Children, null);
|
|
165
174
|
}
|
|
@@ -186,66 +195,86 @@ function Shape(props) {
|
|
|
186
195
|
})), patterns && /* @__PURE__ */ React.createElement(Box, _ref9.cn("Box", {
|
|
187
196
|
"mt": "2px",
|
|
188
197
|
"mr": 1,
|
|
189
|
-
"onClick":
|
|
190
|
-
return onChange(!checked);
|
|
191
|
-
}
|
|
198
|
+
"onClick": () => onChange(!checked)
|
|
192
199
|
}), /* @__PURE__ */ React.createElement(SPatternSymbol, _ref9.cn("SPatternSymbol", {
|
|
193
200
|
"color": color,
|
|
194
201
|
"patternKey": patternKey,
|
|
195
202
|
"aria-hidden": true
|
|
196
203
|
}))));
|
|
197
204
|
}
|
|
198
|
-
return _ref0 = sstyled(styles), /* @__PURE__ */ React.createElement(SPointShape, _ref0.cn("SPointShape",
|
|
205
|
+
return _ref0 = sstyled(styles), /* @__PURE__ */ React.createElement(SPointShape, _ref0.cn("SPointShape", {
|
|
206
|
+
...assignProps({}, _ref2)
|
|
207
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref0.cn("Children", {})));
|
|
199
208
|
}
|
|
200
|
-
function Icon(
|
|
209
|
+
function Icon({
|
|
210
|
+
styles,
|
|
211
|
+
children: hasChildren,
|
|
212
|
+
Children
|
|
213
|
+
}) {
|
|
201
214
|
var _ref3 = arguments[0], _ref1;
|
|
202
|
-
|
|
203
|
-
var SIcon = Box;
|
|
215
|
+
const SIcon = Box;
|
|
204
216
|
if (!hasChildren) {
|
|
205
217
|
return null;
|
|
206
218
|
}
|
|
207
|
-
return _ref1 = sstyled(styles), /* @__PURE__ */ React.createElement(SIcon, _ref1.cn("SIcon",
|
|
208
|
-
|
|
209
|
-
|
|
219
|
+
return _ref1 = sstyled(styles), /* @__PURE__ */ React.createElement(SIcon, _ref1.cn("SIcon", {
|
|
220
|
+
...assignProps({
|
|
221
|
+
"tag": "span"
|
|
222
|
+
}, _ref3)
|
|
223
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref1.cn("Children", {})));
|
|
210
224
|
}
|
|
211
225
|
Icon.displayName = "Icon";
|
|
212
|
-
function Label(
|
|
226
|
+
function Label({
|
|
227
|
+
styles,
|
|
228
|
+
children: hasChildren,
|
|
229
|
+
Children
|
|
230
|
+
}) {
|
|
213
231
|
var _ref4 = arguments[0], _ref10;
|
|
214
|
-
|
|
215
|
-
var SLabel = Text;
|
|
232
|
+
const SLabel = Text;
|
|
216
233
|
if (!hasChildren) {
|
|
217
234
|
return null;
|
|
218
235
|
}
|
|
219
|
-
return _ref10 = sstyled(styles), /* @__PURE__ */ React.createElement(SLabel, _ref10.cn("SLabel",
|
|
220
|
-
|
|
221
|
-
|
|
236
|
+
return _ref10 = sstyled(styles), /* @__PURE__ */ React.createElement(SLabel, _ref10.cn("SLabel", {
|
|
237
|
+
...assignProps({
|
|
238
|
+
"use": "primary"
|
|
239
|
+
}, _ref4)
|
|
240
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref10.cn("Children", {})));
|
|
222
241
|
}
|
|
223
242
|
Label.displayName = "Label";
|
|
224
|
-
function AdditionalLabel(
|
|
243
|
+
function AdditionalLabel({
|
|
244
|
+
styles,
|
|
245
|
+
children: hasChildren,
|
|
246
|
+
Children
|
|
247
|
+
}) {
|
|
225
248
|
var _ref5 = arguments[0], _ref11;
|
|
226
|
-
|
|
227
|
-
var SAdditionalLabel = Text;
|
|
249
|
+
const SAdditionalLabel = Text;
|
|
228
250
|
if (!hasChildren) {
|
|
229
251
|
return null;
|
|
230
252
|
}
|
|
231
|
-
return _ref11 = sstyled(styles), /* @__PURE__ */ React.createElement(SAdditionalLabel, _ref11.cn("SAdditionalLabel",
|
|
232
|
-
|
|
233
|
-
|
|
253
|
+
return _ref11 = sstyled(styles), /* @__PURE__ */ React.createElement(SAdditionalLabel, _ref11.cn("SAdditionalLabel", {
|
|
254
|
+
...assignProps({
|
|
255
|
+
"use": "secondary"
|
|
256
|
+
}, _ref5)
|
|
257
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref11.cn("Children", {})));
|
|
234
258
|
}
|
|
235
259
|
AdditionalLabel.displayName = "AdditionalLabel";
|
|
236
|
-
function Count(
|
|
260
|
+
function Count({
|
|
261
|
+
styles,
|
|
262
|
+
children: hasChildren,
|
|
263
|
+
Children
|
|
264
|
+
}) {
|
|
237
265
|
var _ref6 = arguments[0], _ref12;
|
|
238
|
-
|
|
239
|
-
var SCount = Text;
|
|
266
|
+
const SCount = Text;
|
|
240
267
|
if (!hasChildren) {
|
|
241
268
|
return null;
|
|
242
269
|
}
|
|
243
|
-
return _ref12 = sstyled(styles), /* @__PURE__ */ React.createElement(SCount, _ref12.cn("SCount",
|
|
244
|
-
|
|
245
|
-
|
|
270
|
+
return _ref12 = sstyled(styles), /* @__PURE__ */ React.createElement(SCount, _ref12.cn("SCount", {
|
|
271
|
+
...assignProps({
|
|
272
|
+
"use": "secondary"
|
|
273
|
+
}, _ref6)
|
|
274
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref12.cn("Children", {})));
|
|
246
275
|
}
|
|
247
276
|
Count.displayName = "Count";
|
|
248
|
-
|
|
277
|
+
const LegendItemComponent = createComponent(LegendItemRoot, {
|
|
249
278
|
Shape,
|
|
250
279
|
Icon,
|
|
251
280
|
Label,
|
|
@@ -1,84 +1,86 @@
|
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
-
import _callSuper from "@babel/runtime/helpers/esm/callSuper";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
1
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
7
2
|
import { createComponent, sstyled, assignProps } from "@semcore/core";
|
|
8
|
-
import { Box } from "@semcore/
|
|
3
|
+
import { Box } from "@semcore/base-components";
|
|
9
4
|
import React from "react";
|
|
10
5
|
import { BaseLegend } from "../BaseLegend.mjs";
|
|
11
6
|
import { LegendItemComponent } from "../LegendItem/LegendItem.mjs";
|
|
12
7
|
/*!__reshadow-styles__:"./legend-table.shadow.css"*/
|
|
13
|
-
|
|
8
|
+
const style = (
|
|
14
9
|
/*__reshadow_css_start__*/
|
|
15
10
|
(sstyled.insert(
|
|
16
11
|
/*__inner_css_start__*/
|
|
17
|
-
'.
|
|
12
|
+
'.___SLegendTable_1jxzo_gg_.__columns-count_1jxzo_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_1jxzo_gg_._size_l_1jxzo_gg_{font-size:var(--intergalactic-fs-300, 16px);text-align:right}.___SColumnItem_1jxzo_gg_._size_m_1jxzo_gg_{font-size:var(--intergalactic-fs-200, 14px);text-align:right}',
|
|
18
13
|
/*__inner_css_end__*/
|
|
19
|
-
"
|
|
14
|
+
"1jxzo_gg_"
|
|
20
15
|
), /*__reshadow_css_end__*/
|
|
21
16
|
{
|
|
22
|
-
"__SLegendTable": "
|
|
23
|
-
"_columns-count": "__columns-
|
|
24
|
-
"__SColumnItem": "
|
|
25
|
-
"_size_l": "
|
|
26
|
-
"_size_m": "
|
|
17
|
+
"__SLegendTable": "___SLegendTable_1jxzo_gg_",
|
|
18
|
+
"_columns-count": "__columns-count_1jxzo_gg_",
|
|
19
|
+
"__SColumnItem": "___SColumnItem_1jxzo_gg_",
|
|
20
|
+
"_size_l": "_size_l_1jxzo_gg_",
|
|
21
|
+
"_size_m": "_size_m_1jxzo_gg_"
|
|
27
22
|
})
|
|
28
23
|
);
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
24
|
+
class LegendTableRoot extends BaseLegend {
|
|
25
|
+
render() {
|
|
26
|
+
var _a;
|
|
27
|
+
var _ref = this.asProps, _ref3;
|
|
28
|
+
const SLegendTable = Box;
|
|
29
|
+
const {
|
|
30
|
+
styles,
|
|
31
|
+
Children,
|
|
32
|
+
size = "m",
|
|
33
|
+
items
|
|
34
|
+
} = this.asProps;
|
|
35
|
+
const columnsCount = (_a = items[0]) == null ? void 0 : _a.columns.length;
|
|
36
|
+
return _ref3 = sstyled(styles), /* @__PURE__ */ React.createElement(SLegendTable, _ref3.cn("SLegendTable", {
|
|
37
|
+
...assignProps({
|
|
43
38
|
"columns-count": columnsCount + 1,
|
|
44
39
|
"role": "group"
|
|
45
|
-
}, _ref)
|
|
46
|
-
|
|
40
|
+
}, _ref)
|
|
41
|
+
}), items.map(({
|
|
42
|
+
id,
|
|
43
|
+
columns = []
|
|
44
|
+
}, _index) => {
|
|
45
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, {
|
|
46
|
+
key: id
|
|
47
|
+
}, /* @__PURE__ */ React.createElement(Children, null), columns.map((item, index) => {
|
|
47
48
|
return /* @__PURE__ */ React.createElement(React.Fragment, {
|
|
48
|
-
key: id
|
|
49
|
-
}, /* @__PURE__ */ React.createElement(
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
size,
|
|
55
|
-
styles
|
|
56
|
-
}, item));
|
|
57
|
-
}));
|
|
49
|
+
key: `${id}__${index}`
|
|
50
|
+
}, /* @__PURE__ */ React.createElement(LegendTable.Column, {
|
|
51
|
+
index,
|
|
52
|
+
size,
|
|
53
|
+
styles
|
|
54
|
+
}, item));
|
|
58
55
|
}));
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
}
|
|
56
|
+
}));
|
|
57
|
+
}
|
|
58
|
+
}
|
|
62
59
|
_defineProperty(LegendTableRoot, "displayName", "LegendTable");
|
|
63
60
|
_defineProperty(LegendTableRoot, "style", style);
|
|
64
|
-
_defineProperty(LegendTableRoot, "defaultProps",
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
};
|
|
68
|
-
});
|
|
61
|
+
_defineProperty(LegendTableRoot, "defaultProps", () => ({
|
|
62
|
+
children: /* @__PURE__ */ React.createElement(LegendTable.LegendItem, null)
|
|
63
|
+
}));
|
|
69
64
|
function ColumnComponent(props) {
|
|
70
65
|
var _ref2 = arguments[0], _ref4;
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
66
|
+
const SColumnItem = Box;
|
|
67
|
+
const {
|
|
68
|
+
styles,
|
|
69
|
+
index,
|
|
70
|
+
size,
|
|
71
|
+
Children
|
|
72
|
+
} = props;
|
|
73
|
+
return _ref4 = sstyled(styles), /* @__PURE__ */ React.createElement(SColumnItem, _ref4.cn("SColumnItem", {
|
|
74
|
+
...assignProps({
|
|
75
|
+
"style": {
|
|
76
|
+
gridColumnStart: `${index + 2}`,
|
|
77
|
+
gridColumnEnd: `${index + 3}`
|
|
78
|
+
},
|
|
79
|
+
"size": size
|
|
80
|
+
}, _ref2)
|
|
81
|
+
}), /* @__PURE__ */ React.createElement(Children, _ref4.cn("Children", {})));
|
|
80
82
|
}
|
|
81
|
-
|
|
83
|
+
const LegendTable = createComponent(LegendTableRoot, {
|
|
82
84
|
LegendItem: LegendItemComponent,
|
|
83
85
|
Column: ColumnComponent
|
|
84
86
|
});
|