@bpfdev/oly-ui 1.0.13 → 1.0.14
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/dist/index.d.mts +50 -1
- package/dist/index.d.ts +50 -1
- package/dist/index.js +343 -295
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +343 -295
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -797,7 +797,12 @@ function InfoPopoverPanel({
|
|
|
797
797
|
placement,
|
|
798
798
|
compact
|
|
799
799
|
}) {
|
|
800
|
-
const
|
|
800
|
+
const hasTitle = typeof content.title === "string" && content.title.trim() !== "";
|
|
801
|
+
const hasDescription = typeof content.description === "string" && content.description.trim() !== "";
|
|
802
|
+
const hasBullets = content.helpBullets.length > 0;
|
|
803
|
+
const hasExplicitHelpTitle = typeof content.helpTitle === "string" && content.helpTitle.trim() !== "";
|
|
804
|
+
const showHelpSection = hasBullets || hasExplicitHelpTitle;
|
|
805
|
+
const helpTitle = hasExplicitHelpTitle ? content.helpTitle : "How does it help?";
|
|
801
806
|
const border = isDark ? popperBorderDark : popperBorder;
|
|
802
807
|
const paperBg = isDark ? "#1c2128" : "#fff";
|
|
803
808
|
const textPrimary = isDark ? "#f0f6fc" : "#1a1a1a";
|
|
@@ -825,7 +830,7 @@ function InfoPopoverPanel({
|
|
|
825
830
|
boxShadow: panelShadow
|
|
826
831
|
},
|
|
827
832
|
children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_Stack.default, { spacing: stackSpacing, sx: { position: "relative", zIndex: 1 }, children: [
|
|
828
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
833
|
+
hasTitle && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
829
834
|
import_Typography.default,
|
|
830
835
|
{
|
|
831
836
|
component: "h3",
|
|
@@ -838,7 +843,7 @@ function InfoPopoverPanel({
|
|
|
838
843
|
children: content.title
|
|
839
844
|
}
|
|
840
845
|
),
|
|
841
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
846
|
+
hasDescription && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
842
847
|
import_Typography.default,
|
|
843
848
|
{
|
|
844
849
|
sx: {
|
|
@@ -849,7 +854,7 @@ function InfoPopoverPanel({
|
|
|
849
854
|
children: content.description
|
|
850
855
|
}
|
|
851
856
|
),
|
|
852
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
857
|
+
showHelpSection && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
853
858
|
import_Typography.default,
|
|
854
859
|
{
|
|
855
860
|
sx: {
|
|
@@ -862,7 +867,7 @@ function InfoPopoverPanel({
|
|
|
862
867
|
children: helpTitle
|
|
863
868
|
}
|
|
864
869
|
),
|
|
865
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
870
|
+
hasBullets && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
866
871
|
import_Box2.default,
|
|
867
872
|
{
|
|
868
873
|
component: "ul",
|
|
@@ -11025,6 +11030,10 @@ function LinePlot({
|
|
|
11025
11030
|
left: lc?.margin?.left ?? 4
|
|
11026
11031
|
};
|
|
11027
11032
|
const xFill = lc?.xAxisTickFill ?? OLY_DEFAULT_CHART_AXIS_TICK_FILL;
|
|
11033
|
+
const xTickAngle = lc?.xAxisTickAngle ?? 0;
|
|
11034
|
+
const xTickStyle = lc?.xAxisTickStyle;
|
|
11035
|
+
const xAxisHeight = lc?.xAxisHeight ?? 40;
|
|
11036
|
+
const xTickAnchor = xTickAngle < 0 ? "end" : xTickAngle > 0 ? "start" : "middle";
|
|
11028
11037
|
const yFill = lc?.yAxisTickFill ?? OLY_DEFAULT_CHART_AXIS_TICK_FILL;
|
|
11029
11038
|
const yWidth = lc?.yAxisWidth ?? 36;
|
|
11030
11039
|
const cursorStroke = lc?.cursorStroke ?? "#9CA3AF";
|
|
@@ -11043,13 +11052,15 @@ function LinePlot({
|
|
|
11043
11052
|
import_recharts6.XAxis,
|
|
11044
11053
|
{
|
|
11045
11054
|
dataKey: "label",
|
|
11046
|
-
tick: { fill: xFill, fontSize: 11 },
|
|
11055
|
+
tick: { fill: xFill, fontSize: 11, style: xTickStyle },
|
|
11047
11056
|
tickLine: false,
|
|
11048
11057
|
axisLine: {
|
|
11049
11058
|
stroke: OLY_DEFAULT_COMPOSED_CHART_CHROME5.axisTickLineStroke
|
|
11050
11059
|
},
|
|
11051
11060
|
interval: 0,
|
|
11052
|
-
height:
|
|
11061
|
+
height: xAxisHeight,
|
|
11062
|
+
angle: xTickAngle,
|
|
11063
|
+
textAnchor: xTickAnchor
|
|
11053
11064
|
}
|
|
11054
11065
|
),
|
|
11055
11066
|
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
@@ -11329,6 +11340,7 @@ var QueueTimeBreakdownArea = ({
|
|
|
11329
11340
|
() => mergeAreaData(series, xAxis),
|
|
11330
11341
|
[series, xAxis]
|
|
11331
11342
|
);
|
|
11343
|
+
const fill = ac?.fillHeight ?? false;
|
|
11332
11344
|
const stackH = ac?.stackHeightPx ?? 330;
|
|
11333
11345
|
const chartH = ac?.chartHeightPx ?? 350;
|
|
11334
11346
|
const margin = React20.useMemo(
|
|
@@ -11348,90 +11360,102 @@ var QueueTimeBreakdownArea = ({
|
|
|
11348
11360
|
}, [chartData, series]);
|
|
11349
11361
|
const yDomain = allZero ? [0, 16e3] : [0, "auto"];
|
|
11350
11362
|
const yTickCount = allZero ? 5 : void 0;
|
|
11351
|
-
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11352
|
-
|
|
11353
|
-
|
|
11354
|
-
|
|
11355
|
-
|
|
11356
|
-
|
|
11357
|
-
|
|
11358
|
-
|
|
11359
|
-
|
|
11360
|
-
|
|
11361
|
-
import_recharts7.
|
|
11362
|
-
|
|
11363
|
-
|
|
11364
|
-
|
|
11365
|
-
|
|
11366
|
-
|
|
11367
|
-
|
|
11368
|
-
),
|
|
11369
|
-
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11370
|
-
import_recharts7.YAxis,
|
|
11371
|
-
{
|
|
11372
|
-
domain: yDomain,
|
|
11373
|
-
tickCount: yTickCount,
|
|
11374
|
-
tick: { fill: theme.palette.text.secondary, fontSize: 11 },
|
|
11375
|
-
axisLine: false,
|
|
11376
|
-
tickLine: false,
|
|
11377
|
-
tickFormatter: (v) => {
|
|
11378
|
-
const n = typeof v === "number" ? v : Number(v);
|
|
11379
|
-
const safe = Number.isFinite(n) ? n : 0;
|
|
11380
|
-
return safe > 1e3 ? `${Math.ceil(safe / 1e3)}k` : String(safe);
|
|
11381
|
-
},
|
|
11382
|
-
label: {
|
|
11383
|
-
value: yLabel,
|
|
11384
|
-
angle: -90,
|
|
11385
|
-
position: "insideLeft",
|
|
11386
|
-
style: { fill: theme.palette.text.secondary, fontSize: 11 }
|
|
11387
|
-
}
|
|
11388
|
-
}
|
|
11389
|
-
),
|
|
11390
|
-
series.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11391
|
-
import_recharts7.Area,
|
|
11392
|
-
{
|
|
11393
|
-
type: "monotone",
|
|
11394
|
-
dataKey: s.name,
|
|
11395
|
-
stackId: "queueArea",
|
|
11396
|
-
stroke: palette[i % palette.length],
|
|
11397
|
-
fill: palette[i % palette.length],
|
|
11398
|
-
fillOpacity: 1,
|
|
11399
|
-
strokeWidth: 0
|
|
11400
|
-
},
|
|
11401
|
-
s.name
|
|
11402
|
-
)),
|
|
11403
|
-
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11404
|
-
import_recharts7.Tooltip,
|
|
11405
|
-
{
|
|
11406
|
-
content: (tooltipProps) => {
|
|
11407
|
-
if (renderTooltip) {
|
|
11408
|
-
const custom = renderTooltip({
|
|
11409
|
-
tooltipProps,
|
|
11410
|
-
chartData,
|
|
11411
|
-
series,
|
|
11412
|
-
xAxis
|
|
11413
|
-
});
|
|
11414
|
-
return custom == null ? null : /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_jsx_runtime41.Fragment, { children: custom });
|
|
11363
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11364
|
+
import_material18.Stack,
|
|
11365
|
+
{
|
|
11366
|
+
justifyContent: fill ? "stretch" : "center",
|
|
11367
|
+
sx: fill ? {
|
|
11368
|
+
flexGrow: 1,
|
|
11369
|
+
minHeight: 0,
|
|
11370
|
+
height: "100%",
|
|
11371
|
+
"& > *": { flex: 1, minHeight: 0 }
|
|
11372
|
+
} : { height: stackH },
|
|
11373
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_recharts7.ResponsiveContainer, { width: "100%", height: fill ? "100%" : chartH, children: /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(import_recharts7.AreaChart, { data: chartData, margin, children: [
|
|
11374
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11375
|
+
import_recharts7.CartesianGrid,
|
|
11376
|
+
{
|
|
11377
|
+
strokeDasharray: "3 3",
|
|
11378
|
+
stroke: gridStroke,
|
|
11379
|
+
vertical: false
|
|
11415
11380
|
}
|
|
11416
|
-
|
|
11417
|
-
|
|
11418
|
-
|
|
11419
|
-
|
|
11420
|
-
|
|
11421
|
-
|
|
11422
|
-
|
|
11423
|
-
|
|
11381
|
+
),
|
|
11382
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11383
|
+
import_recharts7.XAxis,
|
|
11384
|
+
{
|
|
11385
|
+
dataKey: "name",
|
|
11386
|
+
tick: { fill: theme.palette.text.secondary, fontSize: 11 },
|
|
11387
|
+
axisLine: false,
|
|
11388
|
+
tickLine: false
|
|
11389
|
+
}
|
|
11390
|
+
),
|
|
11391
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11392
|
+
import_recharts7.YAxis,
|
|
11393
|
+
{
|
|
11394
|
+
domain: yDomain,
|
|
11395
|
+
tickCount: yTickCount,
|
|
11396
|
+
tick: { fill: theme.palette.text.secondary, fontSize: 11 },
|
|
11397
|
+
axisLine: false,
|
|
11398
|
+
tickLine: false,
|
|
11399
|
+
tickFormatter: (v) => {
|
|
11400
|
+
const n = typeof v === "number" ? v : Number(v);
|
|
11401
|
+
const safe = Number.isFinite(n) ? n : 0;
|
|
11402
|
+
return safe > 1e3 ? `${Math.ceil(safe / 1e3)}k` : String(safe);
|
|
11403
|
+
},
|
|
11404
|
+
label: {
|
|
11405
|
+
value: yLabel,
|
|
11406
|
+
angle: -90,
|
|
11407
|
+
position: "insideLeft",
|
|
11408
|
+
style: { fill: theme.palette.text.secondary, fontSize: 11 }
|
|
11424
11409
|
}
|
|
11425
|
-
|
|
11426
|
-
|
|
11427
|
-
|
|
11428
|
-
|
|
11429
|
-
|
|
11430
|
-
|
|
11431
|
-
|
|
11432
|
-
|
|
11433
|
-
|
|
11434
|
-
|
|
11410
|
+
}
|
|
11411
|
+
),
|
|
11412
|
+
series.map((s, i) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11413
|
+
import_recharts7.Area,
|
|
11414
|
+
{
|
|
11415
|
+
type: "monotone",
|
|
11416
|
+
dataKey: s.name,
|
|
11417
|
+
stackId: "queueArea",
|
|
11418
|
+
stroke: palette[i % palette.length],
|
|
11419
|
+
fill: palette[i % palette.length],
|
|
11420
|
+
fillOpacity: 1,
|
|
11421
|
+
strokeWidth: 0
|
|
11422
|
+
},
|
|
11423
|
+
s.name
|
|
11424
|
+
)),
|
|
11425
|
+
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11426
|
+
import_recharts7.Tooltip,
|
|
11427
|
+
{
|
|
11428
|
+
content: (tooltipProps) => {
|
|
11429
|
+
if (renderTooltip) {
|
|
11430
|
+
const custom = renderTooltip({
|
|
11431
|
+
tooltipProps,
|
|
11432
|
+
chartData,
|
|
11433
|
+
series,
|
|
11434
|
+
xAxis
|
|
11435
|
+
});
|
|
11436
|
+
return custom == null ? null : /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(import_jsx_runtime41.Fragment, { children: custom });
|
|
11437
|
+
}
|
|
11438
|
+
const { active, payload, label } = tooltipProps;
|
|
11439
|
+
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
11440
|
+
QueueTimeBreakdownAreaTooltip,
|
|
11441
|
+
{
|
|
11442
|
+
active,
|
|
11443
|
+
label,
|
|
11444
|
+
payload,
|
|
11445
|
+
styleOverrides: ac?.areaTooltip
|
|
11446
|
+
}
|
|
11447
|
+
);
|
|
11448
|
+
},
|
|
11449
|
+
cursor: {
|
|
11450
|
+
stroke: ac?.cursorStroke ?? "#D4D4D8",
|
|
11451
|
+
strokeWidth: ac?.cursorStrokeWidth ?? 1
|
|
11452
|
+
},
|
|
11453
|
+
wrapperStyle: { outline: "none" }
|
|
11454
|
+
}
|
|
11455
|
+
)
|
|
11456
|
+
] }) })
|
|
11457
|
+
}
|
|
11458
|
+
);
|
|
11435
11459
|
};
|
|
11436
11460
|
var QueueTimeBreakdownArea_default = QueueTimeBreakdownArea;
|
|
11437
11461
|
var xDays = [
|
|
@@ -11612,10 +11636,10 @@ function DonutInnerPercentLabel(props) {
|
|
|
11612
11636
|
);
|
|
11613
11637
|
}
|
|
11614
11638
|
var DEFAULT_LABELS = [
|
|
11615
|
-
"
|
|
11616
|
-
"
|
|
11617
|
-
"
|
|
11618
|
-
"
|
|
11639
|
+
"1-15 mins",
|
|
11640
|
+
"16-30 mins",
|
|
11641
|
+
"30-45 mins",
|
|
11642
|
+
"> 45 mins"
|
|
11619
11643
|
];
|
|
11620
11644
|
function QueueTimeBreakdownDonut({
|
|
11621
11645
|
chartFilter,
|
|
@@ -11635,8 +11659,9 @@ function QueueTimeBreakdownDonut({
|
|
|
11635
11659
|
const padAngle = dn?.paddingAngle ?? 0;
|
|
11636
11660
|
const chartH = dn?.chartHeightPx ?? 220;
|
|
11637
11661
|
const pieData = React21.useMemo(() => {
|
|
11638
|
-
|
|
11639
|
-
|
|
11662
|
+
const count = Math.max(averageData.length, labels.length);
|
|
11663
|
+
return Array.from({ length: count }, (_, i) => ({
|
|
11664
|
+
name: labels[i] ?? `Bucket ${i + 1}`,
|
|
11640
11665
|
value: Math.max(0, averageData[i] ?? 0)
|
|
11641
11666
|
}));
|
|
11642
11667
|
}, [averageData, labels]);
|
|
@@ -12119,6 +12144,9 @@ function QueueTimeBreakdown({
|
|
|
12119
12144
|
data,
|
|
12120
12145
|
Donut_data,
|
|
12121
12146
|
donutYesterdayData,
|
|
12147
|
+
donutLabels,
|
|
12148
|
+
areaSeries,
|
|
12149
|
+
areaXAxis,
|
|
12122
12150
|
headerImageSrc,
|
|
12123
12151
|
headlineTotal = "14,123",
|
|
12124
12152
|
headlineSubtitle = "Queue Time Breakdown Of All Visitors",
|
|
@@ -12143,6 +12171,12 @@ function QueueTimeBreakdown({
|
|
|
12143
12171
|
() => data.some((row) => row.data.some((seg) => (seg.data[0] ?? 0) > 0)),
|
|
12144
12172
|
[data]
|
|
12145
12173
|
);
|
|
12174
|
+
const areaProvided = areaSeries !== void 0;
|
|
12175
|
+
const resolvedAreaSeries = areaSeries !== void 0 ? areaSeries : getQueueTimeBreakdownAreaSeriesData(filter);
|
|
12176
|
+
const resolvedAreaXAxis = areaProvided ? areaXAxis ?? [] : areaXAxis && areaXAxis.length > 0 ? areaXAxis : getQueueTimeBreakdownAreaXAxisData(filter);
|
|
12177
|
+
const hasAreaData = resolvedAreaXAxis.length > 0 && resolvedAreaSeries.some(
|
|
12178
|
+
(s) => s.data.some((v) => (typeof v === "number" ? v : 0) > 0)
|
|
12179
|
+
);
|
|
12146
12180
|
const palette = customization?.chartPalette && customization.chartPalette.length > 0 ? customization.chartPalette : QUEUE_CHART_COLORS;
|
|
12147
12181
|
const legend = queueBucketLegend ?? defaultBucketLegendFromPalette(palette);
|
|
12148
12182
|
const resolvedHeaderImageSrc = headerImageSrc === void 0 ? QUEUE_TIME_BREAKDOWN_DEFAULT_HEADER_IMAGE_SRC : headerImageSrc;
|
|
@@ -12160,234 +12194,245 @@ function QueueTimeBreakdown({
|
|
|
12160
12194
|
{ fontWeight: 700, color: "#0f172a" },
|
|
12161
12195
|
customization?.periodFilter?.titleSx
|
|
12162
12196
|
);
|
|
12163
|
-
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(QueueTimeBreakdownCustomizationProvider, { value: customization ?? {}, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Card2.default, { elevation: customization?.rootCard?.elevation ?? 0, sx: rootSx, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_CardContent2.default, { sx: mergeSx2(customization?.rootCard?.cardContentSx), children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12164
|
-
|
|
12165
|
-
|
|
12166
|
-
|
|
12167
|
-
|
|
12168
|
-
|
|
12169
|
-
|
|
12170
|
-
|
|
12171
|
-
gap: 2,
|
|
12172
|
-
width: "100%",
|
|
12173
|
-
children: [
|
|
12174
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12175
|
-
import_Typography16.default,
|
|
12176
|
-
{
|
|
12177
|
-
variant: isSmallScreen ? "subtitle2" : "body1",
|
|
12178
|
-
sx: periodTitleSx,
|
|
12179
|
-
children: title
|
|
12180
|
-
}
|
|
12181
|
-
),
|
|
12182
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12183
|
-
TimePeriodFilter,
|
|
12184
|
-
{
|
|
12185
|
-
selectedFilter: filter,
|
|
12186
|
-
onFilterChange: setFilter,
|
|
12187
|
-
infoPopover: resolvedPeriodInfoPopover
|
|
12188
|
-
}
|
|
12189
|
-
)
|
|
12190
|
-
]
|
|
12191
|
-
}
|
|
12192
|
-
),
|
|
12193
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Box19.default, { children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Grid.default, { container: true, spacing: 3, children: [
|
|
12194
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Grid.default, { size: { md: 6, xs: 12 }, children: [
|
|
12197
|
+
return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(QueueTimeBreakdownCustomizationProvider, { value: customization ?? {}, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Card2.default, { elevation: customization?.rootCard?.elevation ?? 0, sx: rootSx, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_CardContent2.default, { sx: mergeSx2(customization?.rootCard?.cardContentSx), children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12198
|
+
import_Stack17.default,
|
|
12199
|
+
{
|
|
12200
|
+
width: "100%",
|
|
12201
|
+
direction: "column",
|
|
12202
|
+
gap: 3,
|
|
12203
|
+
sx: mergeSx2({ mb: 4 }, customization?.rootCard?.contentStackSx),
|
|
12204
|
+
children: [
|
|
12195
12205
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12196
12206
|
import_Stack17.default,
|
|
12197
12207
|
{
|
|
12198
|
-
|
|
12199
|
-
|
|
12208
|
+
direction: "row",
|
|
12209
|
+
alignItems: "center",
|
|
12210
|
+
justifyContent: "space-between",
|
|
12211
|
+
flexWrap: "wrap",
|
|
12212
|
+
gap: 2,
|
|
12213
|
+
width: "100%",
|
|
12200
12214
|
children: [
|
|
12201
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12202
|
-
|
|
12215
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12216
|
+
import_Typography16.default,
|
|
12203
12217
|
{
|
|
12204
|
-
|
|
12205
|
-
|
|
12206
|
-
|
|
12207
|
-
alignItems: "center",
|
|
12208
|
-
children: [
|
|
12209
|
-
resolvedHeaderImageSrc ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12210
|
-
import_Box19.default,
|
|
12211
|
-
{
|
|
12212
|
-
component: "img",
|
|
12213
|
-
src: resolvedHeaderImageSrc,
|
|
12214
|
-
alt: "",
|
|
12215
|
-
width: 52,
|
|
12216
|
-
height: 52,
|
|
12217
|
-
sx: { objectFit: "contain" }
|
|
12218
|
-
}
|
|
12219
|
-
) : null,
|
|
12220
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Stack17.default, { children: [
|
|
12221
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12222
|
-
import_Typography16.default,
|
|
12223
|
-
{
|
|
12224
|
-
sx: mergeSx2(
|
|
12225
|
-
{
|
|
12226
|
-
fontSize: "20px",
|
|
12227
|
-
fontWeight: 600,
|
|
12228
|
-
color: "#222222"
|
|
12229
|
-
},
|
|
12230
|
-
customization?.header?.headlineSx
|
|
12231
|
-
),
|
|
12232
|
-
children: headlineTotal
|
|
12233
|
-
}
|
|
12234
|
-
),
|
|
12235
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Stack17.default, { direction: "row", alignItems: "center", gap: 1, children: [
|
|
12236
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12237
|
-
import_Typography16.default,
|
|
12238
|
-
{
|
|
12239
|
-
sx: mergeSx2(
|
|
12240
|
-
{
|
|
12241
|
-
fontSize: "11px",
|
|
12242
|
-
fontWeight: 400,
|
|
12243
|
-
color: "#222222"
|
|
12244
|
-
},
|
|
12245
|
-
customization?.header?.subtitleSx
|
|
12246
|
-
),
|
|
12247
|
-
children: headlineSubtitle
|
|
12248
|
-
}
|
|
12249
|
-
),
|
|
12250
|
-
resolvedHeadlineInfoPopover ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12251
|
-
ChartWidgetInfoButton,
|
|
12252
|
-
{
|
|
12253
|
-
density: "compact",
|
|
12254
|
-
popover: resolvedHeadlineInfoPopover,
|
|
12255
|
-
ariaLabel: "Queue time breakdown information"
|
|
12256
|
-
}
|
|
12257
|
-
) : null
|
|
12258
|
-
] })
|
|
12259
|
-
] })
|
|
12260
|
-
]
|
|
12218
|
+
variant: isSmallScreen ? "subtitle2" : "body1",
|
|
12219
|
+
sx: periodTitleSx,
|
|
12220
|
+
children: title
|
|
12261
12221
|
}
|
|
12262
|
-
)
|
|
12222
|
+
),
|
|
12263
12223
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12264
|
-
|
|
12224
|
+
TimePeriodFilter,
|
|
12265
12225
|
{
|
|
12266
|
-
|
|
12267
|
-
|
|
12268
|
-
|
|
12269
|
-
{
|
|
12270
|
-
row: item,
|
|
12271
|
-
legendRows: legend,
|
|
12272
|
-
renderTooltip: renderStackedBarTooltip
|
|
12273
|
-
},
|
|
12274
|
-
item.name
|
|
12275
|
-
))
|
|
12226
|
+
selectedFilter: filter,
|
|
12227
|
+
onFilterChange: setFilter,
|
|
12228
|
+
infoPopover: resolvedPeriodInfoPopover
|
|
12276
12229
|
}
|
|
12277
12230
|
)
|
|
12278
12231
|
]
|
|
12279
12232
|
}
|
|
12280
12233
|
),
|
|
12281
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12282
|
-
|
|
12283
|
-
|
|
12284
|
-
sx: mergeSx2(
|
|
12285
|
-
{
|
|
12286
|
-
marginTop: "10px",
|
|
12287
|
-
fontSize: "14px",
|
|
12288
|
-
fontWeight: 500,
|
|
12289
|
-
color: "#222222"
|
|
12290
|
-
},
|
|
12291
|
-
customization?.dataComparison?.titleSx
|
|
12292
|
-
),
|
|
12293
|
-
children: dataComparisonTitle
|
|
12294
|
-
}
|
|
12295
|
-
),
|
|
12296
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12297
|
-
import_Card2.default,
|
|
12298
|
-
{
|
|
12299
|
-
elevation: 0,
|
|
12300
|
-
sx: mergeSx2(
|
|
12301
|
-
{
|
|
12302
|
-
cursor: "pointer",
|
|
12303
|
-
marginTop: "10px",
|
|
12304
|
-
bgcolor: "#FFFFFF",
|
|
12305
|
-
border: "1px solid #E5E7EB",
|
|
12306
|
-
borderRadius: 2
|
|
12307
|
-
},
|
|
12308
|
-
customization?.dataComparison?.cardSx
|
|
12309
|
-
),
|
|
12310
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_CardContent2.default, { sx: { padding: "4px 8px" }, children: hasComparisonData ? /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12234
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Box19.default, { children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Grid.default, { container: true, spacing: 3, children: [
|
|
12235
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Grid.default, { size: { md: 6, xs: 12 }, children: [
|
|
12236
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12311
12237
|
import_Stack17.default,
|
|
12312
12238
|
{
|
|
12313
|
-
|
|
12314
|
-
|
|
12315
|
-
alignItems: "center",
|
|
12239
|
+
gap: 1,
|
|
12240
|
+
sx: mergeSx2(customization?.leftColumn?.columnStackSx),
|
|
12316
12241
|
children: [
|
|
12317
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Stack17.default, {
|
|
12318
|
-
|
|
12242
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Stack17.default, { children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12243
|
+
import_Stack17.default,
|
|
12319
12244
|
{
|
|
12320
|
-
|
|
12321
|
-
|
|
12322
|
-
|
|
12323
|
-
|
|
12245
|
+
direction: "row",
|
|
12246
|
+
gap: 4,
|
|
12247
|
+
justifyContent: "start",
|
|
12248
|
+
alignItems: "center",
|
|
12249
|
+
children: [
|
|
12250
|
+
resolvedHeaderImageSrc ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12251
|
+
import_Box19.default,
|
|
12252
|
+
{
|
|
12253
|
+
component: "img",
|
|
12254
|
+
src: resolvedHeaderImageSrc,
|
|
12255
|
+
alt: "",
|
|
12256
|
+
width: 52,
|
|
12257
|
+
height: 52,
|
|
12258
|
+
sx: { objectFit: "contain" }
|
|
12259
|
+
}
|
|
12260
|
+
) : null,
|
|
12261
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Stack17.default, { children: [
|
|
12262
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12263
|
+
import_Typography16.default,
|
|
12264
|
+
{
|
|
12265
|
+
sx: mergeSx2(
|
|
12266
|
+
{
|
|
12267
|
+
fontSize: "20px",
|
|
12268
|
+
fontWeight: 600,
|
|
12269
|
+
color: "#222222"
|
|
12270
|
+
},
|
|
12271
|
+
customization?.header?.headlineSx
|
|
12272
|
+
),
|
|
12273
|
+
children: headlineTotal
|
|
12274
|
+
}
|
|
12275
|
+
),
|
|
12276
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_Stack17.default, { direction: "row", alignItems: "center", gap: 1, children: [
|
|
12277
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12278
|
+
import_Typography16.default,
|
|
12279
|
+
{
|
|
12280
|
+
sx: mergeSx2(
|
|
12281
|
+
{
|
|
12282
|
+
fontSize: "11px",
|
|
12283
|
+
fontWeight: 400,
|
|
12284
|
+
color: "#222222"
|
|
12285
|
+
},
|
|
12286
|
+
customization?.header?.subtitleSx
|
|
12287
|
+
),
|
|
12288
|
+
children: headlineSubtitle
|
|
12289
|
+
}
|
|
12290
|
+
),
|
|
12291
|
+
resolvedHeadlineInfoPopover ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12292
|
+
ChartWidgetInfoButton,
|
|
12293
|
+
{
|
|
12294
|
+
density: "compact",
|
|
12295
|
+
popover: resolvedHeadlineInfoPopover,
|
|
12296
|
+
ariaLabel: "Queue time breakdown information"
|
|
12297
|
+
}
|
|
12298
|
+
) : null
|
|
12299
|
+
] })
|
|
12300
|
+
] })
|
|
12301
|
+
]
|
|
12324
12302
|
}
|
|
12325
12303
|
) }),
|
|
12326
12304
|
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12327
|
-
|
|
12305
|
+
import_Stack17.default,
|
|
12328
12306
|
{
|
|
12329
|
-
|
|
12330
|
-
|
|
12307
|
+
sx: mergeSx2(customization?.leftColumn?.barRowsStackSx),
|
|
12308
|
+
children: data.map((item) => /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12309
|
+
QueueTimeBreakdownStackedBar,
|
|
12331
12310
|
{
|
|
12332
|
-
|
|
12333
|
-
|
|
12334
|
-
|
|
12335
|
-
display: "inline-block"
|
|
12311
|
+
row: item,
|
|
12312
|
+
legendRows: legend,
|
|
12313
|
+
renderTooltip: renderStackedBarTooltip
|
|
12336
12314
|
},
|
|
12337
|
-
|
|
12338
|
-
)
|
|
12339
|
-
}
|
|
12340
|
-
),
|
|
12341
|
-
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Stack17.default, { width: "50%", children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12342
|
-
QueueTimeBreakdownDonut,
|
|
12343
|
-
{
|
|
12344
|
-
averageData: yesterdayDonut,
|
|
12345
|
-
chartFilter: filter,
|
|
12346
|
-
LabelName: "Yesterday",
|
|
12347
|
-
renderTooltip: renderDonutTooltip
|
|
12315
|
+
item.name
|
|
12316
|
+
))
|
|
12348
12317
|
}
|
|
12349
|
-
)
|
|
12318
|
+
)
|
|
12350
12319
|
]
|
|
12351
12320
|
}
|
|
12352
|
-
)
|
|
12353
|
-
|
|
12354
|
-
|
|
12355
|
-
|
|
12356
|
-
|
|
12357
|
-
|
|
12358
|
-
|
|
12359
|
-
|
|
12360
|
-
|
|
12361
|
-
|
|
12362
|
-
|
|
12363
|
-
|
|
12364
|
-
|
|
12365
|
-
|
|
12366
|
-
|
|
12367
|
-
|
|
12368
|
-
|
|
12369
|
-
|
|
12370
|
-
|
|
12371
|
-
|
|
12321
|
+
),
|
|
12322
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12323
|
+
import_Typography16.default,
|
|
12324
|
+
{
|
|
12325
|
+
sx: mergeSx2(
|
|
12326
|
+
{
|
|
12327
|
+
marginTop: "10px",
|
|
12328
|
+
fontSize: "14px",
|
|
12329
|
+
fontWeight: 500,
|
|
12330
|
+
color: "#222222"
|
|
12331
|
+
},
|
|
12332
|
+
customization?.dataComparison?.titleSx
|
|
12333
|
+
),
|
|
12334
|
+
children: dataComparisonTitle
|
|
12335
|
+
}
|
|
12336
|
+
),
|
|
12337
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12338
|
+
import_Card2.default,
|
|
12339
|
+
{
|
|
12340
|
+
elevation: 0,
|
|
12341
|
+
sx: mergeSx2(
|
|
12342
|
+
{
|
|
12343
|
+
cursor: "pointer",
|
|
12344
|
+
marginTop: "10px",
|
|
12345
|
+
bgcolor: "#FFFFFF",
|
|
12346
|
+
border: "1px solid #E5E7EB",
|
|
12347
|
+
borderRadius: 2
|
|
12348
|
+
},
|
|
12349
|
+
customization?.dataComparison?.cardSx
|
|
12350
|
+
),
|
|
12351
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_CardContent2.default, { sx: { padding: "4px 8px" }, children: hasComparisonData ? /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
|
|
12352
|
+
import_Stack17.default,
|
|
12353
|
+
{
|
|
12354
|
+
direction: "row",
|
|
12355
|
+
justifyContent: "space-evenly",
|
|
12356
|
+
alignItems: "center",
|
|
12357
|
+
children: [
|
|
12358
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Stack17.default, { width: "50%", children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12359
|
+
QueueTimeBreakdownDonut,
|
|
12360
|
+
{
|
|
12361
|
+
averageData: Donut_data,
|
|
12362
|
+
labels: donutLabels,
|
|
12363
|
+
chartFilter: filter,
|
|
12364
|
+
LabelName: "Today",
|
|
12365
|
+
renderTooltip: renderDonutTooltip
|
|
12366
|
+
}
|
|
12367
|
+
) }),
|
|
12368
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12369
|
+
import_Box19.default,
|
|
12370
|
+
{
|
|
12371
|
+
component: "span",
|
|
12372
|
+
sx: mergeSx2(
|
|
12373
|
+
{
|
|
12374
|
+
height: "180px",
|
|
12375
|
+
width: "2px",
|
|
12376
|
+
backgroundColor: "#D8D9E4",
|
|
12377
|
+
display: "inline-block"
|
|
12378
|
+
},
|
|
12379
|
+
customization?.dataComparison?.dividerSx
|
|
12380
|
+
)
|
|
12381
|
+
}
|
|
12382
|
+
),
|
|
12383
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Stack17.default, { width: "50%", children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12384
|
+
QueueTimeBreakdownDonut,
|
|
12385
|
+
{
|
|
12386
|
+
averageData: yesterdayDonut,
|
|
12387
|
+
labels: donutLabels,
|
|
12388
|
+
chartFilter: filter,
|
|
12389
|
+
LabelName: "Yesterday",
|
|
12390
|
+
renderTooltip: renderDonutTooltip
|
|
12391
|
+
}
|
|
12392
|
+
) })
|
|
12393
|
+
]
|
|
12394
|
+
}
|
|
12395
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(ChartEmptyState, { minHeight: 220 }) })
|
|
12396
|
+
}
|
|
12397
|
+
)
|
|
12398
|
+
] }),
|
|
12399
|
+
/* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_Grid.default, { size: { md: 6, xs: 12 }, children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12400
|
+
import_Card2.default,
|
|
12372
12401
|
{
|
|
12402
|
+
elevation: 0,
|
|
12373
12403
|
sx: mergeSx2(
|
|
12374
|
-
{
|
|
12375
|
-
|
|
12404
|
+
{
|
|
12405
|
+
cursor: "pointer",
|
|
12406
|
+
borderRadius: "8px",
|
|
12407
|
+
border: "1px solid #E5E7EB",
|
|
12408
|
+
bgcolor: "#FFFFFF",
|
|
12409
|
+
height: "100%"
|
|
12410
|
+
},
|
|
12411
|
+
customization?.areaChart?.cardSx
|
|
12376
12412
|
),
|
|
12377
|
-
children:
|
|
12378
|
-
|
|
12413
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12414
|
+
import_CardContent2.default,
|
|
12379
12415
|
{
|
|
12380
|
-
|
|
12381
|
-
|
|
12382
|
-
|
|
12416
|
+
sx: mergeSx2(
|
|
12417
|
+
{ padding: "10px 8px" },
|
|
12418
|
+
customization?.areaChart?.cardContentSx
|
|
12419
|
+
),
|
|
12420
|
+
children: (areaProvided ? hasAreaData : hasBarData) ? /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
|
|
12421
|
+
QueueTimeBreakdownArea_default,
|
|
12422
|
+
{
|
|
12423
|
+
series: resolvedAreaSeries,
|
|
12424
|
+
xAxis: resolvedAreaXAxis,
|
|
12425
|
+
renderTooltip: renderAreaTooltip
|
|
12426
|
+
}
|
|
12427
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(ChartEmptyState, { minHeight: 330 })
|
|
12383
12428
|
}
|
|
12384
|
-
)
|
|
12429
|
+
)
|
|
12385
12430
|
}
|
|
12386
|
-
)
|
|
12387
|
-
}
|
|
12388
|
-
|
|
12389
|
-
|
|
12390
|
-
|
|
12431
|
+
) })
|
|
12432
|
+
] }) })
|
|
12433
|
+
]
|
|
12434
|
+
}
|
|
12435
|
+
) }) }) });
|
|
12391
12436
|
}
|
|
12392
12437
|
|
|
12393
12438
|
// src/components/charts/StackedComparisonBarChart/stackedComparisonBarChart.chartTokens.ts
|
|
@@ -13399,7 +13444,8 @@ function rowFromHeuristicLabel(zoneName, total) {
|
|
|
13399
13444
|
}));
|
|
13400
13445
|
return { id, label: zoneName, value: a + b + c + d, segments };
|
|
13401
13446
|
}
|
|
13402
|
-
function deriveFootfallHeatMapKpiStrip(activeZone, childTiles, buildBarRow) {
|
|
13447
|
+
function deriveFootfallHeatMapKpiStrip(activeZone, childTiles, buildBarRow, options) {
|
|
13448
|
+
const includeZeroValueRows = options?.includeZeroValueRows ?? false;
|
|
13403
13449
|
const buildRow = (node, role, total, fallback) => {
|
|
13404
13450
|
if (buildBarRow) {
|
|
13405
13451
|
const custom = buildBarRow({ node, activeZone, role, total });
|
|
@@ -13409,7 +13455,7 @@ function deriveFootfallHeatMapKpiStrip(activeZone, childTiles, buildBarRow) {
|
|
|
13409
13455
|
};
|
|
13410
13456
|
if (activeZone) {
|
|
13411
13457
|
const childRowsSource = (activeZone.list ?? []).filter(
|
|
13412
|
-
(n) => parseVisitorCount(n.overallData?.count) > 0
|
|
13458
|
+
(n) => includeZeroValueRows ? true : parseVisitorCount(n.overallData?.count) > 0
|
|
13413
13459
|
);
|
|
13414
13460
|
if (childRowsSource.length > 0) {
|
|
13415
13461
|
const items = childRowsSource.map((node) => {
|
|
@@ -14352,7 +14398,8 @@ function FootFallHeatMapView({
|
|
|
14352
14398
|
return deriveFootfallHeatMapKpiStrip(
|
|
14353
14399
|
activeZoneForStrip,
|
|
14354
14400
|
data.current ?? [],
|
|
14355
|
-
kpiStripPresentation?.buildBarRow
|
|
14401
|
+
kpiStripPresentation?.buildBarRow,
|
|
14402
|
+
{ includeZeroValueRows: kpiStripPresentation?.includeZeroValueRows }
|
|
14356
14403
|
);
|
|
14357
14404
|
}, [
|
|
14358
14405
|
isLoading,
|
|
@@ -14360,7 +14407,8 @@ function FootFallHeatMapView({
|
|
|
14360
14407
|
initialData,
|
|
14361
14408
|
trackingDetails,
|
|
14362
14409
|
data,
|
|
14363
|
-
kpiStripPresentation?.buildBarRow
|
|
14410
|
+
kpiStripPresentation?.buildBarRow,
|
|
14411
|
+
kpiStripPresentation?.includeZeroValueRows
|
|
14364
14412
|
]);
|
|
14365
14413
|
const formatPercentage = (value) => {
|
|
14366
14414
|
if (typeof value !== "number") return "0%";
|