@pantheon-systems/pds-toolkit-react 2.0.0-alpha.49 → 2.0.0-alpha.50
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/codemods/v1-to-v2/mappings.json +44 -0
- package/dist/components/Table/Table.d.ts +31 -1
- package/dist/components/empty-states/HorizontalEmptyState/HorizontalEmptyState.d.ts +12 -7
- package/dist/components/icons/Icon/generated-icon-data.d.ts +1 -1
- package/dist/css/component-css/pds-horizontal-empty-state.css +1 -1
- package/dist/css/component-css/pds-index.css +2 -2
- package/dist/css/component-css/pds-toaster.css +1 -1
- package/dist/css/design-tokens/variables.dark.css +60 -60
- package/dist/css/design-tokens/variables.light.css +64 -64
- package/dist/css/pds-components.css +2 -2
- package/dist/css/pds-core.css +1 -1
- package/dist/index.css +1 -1
- package/dist/index.js +341 -335
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import e, { Children as t, cloneElement as n, createContext as r, createElement as i, forwardRef as a, isValidElement as o, useCallback as s, useContext as c, useEffect as l, useId as u, useImperativeHandle as d, useLayoutEffect as f, useMemo as p, useRef as m, useState as h, useSyncExternalStore as g } from "react";
|
|
2
2
|
import _ from "hash-sum";
|
|
3
3
|
import { FloatingArrow as v, FloatingFocusManager as y, FloatingOverlay as b, FloatingPortal as x, arrow as S, autoUpdate as C, flip as w, offset as T, safePolygon as E, shift as D, size as O, useClick as k, useDismiss as A, useFloating as j, useFocus as M, useHover as N, useId as P, useInteractions as F, useListNavigation as I, useRole as L, useTransitionStyles as R, useTypeahead as z } from "@floating-ui/react";
|
|
4
|
-
import { Bar as B, BarChart as V, CartesianGrid as H, Cell as U, Line as
|
|
5
|
-
import { CodeBlock as
|
|
4
|
+
import { Bar as B, BarChart as V, CartesianGrid as H, Cell as U, Line as W, LineChart as G, Pie as K, PieChart as ee, ReferenceLine as q, ResponsiveContainer as te, Tooltip as ne, XAxis as re, YAxis as ie } from "recharts";
|
|
5
|
+
import { CodeBlock as J } from "react-code-block";
|
|
6
6
|
import { useCombobox as Y, useMultipleSelection as X } from "downshift";
|
|
7
7
|
import { format as ae } from "date-fns";
|
|
8
8
|
import { DayPicker as oe } from "react-day-picker";
|
|
@@ -3524,12 +3524,12 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
3524
3524
|
return e.forEach((t, o) => {
|
|
3525
3525
|
t === i ? (n.push(a), a = [], a.push(t), i = r.shift()) : (a.push(t), o + 1 === e.length && n.push(a));
|
|
3526
3526
|
}), n.filter((e) => e.length > 0);
|
|
3527
|
-
}, H, U = u === "m" ? "s" : "xs",
|
|
3527
|
+
}, H, U = u === "m" ? "s" : "xs", W = f ? /* @__PURE__ */ e.createElement(e.Fragment, null, s, /* @__PURE__ */ e.createElement(Gt, {
|
|
3528
3528
|
className: "pds-button__tally",
|
|
3529
3529
|
label: f.label,
|
|
3530
3530
|
size: U,
|
|
3531
3531
|
type: f.type
|
|
3532
|
-
})) : s,
|
|
3532
|
+
})) : s, G = f ? /* @__PURE__ */ e.createElement("span", { className: `${j}__accordion-label` }, s, /* @__PURE__ */ e.createElement(Gt, {
|
|
3533
3533
|
className: `${j}__tally`,
|
|
3534
3534
|
label: f.label,
|
|
3535
3535
|
size: "s",
|
|
@@ -3546,7 +3546,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
3546
3546
|
iconName: "angleDown",
|
|
3547
3547
|
id: M,
|
|
3548
3548
|
isSplitButton: o,
|
|
3549
|
-
label:
|
|
3549
|
+
label: W,
|
|
3550
3550
|
size: u,
|
|
3551
3551
|
statusDot: d,
|
|
3552
3552
|
type: "button",
|
|
@@ -3571,18 +3571,18 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
3571
3571
|
...C({ onClick: L })
|
|
3572
3572
|
});
|
|
3573
3573
|
}
|
|
3574
|
-
let
|
|
3574
|
+
let K = i ? /* @__PURE__ */ e.createElement("span", { className: `${j}__icon-label` }, /* @__PURE__ */ e.createElement(Q, { iconName: r }), " ", s) : G, ee = T ? `${j}--expanded` : null;
|
|
3575
3575
|
return /* @__PURE__ */ e.createElement("span", {
|
|
3576
3576
|
className: Z([
|
|
3577
3577
|
j,
|
|
3578
|
-
|
|
3578
|
+
ee,
|
|
3579
3579
|
t
|
|
3580
3580
|
]),
|
|
3581
3581
|
"data-testid": p,
|
|
3582
3582
|
..._
|
|
3583
3583
|
}, A ? /* @__PURE__ */ e.createElement(gn, {
|
|
3584
3584
|
disabled: n,
|
|
3585
|
-
label:
|
|
3585
|
+
label: K
|
|
3586
3586
|
}, /* @__PURE__ */ e.createElement("ul", {
|
|
3587
3587
|
className: `${j}__mobile-menu`,
|
|
3588
3588
|
role: "menu"
|
|
@@ -4161,18 +4161,18 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4161
4161
|
}, message: d, onBlur: f, onFocus: p, onOptionSelect: m, options: g, required: _ = !1, showLabel: v = !0, size: y = "s", tooltipText: b = null, validationMessage: x, validationStatus: S, value: C, ...w }) => {
|
|
4162
4162
|
let T = Dt(s), E = "pds-select", D = t ? `${E}--auto-width` : null, O = y === "s" ? null : `${E}--${y}`, k = i ? $.disabled : null, A = _ && !i ? $.required : null, j = S === "error" ? $.error : null, M = S === "success" ? $.success : null, N = null;
|
|
4163
4163
|
S === "error" && (N = "error"), S === "success" && (N = "success");
|
|
4164
|
-
let P = x || d, F = C !== void 0, I = r !== void 0, L = ((e) => e.reduce((e, t) => Rt(t) ? [...e, ...t.options] : [...e, t], []))(g), R = (e) => L.findIndex((t) => t.value === e), z = F && R(C) >= 0 ? R(C) : null, B = I ? R(r) : null, [V, H] = h((z || B) ?? null), { activeIndex: U, floatingStyles:
|
|
4164
|
+
let P = x || d, F = C !== void 0, I = r !== void 0, L = ((e) => e.reduce((e, t) => Rt(t) ? [...e, ...t.options] : [...e, t], []))(g), R = (e) => L.findIndex((t) => t.value === e), z = F && R(C) >= 0 ? R(C) : null, B = I ? R(r) : null, [V, H] = h((z || B) ?? null), { activeIndex: U, floatingStyles: W, getFloatingProps: G, getItemProps: K, getReferenceProps: ee, isMounted: q, listRef: te, refs: ne, setIsOpen: re, transitionStyles: ie } = rn({
|
|
4165
4165
|
enableClick: !i,
|
|
4166
4166
|
enableTypeahead: !0,
|
|
4167
4167
|
role: "listbox",
|
|
4168
4168
|
selectedIndex: V,
|
|
4169
4169
|
variant: "input"
|
|
4170
|
-
}),
|
|
4170
|
+
}), J = V === null ? void 0 : L[V]?.label, Y = V === null ? void 0 : L[V]?.icon, X = V === null ? void 0 : L[V]?.value, ae = (e) => {
|
|
4171
4171
|
let t = L[e];
|
|
4172
|
-
F || (H(e),
|
|
4172
|
+
F || (H(e), re(!1)), m && m(t);
|
|
4173
4173
|
};
|
|
4174
4174
|
l(() => {
|
|
4175
|
-
F && (H(R(C)),
|
|
4175
|
+
F && (H(R(C)), re(!1));
|
|
4176
4176
|
}, [C]);
|
|
4177
4177
|
let oe = () => {
|
|
4178
4178
|
f && f(X);
|
|
@@ -4202,7 +4202,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4202
4202
|
"aria-disabled": t?.disabled,
|
|
4203
4203
|
"aria-selected": r === V && r === U,
|
|
4204
4204
|
tabIndex: r === U ? 0 : -1,
|
|
4205
|
-
...!t?.disabled &&
|
|
4205
|
+
...!t?.disabled && K({
|
|
4206
4206
|
onClick() {
|
|
4207
4207
|
ae(r);
|
|
4208
4208
|
},
|
|
@@ -4226,7 +4226,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4226
4226
|
"aria-disabled": t?.disabled,
|
|
4227
4227
|
"aria-selected": r === V && r === U,
|
|
4228
4228
|
tabIndex: r === U ? 0 : -1,
|
|
4229
|
-
...!t?.disabled &&
|
|
4229
|
+
...!t?.disabled && K({
|
|
4230
4230
|
onClick() {
|
|
4231
4231
|
ae(r);
|
|
4232
4232
|
},
|
|
@@ -4274,23 +4274,23 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4274
4274
|
className: `${E}__input-wrapper`,
|
|
4275
4275
|
id: o,
|
|
4276
4276
|
tabIndex: 0,
|
|
4277
|
-
...
|
|
4277
|
+
...ee({
|
|
4278
4278
|
onClick: ce,
|
|
4279
4279
|
onBlur: oe,
|
|
4280
4280
|
onFocus: se
|
|
4281
4281
|
})
|
|
4282
|
-
}, N && /* @__PURE__ */ e.createElement(Nt, { variant: N }), /* @__PURE__ */ e.createElement("span", { className: `${E}__input-inner` }, /* @__PURE__ */ e.createElement("span", { className: `${E}__option-text` }, (Y || !
|
|
4282
|
+
}, N && /* @__PURE__ */ e.createElement(Nt, { variant: N }), /* @__PURE__ */ e.createElement("span", { className: `${E}__input-inner` }, /* @__PURE__ */ e.createElement("span", { className: `${E}__option-text` }, (Y || !J && a) && le(Y || a, `${E}__icon`), /* @__PURE__ */ e.createElement("span", { className: `${E}__option-label-text` }, J ?? u.selectOptionText)), /* @__PURE__ */ e.createElement(Q, {
|
|
4283
4283
|
className: `${E}__trigger-icon`,
|
|
4284
4284
|
iconName: "angleDown"
|
|
4285
4285
|
}))), q && /* @__PURE__ */ e.createElement("div", {
|
|
4286
4286
|
ref: ne.setFloating,
|
|
4287
4287
|
className: `pds-dropdown__panel ${E}__dropdown`,
|
|
4288
4288
|
style: {
|
|
4289
|
-
...
|
|
4289
|
+
...W,
|
|
4290
4290
|
zIndex: "var(--pds-z-index-dropdown)"
|
|
4291
4291
|
},
|
|
4292
|
-
...
|
|
4293
|
-
}, /* @__PURE__ */ e.createElement("div", { style: { ...
|
|
4292
|
+
...G()
|
|
4293
|
+
}, /* @__PURE__ */ e.createElement("div", { style: { ...ie } }, /* @__PURE__ */ e.createElement("ul", {
|
|
4294
4294
|
className: `${E}__options`,
|
|
4295
4295
|
role: "group"
|
|
4296
4296
|
}, ue(g)))), P && /* @__PURE__ */ e.createElement(jt, {
|
|
@@ -4622,7 +4622,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4622
4622
|
let t = Math.abs(e);
|
|
4623
4623
|
return t >= 1e9 ? `${(e / 1e9).toFixed(1).replace(/\.0$/, "")}B` : t >= 1e6 ? `${(e / 1e6).toFixed(1).replace(/\.0$/, "")}M` : t >= 1e3 ? `${(e / 1e3).toFixed(1).replace(/\.0$/, "")}K` : String(e);
|
|
4624
4624
|
}, ir = ({ barRadius: t = 2, chartHeight: n, chartWidth: r, className: i, colorPalette: a = "categorical", data: o = [], isLoading: c = !1, isThumbnail: u = !1, labelStrings: d = {}, layout: f = "horizontal", legendVariant: p = "inline", onTimePeriodChange: g, selectedTimePeriod: _, series: v = [], showAccessibleTable: y, showAxisLines: b, showGrid: x, showLegend: S, showTooltip: E, timePeriodOptions: O, tooltipContent: k, variant: A = "stacked", xAxisLabel: M, xAxisTickInterval: N, yAxisDomain: P, yAxisFormatter: F = rr, yAxisLabel: I, yAxisTickInterval: L, ...z }) => {
|
|
4625
|
-
let { accessibleTableDescription: U = "Bar chart data", emptyStateHeading:
|
|
4625
|
+
let { accessibleTableDescription: U = "Bar chart data", emptyStateHeading: W = "No data available", emptyStateMessage: G, legendTableHeader: K, loadingLabel: ee = "Loading chart data" } = d, q = m(null), J = Hn(a, Jn(q, a)), Y = n ?? (u ? 60 : 360), X = r ?? (u ? 60 : void 0), ae = x ?? !u, oe = b ?? !u, se = S ?? !u, ce = E ?? !u, le = y ?? !0, [ue, de] = h(null), fe = m(ue);
|
|
4626
4626
|
ue && (fe.current = ue);
|
|
4627
4627
|
let pe = m({ getBoundingClientRect: () => ({
|
|
4628
4628
|
bottom: 0,
|
|
@@ -4672,7 +4672,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4672
4672
|
if (c) return /* @__PURE__ */ e.createElement("div", {
|
|
4673
4673
|
ref: q,
|
|
4674
4674
|
"aria-busy": "true",
|
|
4675
|
-
"aria-label":
|
|
4675
|
+
"aria-label": ee,
|
|
4676
4676
|
className: Z([
|
|
4677
4677
|
be,
|
|
4678
4678
|
`${be}--loading`,
|
|
@@ -4698,8 +4698,8 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4698
4698
|
},
|
|
4699
4699
|
...z
|
|
4700
4700
|
}, /* @__PURE__ */ e.createElement(Ln, {
|
|
4701
|
-
heading:
|
|
4702
|
-
message:
|
|
4701
|
+
heading: W,
|
|
4702
|
+
message: G
|
|
4703
4703
|
}));
|
|
4704
4704
|
let we = f === "vertical", Te = (e) => A === "grouped" || A === "stacked" && e === v.length - 1 ? we ? [
|
|
4705
4705
|
0,
|
|
@@ -4755,7 +4755,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4755
4755
|
stroke: "var(--pds-color-border-default)",
|
|
4756
4756
|
strokeDasharray: "3 3",
|
|
4757
4757
|
vertical: we
|
|
4758
|
-
}), /* @__PURE__ */ e.createElement(
|
|
4758
|
+
}), /* @__PURE__ */ e.createElement(re, {
|
|
4759
4759
|
axisLine: oe,
|
|
4760
4760
|
dataKey: we ? void 0 : "label",
|
|
4761
4761
|
hide: !oe,
|
|
@@ -4771,7 +4771,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4771
4771
|
tickLine: !1,
|
|
4772
4772
|
tickMargin: 10,
|
|
4773
4773
|
type: we ? "number" : "category"
|
|
4774
|
-
}), /* @__PURE__ */ e.createElement(
|
|
4774
|
+
}), /* @__PURE__ */ e.createElement(ie, {
|
|
4775
4775
|
axisLine: oe,
|
|
4776
4776
|
dataKey: we ? "label" : void 0,
|
|
4777
4777
|
domain: P,
|
|
@@ -4803,12 +4803,12 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4803
4803
|
}), v.map((t, n) => /* @__PURE__ */ e.createElement(B, {
|
|
4804
4804
|
key: t.dataKey,
|
|
4805
4805
|
dataKey: t.dataKey,
|
|
4806
|
-
fill: Kn(n,
|
|
4806
|
+
fill: Kn(n, J, t.color, Un(a, t.paletteIndex)),
|
|
4807
4807
|
name: t.label,
|
|
4808
4808
|
onMouseEnter: k ? void 0 : (e) => {
|
|
4809
4809
|
let r = e;
|
|
4810
4810
|
ce && r && de({
|
|
4811
|
-
color: Kn(n,
|
|
4811
|
+
color: Kn(n, J, t.color, Un(a, t.paletteIndex)),
|
|
4812
4812
|
label: String(r.label ?? ""),
|
|
4813
4813
|
name: t.label,
|
|
4814
4814
|
value: Number(r[t.dataKey] ?? 0)
|
|
@@ -4833,8 +4833,8 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4833
4833
|
}), /* @__PURE__ */ e.createElement("span", { className: "recharts-tooltip-item-name" }, fe.current.name), /* @__PURE__ */ e.createElement("span", { className: "recharts-tooltip-item-separator" }, ": "), /* @__PURE__ */ e.createElement("span", { className: "recharts-tooltip-item-value" }, F(fe.current.value)))), se && /* @__PURE__ */ e.createElement(Qn, {
|
|
4834
4834
|
data: o,
|
|
4835
4835
|
series: v,
|
|
4836
|
-
seriesColors:
|
|
4837
|
-
tableHeader:
|
|
4836
|
+
seriesColors: J,
|
|
4837
|
+
tableHeader: K,
|
|
4838
4838
|
valueFormatter: F,
|
|
4839
4839
|
variant: p
|
|
4840
4840
|
}), le && /* @__PURE__ */ e.createElement(Zn, {
|
|
@@ -4849,7 +4849,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4849
4849
|
default: return;
|
|
4850
4850
|
}
|
|
4851
4851
|
}, or = ({ annotations: t, chartHeight: n, chartWidth: r, className: i, colorPalette: a = "categorical", data: o = [], isLoading: s = !1, isThumbnail: c = !1, labelStrings: l = {}, legendVariant: u = "inline", lineStyle: d = "smooth", onTimePeriodChange: f, referenceLines: p, selectedTimePeriod: h, series: g = [], showAccessibleTable: _, showAxisLines: v, showDataPoints: y, showGrid: b, showLegend: x, showTooltip: S, timePeriodOptions: C, tooltipContent: w, xAxisLabel: T, xAxisTickInterval: E, yAxisDomain: D, yAxisFormatter: O = rr, yAxisLabel: k, yAxisTickInterval: A, ...j }) => {
|
|
4852
|
-
let { accessibleTableDescription: M = "Line chart data", emptyStateHeading: N = "No data available", emptyStateMessage: P, legendTableHeader: F, loadingLabel: I = "Loading chart data" } = l, L = m(null), R = Hn(a, Jn(L, a)), z = n ?? (c ? 60 : 360), B = r ?? (c ? 60 : void 0), V = b ?? !c, U = v ?? !c,
|
|
4852
|
+
let { accessibleTableDescription: M = "Line chart data", emptyStateHeading: N = "No data available", emptyStateMessage: P, legendTableHeader: F, loadingLabel: I = "Loading chart data" } = l, L = m(null), R = Hn(a, Jn(L, a)), z = n ?? (c ? 60 : 360), B = r ?? (c ? 60 : void 0), V = b ?? !c, U = v ?? !c, K = x ?? !c, ee = S ?? !c, J = y ?? !c, Y = _ ?? !0, X = "pds-line-chart";
|
|
4853
4853
|
return s ? /* @__PURE__ */ e.createElement("div", {
|
|
4854
4854
|
ref: L,
|
|
4855
4855
|
"aria-busy": "true",
|
|
@@ -4864,7 +4864,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4864
4864
|
}, /* @__PURE__ */ e.createElement(nr, {
|
|
4865
4865
|
height: z,
|
|
4866
4866
|
legendVariant: u,
|
|
4867
|
-
showLegend:
|
|
4867
|
+
showLegend: K
|
|
4868
4868
|
})) : !o || o.length === 0 ? /* @__PURE__ */ e.createElement("div", {
|
|
4869
4869
|
ref: L,
|
|
4870
4870
|
className: Z([
|
|
@@ -4899,7 +4899,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4899
4899
|
})), /* @__PURE__ */ e.createElement("div", { "aria-hidden": "true" }, /* @__PURE__ */ e.createElement(te, {
|
|
4900
4900
|
height: z,
|
|
4901
4901
|
width: "100%"
|
|
4902
|
-
}, /* @__PURE__ */ e.createElement(
|
|
4902
|
+
}, /* @__PURE__ */ e.createElement(G, {
|
|
4903
4903
|
data: o,
|
|
4904
4904
|
margin: c ? {
|
|
4905
4905
|
bottom: 0,
|
|
@@ -4915,7 +4915,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4915
4915
|
}, V && /* @__PURE__ */ e.createElement(H, {
|
|
4916
4916
|
stroke: "var(--pds-color-border-default)",
|
|
4917
4917
|
strokeDasharray: "3 3"
|
|
4918
|
-
}), /* @__PURE__ */ e.createElement(
|
|
4918
|
+
}), /* @__PURE__ */ e.createElement(re, {
|
|
4919
4919
|
axisLine: U,
|
|
4920
4920
|
dataKey: "label",
|
|
4921
4921
|
hide: !U,
|
|
@@ -4929,7 +4929,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4929
4929
|
tick: U ? Yn : !1,
|
|
4930
4930
|
tickLine: !1,
|
|
4931
4931
|
tickMargin: 10
|
|
4932
|
-
}), /* @__PURE__ */ e.createElement(
|
|
4932
|
+
}), /* @__PURE__ */ e.createElement(ie, {
|
|
4933
4933
|
axisLine: U,
|
|
4934
4934
|
domain: D,
|
|
4935
4935
|
hide: !U,
|
|
@@ -4945,7 +4945,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4945
4945
|
tickFormatter: O,
|
|
4946
4946
|
tickLine: !1,
|
|
4947
4947
|
tickMargin: 6
|
|
4948
|
-
}),
|
|
4948
|
+
}), ee && /* @__PURE__ */ e.createElement(ne, { content: (t) => {
|
|
4949
4949
|
if (!t.active || !t.payload?.length) return null;
|
|
4950
4950
|
let n = t.payload.map((e) => ({
|
|
4951
4951
|
color: String(e.color ?? ""),
|
|
@@ -4963,11 +4963,11 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
4963
4963
|
className: "recharts-tooltip-item__color",
|
|
4964
4964
|
style: { backgroundColor: t.color }
|
|
4965
4965
|
}), t.name, /* @__PURE__ */ e.createElement("span", { className: "recharts-tooltip-item-separator" }, " ", ":", " "), O(t.value))));
|
|
4966
|
-
} }), g.map((t, n) => /* @__PURE__ */ e.createElement(
|
|
4966
|
+
} }), g.map((t, n) => /* @__PURE__ */ e.createElement(W, {
|
|
4967
4967
|
key: t.dataKey,
|
|
4968
|
-
activeDot:
|
|
4968
|
+
activeDot: J ? { r: 6 } : !1,
|
|
4969
4969
|
dataKey: t.dataKey,
|
|
4970
|
-
dot:
|
|
4970
|
+
dot: J ? {
|
|
4971
4971
|
fill: Kn(n, R, t.color, Un(a, t.paletteIndex)),
|
|
4972
4972
|
r: 4,
|
|
4973
4973
|
strokeWidth: 0
|
|
@@ -5017,7 +5017,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5017
5017
|
strokeDasharray: ar(t.strokeStyle ?? "dashed"),
|
|
5018
5018
|
x: t.atLabel
|
|
5019
5019
|
});
|
|
5020
|
-
})))),
|
|
5020
|
+
})))), K && /* @__PURE__ */ e.createElement(Qn, {
|
|
5021
5021
|
data: o,
|
|
5022
5022
|
series: g,
|
|
5023
5023
|
seriesColors: R,
|
|
@@ -5108,7 +5108,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5108
5108
|
}, /* @__PURE__ */ e.createElement(te, {
|
|
5109
5109
|
height: w,
|
|
5110
5110
|
width: "100%"
|
|
5111
|
-
}, /* @__PURE__ */ e.createElement(
|
|
5111
|
+
}, /* @__PURE__ */ e.createElement(ee, null, /* @__PURE__ */ e.createElement(K, {
|
|
5112
5112
|
cx: "50%",
|
|
5113
5113
|
cy: "50%",
|
|
5114
5114
|
data: A,
|
|
@@ -5165,7 +5165,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5165
5165
|
width: 0,
|
|
5166
5166
|
x: 0,
|
|
5167
5167
|
y: 0
|
|
5168
|
-
}) }), { context: V, floatingStyles: H, refs: U, update:
|
|
5168
|
+
}) }), { context: V, floatingStyles: H, refs: U, update: W } = j({
|
|
5169
5169
|
middleware: [
|
|
5170
5170
|
T(8),
|
|
5171
5171
|
w(),
|
|
@@ -5174,7 +5174,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5174
5174
|
open: !!I,
|
|
5175
5175
|
placement: "top",
|
|
5176
5176
|
whileElementsMounted: C
|
|
5177
|
-
}), { isMounted:
|
|
5177
|
+
}), { isMounted: G, styles: K } = R(V, {
|
|
5178
5178
|
duration: {
|
|
5179
5179
|
close: 150,
|
|
5180
5180
|
open: 150
|
|
@@ -5184,7 +5184,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5184
5184
|
l(() => {
|
|
5185
5185
|
U.setReference(B.current);
|
|
5186
5186
|
}, [U]);
|
|
5187
|
-
let
|
|
5187
|
+
let ee = s((e) => {
|
|
5188
5188
|
B.current.getBoundingClientRect = () => ({
|
|
5189
5189
|
bottom: e.clientY,
|
|
5190
5190
|
height: 0,
|
|
@@ -5194,8 +5194,8 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5194
5194
|
width: 0,
|
|
5195
5195
|
x: e.clientX,
|
|
5196
5196
|
y: e.clientY
|
|
5197
|
-
}),
|
|
5198
|
-
}, [
|
|
5197
|
+
}), W();
|
|
5198
|
+
}, [W]), q = s(() => {
|
|
5199
5199
|
L(null);
|
|
5200
5200
|
}, []);
|
|
5201
5201
|
return o ? /* @__PURE__ */ e.createElement("div", {
|
|
@@ -5234,7 +5234,7 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5234
5234
|
"aria-hidden": "true",
|
|
5235
5235
|
className: `${k}__track`,
|
|
5236
5236
|
onMouseLeave: N ? q : void 0,
|
|
5237
|
-
onMouseMove: N ?
|
|
5237
|
+
onMouseMove: N ? ee : void 0,
|
|
5238
5238
|
style: { height: t }
|
|
5239
5239
|
}, a.map((t, n) => {
|
|
5240
5240
|
let r = F(n, t), i = Math.round(t.value / P * 100);
|
|
@@ -5252,13 +5252,13 @@ var hn = ({ className: t, clearLabel: n = "Clear", disabled: r = !1, filterKey:
|
|
|
5252
5252
|
flex: t.value
|
|
5253
5253
|
}
|
|
5254
5254
|
});
|
|
5255
|
-
})), N &&
|
|
5255
|
+
})), N && G && z.current && /* @__PURE__ */ e.createElement("div", {
|
|
5256
5256
|
ref: U.setFloating,
|
|
5257
5257
|
className: "recharts-default-tooltip",
|
|
5258
5258
|
role: "tooltip",
|
|
5259
5259
|
style: {
|
|
5260
5260
|
...H,
|
|
5261
|
-
...
|
|
5261
|
+
...K,
|
|
5262
5262
|
pointerEvents: "none",
|
|
5263
5263
|
zIndex: "var(--pds-z-index-notifications)"
|
|
5264
5264
|
}
|
|
@@ -6364,17 +6364,17 @@ var fr = {
|
|
|
6364
6364
|
variant: "reverse"
|
|
6365
6365
|
}))));
|
|
6366
6366
|
}
|
|
6367
|
-
let C = /* @__PURE__ */ e.createElement(
|
|
6367
|
+
let C = /* @__PURE__ */ e.createElement(J.LineContent, null, /* @__PURE__ */ e.createElement(J.Token, null)), w = /* @__PURE__ */ e.createElement("div", { className: `${g}__line ${_}` }, /* @__PURE__ */ e.createElement(J.LineNumber, { className: `${g}__number` }), C), T = /* @__PURE__ */ e.createElement("div", { className: `${g}__line` }, /* @__PURE__ */ e.createElement("span", { className: `${g}__prompt` }, f), C);
|
|
6368
6368
|
return /* @__PURE__ */ e.createElement("div", {
|
|
6369
6369
|
className: Z([g, t ?? ""]),
|
|
6370
6370
|
style: v,
|
|
6371
6371
|
...h
|
|
6372
|
-
}, c ? y : /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement(
|
|
6372
|
+
}, c ? y : /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement(J, {
|
|
6373
6373
|
code: n,
|
|
6374
6374
|
language: l || "",
|
|
6375
6375
|
prism: dr.default,
|
|
6376
6376
|
theme: fr
|
|
6377
|
-
}, /* @__PURE__ */ e.createElement(
|
|
6377
|
+
}, /* @__PURE__ */ e.createElement(J.Code, {
|
|
6378
6378
|
className: `${g}__code`,
|
|
6379
6379
|
tabIndex: 0
|
|
6380
6380
|
}, a || o ? a ? w : T : C)), i && /* @__PURE__ */ e.createElement("div", { className: `${g}__copy` }, /* @__PURE__ */ e.createElement(en, {
|
|
@@ -6439,10 +6439,10 @@ var fr = {
|
|
|
6439
6439
|
className: Z(["pds-video-embed", t ?? ""]),
|
|
6440
6440
|
...a
|
|
6441
6441
|
}, l);
|
|
6442
|
-
}, _r = ({ alignment: t = "center", className: n, ctaRegion: r,
|
|
6443
|
-
let m = "pds-horizontal-empty-state", h = `${m}--${t}`, g =
|
|
6444
|
-
marginInlineStart:
|
|
6445
|
-
width:
|
|
6442
|
+
}, _r = ({ alignment: t = "center", className: n, ctaRegion: r, hasIndentedContent: i, heading: a, headingLevel: o = "h1", image: s, imageMarginLeft: c = "0", imageWidth: l = "40%", maxWidth: u = "100%", message: d, video: f, ...p }) => {
|
|
6443
|
+
let m = "pds-horizontal-empty-state", h = `${m}--${t}`, g = i ? `${m}--indented-content` : null, _ = f ? `${m}--video` : null, v = {
|
|
6444
|
+
marginInlineStart: c,
|
|
6445
|
+
width: l
|
|
6446
6446
|
};
|
|
6447
6447
|
return d = typeof d == "string" ? /* @__PURE__ */ e.createElement("p", { className: `${m}__message` }, d) : /* @__PURE__ */ e.createElement("div", { className: `${m}__message` }, d), /* @__PURE__ */ e.createElement("div", {
|
|
6448
6448
|
className: Z([
|
|
@@ -6456,16 +6456,16 @@ var fr = {
|
|
|
6456
6456
|
...p
|
|
6457
6457
|
}, /* @__PURE__ */ e.createElement("div", { className: `${m}__content` }, /* @__PURE__ */ e.createElement(Jt, {
|
|
6458
6458
|
baseClass: m,
|
|
6459
|
-
className:
|
|
6460
|
-
level:
|
|
6461
|
-
},
|
|
6459
|
+
className: "pds-ts-4xl pds-fw-bold",
|
|
6460
|
+
level: o
|
|
6461
|
+
}, a), d && d, r && /* @__PURE__ */ e.createElement("div", { className: `${m}__cta` }, r)), s && !f && /* @__PURE__ */ e.createElement("div", {
|
|
6462
6462
|
className: `${m}__media ${m}__media--image`,
|
|
6463
6463
|
style: v
|
|
6464
|
-
}, typeof
|
|
6464
|
+
}, typeof s == "string" ? /* @__PURE__ */ e.createElement("img", {
|
|
6465
6465
|
alt: "",
|
|
6466
6466
|
className: `${m}__image`,
|
|
6467
|
-
src:
|
|
6468
|
-
}) :
|
|
6467
|
+
src: s
|
|
6468
|
+
}) : s), f && /* @__PURE__ */ e.createElement("div", { className: `${m}__media ${m}__media--video` }, /* @__PURE__ */ e.createElement(gr, {
|
|
6469
6469
|
platform: f.platform,
|
|
6470
6470
|
videoId: f.videoId
|
|
6471
6471
|
})));
|
|
@@ -6959,15 +6959,15 @@ var fr = {
|
|
|
6959
6959
|
searchShortcut: "Press / to focus the search field",
|
|
6960
6960
|
triggerButton: "Toggle dropdown menu"
|
|
6961
6961
|
}, loadingText: v = "Loading results...", message: y, noResultsText: b = "No results found", onBlur: x, onChange: S, onClear: E, onFocus: D, onOptionSelect: k, options: A, placeholder: M, required: N = !1, showLabel: P = !0, showUnfilteredOptions: F = !1, size: I = "s", tooltipText: L = null, validationMessage: z, validationStatus: B, value: V, ...H }, U) => {
|
|
6962
|
-
let
|
|
6963
|
-
o && (
|
|
6964
|
-
let
|
|
6962
|
+
let W = Dt(d), G = "pds-combobox", K = I === "s" ? null : `${G}--${I}`, ee = r ? $.disabled : null, q = N && !r ? $.required : null, te = B === "error" ? $.error : null, ne = B === "success" ? $.success : null, re = null;
|
|
6963
|
+
o && (re = "search"), B === "error" && (re = "error"), B === "success" && (re = "success");
|
|
6964
|
+
let ie = z || y, J = V !== void 0, X = n !== void 0, ae = (e) => {
|
|
6965
6965
|
let t = A.find((t) => t.value === e);
|
|
6966
6966
|
return t ? t.label : "";
|
|
6967
|
-
}, [oe, se] = h(X ? n : void 0), [ce, le] = h(
|
|
6967
|
+
}, [oe, se] = h(X ? n : void 0), [ce, le] = h(J ? V ?? "" : X ? ae(n) : "");
|
|
6968
6968
|
l(() => {
|
|
6969
|
-
|
|
6970
|
-
}, [
|
|
6969
|
+
J && le(V ?? "");
|
|
6970
|
+
}, [J, V]);
|
|
6971
6971
|
let ue = m(null), de = (e) => e.map(({ label: e, optionDisplay: t, searchIndex: n, value: r, ...i }) => {
|
|
6972
6972
|
let a = r || e, o = [e, r];
|
|
6973
6973
|
return n && o.push(...n), {
|
|
@@ -6997,7 +6997,7 @@ var fr = {
|
|
|
6997
6997
|
le(e ?? "");
|
|
6998
6998
|
},
|
|
6999
6999
|
onSelectedItemChange: ({ selectedItem: e }) => {
|
|
7000
|
-
e && (
|
|
7000
|
+
e && (J || le(e.label), se(e.value), k?.(e));
|
|
7001
7001
|
},
|
|
7002
7002
|
stateReducer: (e, { changes: t, type: n }) => {
|
|
7003
7003
|
if (n === Y.stateChangeTypes.InputBlur) return {
|
|
@@ -7053,7 +7053,7 @@ var fr = {
|
|
|
7053
7053
|
}, [U, Se]), Ee = () => {
|
|
7054
7054
|
_e ? ye() : ve();
|
|
7055
7055
|
}, De = () => {
|
|
7056
|
-
|
|
7056
|
+
J || le(""), se(void 0), ye(), ue.current?.focus(), F && ve(), E?.();
|
|
7057
7057
|
}, Oe = (e) => {
|
|
7058
7058
|
x?.(oe);
|
|
7059
7059
|
}, ke = (e) => {
|
|
@@ -7065,19 +7065,19 @@ var fr = {
|
|
|
7065
7065
|
item: t,
|
|
7066
7066
|
index: n
|
|
7067
7067
|
})
|
|
7068
|
-
}, /* @__PURE__ */ e.createElement("span", { className: `${
|
|
7068
|
+
}, /* @__PURE__ */ e.createElement("span", { className: `${G}__option-label` }, t.optionDisplay || t.label)));
|
|
7069
7069
|
return /* @__PURE__ */ e.createElement("div", {
|
|
7070
7070
|
className: Z([
|
|
7071
7071
|
$.base,
|
|
7072
|
-
W,
|
|
7073
7072
|
G,
|
|
7074
7073
|
K,
|
|
7074
|
+
ee,
|
|
7075
7075
|
q,
|
|
7076
7076
|
te,
|
|
7077
7077
|
ne,
|
|
7078
7078
|
t ?? ""
|
|
7079
7079
|
]),
|
|
7080
|
-
style: d ?
|
|
7080
|
+
style: d ? W : null,
|
|
7081
7081
|
...H
|
|
7082
7082
|
}, /* @__PURE__ */ e.createElement(At, {
|
|
7083
7083
|
disabled: r,
|
|
@@ -7088,16 +7088,16 @@ var fr = {
|
|
|
7088
7088
|
tooltipText: L
|
|
7089
7089
|
}), /* @__PURE__ */ e.createElement("span", {
|
|
7090
7090
|
ref: Te,
|
|
7091
|
-
"aria-describedby":
|
|
7091
|
+
"aria-describedby": ie ? `${u}__message` : null,
|
|
7092
7092
|
"aria-disabled": r ? !0 : null,
|
|
7093
7093
|
"aria-invalid": B === "error" ? !0 : null,
|
|
7094
7094
|
"aria-required": N ? !0 : null,
|
|
7095
|
-
className: `${
|
|
7095
|
+
className: `${G}__input-wrapper`,
|
|
7096
7096
|
id: u
|
|
7097
|
-
},
|
|
7097
|
+
}, re && /* @__PURE__ */ e.createElement(Nt, { variant: re }), /* @__PURE__ */ e.createElement("input", {
|
|
7098
7098
|
ref: ue,
|
|
7099
7099
|
autoComplete: "off",
|
|
7100
|
-
className: `${
|
|
7100
|
+
className: `${G}__input`,
|
|
7101
7101
|
id: `input-${u}`,
|
|
7102
7102
|
...pe({
|
|
7103
7103
|
"aria-label": _.inputInstructions,
|
|
@@ -7119,30 +7119,30 @@ var fr = {
|
|
|
7119
7119
|
}), a && /* @__PURE__ */ e.createElement("button", {
|
|
7120
7120
|
"aria-expanded": _e,
|
|
7121
7121
|
"aria-label": _.triggerButton,
|
|
7122
|
-
className: `${
|
|
7122
|
+
className: `${G}__trigger`,
|
|
7123
7123
|
disabled: r,
|
|
7124
7124
|
onClick: Ee,
|
|
7125
7125
|
type: "button"
|
|
7126
7126
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
7127
|
-
className: `${
|
|
7127
|
+
className: `${G}__trigger-icon`,
|
|
7128
7128
|
iconName: "angleDown",
|
|
7129
7129
|
size: "m"
|
|
7130
7130
|
}))), /* @__PURE__ */ e.createElement("div", {
|
|
7131
7131
|
ref: Se.setFloating,
|
|
7132
|
-
className: `pds-dropdown__panel ${
|
|
7132
|
+
className: `pds-dropdown__panel ${G}__dropdown`,
|
|
7133
7133
|
style: Ce ? {
|
|
7134
7134
|
...xe,
|
|
7135
7135
|
...we,
|
|
7136
7136
|
zIndex: "var(--pds-z-index-dropdown)"
|
|
7137
7137
|
} : { display: "none" }
|
|
7138
|
-
}, Ce && f && /* @__PURE__ */ e.createElement("div", { className: `${
|
|
7139
|
-
className: `${
|
|
7138
|
+
}, Ce && f && /* @__PURE__ */ e.createElement("div", { className: `${G}__loading` }, v), Ce && !f && fe.length === 0 && /* @__PURE__ */ e.createElement("div", { className: "pds-dropdown__no-results" }, b), /* @__PURE__ */ e.createElement("ul", {
|
|
7139
|
+
className: `${G}__options`,
|
|
7140
7140
|
...he(),
|
|
7141
7141
|
style: Ce && !f && fe.length > 0 ? void 0 : { display: "none" }
|
|
7142
|
-
}, Ce && !f && Ae())),
|
|
7142
|
+
}, Ce && !f && Ae())), ie && /* @__PURE__ */ e.createElement(jt, {
|
|
7143
7143
|
hasValidationMessage: !!z,
|
|
7144
7144
|
id: u,
|
|
7145
|
-
message:
|
|
7145
|
+
message: ie,
|
|
7146
7146
|
validationMessageHasDecorators: !1,
|
|
7147
7147
|
validationStatus: B
|
|
7148
7148
|
}));
|
|
@@ -7160,16 +7160,16 @@ var fr = {
|
|
|
7160
7160
|
inputInstructions: "Type to search options",
|
|
7161
7161
|
triggerButton: "Toggle dropdown menu"
|
|
7162
7162
|
}, loadingText: u = "Loading results...", noResultsText: d = "No results found", onChange: f, options: g, placeholder: _ = "Filter", required: v = !1, showAllTags: y = !1, showLabel: b = !0, size: x = "s", ...S }) => {
|
|
7163
|
-
let E = Dt(o), D = "pds-combobox-multi", k = x === "s" ? null : `${D}--${x}`, M = r ? $.disabled : null, N = v && !r ? $.required : null, P = y ? `${D}--show-all-tags` : null, [I, L] = h(""), [R, z] = h(a), [B, V] = h(null), [H, U] = h(!1),
|
|
7163
|
+
let E = Dt(o), D = "pds-combobox-multi", k = x === "s" ? null : `${D}--${x}`, M = r ? $.disabled : null, N = v && !r ? $.required : null, P = y ? `${D}--show-all-tags` : null, [I, L] = h(""), [R, z] = h(a), [B, V] = h(null), [H, U] = h(!1), W = p(() => Dr(g, R, I), [
|
|
7164
7164
|
g,
|
|
7165
7165
|
R,
|
|
7166
7166
|
I
|
|
7167
|
-
]),
|
|
7167
|
+
]), G = p(() => t?.items?.map((e) => ({
|
|
7168
7168
|
...e,
|
|
7169
7169
|
isAlreadySelected: R.some((t) => t.id === e.id)
|
|
7170
|
-
})) || [], [t?.items, R]),
|
|
7170
|
+
})) || [], [t?.items, R]), K = (e) => {
|
|
7171
7171
|
z(e), f?.(e);
|
|
7172
|
-
}, { getDropdownProps:
|
|
7172
|
+
}, { getDropdownProps: ee, getSelectedItemProps: q, removeSelectedItem: te } = X({
|
|
7173
7173
|
selectedItems: R,
|
|
7174
7174
|
onStateChange: ({ selectedItems: e, type: t }) => {
|
|
7175
7175
|
if (!r) switch (t) {
|
|
@@ -7177,13 +7177,13 @@ var fr = {
|
|
|
7177
7177
|
case X.stateChangeTypes.SelectedItemKeyDownDelete:
|
|
7178
7178
|
case X.stateChangeTypes.DropdownKeyDownBackspace:
|
|
7179
7179
|
case X.stateChangeTypes.FunctionRemoveSelectedItem:
|
|
7180
|
-
|
|
7180
|
+
K(e || []);
|
|
7181
7181
|
break;
|
|
7182
7182
|
default: break;
|
|
7183
7183
|
}
|
|
7184
7184
|
}
|
|
7185
|
-
}), { closeMenu: ne, getInputProps:
|
|
7186
|
-
items:
|
|
7185
|
+
}), { closeMenu: ne, getInputProps: re, getItemProps: ie, getMenuProps: J, getToggleButtonProps: ae, highlightedIndex: oe, isOpen: se, openMenu: ce, selectedItem: le } = Y({
|
|
7186
|
+
items: W,
|
|
7187
7187
|
itemToString: (e) => e ? e.label : "",
|
|
7188
7188
|
selectedItem: null,
|
|
7189
7189
|
inputValue: I,
|
|
@@ -7205,7 +7205,7 @@ var fr = {
|
|
|
7205
7205
|
case Y.stateChangeTypes.InputKeyDownEnter:
|
|
7206
7206
|
case Y.stateChangeTypes.ItemClick:
|
|
7207
7207
|
case Y.stateChangeTypes.InputBlur:
|
|
7208
|
-
n && (n.isAlreadySelected ?
|
|
7208
|
+
n && (n.isAlreadySelected ? K(R.filter((e) => e.id !== n.id)) : K([...R, n]), L(""), V(null));
|
|
7209
7209
|
break;
|
|
7210
7210
|
case Y.stateChangeTypes.InputChange:
|
|
7211
7211
|
L(e || ""), V(null);
|
|
@@ -7255,7 +7255,7 @@ var fr = {
|
|
|
7255
7255
|
let t = !H;
|
|
7256
7256
|
U(t), t && se && ne();
|
|
7257
7257
|
}, _e = (e) => {
|
|
7258
|
-
r || (e.isAlreadySelected ?
|
|
7258
|
+
r || (e.isAlreadySelected ? K(R.filter((t) => t.id !== e.id)) : K([...R, e]));
|
|
7259
7259
|
}, ve = () => {
|
|
7260
7260
|
U(!1), t?.onClose?.();
|
|
7261
7261
|
}, ye = () => {
|
|
@@ -7264,7 +7264,7 @@ var fr = {
|
|
|
7264
7264
|
if (B === null) V(R.length - 1);
|
|
7265
7265
|
else {
|
|
7266
7266
|
let e = [...R];
|
|
7267
|
-
e.splice(B, 1),
|
|
7267
|
+
e.splice(B, 1), K(e), V(null);
|
|
7268
7268
|
}
|
|
7269
7269
|
}, xe = m(!1), Se = () => {
|
|
7270
7270
|
r || (xe.current ? ne() : ce());
|
|
@@ -7272,8 +7272,8 @@ var fr = {
|
|
|
7272
7272
|
xe.current = se, !r && e.currentTarget.setAttribute("data-focus-method", "mouse");
|
|
7273
7273
|
}, we = (e) => {
|
|
7274
7274
|
e.currentTarget.setAttribute("data-focus-method", "keyboard"), !r && ((e.key === "Backspace" || e.key === "Delete") && !I && R.length > 0 && (e.preventDefault(), be()), e.key === "Enter" && B !== null && (e.preventDefault(), be()), !se && (e.key === "Enter" || e.key === "ArrowDown") && (e.preventDefault(), ce()));
|
|
7275
|
-
}, Te =
|
|
7276
|
-
...
|
|
7275
|
+
}, Te = re({
|
|
7276
|
+
...ee({ preventKeyAction: se }),
|
|
7277
7277
|
disabled: r,
|
|
7278
7278
|
onKeyDown: we
|
|
7279
7279
|
}), Ee = R.length === 2 ? /* @__PURE__ */ e.createElement("span", { className: `${D}__counter-item` }, R.length - 1) : R.length === 3 ? /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("span", { className: `${D}__counter-layer` }), /* @__PURE__ */ e.createElement("span", { className: `${D}__counter-item` }, R.length - 1)) : R.length > 3 ? /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("span", { className: `${D}__counter-layer` }), /* @__PURE__ */ e.createElement("span", { className: `${D}__counter-layer` }), /* @__PURE__ */ e.createElement("span", { className: `${D}__counter-item` }, R.length - 1)) : "";
|
|
@@ -7351,7 +7351,7 @@ var fr = {
|
|
|
7351
7351
|
iconName: "angleDown",
|
|
7352
7352
|
size: "m"
|
|
7353
7353
|
})))), /* @__PURE__ */ e.createElement("div", {
|
|
7354
|
-
...
|
|
7354
|
+
...ee(),
|
|
7355
7355
|
ref: de.setFloating,
|
|
7356
7356
|
className: `pds-dropdown__panel ${D}__dropdown`,
|
|
7357
7357
|
style: se ? {
|
|
@@ -7366,17 +7366,17 @@ var fr = {
|
|
|
7366
7366
|
onClick: (e) => {
|
|
7367
7367
|
e.stopPropagation();
|
|
7368
7368
|
}
|
|
7369
|
-
})), se && s && /* @__PURE__ */ e.createElement("div", { className: `${D}__loading` }, u), se && !s &&
|
|
7369
|
+
})), se && s && /* @__PURE__ */ e.createElement("div", { className: `${D}__loading` }, u), se && !s && W.length === 0 && /* @__PURE__ */ e.createElement("div", { className: "pds-dropdown__no-results" }, d), /* @__PURE__ */ e.createElement("ul", {
|
|
7370
7370
|
className: `${D}__dropdown-list`,
|
|
7371
|
-
...
|
|
7372
|
-
style: se && !s &&
|
|
7373
|
-
}, se && !s &&
|
|
7371
|
+
...J(),
|
|
7372
|
+
style: se && !s && W.length > 0 ? void 0 : { display: "none" }
|
|
7373
|
+
}, se && !s && W.map((t, n) => /* @__PURE__ */ e.createElement(zt, {
|
|
7374
7374
|
key: `${t.id}-${n}`,
|
|
7375
7375
|
className: `${D}__dropdown-item
|
|
7376
7376
|
${oe === n ? "pds-dropdown__item--focused" : ""}
|
|
7377
7377
|
${le === t ? `${D}__dropdown-item--selected` : ""}
|
|
7378
7378
|
${t.isAlreadySelected ? "pds-dropdown__item--active" : ""}`,
|
|
7379
|
-
...
|
|
7379
|
+
...ie({
|
|
7380
7380
|
item: t,
|
|
7381
7381
|
index: n
|
|
7382
7382
|
})
|
|
@@ -7395,7 +7395,7 @@ var fr = {
|
|
|
7395
7395
|
className: `${D}__aux-panel-icon`,
|
|
7396
7396
|
iconName: "sparkles",
|
|
7397
7397
|
size: "m"
|
|
7398
|
-
}), /* @__PURE__ */ e.createElement("div", { className: `${D}__aux-panel-items` },
|
|
7398
|
+
}), /* @__PURE__ */ e.createElement("div", { className: `${D}__aux-panel-items` }, G.map((t) => /* @__PURE__ */ e.createElement("button", {
|
|
7399
7399
|
key: t.id,
|
|
7400
7400
|
className: Z([`${D}__aux-panel-item`, t.isAlreadySelected ? `${D}__aux-panel-item--selected` : ""]),
|
|
7401
7401
|
onClick: () => _e(t),
|
|
@@ -7487,7 +7487,7 @@ var fr = {
|
|
|
7487
7487
|
let E = {
|
|
7488
7488
|
...jr,
|
|
7489
7489
|
...v
|
|
7490
|
-
}, [O, k] = h(x), [A, M] = h(!1), [N, P] = h(null), [F, I] = h(r ? x?.from : x), L = Dt(a), R = "pds-datepicker", z = n ? $.disabled : null, B = m && !n ? $.required : null, V = b === "error" ? $.error : null, H = b === "success" ? $.success : null, U = y || u, { floatingStyles:
|
|
7490
|
+
}, [O, k] = h(x), [A, M] = h(!1), [N, P] = h(null), [F, I] = h(r ? x?.from : x), L = Dt(a), R = "pds-datepicker", z = n ? $.disabled : null, B = m && !n ? $.required : null, V = b === "error" ? $.error : null, H = b === "success" ? $.success : null, U = y || u, { floatingStyles: W, refs: G } = j({
|
|
7491
7491
|
open: A,
|
|
7492
7492
|
onOpenChange: M,
|
|
7493
7493
|
placement: "bottom-start",
|
|
@@ -7497,22 +7497,22 @@ var fr = {
|
|
|
7497
7497
|
D({ padding: 8 })
|
|
7498
7498
|
],
|
|
7499
7499
|
whileElementsMounted: C
|
|
7500
|
-
}),
|
|
7500
|
+
}), K = (e) => {
|
|
7501
7501
|
k(e), f?.(e), r || setTimeout(() => {
|
|
7502
7502
|
M(!1);
|
|
7503
7503
|
}, 300);
|
|
7504
|
-
},
|
|
7505
|
-
|
|
7504
|
+
}, ee = (e) => {
|
|
7505
|
+
K(e);
|
|
7506
7506
|
}, q = (e) => {
|
|
7507
|
-
|
|
7507
|
+
K(e);
|
|
7508
7508
|
}, te = () => {
|
|
7509
7509
|
k(void 0), f?.(void 0);
|
|
7510
7510
|
}, ne = () => {
|
|
7511
7511
|
M(!1);
|
|
7512
|
-
},
|
|
7512
|
+
}, re = () => {
|
|
7513
7513
|
let e = /* @__PURE__ */ new Date();
|
|
7514
7514
|
I(e), r ? (k(void 0), f?.(void 0)) : (k(e), f?.(e));
|
|
7515
|
-
},
|
|
7515
|
+
}, ie = () => r ? O?.from : O, J = ({ className: t, orientation: n }) => n === "left" ? /* @__PURE__ */ e.createElement(Q, {
|
|
7516
7516
|
className: t,
|
|
7517
7517
|
iconName: "angleLeft",
|
|
7518
7518
|
size: "m"
|
|
@@ -7540,7 +7540,7 @@ var fr = {
|
|
|
7540
7540
|
return e ? `${E.selectedDate}${kr(e, s)}` : E.noDateSelected || "";
|
|
7541
7541
|
}
|
|
7542
7542
|
}, ue = (e) => {
|
|
7543
|
-
|
|
7543
|
+
G.floating.current && !G.floating.current.contains(e.target) && N && !N.contains(e.target) && M(!1);
|
|
7544
7544
|
};
|
|
7545
7545
|
return l(() => {
|
|
7546
7546
|
k(x);
|
|
@@ -7567,7 +7567,7 @@ var fr = {
|
|
|
7567
7567
|
tooltipText: _
|
|
7568
7568
|
}), /* @__PURE__ */ e.createElement("div", { className: `${R}__input-wrapper` }, /* @__PURE__ */ e.createElement("button", {
|
|
7569
7569
|
ref: (e) => {
|
|
7570
|
-
|
|
7570
|
+
G.setReference(e), P(e);
|
|
7571
7571
|
},
|
|
7572
7572
|
"aria-describedby": U ? `${i}__message` : null,
|
|
7573
7573
|
"aria-expanded": A,
|
|
@@ -7576,7 +7576,7 @@ var fr = {
|
|
|
7576
7576
|
className: Z([`${R}__trigger`, A ? `${R}__trigger--open` : null]),
|
|
7577
7577
|
disabled: n,
|
|
7578
7578
|
onClick: () => {
|
|
7579
|
-
A || I(
|
|
7579
|
+
A || I(ie() ?? /* @__PURE__ */ new Date()), M(!A);
|
|
7580
7580
|
},
|
|
7581
7581
|
type: "button"
|
|
7582
7582
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
@@ -7588,11 +7588,11 @@ var fr = {
|
|
|
7588
7588
|
message: U,
|
|
7589
7589
|
validationStatus: b
|
|
7590
7590
|
}), A && /* @__PURE__ */ e.createElement("div", {
|
|
7591
|
-
ref:
|
|
7591
|
+
ref: G.setFloating,
|
|
7592
7592
|
className: `${R}__popover`,
|
|
7593
|
-
style:
|
|
7593
|
+
style: W
|
|
7594
7594
|
}, /* @__PURE__ */ e.createElement("div", { className: `${R}__calendar` }, r ? /* @__PURE__ */ e.createElement(oe, {
|
|
7595
|
-
components: { Chevron:
|
|
7595
|
+
components: { Chevron: J },
|
|
7596
7596
|
disabled: X(),
|
|
7597
7597
|
footer: /* @__PURE__ */ e.createElement("div", { className: "visually-hidden" }, le()),
|
|
7598
7598
|
formatters: { formatWeekdayName: Y },
|
|
@@ -7602,10 +7602,10 @@ var fr = {
|
|
|
7602
7602
|
navLayout: "around",
|
|
7603
7603
|
numberOfMonths: 2,
|
|
7604
7604
|
onMonthChange: I,
|
|
7605
|
-
onSelect:
|
|
7605
|
+
onSelect: ee,
|
|
7606
7606
|
selected: O
|
|
7607
7607
|
}) : /* @__PURE__ */ e.createElement(oe, {
|
|
7608
|
-
components: { Chevron:
|
|
7608
|
+
components: { Chevron: J },
|
|
7609
7609
|
disabled: X(),
|
|
7610
7610
|
footer: /* @__PURE__ */ e.createElement("div", { className: "visually-hidden" }, le()),
|
|
7611
7611
|
formatters: { formatWeekdayName: Y },
|
|
@@ -7620,7 +7620,7 @@ var fr = {
|
|
|
7620
7620
|
})), /* @__PURE__ */ e.createElement("div", { className: `${R}__actions` }, /* @__PURE__ */ e.createElement(Xt, {
|
|
7621
7621
|
className: `${R}__action-button ${R}__action-button--today`,
|
|
7622
7622
|
label: E.todayButton,
|
|
7623
|
-
onClick:
|
|
7623
|
+
onClick: re,
|
|
7624
7624
|
size: "s",
|
|
7625
7625
|
type: "button",
|
|
7626
7626
|
variant: "secondary"
|
|
@@ -7658,13 +7658,13 @@ var fr = {
|
|
|
7658
7658
|
if (!e || !r) return;
|
|
7659
7659
|
let t = new DataTransfer();
|
|
7660
7660
|
t.items.add(H), e.files = t.files, E(!0);
|
|
7661
|
-
},
|
|
7661
|
+
}, W = (e) => {
|
|
7662
7662
|
if (e.target.files.length === 0) {
|
|
7663
7663
|
r ? U() : E(!1);
|
|
7664
7664
|
return;
|
|
7665
7665
|
}
|
|
7666
7666
|
se && r && (r === e.target.value ? O(!0) : O(!1)), m && m(e.target.files), E(!0);
|
|
7667
|
-
},
|
|
7667
|
+
}, G = () => {
|
|
7668
7668
|
let e = document.getElementById(`${o}--input`);
|
|
7669
7669
|
e.value = "", se && O(!1), p && p(), E(!1), e.focus();
|
|
7670
7670
|
};
|
|
@@ -7708,13 +7708,13 @@ var fr = {
|
|
|
7708
7708
|
disabled: i,
|
|
7709
7709
|
id: `${o}--input`,
|
|
7710
7710
|
multiple: f,
|
|
7711
|
-
onChange:
|
|
7711
|
+
onChange: W,
|
|
7712
7712
|
required: g,
|
|
7713
7713
|
type: "file",
|
|
7714
7714
|
...s
|
|
7715
7715
|
}), T && /* @__PURE__ */ e.createElement(Ft, {
|
|
7716
7716
|
clearLabel: u.clearButton,
|
|
7717
|
-
handleClearInput:
|
|
7717
|
+
handleClearInput: G,
|
|
7718
7718
|
id: o
|
|
7719
7719
|
})), R && /* @__PURE__ */ e.createElement(jt, {
|
|
7720
7720
|
hasValidationMessage: !!x,
|
|
@@ -7917,9 +7917,9 @@ var fr = {
|
|
|
7917
7917
|
tagRemove: "Remove {value}",
|
|
7918
7918
|
tagsListLabel: "Current tags"
|
|
7919
7919
|
}, validationMessage: b, validationStatus: x, ...S }, C) => {
|
|
7920
|
-
let w = Dt(o), T = "pds-tags-input", E = g === "s" ? null : `${T}--${g}`, D = r ? $.disabled : null, O = f && !r ? $.required : null, k = x === "error" ? $.error : null, A = x === "success" ? $.success : null, j = b || l, [M, N] = h(""), [P, F] = h(null), [I, L] = h(null), [R, z] = h(null), [B, V] = h(null), [H, U] = h(""),
|
|
7920
|
+
let w = Dt(o), T = "pds-tags-input", E = g === "s" ? null : `${T}--${g}`, D = r ? $.disabled : null, O = f && !r ? $.required : null, k = x === "error" ? $.error : null, A = x === "success" ? $.success : null, j = b || l, [M, N] = h(""), [P, F] = h(null), [I, L] = h(null), [R, z] = h(null), [B, V] = h(null), [H, U] = h(""), W = m(null), G = _.length > 0 ? t : d, K = (e) => {
|
|
7921
7921
|
U(e), setTimeout(() => U(""), 1e3);
|
|
7922
|
-
},
|
|
7922
|
+
}, ee = (e) => {
|
|
7923
7923
|
u(e);
|
|
7924
7924
|
}, q = (e) => {
|
|
7925
7925
|
F(e);
|
|
@@ -7927,21 +7927,21 @@ var fr = {
|
|
|
7927
7927
|
F(null), L(null), z(null);
|
|
7928
7928
|
}, ne = (e, t) => {
|
|
7929
7929
|
P === null || P === e || (L(e), z(t));
|
|
7930
|
-
},
|
|
7930
|
+
}, re = (e) => {
|
|
7931
7931
|
if (e.preventDefault(), P === null || I === null || R === null) return;
|
|
7932
7932
|
let t = _.findIndex((e) => e.id === P), n = _.findIndex((e) => e.id === I);
|
|
7933
7933
|
if (t === -1 || n === -1) return;
|
|
7934
7934
|
let r = [..._], [i] = r.splice(t, 1), a = n;
|
|
7935
|
-
a = R === "after" ? t < n ? n : n + 1 : n, r.splice(a, 0, i),
|
|
7936
|
-
},
|
|
7935
|
+
a = R === "after" ? t < n ? n : n + 1 : n, r.splice(a, 0, i), ee(r), K("Tag reordered"), F(null), L(null), z(null);
|
|
7936
|
+
}, ie = (e, t) => {
|
|
7937
7937
|
let n = [..._], [r] = n.splice(e, 1);
|
|
7938
|
-
n.splice(t, 0, r),
|
|
7939
|
-
},
|
|
7938
|
+
n.splice(t, 0, r), K(`${r.value} moved to position ${t + 1} of ${_.length}`), ee(n);
|
|
7939
|
+
}, J = (e) => {
|
|
7940
7940
|
let t = _.find((t) => t.id === e);
|
|
7941
|
-
|
|
7941
|
+
ee(_.filter((t) => t.id !== e)), t && K(`${t.value} removed`);
|
|
7942
7942
|
}, Y = () => {
|
|
7943
7943
|
V(null), setTimeout(() => {
|
|
7944
|
-
|
|
7944
|
+
W.current?.focus();
|
|
7945
7945
|
}, 0);
|
|
7946
7946
|
}, X = (e) => {
|
|
7947
7947
|
if (!r) if (e.key === "Enter" && M.trim()) {
|
|
@@ -7950,10 +7950,10 @@ var fr = {
|
|
|
7950
7950
|
id: Date.now().toString(),
|
|
7951
7951
|
value: M.trim()
|
|
7952
7952
|
};
|
|
7953
|
-
|
|
7953
|
+
ee([..._, t]), K(`${M.trim()} added`), N("");
|
|
7954
7954
|
} else if (e.key === "Backspace" && !M && _.length > 0) {
|
|
7955
7955
|
let e = _[_.length - 1];
|
|
7956
|
-
|
|
7956
|
+
ee(_.slice(0, -1)), K(`${e.value} removed`);
|
|
7957
7957
|
} else e.key === "ArrowLeft" && !M && _.length > 0 && (e.preventDefault(), V(_.length - 1));
|
|
7958
7958
|
};
|
|
7959
7959
|
return /* @__PURE__ */ e.createElement("div", {
|
|
@@ -7989,7 +7989,7 @@ var fr = {
|
|
|
7989
7989
|
"aria-label": y.tagsListLabel,
|
|
7990
7990
|
className: `${T}__tags`,
|
|
7991
7991
|
onDragOver: s ? (e) => e.preventDefault() : void 0,
|
|
7992
|
-
onDrop: s ?
|
|
7992
|
+
onDrop: s ? re : void 0,
|
|
7993
7993
|
role: "list"
|
|
7994
7994
|
}, _.map((t, n) => {
|
|
7995
7995
|
let i = null;
|
|
@@ -8007,8 +8007,8 @@ var fr = {
|
|
|
8007
8007
|
onDragOver: ne,
|
|
8008
8008
|
onDragStart: q,
|
|
8009
8009
|
onFocusInput: Y,
|
|
8010
|
-
onKeyboardMove:
|
|
8011
|
-
onRemove:
|
|
8010
|
+
onKeyboardMove: ie,
|
|
8011
|
+
onRemove: J,
|
|
8012
8012
|
setFocusedIndex: V,
|
|
8013
8013
|
tag: t,
|
|
8014
8014
|
totalTags: _.length,
|
|
@@ -8016,7 +8016,7 @@ var fr = {
|
|
|
8016
8016
|
}));
|
|
8017
8017
|
})), /* @__PURE__ */ e.createElement("input", {
|
|
8018
8018
|
ref: (e) => {
|
|
8019
|
-
|
|
8019
|
+
W.current = e, typeof C == "function" ? C(e) : C && (C.current = e);
|
|
8020
8020
|
},
|
|
8021
8021
|
"aria-describedby": `${i}__instructions`,
|
|
8022
8022
|
"aria-invalid": x === "error" ? !0 : null,
|
|
@@ -8026,7 +8026,7 @@ var fr = {
|
|
|
8026
8026
|
name: i,
|
|
8027
8027
|
onChange: (e) => N(e.target.value),
|
|
8028
8028
|
onKeyDown: X,
|
|
8029
|
-
placeholder:
|
|
8029
|
+
placeholder: G,
|
|
8030
8030
|
required: f,
|
|
8031
8031
|
type: "text",
|
|
8032
8032
|
value: M
|
|
@@ -8114,8 +8114,8 @@ var fr = {
|
|
|
8114
8114
|
}, type: O = "text", validationMessage: k, validationStatus: A, value: j, ...M }, N) => {
|
|
8115
8115
|
let P = Dt(d), F = "pds-text-input", I = a ? $.disabled : null, L = x && !a ? $.required : null, R = A === "error" ? $.error : null, z = A === "success" ? $.success : null, B = b ? $.readonly : null, V = T === "s" ? null : `${F}--${T}`, H = c && O === "url" ? `${F}--has-url-prefix` : null, U = null;
|
|
8116
8116
|
O === "search" && (U = "search"), O === "search" && S === "filter" && (U = "filter"), A === "error" && (U = "error"), A === "success" && (U = "success");
|
|
8117
|
-
let
|
|
8118
|
-
if (w &&
|
|
8117
|
+
let W = k || p, G = j !== void 0, [K, ee] = h(i === void 0 ? "" : i), q = j || K, te = (e) => {
|
|
8118
|
+
if (w && ie && J(!1), c && O === "url") {
|
|
8119
8119
|
let t = Ot(e.target.value), n = {
|
|
8120
8120
|
...e,
|
|
8121
8121
|
target: {
|
|
@@ -8134,18 +8134,18 @@ var fr = {
|
|
|
8134
8134
|
value: t
|
|
8135
8135
|
}
|
|
8136
8136
|
};
|
|
8137
|
-
|
|
8138
|
-
} else
|
|
8139
|
-
},
|
|
8140
|
-
|
|
8137
|
+
G || ee(t), g && g(n);
|
|
8138
|
+
} else G || ee(e.target.value), g && g(e);
|
|
8139
|
+
}, re = () => {
|
|
8140
|
+
G || ee(""), _ && _();
|
|
8141
8141
|
let e = document.getElementById(l);
|
|
8142
8142
|
e && e.focus();
|
|
8143
|
-
}, [
|
|
8144
|
-
|
|
8143
|
+
}, [ie, J] = h(!1), Y = () => {
|
|
8144
|
+
J((e) => !e);
|
|
8145
8145
|
let e = document.getElementById(l);
|
|
8146
8146
|
e && e.focus();
|
|
8147
8147
|
}, X = O;
|
|
8148
|
-
return w && O === "password" && (X =
|
|
8148
|
+
return w && O === "password" && (X = ie ? "text" : "password"), /* @__PURE__ */ e.createElement("div", {
|
|
8149
8149
|
className: Z([
|
|
8150
8150
|
$.base,
|
|
8151
8151
|
F,
|
|
@@ -8170,9 +8170,9 @@ var fr = {
|
|
|
8170
8170
|
}), w && O === "password" && /* @__PURE__ */ e.createElement("div", {
|
|
8171
8171
|
"aria-live": "polite",
|
|
8172
8172
|
className: "visually-hidden"
|
|
8173
|
-
}, `${D.visibilityStatus} ${
|
|
8173
|
+
}, `${D.visibilityStatus} ${ie ? "visible" : "hidden"}.`), /* @__PURE__ */ e.createElement("div", { className: `${F}__input-wrapper ${c && O === "url" ? `${F}__input-wrapper--has-prefix` : ""}` }, U && /* @__PURE__ */ e.createElement(Nt, { variant: U }), c && O === "url" && /* @__PURE__ */ e.createElement(Br, null), /* @__PURE__ */ e.createElement("input", {
|
|
8174
8174
|
ref: N,
|
|
8175
|
-
"aria-describedby":
|
|
8175
|
+
"aria-describedby": W ? `${l}__message` : null,
|
|
8176
8176
|
"aria-invalid": A === "error" ? !0 : null,
|
|
8177
8177
|
autoComplete: O === "password" ? "off" : t,
|
|
8178
8178
|
className: `${F}__input ${c && O === "url" ? `${F}__input--has-prefix` : ""}`,
|
|
@@ -8186,21 +8186,21 @@ var fr = {
|
|
|
8186
8186
|
readOnly: b,
|
|
8187
8187
|
required: x,
|
|
8188
8188
|
type: X,
|
|
8189
|
-
value:
|
|
8189
|
+
value: G ? j : K,
|
|
8190
8190
|
...u
|
|
8191
8191
|
}), o && q && /* @__PURE__ */ e.createElement(Ft, {
|
|
8192
8192
|
clearLabel: D.clearButton,
|
|
8193
|
-
handleClearInput:
|
|
8193
|
+
handleClearInput: re,
|
|
8194
8194
|
id: l
|
|
8195
8195
|
}), w && O === "password" && /* @__PURE__ */ e.createElement("button", {
|
|
8196
8196
|
"aria-controls": l,
|
|
8197
8197
|
className: `${F}__visibility-toggle`,
|
|
8198
8198
|
onClick: Y,
|
|
8199
8199
|
onMouseDown: (e) => e.preventDefault(),
|
|
8200
|
-
title:
|
|
8200
|
+
title: ie ? D.visibilityToggleHide : D.visibilityToggleShow,
|
|
8201
8201
|
type: "button"
|
|
8202
8202
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
8203
|
-
iconName:
|
|
8203
|
+
iconName: ie ? "eyeSlash" : "eye",
|
|
8204
8204
|
size: "m"
|
|
8205
8205
|
})), s && O === "search" && !q && /* @__PURE__ */ e.createElement(Pt, {
|
|
8206
8206
|
inputId: l,
|
|
@@ -8210,10 +8210,10 @@ var fr = {
|
|
|
8210
8210
|
id: l,
|
|
8211
8211
|
maxLength: r,
|
|
8212
8212
|
overLimitMessage: D.counterOverLimit
|
|
8213
|
-
})),
|
|
8213
|
+
})), W && /* @__PURE__ */ e.createElement(jt, {
|
|
8214
8214
|
hasValidationMessage: !!k,
|
|
8215
8215
|
id: l,
|
|
8216
|
-
message:
|
|
8216
|
+
message: W,
|
|
8217
8217
|
validationMessageHasDecorators: !1,
|
|
8218
8218
|
validationStatus: A
|
|
8219
8219
|
}));
|
|
@@ -9274,7 +9274,7 @@ var fr = {
|
|
|
9274
9274
|
D()
|
|
9275
9275
|
],
|
|
9276
9276
|
whileElementsMounted: C
|
|
9277
|
-
}), z = k(M, { event: "mousedown" }), B = A(M), V = L(M, { role: "menu" }), H = m([]), { getFloatingProps: U, getItemProps:
|
|
9277
|
+
}), z = k(M, { event: "mousedown" }), B = A(M), V = L(M, { role: "menu" }), H = m([]), { getFloatingProps: U, getItemProps: W, getReferenceProps: G } = F([
|
|
9278
9278
|
B,
|
|
9279
9279
|
V,
|
|
9280
9280
|
z,
|
|
@@ -9287,7 +9287,7 @@ var fr = {
|
|
|
9287
9287
|
focusItemOnOpen: !1,
|
|
9288
9288
|
focusItemOnHover: !0
|
|
9289
9289
|
})
|
|
9290
|
-
]), { isMounted:
|
|
9290
|
+
]), { isMounted: K, styles: ee } = R(M, {
|
|
9291
9291
|
duration: {
|
|
9292
9292
|
open: 300,
|
|
9293
9293
|
close: 150
|
|
@@ -9319,13 +9319,13 @@ var fr = {
|
|
|
9319
9319
|
let n = e.id ? e.id : `${S}-item-${t}`;
|
|
9320
9320
|
y.current.push(n), b.current.push(e);
|
|
9321
9321
|
});
|
|
9322
|
-
let
|
|
9322
|
+
let re = (e) => {
|
|
9323
9323
|
let t = y.current.indexOf(e), n = b.current[t];
|
|
9324
9324
|
n.linkContent && !n.disabled && (H.current[t].querySelector("a").click(), v(!1)), n.callback && !n.disabled && (n.callback(), v(!1));
|
|
9325
|
-
}, re = (e) => {
|
|
9326
|
-
e.preventDefault(), e.key === "Enter" && J(e.currentTarget.id);
|
|
9327
9325
|
}, ie = (e) => {
|
|
9328
|
-
|
|
9326
|
+
e.preventDefault(), e.key === "Enter" && re(e.currentTarget.id);
|
|
9327
|
+
}, J = (e) => {
|
|
9328
|
+
re(e.currentTarget.id);
|
|
9329
9329
|
}, Y = r.map((t, n) => {
|
|
9330
9330
|
let r = y.current[n], i = `${E}__item`, a = t.disabled ? `${i}--disabled` : null;
|
|
9331
9331
|
return /* @__PURE__ */ e.createElement("li", {
|
|
@@ -9335,10 +9335,10 @@ var fr = {
|
|
|
9335
9335
|
},
|
|
9336
9336
|
className: Z([i, a]),
|
|
9337
9337
|
id: r,
|
|
9338
|
-
onKeyDown:
|
|
9338
|
+
onKeyDown: ie,
|
|
9339
9339
|
role: "menuitem",
|
|
9340
9340
|
tabIndex: p === n ? 0 : -1,
|
|
9341
|
-
...
|
|
9341
|
+
...W({ onClick: (e) => J(e) })
|
|
9342
9342
|
}, t.linkContent ? t.linkContent : t.label, t.iconName && /* @__PURE__ */ e.createElement(Q, {
|
|
9343
9343
|
className: `${E}__icon`,
|
|
9344
9344
|
iconName: t.iconName,
|
|
@@ -9371,8 +9371,8 @@ var fr = {
|
|
|
9371
9371
|
"aria-label": t,
|
|
9372
9372
|
className: `${E}__trigger`,
|
|
9373
9373
|
type: "button",
|
|
9374
|
-
...
|
|
9375
|
-
}, q),
|
|
9374
|
+
...G()
|
|
9375
|
+
}, q), K && /* @__PURE__ */ e.createElement(x, null, /* @__PURE__ */ e.createElement("div", {
|
|
9376
9376
|
ref: P.setFloating,
|
|
9377
9377
|
className: `${E}__dropdown`,
|
|
9378
9378
|
style: {
|
|
@@ -9380,7 +9380,7 @@ var fr = {
|
|
|
9380
9380
|
zIndex: "var(--pds-z-index-dropdown)"
|
|
9381
9381
|
},
|
|
9382
9382
|
...U()
|
|
9383
|
-
}, /* @__PURE__ */ e.createElement("div", { style: { ...
|
|
9383
|
+
}, /* @__PURE__ */ e.createElement("div", { style: { ...ee } }, /* @__PURE__ */ e.createElement("ul", {
|
|
9384
9384
|
className: O,
|
|
9385
9385
|
role: "menu"
|
|
9386
9386
|
}, te, /* @__PURE__ */ e.createElement("li", { role: "separator" }), ne, Y)))));
|
|
@@ -10420,7 +10420,7 @@ var fr = {
|
|
|
10420
10420
|
}, [d]), l(() => {
|
|
10421
10421
|
f(O);
|
|
10422
10422
|
}, [O]);
|
|
10423
|
-
let N = typeof a, P = "pds-popover", I = Z([`${P}__trigger-custom`, N === "string" ? `${P}__trigger-text` : ""]), z = a ? s : 0, B = m(null), { context: V, floatingStyles: H, middlewareData: U, refs:
|
|
10423
|
+
let N = typeof a, P = "pds-popover", I = Z([`${P}__trigger-custom`, N === "string" ? `${P}__trigger-text` : ""]), z = a ? s : 0, B = m(null), { context: V, floatingStyles: H, middlewareData: U, refs: W } = j({
|
|
10424
10424
|
placement: u,
|
|
10425
10425
|
open: O,
|
|
10426
10426
|
onOpenChange(e) {
|
|
@@ -10433,44 +10433,44 @@ var fr = {
|
|
|
10433
10433
|
S({ element: B })
|
|
10434
10434
|
],
|
|
10435
10435
|
whileElementsMounted: C
|
|
10436
|
-
}),
|
|
10436
|
+
}), G = () => {
|
|
10437
10437
|
M(!1), c && c();
|
|
10438
|
-
}, { getFloatingProps:
|
|
10438
|
+
}, { getFloatingProps: K, getReferenceProps: ee } = F([
|
|
10439
10439
|
k(V),
|
|
10440
10440
|
A(V),
|
|
10441
10441
|
L(V)
|
|
10442
|
-
]), q = U.arrow?.x ?? 0, te = U.arrow?.y ?? 0, ne = q + ea / 2,
|
|
10442
|
+
]), q = U.arrow?.x ?? 0, te = U.arrow?.y ?? 0, ne = q + ea / 2, re = te + $i, { isMounted: ie } = R(V, {
|
|
10443
10443
|
initial: { transform: "scale(0)" },
|
|
10444
10444
|
common: ({ side: e }) => ({ transformOrigin: {
|
|
10445
10445
|
top: `${ne}px calc(100% + ${$i}px)`,
|
|
10446
10446
|
bottom: `${ne}px -8px`,
|
|
10447
|
-
left: `calc(100% + ${$i}px) ${
|
|
10448
|
-
right: `-8px ${
|
|
10447
|
+
left: `calc(100% + ${$i}px) ${re}px`,
|
|
10448
|
+
right: `-8px ${re}px`
|
|
10449
10449
|
}[e] })
|
|
10450
10450
|
});
|
|
10451
10451
|
return /* @__PURE__ */ e.createElement("div", {
|
|
10452
10452
|
className: Z([P, t]),
|
|
10453
10453
|
...E
|
|
10454
10454
|
}, /* @__PURE__ */ e.createElement("span", {
|
|
10455
|
-
ref:
|
|
10455
|
+
ref: W.setReference,
|
|
10456
10456
|
className: `${P}__trigger`,
|
|
10457
10457
|
role: "button",
|
|
10458
10458
|
tabIndex: 0,
|
|
10459
|
-
...
|
|
10459
|
+
...ee(),
|
|
10460
10460
|
...E
|
|
10461
10461
|
}, a ? /* @__PURE__ */ e.createElement("span", { className: I }, a) : /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("span", { className: "visually-hidden" }, g), /* @__PURE__ */ e.createElement(Q, {
|
|
10462
10462
|
className: `${P}__icon`,
|
|
10463
10463
|
iconName: _,
|
|
10464
10464
|
size: b
|
|
10465
|
-
}))),
|
|
10465
|
+
}))), ie && /* @__PURE__ */ e.createElement(x, null, /* @__PURE__ */ e.createElement(y, {
|
|
10466
10466
|
context: V,
|
|
10467
10467
|
initialFocus: -1,
|
|
10468
10468
|
modal: o
|
|
10469
10469
|
}, /* @__PURE__ */ e.createElement("div", {
|
|
10470
|
-
ref:
|
|
10470
|
+
ref: W.setFloating,
|
|
10471
10471
|
className: Z([`${P}__container`, n]),
|
|
10472
10472
|
style: H,
|
|
10473
|
-
...
|
|
10473
|
+
...K()
|
|
10474
10474
|
}, /* @__PURE__ */ e.createElement(v, {
|
|
10475
10475
|
ref: B,
|
|
10476
10476
|
className: `${P}__arrow`,
|
|
@@ -10483,7 +10483,7 @@ var fr = {
|
|
|
10483
10483
|
width: ea
|
|
10484
10484
|
}), /* @__PURE__ */ e.createElement("div", { className: `${P}__container-inner` }, p && /* @__PURE__ */ e.createElement("div", { className: `${P}__title` }, p), i && /* @__PURE__ */ e.createElement("div", { className: `${P}__content` }, i), o && /* @__PURE__ */ e.createElement("div", { className: `${P}__close-wrapper` }, /* @__PURE__ */ e.createElement(tn, {
|
|
10485
10485
|
ariaLabel: r,
|
|
10486
|
-
onClick:
|
|
10486
|
+
onClick: G,
|
|
10487
10487
|
size: "s"
|
|
10488
10488
|
})))))));
|
|
10489
10489
|
}, na = {
|
|
@@ -10794,7 +10794,7 @@ function _a(e) {
|
|
|
10794
10794
|
//#endregion
|
|
10795
10795
|
//#region src/components/SortableList/SortableList.tsx
|
|
10796
10796
|
var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ children: n, className: r, columns: i, defaultItems: a, getItemLabel: c = (e) => String(e.id), isDragEnabled: l, isItemLocked: u = () => !1, isNestingLocked: f = () => !1, items: g, maxDepth: _ = 0, onReorder: v, renderRow: y, reorderMode: b = "always", screenReaderInstructions: x, ...S }, C) {
|
|
10797
|
-
let w = "pds-sortable-list", [T, E] = h(null), D = m(null), [O, k] = h(!1), A = m(!1), [j, M] = h(null), N = m(0), P = m(0), F = m("pointer"), I = m(0), L = m(null), [R, z] = h(0), B = m(0), [V, H] = h(0), U = m(0),
|
|
10797
|
+
let w = "pds-sortable-list", [T, E] = h(null), D = m(null), [O, k] = h(!1), A = m(!1), [j, M] = h(null), N = m(0), P = m(0), F = m("pointer"), I = m(0), L = m(null), [R, z] = h(0), B = m(0), [V, H] = h(0), U = m(0), W = s((e, t) => {
|
|
10798
10798
|
if (_ > 0 && (e.key === "ArrowLeft" || e.key === "ArrowRight")) {
|
|
10799
10799
|
e.preventDefault();
|
|
10800
10800
|
let n = e.key === "ArrowRight" ? 1 : -1, r = B.current, i = Math.max(-_, Math.min(_, r + n)), a = i - r;
|
|
@@ -10804,14 +10804,14 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10804
10804
|
};
|
|
10805
10805
|
}
|
|
10806
10806
|
return we(e, t);
|
|
10807
|
-
}, [_]),
|
|
10807
|
+
}, [_]), G = b === "always" || b === "toggle" && (l ?? !1), { currentItems: K, expandItem: ee, flatNodes: q, handleReorder: te, resetToSnapshot: ne, sortableIds: re, toggleExpand: ie } = ha({
|
|
10808
10808
|
defaultItems: a,
|
|
10809
|
-
isDragEnabled:
|
|
10809
|
+
isDragEnabled: G,
|
|
10810
10810
|
items: g,
|
|
10811
10811
|
onReorder: v
|
|
10812
10812
|
});
|
|
10813
10813
|
d(C, () => ({ resetToSnapshot: ne }), [ne]);
|
|
10814
|
-
let
|
|
10814
|
+
let J = Se(xe(ye, { activationConstraint: { distance: 5 } }), xe(_e, { coordinateGetter: W })), Y = G ? `${w}--reorder-active` : null, X = p(() => new Set(q.filter((e) => u(e.data)).map((e) => e.id)), [q, u]), ae = p(() => new Set(q.filter((e) => f(e.data)).map((e) => e.id)), [q, f]), oe = s((e) => {
|
|
10815
10815
|
if (_ === 0 || ae.has(String(e))) return !1;
|
|
10816
10816
|
let t = q.find((t) => t.id === e);
|
|
10817
10817
|
return !t || t.depth >= _ ? !1 : t.hasChildren ? !t.isExpanded : !0;
|
|
@@ -10831,7 +10831,7 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10831
10831
|
oe,
|
|
10832
10832
|
X,
|
|
10833
10833
|
j
|
|
10834
|
-
]).size > 0, le = p(() => T ? q.find((e) => e.id === T) ?? null : null, [T, q]), ue = p(() => T ? fa(
|
|
10834
|
+
]).size > 0, le = p(() => T ? q.find((e) => e.id === T) ?? null : null, [T, q]), ue = p(() => T ? fa(K, String(T)) ?? null : null, [T, K]), de = p(() => {
|
|
10835
10835
|
let e = le?.depth ?? 0;
|
|
10836
10836
|
return !T || !j || O || _ === 0 ? e : pa(q, String(T), String(j), V * va, va, _);
|
|
10837
10837
|
}, [
|
|
@@ -10855,8 +10855,8 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10855
10855
|
de
|
|
10856
10856
|
]), pe = s((e) => {
|
|
10857
10857
|
let { active: t } = e, n = F.current === "keyboard", r = q.find((e) => e.id === t.id);
|
|
10858
|
-
E(t.id), D.current = t.id, k(n), A.current = n, I.current = r?.depth ?? 0, M(null), N.current = 0, P.current = 0, U.current = 0, H(0), B.current = 0, z(0), r?.hasChildren && r?.isExpanded && (
|
|
10859
|
-
}, [q,
|
|
10858
|
+
E(t.id), D.current = t.id, k(n), A.current = n, I.current = r?.depth ?? 0, M(null), N.current = 0, P.current = 0, U.current = 0, H(0), B.current = 0, z(0), r?.hasChildren && r?.isExpanded && (ie(String(t.id)), L.current = String(t.id));
|
|
10859
|
+
}, [q, ie]), me = s((e) => {
|
|
10860
10860
|
let t = be(e);
|
|
10861
10861
|
if (!t.length || !D.current || X.size === 0) return t;
|
|
10862
10862
|
let n = q.findIndex((e) => e.id === D.current);
|
|
@@ -10895,7 +10895,7 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10895
10895
|
(n > r || n < r && t < r * va - va * .4) && (U.current = n, H(n));
|
|
10896
10896
|
}, [_]), De = s((e) => {
|
|
10897
10897
|
let { active: t, over: n } = e, r = A.current, i = B.current, a = U.current;
|
|
10898
|
-
E(null), D.current = null, k(!1), A.current = !1, M(null), U.current = 0, H(0), L.current && (
|
|
10898
|
+
E(null), D.current = null, k(!1), A.current = !1, M(null), U.current = 0, H(0), L.current && (ee(L.current), L.current = null);
|
|
10899
10899
|
let o = q.findIndex((e) => e.id === t.id), s = r ? i * va : a * va, c = !n || t.id === n.id, l = n?.id ?? null;
|
|
10900
10900
|
if (r && i > 0 && c && o > 0 && (l = q[o - 1].id), !l || t.id === l) {
|
|
10901
10901
|
if (o === -1) return;
|
|
@@ -10913,7 +10913,7 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10913
10913
|
r.splice(o, 0, c);
|
|
10914
10914
|
let l = q.filter((e) => e.id !== t.id).map((e) => e.id), u = r.filter((e) => e.id !== t.id).map((e) => e.id);
|
|
10915
10915
|
if (l.some((e, t) => X.has(e) ? u.indexOf(e) !== t : !1)) return;
|
|
10916
|
-
te(r), n > 0 && a &&
|
|
10916
|
+
te(r), n > 0 && a && ee(a);
|
|
10917
10917
|
return;
|
|
10918
10918
|
}
|
|
10919
10919
|
let u = q.findIndex((e) => e.id === l);
|
|
@@ -10937,9 +10937,9 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10937
10937
|
}, b = d[h], x = b && b.depth === g - 1 && v === String(l) || o < u ? h + 1 : h;
|
|
10938
10938
|
d.splice(x, 0, y, ...m);
|
|
10939
10939
|
let S = new Set([String(t.id), ...m.map((e) => e.id)]);
|
|
10940
|
-
q.some((e, t) => !X.has(e.id) || S.has(e.id) || e.id === v ? !1 : d.findIndex((t) => t.id === e.id) !== t) || (te(d), g > 0 && v !== null &&
|
|
10940
|
+
q.some((e, t) => !X.has(e.id) || S.has(e.id) || e.id === v ? !1 : d.findIndex((t) => t.id === e.id) !== t) || (te(d), g > 0 && v !== null && ee(v));
|
|
10941
10941
|
}, [
|
|
10942
|
-
|
|
10942
|
+
ee,
|
|
10943
10943
|
q,
|
|
10944
10944
|
te,
|
|
10945
10945
|
oe,
|
|
@@ -10947,31 +10947,31 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10947
10947
|
_,
|
|
10948
10948
|
ae
|
|
10949
10949
|
]), Oe = s(() => {
|
|
10950
|
-
E(null), D.current = null, k(!1), A.current = !1, M(null), P.current = 0, U.current = 0, H(0), B.current = 0, z(0), L.current && (
|
|
10951
|
-
}, [
|
|
10950
|
+
E(null), D.current = null, k(!1), A.current = !1, M(null), P.current = 0, U.current = 0, H(0), B.current = 0, z(0), L.current && (ee(L.current), L.current = null);
|
|
10951
|
+
}, [ee]), ke = p(() => ({
|
|
10952
10952
|
onDragStart({ active: e }) {
|
|
10953
|
-
let t = q.find((t) => t.id === e.id), n = fa(
|
|
10953
|
+
let t = q.find((t) => t.id === e.id), n = fa(K, String(e.id));
|
|
10954
10954
|
return `Picked up ${n ? c(n) : String(e.id)}. Current position: ${t ? q.indexOf(t) + 1 : "?"} of ${q.length} at depth ${t?.depth ?? 0}.`;
|
|
10955
10955
|
},
|
|
10956
10956
|
onDragOver({ active: e, over: t }) {
|
|
10957
10957
|
if (!t) return;
|
|
10958
10958
|
let n = q.findIndex((e) => e.id === t.id);
|
|
10959
10959
|
if (n === -1) return;
|
|
10960
|
-
let r = fa(
|
|
10960
|
+
let r = fa(K, String(e.id)), i = r ? c(r) : String(e.id), a = pa(q, String(e.id), String(t.id), P.current, va, _);
|
|
10961
10961
|
return `Moving ${i}. Target position: ${n + 1} of ${q.length} at depth ${a}.`;
|
|
10962
10962
|
},
|
|
10963
10963
|
onDragEnd({ active: e, over: t }) {
|
|
10964
|
-
let n = fa(
|
|
10964
|
+
let n = fa(K, String(e.id)), r = n ? c(n) : String(e.id);
|
|
10965
10965
|
if (!t || e.id === t.id) return `${r} dropped. No change in position.`;
|
|
10966
10966
|
let i = q.findIndex((e) => e.id === t.id), a = pa(q, String(e.id), String(t.id), P.current, va, _);
|
|
10967
10967
|
return `${r} dropped at position ${i + 1} of ${q.length} at depth ${a}.`;
|
|
10968
10968
|
},
|
|
10969
10969
|
onDragCancel({ active: e }) {
|
|
10970
|
-
let t = q.find((t) => t.id === e.id), n = fa(
|
|
10970
|
+
let t = q.find((t) => t.id === e.id), n = fa(K, String(e.id));
|
|
10971
10971
|
return `Sorting cancelled. ${n ? c(n) : String(e.id)} returned to position ${t ? q.indexOf(t) + 1 : "?"} of ${q.length}.`;
|
|
10972
10972
|
}
|
|
10973
10973
|
}), [
|
|
10974
|
-
|
|
10974
|
+
K,
|
|
10975
10975
|
q,
|
|
10976
10976
|
c,
|
|
10977
10977
|
_
|
|
@@ -10988,9 +10988,9 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
10988
10988
|
onDragMove: Te,
|
|
10989
10989
|
onDragOver: ve,
|
|
10990
10990
|
onDragStart: pe,
|
|
10991
|
-
sensors:
|
|
10991
|
+
sensors: J
|
|
10992
10992
|
}, /* @__PURE__ */ e.createElement(Ce, {
|
|
10993
|
-
items:
|
|
10993
|
+
items: re,
|
|
10994
10994
|
strategy: se
|
|
10995
10995
|
}, /* @__PURE__ */ e.createElement("div", {
|
|
10996
10996
|
className: Z([
|
|
@@ -11014,18 +11014,18 @@ var va = 24, ya = { droppable: { strategy: ve.Always } }, ba = a(function({ chil
|
|
|
11014
11014
|
isDragging: t.id === T,
|
|
11015
11015
|
isExpanded: t.isExpanded,
|
|
11016
11016
|
isLocked: X.has(t.id),
|
|
11017
|
-
toggleExpand: () =>
|
|
11017
|
+
toggleExpand: () => ie(t.id)
|
|
11018
11018
|
}, r = y(t.data, n), a = t.id === T, s = {
|
|
11019
11019
|
columns: i,
|
|
11020
11020
|
depth: t.depth,
|
|
11021
11021
|
hasChildren: t.hasChildren,
|
|
11022
|
-
isDragActive:
|
|
11022
|
+
isDragActive: G,
|
|
11023
11023
|
isDragging: a,
|
|
11024
11024
|
isDropTarget: t.id === j && oe(t.id),
|
|
11025
11025
|
isProjectedParent: t.id === fe && !ae.has(t.id),
|
|
11026
11026
|
isExpanded: t.isExpanded,
|
|
11027
11027
|
...X.has(t.id) ? { isLocked: !0 } : {},
|
|
11028
|
-
onToggleExpand: () =>
|
|
11028
|
+
onToggleExpand: () => ie(t.id),
|
|
11029
11029
|
...a && !O && _ > 0 ? { projectedDepthDelta: de - t.depth } : {}
|
|
11030
11030
|
};
|
|
11031
11031
|
return o(r) ? e.cloneElement(r, {
|
|
@@ -11344,76 +11344,79 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11344
11344
|
className: Z([a, t ?? ""]),
|
|
11345
11345
|
...i
|
|
11346
11346
|
}, /* @__PURE__ */ e.createElement("ol", { className: `${a}__steps` }, r && c));
|
|
11347
|
-
}, ka = ({ className: t, closeDetailPanelLabel: n = "Close detail panel", columns: r, currentPage: i, defaultSortKey: a, defaultSortOrder: o = "asc", detailPanelNav: s = !0, detailPanelTitle: c, detailPanelWidth: d, emptyState: f, emptyStateHeading: m = "No results found.", emptyStateMessage: g, footer: _, getPageSizeLabel: v = (e) => `Show ${e} rows per page`, getRowClassName: y, getRowId: b,
|
|
11348
|
-
let
|
|
11347
|
+
}, ka = ({ className: t, closeDetailPanelLabel: n = "Close detail panel", columns: r, currentPage: i, defaultSortKey: a, defaultSortOrder: o = "asc", detailPanelNav: s = !0, detailPanelTitle: c, detailPanelWidth: d, emptyState: f, emptyStateHeading: m = "No results found.", emptyStateMessage: g, footer: _, getPageSizeLabel: v = (e) => `Show ${e} rows per page`, getRowClassName: y, getRowId: b, getRowSelectDisabledReason: x, getSelectRowLabel: S = (e, t) => `Select row ${t}`, getSortLabel: C = (e) => `Sort by ${e}`, inspectedRowId: w, isLoading: T = !1, isRowSelectable: E = () => !0, itemsPerPage: D, loadingRowCount: O = 5, nextDetailPanelRowLabel: k = "Next row", onDetailPanelNext: A, onDetailPanelPrev: j, onPageChange: M, onPageSizeChange: N, onRowInspect: P, onRowSelectionChange: F, onSort: I, pageSizeOptions: L, pageSizeSelectLabel: R = "Rows per page", paginationLabels: z, panel: B, prevDetailPanelRowLabel: V = "Previous row", renderDetailPanel: H, renderDetailPanelFooter: U, rowData: W, selectAllLabel: G = "Select all rows", selectedRows: K, sortKey: ee, sortOrder: q, totalItemCount: te, ...ne }) => {
|
|
11348
|
+
let re = "pds-table", ie = u(), J = u(), Y = I !== void 0, X = M !== void 0, ae = N !== void 0, oe = X || D !== void 0 || L !== void 0, [se, ce] = h({
|
|
11349
11349
|
key: a ?? "",
|
|
11350
11350
|
order: a === void 0 ? "asc" : o
|
|
11351
|
-
}), [
|
|
11352
|
-
|
|
11351
|
+
}), [le, ue] = h(1), [de, fe] = h(D ?? L?.[0] ?? 10), [pe, me] = h(null), he = w ?? pe, ge = !!he && !!H, _e = X ? D ?? 10 : de, ve = (e) => {
|
|
11352
|
+
ae ? N(e) : fe(e), X || ue(1);
|
|
11353
11353
|
};
|
|
11354
11354
|
l(() => {
|
|
11355
|
-
|
|
11356
|
-
}, [
|
|
11357
|
-
process.env.NODE_ENV !== "production" && i !== void 0 && !
|
|
11355
|
+
X || ue(1);
|
|
11356
|
+
}, [W.length, X]), l(() => {
|
|
11357
|
+
process.env.NODE_ENV !== "production" && i !== void 0 && !M && console.warn("[Table] `currentPage` was provided without `onPageChange`. Controlled pagination requires both props. The table is running in uncontrolled mode.");
|
|
11358
11358
|
}, []);
|
|
11359
|
-
let
|
|
11360
|
-
|
|
11361
|
-
|
|
11359
|
+
let ye = F !== void 0, be = K !== void 0, [xe, Se] = h(/* @__PURE__ */ new Set()), Ce = be ? new Set(K) : xe, we = p(() => new Map(W.map((e, t) => [e, t])), [W]), Te = (e, t) => b ? b(e) : String(we.get(e) ?? t), Ee = p(() => W.findIndex((e, t) => (b ? b(e) : String(we.get(e) ?? t)) === he), [
|
|
11360
|
+
W,
|
|
11361
|
+
he,
|
|
11362
11362
|
b,
|
|
11363
|
-
|
|
11364
|
-
]),
|
|
11365
|
-
|
|
11366
|
-
},
|
|
11367
|
-
|
|
11368
|
-
},
|
|
11369
|
-
if (
|
|
11370
|
-
let e =
|
|
11371
|
-
|
|
11372
|
-
},
|
|
11373
|
-
if (
|
|
11374
|
-
let e =
|
|
11375
|
-
|
|
11376
|
-
},
|
|
11377
|
-
if (
|
|
11378
|
-
let e =
|
|
11379
|
-
if (!
|
|
11380
|
-
let t = r.find((e) => e.id ===
|
|
11363
|
+
we
|
|
11364
|
+
]), De = Ee >= 0 ? W[Ee] : null, Oe = (e, t) => {
|
|
11365
|
+
H && w === void 0 && me(t), P?.(e, t);
|
|
11366
|
+
}, ke = () => {
|
|
11367
|
+
w === void 0 && me(null);
|
|
11368
|
+
}, Ae = () => {
|
|
11369
|
+
if (Ee <= 0) return;
|
|
11370
|
+
let e = W[Ee - 1], t = Te(e, Ee - 1);
|
|
11371
|
+
w === void 0 && me(t), P?.(e, t), j?.(e, t);
|
|
11372
|
+
}, je = () => {
|
|
11373
|
+
if (Ee >= W.length - 1) return;
|
|
11374
|
+
let e = W[Ee + 1], t = Te(e, Ee + 1);
|
|
11375
|
+
w === void 0 && me(t), P?.(e, t), A?.(e, t);
|
|
11376
|
+
}, Me = Y ? ee ?? "" : se.key, Ne = Y ? q ?? "asc" : se.order, Pe = p(() => {
|
|
11377
|
+
if (T) return [];
|
|
11378
|
+
let e = W;
|
|
11379
|
+
if (!Y && se.key !== "") {
|
|
11380
|
+
let t = r.find((e) => e.id === se.key)?.sortKey ?? se.key;
|
|
11381
11381
|
e = [...e].sort((e, n) => {
|
|
11382
11382
|
let r = String(e[t]).localeCompare(String(n[t]));
|
|
11383
|
-
return
|
|
11383
|
+
return se.order === "asc" ? r : -r;
|
|
11384
11384
|
});
|
|
11385
11385
|
}
|
|
11386
|
-
if (!
|
|
11387
|
-
let t = (
|
|
11388
|
-
e = e.slice(t, t +
|
|
11386
|
+
if (!X && oe && _e) {
|
|
11387
|
+
let t = (le - 1) * _e;
|
|
11388
|
+
e = e.slice(t, t + _e);
|
|
11389
11389
|
}
|
|
11390
11390
|
return e;
|
|
11391
11391
|
}, [
|
|
11392
|
-
|
|
11392
|
+
W,
|
|
11393
|
+
se,
|
|
11393
11394
|
Y,
|
|
11394
|
-
|
|
11395
|
-
|
|
11396
|
-
|
|
11397
|
-
|
|
11398
|
-
|
|
11399
|
-
|
|
11400
|
-
|
|
11401
|
-
ne ? P(e, U === e && ee === "asc" ? "desc" : "asc") : X((t) => ({
|
|
11395
|
+
X,
|
|
11396
|
+
oe,
|
|
11397
|
+
le,
|
|
11398
|
+
_e,
|
|
11399
|
+
T
|
|
11400
|
+
]), Fe = (e) => {
|
|
11401
|
+
Y ? I(e, ee === e && q === "asc" ? "desc" : "asc") : ce((t) => ({
|
|
11402
11402
|
key: e,
|
|
11403
11403
|
order: t.key === e && t.order === "asc" ? "desc" : "asc"
|
|
11404
11404
|
}));
|
|
11405
|
-
},
|
|
11406
|
-
let n = `${
|
|
11407
|
-
if (
|
|
11408
|
-
let i =
|
|
11409
|
-
return t === "top" ? i &&
|
|
11410
|
-
},
|
|
11411
|
-
let
|
|
11412
|
-
|
|
11413
|
-
}, Re = () => {
|
|
11414
|
-
let
|
|
11415
|
-
|
|
11416
|
-
},
|
|
11405
|
+
}, Ie = (e) => Me === e ? Ne === "asc" ? "ascending" : "descending" : "none", Le = (e, t) => {
|
|
11406
|
+
let n = `${re}__sort-button-${t}`, r = !T && Pe.length === 0;
|
|
11407
|
+
if (T || r || Me === "") return t === "top" ? `${n}--inactive` : "";
|
|
11408
|
+
let i = Me === e;
|
|
11409
|
+
return t === "top" ? i && Ne === "asc" ? "" : `${n}--inactive` : i && Ne === "desc" ? `${n}--desc` : "";
|
|
11410
|
+
}, Re = Pe.reduce((e, t, n) => {
|
|
11411
|
+
let r = Te(t, n);
|
|
11412
|
+
return E(t, r) && e.push(r), e;
|
|
11413
|
+
}, []), ze = Re.length > 0 && Re.every((e) => Ce.has(e)), Be = !ze && Re.some((e) => Ce.has(e)), Ve = (e) => {
|
|
11414
|
+
let t = new Set(Ce);
|
|
11415
|
+
t.has(e) ? t.delete(e) : t.add(e), be || Se(t), F?.(Array.from(t));
|
|
11416
|
+
}, He = () => {
|
|
11417
|
+
let e = new Set(Ce);
|
|
11418
|
+
ze || Be ? Re.forEach((t) => e.delete(t)) : Re.forEach((t) => e.add(t)), be || Se(e), F?.(Array.from(e));
|
|
11419
|
+
}, Ue = (t) => /* @__PURE__ */ e.createElement("tr", { key: `skeleton-${t}` }, ye && /* @__PURE__ */ e.createElement("td", { className: "pds-table__checkbox-cell" }, /* @__PURE__ */ e.createElement(er, {
|
|
11417
11420
|
shape: "rounded",
|
|
11418
11421
|
size: {
|
|
11419
11422
|
height: 1,
|
|
@@ -11422,119 +11425,122 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11422
11425
|
})), r.map((n) => /* @__PURE__ */ e.createElement("td", { key: `skeleton-${t}-${n.id}` }, /* @__PURE__ */ e.createElement(er, {
|
|
11423
11426
|
shape: "rounded",
|
|
11424
11427
|
size: { height: 1 }
|
|
11425
|
-
})))),
|
|
11428
|
+
})))), We = () => /* @__PURE__ */ e.createElement("tr", null, /* @__PURE__ */ e.createElement("td", {
|
|
11426
11429
|
className: "pds-table__empty-cell",
|
|
11427
|
-
colSpan: r.length + +!!
|
|
11430
|
+
colSpan: r.length + +!!ye
|
|
11428
11431
|
}, f ?? /* @__PURE__ */ e.createElement(Ln, {
|
|
11429
11432
|
heading: m,
|
|
11430
11433
|
iconName: "emptySet",
|
|
11431
11434
|
message: g
|
|
11432
|
-
}))),
|
|
11433
|
-
let i =
|
|
11435
|
+
}))), Ge = (t, n) => {
|
|
11436
|
+
let i = Te(t, n), a = P !== void 0 || H !== void 0, o = a && he === i, s = E(t, i), c = s ? void 0 : x?.(t, i), l = S(t, n + 1), u = c ? `${l} (${c})` : l;
|
|
11434
11437
|
return /* @__PURE__ */ e.createElement("tr", {
|
|
11435
11438
|
key: `row-${i}`,
|
|
11436
11439
|
"aria-selected": a ? o : void 0,
|
|
11437
11440
|
className: Z([
|
|
11438
|
-
a ? `${
|
|
11439
|
-
o ? `${
|
|
11441
|
+
a ? `${re}__row--inspectable` : null,
|
|
11442
|
+
o ? `${re}__row--inspected` : null,
|
|
11440
11443
|
y?.(t, i) ?? null
|
|
11441
11444
|
]),
|
|
11442
|
-
onClick: a ? () =>
|
|
11445
|
+
onClick: a ? () => Oe(t, i) : void 0,
|
|
11443
11446
|
onKeyDown: a ? (e) => {
|
|
11444
|
-
(e.key === "Enter" || e.key === " ") && (e.preventDefault(),
|
|
11447
|
+
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), Oe(t, i));
|
|
11445
11448
|
} : void 0,
|
|
11446
11449
|
tabIndex: a ? 0 : void 0
|
|
11447
|
-
},
|
|
11448
|
-
checked:
|
|
11449
|
-
|
|
11450
|
-
|
|
11451
|
-
|
|
11450
|
+
}, ye && /* @__PURE__ */ e.createElement("td", { className: "pds-table__checkbox-cell" }, /* @__PURE__ */ e.createElement(Cr, {
|
|
11451
|
+
checked: Ce.has(i),
|
|
11452
|
+
disabled: !s,
|
|
11453
|
+
id: `${J}-row-${i}`,
|
|
11454
|
+
inputProps: c ? { title: c } : void 0,
|
|
11455
|
+
label: u,
|
|
11456
|
+
onChange: () => Ve(i),
|
|
11452
11457
|
showLabel: !1
|
|
11453
11458
|
})), r.map((n) => /* @__PURE__ */ e.createElement("td", { key: `${i}-${n.id}` }, t[n.id])));
|
|
11454
|
-
},
|
|
11455
|
-
className: Z(["pds-table-wrapper__content",
|
|
11456
|
-
style:
|
|
11459
|
+
}, Ke = d ? { "--pds-detail-panel-width": d } : void 0, qe = /* @__PURE__ */ e.createElement("div", { className: Z(["pds-table-wrapper", B ? "pds-table-wrapper--in-panel" : null]) }, /* @__PURE__ */ e.createElement("div", {
|
|
11460
|
+
className: Z(["pds-table-wrapper__content", ge ? "pds-table-wrapper__content--panel-open" : null]),
|
|
11461
|
+
style: Ke
|
|
11457
11462
|
}, /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__table-column" }, /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__table-area" }, /* @__PURE__ */ e.createElement("table", {
|
|
11458
|
-
"aria-busy":
|
|
11459
|
-
className: Z([
|
|
11460
|
-
...
|
|
11461
|
-
}, /* @__PURE__ */ e.createElement("thead", null, /* @__PURE__ */ e.createElement("tr", null,
|
|
11462
|
-
checked:
|
|
11463
|
-
id:
|
|
11464
|
-
indeterminate:
|
|
11465
|
-
label:
|
|
11466
|
-
onChange:
|
|
11463
|
+
"aria-busy": T,
|
|
11464
|
+
className: Z([re, t]),
|
|
11465
|
+
...ne
|
|
11466
|
+
}, /* @__PURE__ */ e.createElement("thead", null, /* @__PURE__ */ e.createElement("tr", null, ye && /* @__PURE__ */ e.createElement("th", { className: "pds-table__checkbox-cell" }, /* @__PURE__ */ e.createElement(Cr, {
|
|
11467
|
+
checked: ze,
|
|
11468
|
+
id: J,
|
|
11469
|
+
indeterminate: Be,
|
|
11470
|
+
label: G,
|
|
11471
|
+
onChange: He,
|
|
11467
11472
|
showLabel: !1
|
|
11468
11473
|
})), r.map((t) => /* @__PURE__ */ e.createElement("th", {
|
|
11469
11474
|
key: t.id,
|
|
11470
|
-
"aria-sort": t.sortable ?
|
|
11475
|
+
"aria-sort": t.sortable ? Ie(t.id) : void 0
|
|
11471
11476
|
}, t.sortable ? /* @__PURE__ */ e.createElement("button", {
|
|
11472
|
-
"aria-label":
|
|
11473
|
-
className: `${
|
|
11474
|
-
onClick: () =>
|
|
11477
|
+
"aria-label": C(Yt(t.header)),
|
|
11478
|
+
className: `${re}__sort-button`,
|
|
11479
|
+
onClick: () => Fe(t.id),
|
|
11475
11480
|
type: "button"
|
|
11476
11481
|
}, t.header, /* @__PURE__ */ e.createElement("span", {
|
|
11477
11482
|
"aria-hidden": "true",
|
|
11478
|
-
className: `${
|
|
11479
|
-
}, /* @__PURE__ */ e.createElement("span", { className: Z([`${
|
|
11483
|
+
className: `${re}__sort-icons`
|
|
11484
|
+
}, /* @__PURE__ */ e.createElement("span", { className: Z([`${re}__sort-button-top`, Le(t.id, "top")]) }, /* @__PURE__ */ e.createElement(Q, {
|
|
11480
11485
|
iconName: "caretUp",
|
|
11481
11486
|
size: "m"
|
|
11482
|
-
})), /* @__PURE__ */ e.createElement("span", { className: Z([`${
|
|
11487
|
+
})), /* @__PURE__ */ e.createElement("span", { className: Z([`${re}__sort-button-bottom`, Le(t.id, "bottom")]) }, /* @__PURE__ */ e.createElement(Q, {
|
|
11483
11488
|
iconName: "caretDown",
|
|
11484
11489
|
size: "m"
|
|
11485
|
-
})))) : /* @__PURE__ */ e.createElement("span", null, t.header))))), /* @__PURE__ */ e.createElement("tbody", null,
|
|
11490
|
+
})))) : /* @__PURE__ */ e.createElement("span", null, t.header))))), /* @__PURE__ */ e.createElement("tbody", null, T ? Array.from({ length: O }, (e, t) => Ue(t)) : Pe.length === 0 ? We() : Pe.map((e, t) => Ge(e, t))))), oe && !T && (X || W.length > 0) && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__pagination" }, L && L.length > 0 && /* @__PURE__ */ e.createElement(Bn, {
|
|
11486
11491
|
autoWidth: !0,
|
|
11487
|
-
id:
|
|
11488
|
-
label:
|
|
11489
|
-
onOptionSelect: (e) =>
|
|
11490
|
-
options:
|
|
11492
|
+
id: ie,
|
|
11493
|
+
label: R,
|
|
11494
|
+
onOptionSelect: (e) => ve(Number(e.value)),
|
|
11495
|
+
options: L.map((e) => ({
|
|
11491
11496
|
label: v(e),
|
|
11492
11497
|
value: String(e)
|
|
11493
11498
|
})),
|
|
11494
11499
|
showLabel: !1,
|
|
11495
11500
|
size: "s",
|
|
11496
|
-
value: String(
|
|
11501
|
+
value: String(_e)
|
|
11497
11502
|
}), /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__pagination-controls" }, /* @__PURE__ */ e.createElement(Hi, {
|
|
11498
|
-
currentPage:
|
|
11499
|
-
itemsPerPage:
|
|
11500
|
-
|
|
11501
|
-
|
|
11502
|
-
|
|
11503
|
+
currentPage: X ? i ?? 1 : le,
|
|
11504
|
+
itemsPerPage: _e,
|
|
11505
|
+
labelStrings: z,
|
|
11506
|
+
onPageChange: X ? M : ue,
|
|
11507
|
+
totalItemCount: X ? te ?? 0 : W.length
|
|
11508
|
+
}))), _ && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__footer" }, _)), H && /* @__PURE__ */ e.createElement("div", { className: Z(["pds-table-wrapper__detail-panel", ge ? "pds-table-wrapper__detail-panel--open" : null]) }, /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-upper" }, /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-header" }, c && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-title" }, c), /* @__PURE__ */ e.createElement(tn, {
|
|
11503
11509
|
ariaLabel: n,
|
|
11504
|
-
onClick:
|
|
11510
|
+
onClick: ke,
|
|
11505
11511
|
size: "s"
|
|
11506
|
-
})), /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-content" },
|
|
11507
|
-
rowId:
|
|
11508
|
-
onClose:
|
|
11509
|
-
onPrev:
|
|
11510
|
-
onNext:
|
|
11511
|
-
hasPrev:
|
|
11512
|
-
hasNext:
|
|
11513
|
-
}))),
|
|
11514
|
-
hasNext:
|
|
11515
|
-
hasPrev:
|
|
11516
|
-
onClose:
|
|
11517
|
-
onNext:
|
|
11518
|
-
onPrev:
|
|
11519
|
-
rowId:
|
|
11512
|
+
})), /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-content" }, ge && De && H(De, {
|
|
11513
|
+
rowId: he,
|
|
11514
|
+
onClose: ke,
|
|
11515
|
+
onPrev: Ae,
|
|
11516
|
+
onNext: je,
|
|
11517
|
+
hasPrev: Ee > 0,
|
|
11518
|
+
hasNext: Ee < W.length - 1
|
|
11519
|
+
}))), ge && De && (U || s) && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-footer" }, U ? U(De, {
|
|
11520
|
+
hasNext: Ee < W.length - 1,
|
|
11521
|
+
hasPrev: Ee > 0,
|
|
11522
|
+
onClose: ke,
|
|
11523
|
+
onNext: je,
|
|
11524
|
+
onPrev: Ae,
|
|
11525
|
+
rowId: he
|
|
11520
11526
|
}) : /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-nav" }, /* @__PURE__ */ e.createElement($t, {
|
|
11521
11527
|
hasBorder: !0,
|
|
11522
|
-
ariaLabel:
|
|
11523
|
-
disabled:
|
|
11528
|
+
ariaLabel: V,
|
|
11529
|
+
disabled: Ee <= 0,
|
|
11524
11530
|
iconName: "angleUp",
|
|
11525
|
-
onClick:
|
|
11531
|
+
onClick: Ae,
|
|
11526
11532
|
size: "s",
|
|
11527
11533
|
variant: "standard"
|
|
11528
11534
|
}), /* @__PURE__ */ e.createElement($t, {
|
|
11529
11535
|
hasBorder: !0,
|
|
11530
|
-
ariaLabel:
|
|
11531
|
-
disabled:
|
|
11536
|
+
ariaLabel: k,
|
|
11537
|
+
disabled: Ee >= W.length - 1,
|
|
11532
11538
|
iconName: "angleDown",
|
|
11533
|
-
onClick:
|
|
11539
|
+
onClick: je,
|
|
11534
11540
|
size: "s",
|
|
11535
11541
|
variant: "standard"
|
|
11536
11542
|
}))))));
|
|
11537
|
-
return
|
|
11543
|
+
return B ? /* @__PURE__ */ e.createElement(Ki, { padding: "none" }, qe) : qe;
|
|
11538
11544
|
}, Aa = [
|
|
11539
11545
|
" ",
|
|
11540
11546
|
"/",
|
|
@@ -11869,11 +11875,11 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11869
11875
|
return;
|
|
11870
11876
|
}
|
|
11871
11877
|
N(!M);
|
|
11872
|
-
},
|
|
11878
|
+
}, W = Wa();
|
|
11873
11879
|
l(() => {
|
|
11874
|
-
|
|
11875
|
-
}, [
|
|
11876
|
-
let
|
|
11880
|
+
W === "sm" && !M ? (H.current = !0, S ? S() : N(!0)) : W !== "sm" && H.current && (H.current = !1, S ? S() : N(!1));
|
|
11881
|
+
}, [W]);
|
|
11882
|
+
let G = s(() => {
|
|
11877
11883
|
let e = document.activeElement;
|
|
11878
11884
|
if (!e) return !1;
|
|
11879
11885
|
let t = e.tagName.toLowerCase();
|
|
@@ -11890,15 +11896,15 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11890
11896
|
].includes(t);
|
|
11891
11897
|
}
|
|
11892
11898
|
return e.isContentEditable;
|
|
11893
|
-
}, []),
|
|
11899
|
+
}, []), K = p && c;
|
|
11894
11900
|
Tt("[", (e) => {
|
|
11895
|
-
|
|
11896
|
-
}, { enabled:
|
|
11897
|
-
|
|
11898
|
-
}, { enabled:
|
|
11899
|
-
let
|
|
11901
|
+
G() || (e.preventDefault(), M || U());
|
|
11902
|
+
}, { enabled: K }), Tt("]", (e) => {
|
|
11903
|
+
G() || (e.preventDefault(), M && U());
|
|
11904
|
+
}, { enabled: K });
|
|
11905
|
+
let ee = m(null);
|
|
11900
11906
|
f(() => {
|
|
11901
|
-
let e =
|
|
11907
|
+
let e = ee.current;
|
|
11902
11908
|
if (!e) return;
|
|
11903
11909
|
if (z != null) {
|
|
11904
11910
|
e.style.setProperty("--pds-app-layout-top-offset", z);
|
|
@@ -11916,14 +11922,14 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11916
11922
|
r.disconnect(), i?.disconnect(), window.removeEventListener("resize", t);
|
|
11917
11923
|
};
|
|
11918
11924
|
}, [z]);
|
|
11919
|
-
let q = Le(t), te = q.__unslotted, ne = q.header,
|
|
11925
|
+
let q = Le(t), te = q.__unslotted, ne = q.header, re = q.footer, ie = q.sidebar, J = q.identity, Y = q["content-top"], X = q.navigation, ae = q["content-bottom"], oe = J || Y || X || ae, se = oe ? /* @__PURE__ */ e.createElement(e.Fragment, null, (J || o) && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-identity` }, J, o && !M && /* @__PURE__ */ e.createElement($t, {
|
|
11920
11926
|
hasBorder: !0,
|
|
11921
11927
|
ariaLabel: I.drawerToggle,
|
|
11922
11928
|
className: `${P}__drawer-toggle`,
|
|
11923
11929
|
iconName: "sidebar",
|
|
11924
11930
|
onClick: x,
|
|
11925
11931
|
size: "s"
|
|
11926
|
-
})), Y && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-content-top` }, Y), X && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-navigation` }, X), ae && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-content-bottom` }, ae)) :
|
|
11932
|
+
})), Y && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-content-top` }, Y), X && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-navigation` }, X), ae && /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-content-bottom` }, ae)) : ie, ce = i(v, {
|
|
11927
11933
|
...b,
|
|
11928
11934
|
className: Z([`${P}__main`, b?.className]),
|
|
11929
11935
|
id: L,
|
|
@@ -11938,10 +11944,10 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11938
11944
|
}, te)), le = /* @__PURE__ */ e.createElement("div", {
|
|
11939
11945
|
className: `${P}__content-column`,
|
|
11940
11946
|
style: { backgroundColor: _ || void 0 }
|
|
11941
|
-
}, ce,
|
|
11947
|
+
}, ce, re && /* @__PURE__ */ e.createElement("div", { className: `${P}__footer` }, /* @__PURE__ */ e.createElement("div", {
|
|
11942
11948
|
className: `${P}__footer-inner`,
|
|
11943
11949
|
style: { maxWidth: R }
|
|
11944
|
-
},
|
|
11950
|
+
}, re))), ue = /* @__PURE__ */ e.createElement(e.Fragment, null, (ie || oe) && /* @__PURE__ */ e.createElement("div", {
|
|
11945
11951
|
...k,
|
|
11946
11952
|
className: Z([
|
|
11947
11953
|
`${P}__sidebar`,
|
|
@@ -11970,7 +11976,7 @@ var Sa = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
11970
11976
|
preferredPlacement: "right-end"
|
|
11971
11977
|
}), /* @__PURE__ */ e.createElement("div", { className: `${P}__sidebar-inner` }, se)), le);
|
|
11972
11978
|
return /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("div", {
|
|
11973
|
-
ref:
|
|
11979
|
+
ref: ee,
|
|
11974
11980
|
className: Z([
|
|
11975
11981
|
P,
|
|
11976
11982
|
F,
|