@neo4j-ndl/react-charts 2.1.21 → 2.2.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/lib/LICENSES.txt +0 -295
- package/lib/NOTICE.txt +1383 -1392
- package/lib/{esm/charts/index.js → cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/defineProperty.js} +13 -5
- package/lib/cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/objectSpread2.js +46 -0
- package/lib/{esm/charts/tests/ChartWrapperWithTooltipFormatter.js → cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/objectWithoutProperties.js} +12 -13
- package/lib/{esm/index.js → cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/objectWithoutPropertiesLoose.js} +13 -2
- package/lib/cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/toPrimitive.js +35 -0
- package/lib/{esm/charts/utils/chart-types.js → cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/toPropertyKey.js} +10 -2
- package/lib/cjs/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/typeof.js +37 -0
- package/lib/cjs/_virtual/_rolldown/runtime.js +44 -0
- package/lib/cjs/charts/Chart.js +121 -111
- package/lib/cjs/charts/Chart.js.map +1 -1
- package/lib/cjs/charts/ChartContainer.js +67 -62
- package/lib/cjs/charts/ChartContainer.js.map +1 -1
- package/lib/cjs/charts/ChartEmpty.js +45 -30
- package/lib/cjs/charts/ChartEmpty.js.map +1 -1
- package/lib/cjs/charts/ChartRender.js +112 -87
- package/lib/cjs/charts/ChartRender.js.map +1 -1
- package/lib/cjs/charts/ChartTooltip.js +111 -65
- package/lib/cjs/charts/ChartTooltip.js.map +1 -1
- package/lib/cjs/charts/Legend.js +81 -69
- package/lib/cjs/charts/Legend.js.map +1 -1
- package/lib/cjs/charts/LegendItem.js +83 -62
- package/lib/cjs/charts/LegendItem.js.map +1 -1
- package/lib/cjs/charts/LegendLayout.js +330 -348
- package/lib/cjs/charts/LegendLayout.js.map +1 -1
- package/lib/cjs/charts/hooks/use-chart-instance.js +115 -122
- package/lib/cjs/charts/hooks/use-chart-instance.js.map +1 -1
- package/lib/cjs/charts/hooks/use-chart-option.js +79 -80
- package/lib/cjs/charts/hooks/use-chart-option.js.map +1 -1
- package/lib/cjs/charts/hooks/use-chart-refs.js +47 -44
- package/lib/cjs/charts/hooks/use-chart-refs.js.map +1 -1
- package/lib/cjs/charts/hooks/use-chart-zoom.js +102 -127
- package/lib/cjs/charts/hooks/use-chart-zoom.js.map +1 -1
- package/lib/cjs/charts/hooks/use-legend-interactions.js +127 -132
- package/lib/cjs/charts/hooks/use-legend-interactions.js.map +1 -1
- package/lib/cjs/charts/hooks/use-legend-series.js +143 -174
- package/lib/cjs/charts/hooks/use-legend-series.js.map +1 -1
- package/lib/cjs/charts/hooks/use-legend-visibility.js +66 -85
- package/lib/cjs/charts/hooks/use-legend-visibility.js.map +1 -1
- package/lib/cjs/charts/index.js +31 -40
- package/lib/cjs/charts/index.js.map +1 -1
- package/lib/cjs/charts/themes/ndl-echarts-theme.js +136 -168
- package/lib/cjs/charts/themes/ndl-echarts-theme.js.map +1 -1
- package/lib/cjs/charts/utils/aria-description.js +150 -214
- package/lib/cjs/charts/utils/aria-description.js.map +1 -1
- package/lib/cjs/charts/utils/build-chart-option.js +166 -174
- package/lib/cjs/charts/utils/build-chart-option.js.map +1 -1
- package/lib/cjs/charts/utils/chart-tooltip-formatter.js +156 -172
- package/lib/cjs/charts/utils/chart-tooltip-formatter.js.map +1 -1
- package/lib/cjs/charts/utils/chart-types.js +25 -20
- package/lib/cjs/charts/utils/chart-types.js.map +1 -1
- package/lib/cjs/charts/utils/defaults.js +69 -67
- package/lib/cjs/charts/utils/defaults.js.map +1 -1
- package/lib/cjs/charts/utils/format-utils.js +55 -66
- package/lib/cjs/charts/utils/format-utils.js.map +1 -1
- package/lib/cjs/charts/utils/legend-layout.js +54 -53
- package/lib/cjs/charts/utils/legend-layout.js.map +1 -1
- package/lib/cjs/charts/utils/legend-utils.js +82 -121
- package/lib/cjs/charts/utils/legend-utils.js.map +1 -1
- package/lib/cjs/charts/utils/scatter-tooltip-points.js +191 -266
- package/lib/cjs/charts/utils/scatter-tooltip-points.js.map +1 -1
- package/lib/cjs/charts/utils/threshold.js +89 -102
- package/lib/cjs/charts/utils/threshold.js.map +1 -1
- package/lib/cjs/charts/utils/user-option-utils.js +419 -347
- package/lib/cjs/charts/utils/user-option-utils.js.map +1 -1
- package/lib/cjs/index.js +31 -35
- package/lib/cjs/index.js.map +1 -1
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/defineProperty.mjs +11 -0
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/objectSpread2.mjs +24 -0
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/objectWithoutProperties.mjs +12 -0
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/objectWithoutPropertiesLoose.mjs +11 -0
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/toPrimitive.mjs +13 -0
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/toPropertyKey.mjs +8 -0
- package/lib/esm/_virtual/_@oxc-project_runtime@0.156.0/helpers/esm/typeof.mjs +10 -0
- package/lib/esm/charts/Chart.mjs +123 -0
- package/lib/esm/charts/Chart.mjs.map +1 -0
- package/lib/esm/charts/ChartContainer.mjs +71 -0
- package/lib/esm/charts/ChartContainer.mjs.map +1 -0
- package/lib/esm/charts/ChartEmpty.mjs +46 -0
- package/lib/esm/charts/ChartEmpty.mjs.map +1 -0
- package/lib/esm/charts/ChartRender.mjs +113 -0
- package/lib/esm/charts/ChartRender.mjs.map +1 -0
- package/lib/esm/charts/ChartTooltip.mjs +109 -0
- package/lib/esm/charts/ChartTooltip.mjs.map +1 -0
- package/lib/esm/charts/Legend.mjs +82 -0
- package/lib/esm/charts/Legend.mjs.map +1 -0
- package/lib/esm/charts/LegendItem.mjs +82 -0
- package/lib/esm/charts/LegendItem.mjs.map +1 -0
- package/lib/esm/charts/LegendLayout.mjs +337 -0
- package/lib/esm/charts/LegendLayout.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-chart-instance.mjs +119 -0
- package/lib/esm/charts/hooks/use-chart-instance.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-chart-option.mjs +79 -0
- package/lib/esm/charts/hooks/use-chart-option.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-chart-refs.mjs +49 -0
- package/lib/esm/charts/hooks/use-chart-refs.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-chart-zoom.mjs +102 -0
- package/lib/esm/charts/hooks/use-chart-zoom.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-legend-interactions.mjs +138 -0
- package/lib/esm/charts/hooks/use-legend-interactions.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-legend-series.mjs +151 -0
- package/lib/esm/charts/hooks/use-legend-series.mjs.map +1 -0
- package/lib/esm/charts/hooks/use-legend-visibility.mjs +67 -0
- package/lib/esm/charts/hooks/use-legend-visibility.mjs.map +1 -0
- package/lib/esm/charts/index.mjs +27 -0
- package/lib/esm/charts/index.mjs.map +1 -0
- package/lib/esm/charts/themes/ndl-echarts-theme.mjs +139 -0
- package/lib/esm/charts/themes/ndl-echarts-theme.mjs.map +1 -0
- package/lib/esm/charts/utils/aria-description.mjs +162 -0
- package/lib/esm/charts/utils/aria-description.mjs.map +1 -0
- package/lib/esm/charts/utils/build-chart-option.mjs +184 -0
- package/lib/esm/charts/utils/build-chart-option.mjs.map +1 -0
- package/lib/esm/charts/utils/chart-tooltip-formatter.mjs +159 -0
- package/lib/esm/charts/utils/chart-tooltip-formatter.mjs.map +1 -0
- package/lib/esm/charts/utils/chart-types.mjs +24 -0
- package/lib/esm/charts/utils/chart-types.mjs.map +1 -0
- package/lib/esm/charts/utils/defaults.mjs +73 -0
- package/lib/esm/charts/utils/defaults.mjs.map +1 -0
- package/lib/esm/charts/utils/format-utils.mjs +61 -0
- package/lib/esm/charts/utils/format-utils.mjs.map +1 -0
- package/lib/esm/charts/utils/legend-layout.mjs +57 -0
- package/lib/esm/charts/utils/legend-layout.mjs.map +1 -0
- package/lib/esm/charts/utils/legend-utils.mjs +90 -0
- package/lib/esm/charts/utils/legend-utils.mjs.map +1 -0
- package/lib/esm/charts/utils/scatter-tooltip-points.mjs +215 -0
- package/lib/esm/charts/utils/scatter-tooltip-points.mjs.map +1 -0
- package/lib/esm/charts/utils/threshold.mjs +92 -0
- package/lib/esm/charts/utils/threshold.mjs.map +1 -0
- package/lib/esm/charts/utils/user-option-utils.mjs +445 -0
- package/lib/esm/charts/utils/user-option-utils.mjs.map +1 -0
- package/lib/esm/index.mjs +27 -0
- package/lib/esm/index.mjs.map +1 -0
- package/package.json +12 -16
- package/skills/ndl-react-charts/SKILL.md +2 -2
- package/lib/cjs/charts/tests/ChartWrapperWithTooltipFormatter.js +0 -38
- package/lib/cjs/charts/tests/ChartWrapperWithTooltipFormatter.js.map +0 -1
- package/lib/cjs/charts/tests/ChartZoomHarness.js +0 -113
- package/lib/cjs/charts/tests/ChartZoomHarness.js.map +0 -1
- package/lib/cjs/charts/tests/HorizontalBarWithVerticalSlider.js +0 -78
- package/lib/cjs/charts/tests/HorizontalBarWithVerticalSlider.js.map +0 -1
- package/lib/cjs/charts/tests/PieChartWithRerender.js +0 -46
- package/lib/cjs/charts/tests/PieChartWithRerender.js.map +0 -1
- package/lib/cjs/charts/tests/chart-test-utils.js +0 -527
- package/lib/cjs/charts/tests/chart-test-utils.js.map +0 -1
- package/lib/esm/charts/Chart.js +0 -114
- package/lib/esm/charts/Chart.js.map +0 -1
- package/lib/esm/charts/ChartContainer.js +0 -67
- package/lib/esm/charts/ChartContainer.js.map +0 -1
- package/lib/esm/charts/ChartEmpty.js +0 -33
- package/lib/esm/charts/ChartEmpty.js.map +0 -1
- package/lib/esm/charts/ChartRender.js +0 -89
- package/lib/esm/charts/ChartRender.js.map +0 -1
- package/lib/esm/charts/ChartTooltip.js +0 -64
- package/lib/esm/charts/ChartTooltip.js.map +0 -1
- package/lib/esm/charts/Legend.js +0 -71
- package/lib/esm/charts/Legend.js.map +0 -1
- package/lib/esm/charts/LegendItem.js +0 -61
- package/lib/esm/charts/LegendItem.js.map +0 -1
- package/lib/esm/charts/LegendLayout.js +0 -323
- package/lib/esm/charts/LegendLayout.js.map +0 -1
- package/lib/esm/charts/hooks/use-chart-instance.js +0 -128
- package/lib/esm/charts/hooks/use-chart-instance.js.map +0 -1
- package/lib/esm/charts/hooks/use-chart-option.js +0 -82
- package/lib/esm/charts/hooks/use-chart-option.js.map +0 -1
- package/lib/esm/charts/hooks/use-chart-refs.js +0 -48
- package/lib/esm/charts/hooks/use-chart-refs.js.map +0 -1
- package/lib/esm/charts/hooks/use-chart-zoom.js +0 -129
- package/lib/esm/charts/hooks/use-chart-zoom.js.map +0 -1
- package/lib/esm/charts/hooks/use-legend-interactions.js +0 -145
- package/lib/esm/charts/hooks/use-legend-interactions.js.map +0 -1
- package/lib/esm/charts/hooks/use-legend-series.js +0 -184
- package/lib/esm/charts/hooks/use-legend-series.js.map +0 -1
- package/lib/esm/charts/hooks/use-legend-visibility.js +0 -87
- package/lib/esm/charts/hooks/use-legend-visibility.js.map +0 -1
- package/lib/esm/charts/index.js.map +0 -1
- package/lib/esm/charts/tests/ChartWrapperWithTooltipFormatter.js.map +0 -1
- package/lib/esm/charts/tests/ChartZoomHarness.js +0 -109
- package/lib/esm/charts/tests/ChartZoomHarness.js.map +0 -1
- package/lib/esm/charts/tests/HorizontalBarWithVerticalSlider.js +0 -74
- package/lib/esm/charts/tests/HorizontalBarWithVerticalSlider.js.map +0 -1
- package/lib/esm/charts/tests/PieChartWithRerender.js +0 -43
- package/lib/esm/charts/tests/PieChartWithRerender.js.map +0 -1
- package/lib/esm/charts/tests/chart-test-utils.js +0 -500
- package/lib/esm/charts/tests/chart-test-utils.js.map +0 -1
- package/lib/esm/charts/themes/ndl-echarts-theme.js +0 -172
- package/lib/esm/charts/themes/ndl-echarts-theme.js.map +0 -1
- package/lib/esm/charts/utils/aria-description.js +0 -228
- package/lib/esm/charts/utils/aria-description.js.map +0 -1
- package/lib/esm/charts/utils/build-chart-option.js +0 -193
- package/lib/esm/charts/utils/build-chart-option.js.map +0 -1
- package/lib/esm/charts/utils/chart-tooltip-formatter.js +0 -177
- package/lib/esm/charts/utils/chart-tooltip-formatter.js.map +0 -1
- package/lib/esm/charts/utils/chart-types.js.map +0 -1
- package/lib/esm/charts/utils/defaults.js +0 -73
- package/lib/esm/charts/utils/defaults.js.map +0 -1
- package/lib/esm/charts/utils/format-utils.js +0 -74
- package/lib/esm/charts/utils/format-utils.js.map +0 -1
- package/lib/esm/charts/utils/legend-layout.js +0 -59
- package/lib/esm/charts/utils/legend-layout.js.map +0 -1
- package/lib/esm/charts/utils/legend-utils.js +0 -131
- package/lib/esm/charts/utils/legend-utils.js.map +0 -1
- package/lib/esm/charts/utils/scatter-tooltip-points.js +0 -291
- package/lib/esm/charts/utils/scatter-tooltip-points.js.map +0 -1
- package/lib/esm/charts/utils/threshold.js +0 -106
- package/lib/esm/charts/utils/threshold.js.map +0 -1
- package/lib/esm/charts/utils/user-option-utils.js +0 -374
- package/lib/esm/charts/utils/user-option-utils.js.map +0 -1
- package/lib/esm/index.js.map +0 -1
|
@@ -1,80 +1,82 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
Object.defineProperties(exports, {
|
|
3
|
+
__esModule: { value: true },
|
|
4
|
+
[Symbol.toStringTag]: { value: "Module" }
|
|
5
|
+
});
|
|
6
|
+
// src/charts/utils/defaults.ts
|
|
2
7
|
/*!
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
exports.tooltipMaxWidth = exports.tooltipExtraCssText = exports.needleOwnedComponents = exports.defaultThresholdLineSeriesOption = exports.defaultChartSettings = void 0;
|
|
24
|
-
const defaultThresholdLineSeriesOption = {
|
|
25
|
-
condition: 'greater',
|
|
26
|
-
};
|
|
27
|
-
exports.defaultThresholdLineSeriesOption = defaultThresholdLineSeriesOption;
|
|
8
|
+
*
|
|
9
|
+
* Copyright (c) "Neo4j"
|
|
10
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
11
|
+
*
|
|
12
|
+
* This file is part of Neo4j.
|
|
13
|
+
*
|
|
14
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
15
|
+
* it under the terms of the GNU General Public License as published by
|
|
16
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
17
|
+
* (at your option) any later version.
|
|
18
|
+
*
|
|
19
|
+
* This program is distributed in the hope that it will be useful,
|
|
20
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
21
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
22
|
+
* GNU General Public License for more details.
|
|
23
|
+
*
|
|
24
|
+
* You should have received a copy of the GNU General Public License
|
|
25
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
26
|
+
*/
|
|
27
|
+
const defaultThresholdLineSeriesOption = { condition: "greater" };
|
|
28
28
|
const tooltipMaxWidth = 400;
|
|
29
|
-
exports.tooltipMaxWidth = tooltipMaxWidth;
|
|
30
29
|
/**
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
30
|
+
* ECharts writes `white-space: nowrap` inline on the tooltip container, so a
|
|
31
|
+
* long series name or category label stretches the tooltip across the chart
|
|
32
|
+
* until the max width and normal wrapping override it. `overflow-wrap` is
|
|
33
|
+
* needed on top of that: the tooltip rows are flex items, and only `anywhere`
|
|
34
|
+
* lets their min-content size drop below the longest word.
|
|
35
|
+
*/
|
|
37
36
|
const tooltipExtraCssText = [
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
].join(
|
|
44
|
-
exports.tooltipExtraCssText = tooltipExtraCssText;
|
|
37
|
+
"box-shadow: none",
|
|
38
|
+
"background-color: transparent",
|
|
39
|
+
`max-width: 400px`,
|
|
40
|
+
"white-space: normal",
|
|
41
|
+
"overflow-wrap: anywhere"
|
|
42
|
+
].join("; ");
|
|
45
43
|
/**
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
44
|
+
* ECharts component main types that `buildChartOption` always writes in full,
|
|
45
|
+
* so replacing them gives the same "drop what disappeared" behavior as
|
|
46
|
+
* `notMerge`. Every entry has to be a registered component main type, which is
|
|
47
|
+
* only asserted by ECharts in development builds.
|
|
48
|
+
*
|
|
49
|
+
* `toolbox` is deliberately absent: it has to keep its view instance across
|
|
50
|
+
* updates, see `defaultChartSettings`.
|
|
51
|
+
*/
|
|
54
52
|
const needleOwnedComponents = [
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
53
|
+
"dataZoom",
|
|
54
|
+
"dataset",
|
|
55
|
+
"grid",
|
|
56
|
+
"legend",
|
|
57
|
+
"series",
|
|
58
|
+
"tooltip",
|
|
59
|
+
"xAxis",
|
|
60
|
+
"yAxis"
|
|
63
61
|
];
|
|
64
|
-
exports.needleOwnedComponents = needleOwnedComponents;
|
|
65
62
|
/**
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
63
|
+
* `notMerge` rebuilds every component view on each `setOption`. That makes
|
|
64
|
+
* ECharts mount a fresh toolbox brush controller while the previous one stays
|
|
65
|
+
* attached to the renderer, because `ToolboxView.dispose` iterates its feature
|
|
66
|
+
* map with `zrUtil.each` and so never disposes anything. Every leftover
|
|
67
|
+
* controller then re-applies the same drag, each time against an axis the
|
|
68
|
+
* previous one already zoomed, which shrinks the selected range.
|
|
69
|
+
*/
|
|
73
70
|
const defaultChartSettings = {
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
71
|
+
lazyUpdate: false,
|
|
72
|
+
notMerge: false,
|
|
73
|
+
replaceMerge: needleOwnedComponents,
|
|
74
|
+
silent: false
|
|
78
75
|
};
|
|
79
76
|
exports.defaultChartSettings = defaultChartSettings;
|
|
77
|
+
exports.defaultThresholdLineSeriesOption = defaultThresholdLineSeriesOption;
|
|
78
|
+
exports.needleOwnedComponents = needleOwnedComponents;
|
|
79
|
+
exports.tooltipExtraCssText = tooltipExtraCssText;
|
|
80
|
+
exports.tooltipMaxWidth = tooltipMaxWidth;
|
|
81
|
+
|
|
80
82
|
//# sourceMappingURL=defaults.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defaults.js","
|
|
1
|
+
{"version":3,"file":"defaults.js","names":[],"sources":["../../../../src/charts/utils/defaults.ts"],"sourcesContent":["/*!\n *\n * Copyright (c) \"Neo4j\"\n * Neo4j Sweden AB [http://neo4j.com]\n *\n * This file is part of Neo4j.\n *\n * Neo4j is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport type { ChartProps, Condition } from './chart-types';\n\nconst defaultThresholdLineSeriesOption: {\n condition: Condition;\n} = {\n condition: 'greater',\n};\n\nconst tooltipMaxWidth = 400;\n\n/**\n * ECharts writes `white-space: nowrap` inline on the tooltip container, so a\n * long series name or category label stretches the tooltip across the chart\n * until the max width and normal wrapping override it. `overflow-wrap` is\n * needed on top of that: the tooltip rows are flex items, and only `anywhere`\n * lets their min-content size drop below the longest word.\n */\nconst tooltipExtraCssText = [\n 'box-shadow: none',\n 'background-color: transparent',\n `max-width: ${tooltipMaxWidth}px`,\n 'white-space: normal',\n 'overflow-wrap: anywhere',\n].join('; ');\n\n/**\n * ECharts component main types that `buildChartOption` always writes in full,\n * so replacing them gives the same \"drop what disappeared\" behavior as\n * `notMerge`. Every entry has to be a registered component main type, which is\n * only asserted by ECharts in development builds.\n *\n * `toolbox` is deliberately absent: it has to keep its view instance across\n * updates, see `defaultChartSettings`.\n */\nconst needleOwnedComponents = [\n 'dataZoom',\n 'dataset',\n 'grid',\n 'legend',\n 'series',\n 'tooltip',\n 'xAxis',\n 'yAxis',\n];\n\n/**\n * `notMerge` rebuilds every component view on each `setOption`. That makes\n * ECharts mount a fresh toolbox brush controller while the previous one stays\n * attached to the renderer, because `ToolboxView.dispose` iterates its feature\n * map with `zrUtil.each` and so never disposes anything. Every leftover\n * controller then re-applies the same drag, each time against an axis the\n * previous one already zoomed, which shrinks the selected range.\n */\nconst defaultChartSettings: NonNullable<ChartProps['settings']> = {\n lazyUpdate: false,\n notMerge: false,\n replaceMerge: needleOwnedComponents,\n silent: false,\n};\n\nexport {\n defaultChartSettings,\n defaultThresholdLineSeriesOption,\n needleOwnedComponents,\n tooltipExtraCssText,\n tooltipMaxWidth,\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAuBA,MAAM,mCAEF,EACF,WAAW,UACb;AAEA,MAAM,kBAAkB;;;;;;;;AASxB,MAAM,sBAAsB;CAC1B;CACA;CACA;CACA;CACA;AACF,CAAC,CAAC,KAAK,IAAI;;;;;;;;;;AAWX,MAAM,wBAAwB;CAC5B;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF;;;;;;;;;AAUA,MAAM,uBAA4D;CAChE,YAAY;CACZ,UAAU;CACV,cAAc;CACd,QAAQ;AACV"}
|
|
@@ -1,81 +1,70 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
Object.defineProperties(exports, {
|
|
3
|
+
__esModule: { value: true },
|
|
4
|
+
[Symbol.toStringTag]: { value: "Module" }
|
|
5
|
+
});
|
|
6
|
+
let echarts = require("echarts");
|
|
7
|
+
// src/charts/utils/format-utils.ts
|
|
2
8
|
/*!
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
|
-
exports.formatTooltipValue = exports.formatTimeAxisDate = exports.formatNumberEnUS = exports.extractValueFromTooltipSeries = exports.capitalizeFirstLetter = void 0;
|
|
24
|
-
const echarts_1 = require("echarts");
|
|
9
|
+
*
|
|
10
|
+
* Copyright (c) "Neo4j"
|
|
11
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
12
|
+
*
|
|
13
|
+
* This file is part of Neo4j.
|
|
14
|
+
*
|
|
15
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
16
|
+
* it under the terms of the GNU General Public License as published by
|
|
17
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
18
|
+
* (at your option) any later version.
|
|
19
|
+
*
|
|
20
|
+
* This program is distributed in the hope that it will be useful,
|
|
21
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
22
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
23
|
+
* GNU General Public License for more details.
|
|
24
|
+
*
|
|
25
|
+
* You should have received a copy of the GNU General Public License
|
|
26
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
27
|
+
*/
|
|
25
28
|
const capitalizeFirstLetter = (str) => {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
}
|
|
29
|
-
return str.charAt(0).toUpperCase() + str.substring(1);
|
|
29
|
+
if (!str) return str;
|
|
30
|
+
return str.charAt(0).toUpperCase() + str.substring(1);
|
|
30
31
|
};
|
|
31
|
-
|
|
32
|
-
const enUSNumberFormatter = new Intl.NumberFormat('en-US');
|
|
32
|
+
const enUSNumberFormatter = new Intl.NumberFormat("en-US");
|
|
33
33
|
/**
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
34
|
+
* Formats finite number values with en-US separators and returns all other
|
|
35
|
+
* values unchanged.
|
|
36
|
+
*/
|
|
37
37
|
const formatNumberEnUS = (value) => {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
41
|
-
return value;
|
|
38
|
+
if (typeof value === "number") return Number.isFinite(value) ? enUSNumberFormatter.format(value) : value;
|
|
39
|
+
return value;
|
|
42
40
|
};
|
|
43
|
-
exports.formatNumberEnUS = formatNumberEnUS;
|
|
44
41
|
/**
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
const formatTimeAxisDate = (date) =>
|
|
48
|
-
exports.formatTimeAxisDate = formatTimeAxisDate;
|
|
42
|
+
* Formats a date the way ECharts labels a time axis, so tooltips match it.
|
|
43
|
+
*/
|
|
44
|
+
const formatTimeAxisDate = (date) => echarts.time.format(date, "{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}", false);
|
|
49
45
|
/**
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
46
|
+
* Default tooltip formatting. Numbers get en-US separators and dates use
|
|
47
|
+
* `formatTimeAxisDate`. Other values are returned unchanged.
|
|
48
|
+
*/
|
|
53
49
|
const formatTooltipValue = (value) => {
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
}
|
|
57
|
-
return formatNumberEnUS(value);
|
|
50
|
+
if (value instanceof Date) return formatTimeAxisDate(value);
|
|
51
|
+
return formatNumberEnUS(value);
|
|
58
52
|
};
|
|
59
|
-
exports.formatTooltipValue = formatTooltipValue;
|
|
60
53
|
/**
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
const extractValueFromTooltipSeries = (value, encode,
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
return value;
|
|
71
|
-
}
|
|
72
|
-
// The axisDim is the axis that the tooltip was triggered on,
|
|
73
|
-
// if it was triggered on the x axis the value should be read from the y axis and vice versa
|
|
74
|
-
const encodeValueToRead = axisDim === 'x' ? encode === null || encode === void 0 ? void 0 : encode.y : ((_a = encode === null || encode === void 0 ? void 0 : encode.x) !== null && _a !== void 0 ? _a : 1);
|
|
75
|
-
const seriesValueIdx = Array.isArray(encodeValueToRead)
|
|
76
|
-
? encodeValueToRead[0]
|
|
77
|
-
: encodeValueToRead;
|
|
78
|
-
return (_b = value[seriesValueIdx]) !== null && _b !== void 0 ? _b : value;
|
|
54
|
+
* Extract the tooltip value from the series depending on the axisDim and encode properties
|
|
55
|
+
* If the value is a single value, return it as it is
|
|
56
|
+
* If the encode property does not exist fallback to 1
|
|
57
|
+
*/
|
|
58
|
+
const extractValueFromTooltipSeries = (value, encode, axisDim = "x") => {
|
|
59
|
+
var _encode$x, _value$seriesValueIdx;
|
|
60
|
+
if (!Array.isArray(value)) return value;
|
|
61
|
+
const encodeValueToRead = axisDim === "x" ? encode === null || encode === void 0 ? void 0 : encode.y : (_encode$x = encode === null || encode === void 0 ? void 0 : encode.x) !== null && _encode$x !== void 0 ? _encode$x : 1;
|
|
62
|
+
return (_value$seriesValueIdx = value[Array.isArray(encodeValueToRead) ? encodeValueToRead[0] : encodeValueToRead]) !== null && _value$seriesValueIdx !== void 0 ? _value$seriesValueIdx : value;
|
|
79
63
|
};
|
|
64
|
+
exports.capitalizeFirstLetter = capitalizeFirstLetter;
|
|
80
65
|
exports.extractValueFromTooltipSeries = extractValueFromTooltipSeries;
|
|
66
|
+
exports.formatNumberEnUS = formatNumberEnUS;
|
|
67
|
+
exports.formatTimeAxisDate = formatTimeAxisDate;
|
|
68
|
+
exports.formatTooltipValue = formatTooltipValue;
|
|
69
|
+
|
|
81
70
|
//# sourceMappingURL=format-utils.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"format-utils.js","
|
|
1
|
+
{"version":3,"file":"format-utils.js","names":["time"],"sources":["../../../../src/charts/utils/format-utils.ts"],"sourcesContent":["/*!\n *\n * Copyright (c) \"Neo4j\"\n * Neo4j Sweden AB [http://neo4j.com]\n *\n * This file is part of Neo4j.\n *\n * Neo4j is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { time } from 'echarts';\n\nconst capitalizeFirstLetter = (str: string) => {\n if (!str) {\n return str;\n }\n return str.charAt(0).toUpperCase() + str.substring(1);\n};\n\nconst enUSNumberFormatter = new Intl.NumberFormat('en-US');\n\n/**\n * Formats finite number values with en-US separators and returns all other\n * values unchanged.\n */\nconst formatNumberEnUS = <T>(value: T): string | T => {\n if (typeof value === 'number') {\n return Number.isFinite(value) ? enUSNumberFormatter.format(value) : value;\n }\n\n return value;\n};\n\n/**\n * Formats a date the way ECharts labels a time axis, so tooltips match it.\n */\nconst formatTimeAxisDate = (date: Date) =>\n time.format(date, '{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}', false);\n\n/**\n * Default tooltip formatting. Numbers get en-US separators and dates use\n * `formatTimeAxisDate`. Other values are returned unchanged.\n */\nconst formatTooltipValue = <T>(value: T): string | T => {\n if (value instanceof Date) {\n return formatTimeAxisDate(value);\n }\n\n return formatNumberEnUS(value);\n};\n\n/**\n * Extract the tooltip value from the series depending on the axisDim and encode properties\n * If the value is a single value, return it as it is\n * If the encode property does not exist fallback to 1\n */\nconst extractValueFromTooltipSeries = (\n value: string | number | (number | string)[],\n encode: {\n // E-Charts uses encode.x and encode.y - https://echarts.apache.org/en/option.html#series-line.encode\n // oxlint-disable-next-line id-length\n x: number | number[];\n // oxlint-disable-next-line id-length\n y: number | number[];\n },\n // We currently only support x and y axes\n axisDim: 'x' | 'y' | 'angle' | 'radius' | 'single' = 'x',\n) => {\n if (!Array.isArray(value)) {\n return value;\n }\n\n // The axisDim is the axis that the tooltip was triggered on,\n // if it was triggered on the x axis the value should be read from the y axis and vice versa\n const encodeValueToRead = axisDim === 'x' ? encode?.y : (encode?.x ?? 1);\n\n const seriesValueIdx = Array.isArray(encodeValueToRead)\n ? encodeValueToRead[0]\n : encodeValueToRead;\n\n return value[seriesValueIdx] ?? value;\n};\n\nexport {\n capitalizeFirstLetter,\n extractValueFromTooltipSeries,\n formatNumberEnUS,\n formatTimeAxisDate,\n formatTooltipValue,\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAuBA,MAAM,yBAAyB,QAAgB;CAC7C,IAAI,CAAC,KACH,OAAO;CAET,OAAO,IAAI,OAAO,CAAC,CAAC,CAAC,YAAY,IAAI,IAAI,UAAU,CAAC;AACtD;AAEA,MAAM,sBAAsB,IAAI,KAAK,aAAa,OAAO;;;;;AAMzD,MAAM,oBAAuB,UAAyB;CACpD,IAAI,OAAO,UAAU,UACnB,OAAO,OAAO,SAAS,KAAK,IAAI,oBAAoB,OAAO,KAAK,IAAI;CAGtE,OAAO;AACT;;;;AAKA,MAAM,sBAAsB,SAC1BA,QAAAA,KAAK,OAAO,MAAM,mCAAmC,KAAK;;;;;AAM5D,MAAM,sBAAyB,UAAyB;CACtD,IAAI,iBAAiB,MACnB,OAAO,mBAAmB,KAAK;CAGjC,OAAO,iBAAiB,KAAK;AAC/B;;;;;;AAOA,MAAM,iCACJ,OACA,QAQA,UAAqD,QAClD;;CACH,IAAI,CAAC,MAAM,QAAQ,KAAK,GACtB,OAAO;CAKT,MAAM,oBAAoB,YAAY,MAAA,WAAA,QAAA,WAAA,KAAA,IAAA,KAAA,IAAM,OAAQ,KAAA,YAAA,WAAA,QAAA,WAAA,KAAA,IAAA,KAAA,IAAK,OAAQ,OAAA,QAAA,cAAA,KAAA,IAAA,YAAK;CAMtE,QAAA,wBAAO,MAJgB,MAAM,QAAQ,iBAAiB,IAClD,kBAAkB,KAClB,wBAAA,QAAA,0BAAA,KAAA,IAAA,wBAE4B;AAClC"}
|
|
@@ -1,65 +1,66 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
Object.defineProperties(exports, {
|
|
3
|
+
__esModule: { value: true },
|
|
4
|
+
[Symbol.toStringTag]: { value: "Module" }
|
|
5
|
+
});
|
|
6
|
+
// src/charts/utils/legend-layout.ts
|
|
2
7
|
/*!
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
exports.COLLAPSED_LEGEND_ROWS = 2;
|
|
25
|
-
exports.COLLAPSED_LEGEND_MAX_HEIGHT = 64;
|
|
8
|
+
*
|
|
9
|
+
* Copyright (c) "Neo4j"
|
|
10
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
11
|
+
*
|
|
12
|
+
* This file is part of Neo4j.
|
|
13
|
+
*
|
|
14
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
15
|
+
* it under the terms of the GNU General Public License as published by
|
|
16
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
17
|
+
* (at your option) any later version.
|
|
18
|
+
*
|
|
19
|
+
* This program is distributed in the hope that it will be useful,
|
|
20
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
21
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
22
|
+
* GNU General Public License for more details.
|
|
23
|
+
*
|
|
24
|
+
* You should have received a copy of the GNU General Public License
|
|
25
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
26
|
+
*/
|
|
27
|
+
const COLLAPSED_LEGEND_ROWS = 2;
|
|
28
|
+
const COLLAPSED_LEGEND_MAX_HEIGHT = 64;
|
|
26
29
|
/**
|
|
27
|
-
|
|
28
|
-
|
|
30
|
+
* Get the computed element width, including both paddings and margins
|
|
31
|
+
*/
|
|
29
32
|
const getComputedElementWidth = (element) => {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
const elementRect = element.getBoundingClientRect();
|
|
34
|
+
const elementComputedStyle = window.getComputedStyle(element);
|
|
35
|
+
const elementMarginLeft = parseFloat(elementComputedStyle.marginLeft);
|
|
36
|
+
const elementMarginRight = parseFloat(elementComputedStyle.marginRight);
|
|
37
|
+
return elementRect.width + elementMarginLeft + elementMarginRight;
|
|
35
38
|
};
|
|
36
|
-
exports.getComputedElementWidth = getComputedElementWidth;
|
|
37
39
|
const getItemCountThatFitsRow = (itemWidths, availableWidth, { keepOversizedFirstItem = true } = {}) => {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
rowWidth += itemWidth;
|
|
48
|
-
count += 1;
|
|
49
|
-
}
|
|
50
|
-
return count;
|
|
40
|
+
let rowWidth = 0;
|
|
41
|
+
let count = 0;
|
|
42
|
+
for (const itemWidth of itemWidths) {
|
|
43
|
+
if (count === 0 && itemWidth > availableWidth) return keepOversizedFirstItem ? 1 : 0;
|
|
44
|
+
if (rowWidth + itemWidth > availableWidth) return count;
|
|
45
|
+
rowWidth += itemWidth;
|
|
46
|
+
count += 1;
|
|
47
|
+
}
|
|
48
|
+
return count;
|
|
51
49
|
};
|
|
52
|
-
exports.getItemCountThatFitsRow = getItemCountThatFitsRow;
|
|
53
50
|
/**
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
51
|
+
* Calculates how many legend items fit in the two-row collapsed layout.
|
|
52
|
+
*
|
|
53
|
+
* The second row reserves space for the "View more" action so that control
|
|
54
|
+
* remains visible at the end of the collapsed legend.
|
|
55
|
+
*/
|
|
59
56
|
const getCollapsedVisibleItemCount = (itemWidths, availableRowWidth, viewMoreButtonWidth) => {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
return firstRowItemCount + secondRowItemCount;
|
|
57
|
+
const firstRowItemCount = getItemCountThatFitsRow(itemWidths, availableRowWidth);
|
|
58
|
+
return firstRowItemCount + getItemCountThatFitsRow(itemWidths.slice(firstRowItemCount), availableRowWidth - viewMoreButtonWidth, { keepOversizedFirstItem: false });
|
|
63
59
|
};
|
|
60
|
+
exports.COLLAPSED_LEGEND_MAX_HEIGHT = COLLAPSED_LEGEND_MAX_HEIGHT;
|
|
61
|
+
exports.COLLAPSED_LEGEND_ROWS = COLLAPSED_LEGEND_ROWS;
|
|
64
62
|
exports.getCollapsedVisibleItemCount = getCollapsedVisibleItemCount;
|
|
63
|
+
exports.getComputedElementWidth = getComputedElementWidth;
|
|
64
|
+
exports.getItemCountThatFitsRow = getItemCountThatFitsRow;
|
|
65
|
+
|
|
65
66
|
//# sourceMappingURL=legend-layout.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"legend-layout.js","
|
|
1
|
+
{"version":3,"file":"legend-layout.js","names":[],"sources":["../../../../src/charts/utils/legend-layout.ts"],"sourcesContent":["/*!\n *\n * Copyright (c) \"Neo4j\"\n * Neo4j Sweden AB [http://neo4j.com]\n *\n * This file is part of Neo4j.\n *\n * Neo4j is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n */\n\nexport const COLLAPSED_LEGEND_ROWS = 2;\nexport const COLLAPSED_LEGEND_MAX_HEIGHT = 64;\n\n/**\n * Get the computed element width, including both paddings and margins\n */\nexport const getComputedElementWidth = (element: Element) => {\n const elementRect = element.getBoundingClientRect();\n const elementComputedStyle = window.getComputedStyle(element);\n const elementMarginLeft = parseFloat(elementComputedStyle.marginLeft);\n const elementMarginRight = parseFloat(elementComputedStyle.marginRight);\n\n return elementRect.width + elementMarginLeft + elementMarginRight;\n};\n\nexport const getItemCountThatFitsRow = (\n itemWidths: number[],\n availableWidth: number,\n { keepOversizedFirstItem = true } = {},\n) => {\n let rowWidth = 0;\n let count = 0;\n\n for (const itemWidth of itemWidths) {\n if (count === 0 && itemWidth > availableWidth) {\n return keepOversizedFirstItem ? 1 : 0;\n }\n\n if (rowWidth + itemWidth > availableWidth) {\n return count;\n }\n\n rowWidth += itemWidth;\n count += 1;\n }\n\n return count;\n};\n\n/**\n * Calculates how many legend items fit in the two-row collapsed layout.\n *\n * The second row reserves space for the \"View more\" action so that control\n * remains visible at the end of the collapsed legend.\n */\nexport const getCollapsedVisibleItemCount = (\n itemWidths: number[],\n availableRowWidth: number,\n viewMoreButtonWidth: number,\n) => {\n const firstRowItemCount = getItemCountThatFitsRow(\n itemWidths,\n availableRowWidth,\n );\n const secondRowItemCount = getItemCountThatFitsRow(\n itemWidths.slice(firstRowItemCount),\n availableRowWidth - viewMoreButtonWidth,\n { keepOversizedFirstItem: false },\n );\n\n return firstRowItemCount + secondRowItemCount;\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAqBA,MAAa,wBAAwB;AACrC,MAAa,8BAA8B;;;;AAK3C,MAAa,2BAA2B,YAAqB;CAC3D,MAAM,cAAc,QAAQ,sBAAsB;CAClD,MAAM,uBAAuB,OAAO,iBAAiB,OAAO;CAC5D,MAAM,oBAAoB,WAAW,qBAAqB,UAAU;CACpE,MAAM,qBAAqB,WAAW,qBAAqB,WAAW;CAEtE,OAAO,YAAY,QAAQ,oBAAoB;AACjD;AAEA,MAAa,2BACX,YACA,gBACA,EAAE,yBAAyB,SAAS,CAAC,MAClC;CACH,IAAI,WAAW;CACf,IAAI,QAAQ;CAEZ,KAAK,MAAM,aAAa,YAAY;EAClC,IAAI,UAAU,KAAK,YAAY,gBAC7B,OAAO,yBAAyB,IAAI;EAGtC,IAAI,WAAW,YAAY,gBACzB,OAAO;EAGT,YAAY;EACZ,SAAS;CACX;CAEA,OAAO;AACT;;;;;;;AAQA,MAAa,gCACX,YACA,mBACA,wBACG;CACH,MAAM,oBAAoB,wBACxB,YACA,iBACF;CAOA,OAAO,oBANoB,wBACzB,WAAW,MAAM,iBAAiB,GAClC,oBAAoB,qBACpB,EAAE,wBAAwB,MAAM,CAGU;AAC9C"}
|