@pantheon-systems/pds-toolkit-react 2.0.0-alpha.91 → 2.0.0-alpha.93
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/components/icons/Icon/generated-icon-data.d.ts +9 -2
- package/dist/components/inputs/Datepicker/Datepicker.d.ts +32 -9
- package/dist/css/layout-css/pds-index.css +1 -1
- package/dist/css/layout-css/pds-stepper-layout.css +1 -1
- package/dist/css/pds-core.css +1 -1
- package/dist/css/pds-layouts.css +1 -1
- package/dist/index.css +1 -1
- package/dist/index.js +593 -542
- package/dist/index.js.map +1 -1
- package/dist/svg/zappy.svg +3 -0
- package/dist/utilities/FlexContainer/FlexContainer.d.ts +69 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import e, { Children as t, Fragment as n, cloneElement as r, createContext as i, createElement as a, forwardRef as o, isValidElement as s, useCallback as c, useContext as l, useEffect as u, useId as d, useImperativeHandle as f, useLayoutEffect as p, useMemo as m, useRef as h, useState as g, useSyncExternalStore as _ } from "react";
|
|
2
|
-
import { FloatingArrow as v, FloatingFocusManager as y, FloatingNode as b, FloatingOverlay as x, FloatingPortal as S, FloatingTree as C, arrow as w, autoUpdate as T, flip as E, offset as D, safePolygon as O, shift as k, size as A, useClick as j, useDismiss as M, useFloating as N, useFloatingNodeId as P, useFloatingParentNodeId as F, useFocus as I, useHover as L, useId as R, useInteractions as z, useListNavigation as
|
|
2
|
+
import { FloatingArrow as v, FloatingFocusManager as y, FloatingNode as b, FloatingOverlay as x, FloatingPortal as S, FloatingTree as C, arrow as w, autoUpdate as T, flip as E, offset as D, safePolygon as O, shift as k, size as A, useClick as j, useDismiss as M, useFloating as N, useFloatingNodeId as P, useFloatingParentNodeId as F, useFocus as I, useHover as L, useId as R, useInteractions as z, useListNavigation as ee, useMergeRefs as B, useRole as V, useTransitionStyles as H, useTypeahead as U } from "@floating-ui/react";
|
|
3
3
|
import { useHotkeys as W } from "react-hotkeys-hook";
|
|
4
|
-
import { Bar as G, BarChart as K, CartesianGrid as q, Cell as te, Line as
|
|
4
|
+
import { Bar as G, BarChart as K, CartesianGrid as q, Cell as te, Line as ne, LineChart as re, Pie as J, PieChart as ie, Rectangle as ae, ReferenceLine as Y, ResponsiveContainer as oe, Tooltip as se, XAxis as ce, YAxis as le } from "recharts";
|
|
5
5
|
import { CodeBlock as ue } from "react-code-block";
|
|
6
6
|
import de from "hash-sum";
|
|
7
7
|
import { useCombobox as fe, useMultipleSelection as pe } from "downshift";
|
|
8
|
-
import { CalendarDate as me, Time as he, createCalendar as ge, endOfMonth as
|
|
8
|
+
import { CalendarDate as me, Time as he, createCalendar as ge, endOfMonth as _e, endOfWeek as ve, fromDate as X, getLocalTimeZone as ye, startOfMonth as be, startOfWeek as xe, toCalendarDateTime as Se, toTimeZone as Ce, toZoned as we, today as Te } from "@internationalized/date";
|
|
9
9
|
import { format as Ee } from "date-fns";
|
|
10
10
|
import { I18nProvider as De, mergeProps as Oe, useButton as ke, useCalendar as Ae, useCalendarCell as je, useCalendarGrid as Me, useDateSegment as Ne, useFocusRing as Pe, useLocale as Fe, useRangeCalendar as Ie, useTimeField as Le } from "react-aria";
|
|
11
11
|
import { useCalendarState as Re, useRangeCalendarState as ze, useTimeFieldState as Be } from "react-stately";
|
|
@@ -124,6 +124,12 @@ var st = Object.create, ct = Object.defineProperty, lt = Object.getOwnPropertyDe
|
|
|
124
124
|
svgPathData: "M289.771 226.425C293.918 226.425 296.703 231.118 295.035 235.301L235.921 413.714L405.679 224.541C409.261 220.543 420.16 208.132 422.713 203.926L511.022 108.127C513.575 103.92 510.832 98.2854 506.239 98.2854H295.649C294.855 98.2854 294.075 98.3754 293.317 98.5481C292.797 98.3779 292.239 98.2854 291.65 98.2854H81.0613C76.4469 98.2854 72.2795 101.323 70.48 106.003L27.4902 217.627C25.8806 221.801 28.6614 226.425 32.7787 226.425H75.183C79.3291 226.425 82.1152 231.118 80.4459 235.301L21.3334 413.714L191.09 224.541C194.672 220.543 205.571 208.132 208.125 203.926L275.507 130.829L242.078 217.627C240.468 221.801 243.249 226.425 247.366 226.425H289.771Z",
|
|
125
125
|
type: "path",
|
|
126
126
|
width: 512
|
|
127
|
+
},
|
|
128
|
+
zappy: {
|
|
129
|
+
height: 512,
|
|
130
|
+
svgPathData: "M0 291.5748L240.7741 0L212.7775 227.4007H373.76L131.586 512L166.5823 291.5748H0Z",
|
|
131
|
+
type: "path",
|
|
132
|
+
width: 374
|
|
127
133
|
}
|
|
128
134
|
}, bt = {
|
|
129
135
|
angleDown: {
|
|
@@ -2384,8 +2390,19 @@ var st = Object.create, ct = Object.defineProperty, lt = Object.getOwnPropertyDe
|
|
|
2384
2390
|
height: 512,
|
|
2385
2391
|
svgPathData: "M549.7 124.1C543.5 100.4 524.9 81.8 501.4 75.5 458.9 64 288.1 64 288.1 64S117.3 64 74.7 75.5C51.2 81.8 32.7 100.4 26.4 124.1 15 167 15 256.4 15 256.4s0 89.4 11.4 132.3c6.3 23.6 24.8 41.5 48.3 47.8 42.6 11.5 213.4 11.5 213.4 11.5s170.8 0 213.4-11.5c23.5-6.3 42-24.2 48.3-47.8 11.4-42.9 11.4-132.3 11.4-132.3s0-89.4-11.4-132.3zM232.2 337.6l0-162.4 142.7 81.2-142.7 81.2z",
|
|
2386
2392
|
width: 576
|
|
2393
|
+
},
|
|
2394
|
+
zappy: {
|
|
2395
|
+
aliases: [
|
|
2396
|
+
"ai",
|
|
2397
|
+
"agent",
|
|
2398
|
+
"bolt"
|
|
2399
|
+
],
|
|
2400
|
+
categories: ["custom", "status"],
|
|
2401
|
+
height: 512,
|
|
2402
|
+
svgPathData: "M0 291.5748L240.7741 0L212.7775 227.4007H373.76L131.586 512L166.5823 291.5748H0Z",
|
|
2403
|
+
width: 374
|
|
2387
2404
|
}
|
|
2388
|
-
}, xt = /* @__PURE__ */ "angleDown.angleLeft.angleRight.anglesDown.anglesLeft.anglesRight.anglesUp.angleUp.arrowDownToLine.arrowDownWideShort.arrowLeft.arrowRight.arrowsRetweet.arrowUpShortWide.asterisk.banBug.bars.barsFilter.barsStaggered.bell.billboard.bitbucket.bluesky.bolt.boltPantheon.boltSolid.book.bookmark.bookmarkSolid.books.box.bracketRight.bracketsSquare.brainCircuit.broomWide.building.buildings.bullhorn.calendarDays.caretDown.caretLeft.caretRight.caretUp.ccAmex.ccApplePay.ccDiscover.ccGeneric.ccMC.ccPaypal.ccVisa.chartLine.chartNetwork.chartSimple.check.circle.circleCheck.circleExclamation.circleExclamationSolid.circleHalfStroke.circleInfo.circleInfoSolid.circleMinus.circleNotch.circlePlus.circleQuestion.circleQuestionSolid.circleUser.circleXmark.claude.clock.cloud.cloudArrowDown.cloudArrowUp.cloudPlus.code.codeBranch.codeMerge.collapseToCenter.command.comment.compress.copy.desktop.diagramVenn.diamondExclamation.diamonds4.discourse.display.dollarSign.download.drupal.ellipsis.ellipsisVertical.emptySet.envelope.envelopeOpen.exclamation.expand.expandFromCenter.externalLink.eye.eyeSlash.facebook.file.fileCheck.fileContract.fileCSV.fileDiff.fileExport.fileImport.fileLines.filePDF.files.fileZip.floppyDisk.folder.folders.folderTree.gear.gem.github.gitlab.globe.graduationCap.grid.grid2.gripDots.gripDotsVertical.heart.heartSolid.house.idCard.image.inputText.instagram.keySkeleton.landmark.laptop.laptopCode.leaf.lifeRing.link.linkedin.list.listCheck.locationCrosshairs.lock.lockOpen.magnifyingGlass.medal.memo.messages.minus.moon.move.nextJs.octagonExclamation.openai.paperclip.paperPlane.pause.pen.penField.penPaintbrush.phone.play.plus.question.quotesLeft.quotesRight.rectangleList.rectanglesMixed.reply.robot.rocketLaunch.rotate.rotateClock.rotateLeft.rotateRight.rss.save.server.shareNodes.shield.shieldQuartered.shovel.sidebar.siren.sirenOn.sitemap.slack.slashForward.slider.slidersSimple.snowflake.sparkles.squareCheck.squareCode.squareDashed.squareMinus.squarePen.squareQuestion.squareTerminal.star.starSolid.sun.sunBright.table.tableColumns.tableRows.terminal.text.threads.thumbsDown.thumbsUp.trash.triangleExclamation.twitter.unlink.upload.user.userAstronaut.userGear.userPlus.users.userSolid.video.wavePulse.windowRestore.wordpress.wreathLaurel.wrench.xmark.xmarkLarge.xTwitter.youtube".split("."), Q = ({ className: t, display: n = "inline-block", iconName: r, size: i = "xl", style: a, verticalAlign: o = "middle", ...s }) => {
|
|
2405
|
+
}, xt = /* @__PURE__ */ "angleDown.angleLeft.angleRight.anglesDown.anglesLeft.anglesRight.anglesUp.angleUp.arrowDownToLine.arrowDownWideShort.arrowLeft.arrowRight.arrowsRetweet.arrowUpShortWide.asterisk.banBug.bars.barsFilter.barsStaggered.bell.billboard.bitbucket.bluesky.bolt.boltPantheon.boltSolid.book.bookmark.bookmarkSolid.books.box.bracketRight.bracketsSquare.brainCircuit.broomWide.building.buildings.bullhorn.calendarDays.caretDown.caretLeft.caretRight.caretUp.ccAmex.ccApplePay.ccDiscover.ccGeneric.ccMC.ccPaypal.ccVisa.chartLine.chartNetwork.chartSimple.check.circle.circleCheck.circleExclamation.circleExclamationSolid.circleHalfStroke.circleInfo.circleInfoSolid.circleMinus.circleNotch.circlePlus.circleQuestion.circleQuestionSolid.circleUser.circleXmark.claude.clock.cloud.cloudArrowDown.cloudArrowUp.cloudPlus.code.codeBranch.codeMerge.collapseToCenter.command.comment.compress.copy.desktop.diagramVenn.diamondExclamation.diamonds4.discourse.display.dollarSign.download.drupal.ellipsis.ellipsisVertical.emptySet.envelope.envelopeOpen.exclamation.expand.expandFromCenter.externalLink.eye.eyeSlash.facebook.file.fileCheck.fileContract.fileCSV.fileDiff.fileExport.fileImport.fileLines.filePDF.files.fileZip.floppyDisk.folder.folders.folderTree.gear.gem.github.gitlab.globe.graduationCap.grid.grid2.gripDots.gripDotsVertical.heart.heartSolid.house.idCard.image.inputText.instagram.keySkeleton.landmark.laptop.laptopCode.leaf.lifeRing.link.linkedin.list.listCheck.locationCrosshairs.lock.lockOpen.magnifyingGlass.medal.memo.messages.minus.moon.move.nextJs.octagonExclamation.openai.paperclip.paperPlane.pause.pen.penField.penPaintbrush.phone.play.plus.question.quotesLeft.quotesRight.rectangleList.rectanglesMixed.reply.robot.rocketLaunch.rotate.rotateClock.rotateLeft.rotateRight.rss.save.server.shareNodes.shield.shieldQuartered.shovel.sidebar.siren.sirenOn.sitemap.slack.slashForward.slider.slidersSimple.snowflake.sparkles.squareCheck.squareCode.squareDashed.squareMinus.squarePen.squareQuestion.squareTerminal.star.starSolid.sun.sunBright.table.tableColumns.tableRows.terminal.text.threads.thumbsDown.thumbsUp.trash.triangleExclamation.twitter.unlink.upload.user.userAstronaut.userGear.userPlus.users.userSolid.video.wavePulse.windowRestore.wordpress.wreathLaurel.wrench.xmark.xmarkLarge.xTwitter.youtube.zappy".split("."), Q = ({ className: t, display: n = "inline-block", iconName: r, size: i = "xl", style: a, verticalAlign: o = "middle", ...s }) => {
|
|
2389
2406
|
let c = "pds-icon", l = `${c} ${c}--${i} ${c}--${r}`, u = bt[r], d = `0 0 ${u.width} ${u.height}`, f = r in yt ? yt[r] : null, p;
|
|
2390
2407
|
if (f?.type === "complex") p = f.render();
|
|
2391
2408
|
else {
|
|
@@ -2529,9 +2546,9 @@ var st = Object.create, ct = Object.defineProperty, lt = Object.getOwnPropertyDe
|
|
|
2529
2546
|
}),
|
|
2530
2547
|
I(C, { enabled: !i }),
|
|
2531
2548
|
M(C),
|
|
2532
|
-
|
|
2549
|
+
V(C, { role: "tooltip" }),
|
|
2533
2550
|
j(C, { enabled: !a && !x })
|
|
2534
|
-
]), { isMounted: F, styles: R } =
|
|
2551
|
+
]), { isMounted: F, styles: R } = H(C, {
|
|
2535
2552
|
duration: {
|
|
2536
2553
|
open: 0,
|
|
2537
2554
|
close: 300
|
|
@@ -3069,7 +3086,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3069
3086
|
let n = t.toLowerCase();
|
|
3070
3087
|
return e.find((e) => (e?.textContent?.trim().toLowerCase() ?? "").startsWith(n));
|
|
3071
3088
|
}, In = ({ allowEscape: e = !1, enableClick: t = !0, enableListNavigation: n = !0, enableShift: r = !0, enableTransition: i = !0, enableTypeahead: a = !1, matchReferenceWidth: o = !1, maxHeightValue: s, offsetValue: c = 0, openOnHover: l = !1, placement: u = "bottom-start", role: d = "menu", selectedIndex: f = null, shiftPadding: p = 24, variant: m = "default", virtual: _ = !1 } = {}) => {
|
|
3072
|
-
let [v, y] = g(!1), [b, x] = g(null), S = h([]), C = P(), w = m === "input", F = w || o, { context: I, floatingStyles: R, refs:
|
|
3089
|
+
let [v, y] = g(!1), [b, x] = g(null), S = h([]), C = P(), w = m === "input", F = w || o, { context: I, floatingStyles: R, refs: B } = N({
|
|
3073
3090
|
nodeId: C,
|
|
3074
3091
|
open: v,
|
|
3075
3092
|
onOpenChange: y,
|
|
@@ -3105,7 +3122,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3105
3122
|
event: "mousedown"
|
|
3106
3123
|
}),
|
|
3107
3124
|
M(I),
|
|
3108
|
-
|
|
3125
|
+
V(I, { role: d }),
|
|
3109
3126
|
L(I, {
|
|
3110
3127
|
enabled: l,
|
|
3111
3128
|
move: !1,
|
|
@@ -3119,7 +3136,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3119
3136
|
blockPointerEvents: !0
|
|
3120
3137
|
})
|
|
3121
3138
|
}),
|
|
3122
|
-
|
|
3139
|
+
ee(I, {
|
|
3123
3140
|
enabled: n,
|
|
3124
3141
|
listRef: S,
|
|
3125
3142
|
activeIndex: b,
|
|
@@ -3129,7 +3146,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3129
3146
|
allowEscape: e,
|
|
3130
3147
|
focusItemOnHover: !_
|
|
3131
3148
|
}),
|
|
3132
|
-
|
|
3149
|
+
U(I, {
|
|
3133
3150
|
enabled: a,
|
|
3134
3151
|
listRef: S,
|
|
3135
3152
|
activeIndex: b,
|
|
@@ -3139,7 +3156,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3139
3156
|
},
|
|
3140
3157
|
findMatch: Fn
|
|
3141
3158
|
})
|
|
3142
|
-
]), { isMounted: q, styles: te } =
|
|
3159
|
+
]), { isMounted: q, styles: te } = H(I, i ? {
|
|
3143
3160
|
duration: {
|
|
3144
3161
|
open: 300,
|
|
3145
3162
|
close: 150
|
|
@@ -3158,7 +3175,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3158
3175
|
isMounted: q,
|
|
3159
3176
|
listRef: S,
|
|
3160
3177
|
nodeId: C,
|
|
3161
|
-
refs:
|
|
3178
|
+
refs: B,
|
|
3162
3179
|
setActiveIndex: x,
|
|
3163
3180
|
setIsOpen: y,
|
|
3164
3181
|
transitionStyles: te
|
|
@@ -3215,7 +3232,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3215
3232
|
}
|
|
3216
3233
|
f?.(M);
|
|
3217
3234
|
}, [M]);
|
|
3218
|
-
let
|
|
3235
|
+
let ee = Zt(), B = o && ee, V = "pds-menu-button", H = w === "navbar", U = H ? "subtle" : w, W = a, [G] = g(`menu-button-${a}`), K = [], q = [];
|
|
3219
3236
|
((e) => {
|
|
3220
3237
|
e.forEach((e) => {
|
|
3221
3238
|
!Hn(e) && !Un(e) && !Gn(e) && q.push(e);
|
|
@@ -3223,9 +3240,9 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3223
3240
|
})(l);
|
|
3224
3241
|
let te = (e) => {
|
|
3225
3242
|
"disabled" in e && e.disabled || ("callback" in e && e.callback && e.callback(e), I(!1));
|
|
3226
|
-
},
|
|
3243
|
+
}, ne = () => {
|
|
3227
3244
|
d && d();
|
|
3228
|
-
},
|
|
3245
|
+
}, re = (t, n, r = "", i = "") => {
|
|
3229
3246
|
let a = W + (r ? `-group-${r}` : "") + "-item-" + (n + 1), o = "id" in t && t.id ? t.id : a;
|
|
3230
3247
|
if (Hn(t)) return /* @__PURE__ */ e.createElement("li", {
|
|
3231
3248
|
key: o,
|
|
@@ -3234,7 +3251,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3234
3251
|
});
|
|
3235
3252
|
if (Un(t)) return /* @__PURE__ */ e.createElement("li", {
|
|
3236
3253
|
key: i || o,
|
|
3237
|
-
className: `pds-dropdown__heading ${
|
|
3254
|
+
className: `pds-dropdown__heading ${V}__listbox-heading`,
|
|
3238
3255
|
id: i || void 0,
|
|
3239
3256
|
role: "presentation"
|
|
3240
3257
|
}, t.label);
|
|
@@ -3263,8 +3280,8 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3263
3280
|
tabIndex: -1,
|
|
3264
3281
|
...n.props,
|
|
3265
3282
|
onClick: () => I(!1)
|
|
3266
|
-
}, /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${
|
|
3267
|
-
} else l = /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${
|
|
3283
|
+
}, /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${V}__item-label` }, s), c));
|
|
3284
|
+
} else l = /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${V}__item-label` }, s), c);
|
|
3268
3285
|
let u = Z([
|
|
3269
3286
|
"pds-dropdown__item",
|
|
3270
3287
|
r ? "pds-dropdown__item--focused" : null,
|
|
@@ -3291,7 +3308,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3291
3308
|
})
|
|
3292
3309
|
}, l);
|
|
3293
3310
|
}
|
|
3294
|
-
},
|
|
3311
|
+
}, J = (t, n) => {
|
|
3295
3312
|
let r = "id" in t && t.id ? t.id : `${W}-accordion-item-${n + 1}`;
|
|
3296
3313
|
if (Hn(t)) return /* @__PURE__ */ e.createElement("li", {
|
|
3297
3314
|
key: r,
|
|
@@ -3300,7 +3317,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3300
3317
|
});
|
|
3301
3318
|
if (Un(t)) return /* @__PURE__ */ e.createElement("li", {
|
|
3302
3319
|
key: r,
|
|
3303
|
-
className: `pds-dropdown__heading ${
|
|
3320
|
+
className: `pds-dropdown__heading ${V}__listbox-heading`,
|
|
3304
3321
|
role: "presentation"
|
|
3305
3322
|
}, t.label);
|
|
3306
3323
|
if (Gn(t)) return /* @__PURE__ */ e.createElement("li", {
|
|
@@ -3327,8 +3344,8 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3327
3344
|
c = /* @__PURE__ */ e.createElement(r, {
|
|
3328
3345
|
tabIndex: -1,
|
|
3329
3346
|
...n.props
|
|
3330
|
-
}, /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${
|
|
3331
|
-
} else c = /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${
|
|
3347
|
+
}, /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${V}__item-label` }, o), s));
|
|
3348
|
+
} else c = /* @__PURE__ */ e.createElement("span", { className: "pds-dropdown__item-label" }, /* @__PURE__ */ e.createElement("span", { className: `${V}__item-label` }, o), s);
|
|
3332
3349
|
return /* @__PURE__ */ e.createElement("li", {
|
|
3333
3350
|
key: r,
|
|
3334
3351
|
"aria-disabled": t.disabled || void 0,
|
|
@@ -3344,8 +3361,8 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3344
3361
|
}, ie = (t) => {
|
|
3345
3362
|
let n = t.filter(Un || Hn), r = n.length > 0, a = Z([
|
|
3346
3363
|
"pds-dropdown__panel",
|
|
3347
|
-
`${
|
|
3348
|
-
i ? `${
|
|
3364
|
+
`${V}__listbox`,
|
|
3365
|
+
i ? `${V}__listbox--icon-only` : null
|
|
3349
3366
|
]), o = 0;
|
|
3350
3367
|
if (r) {
|
|
3351
3368
|
let r = ae(t, n);
|
|
@@ -3371,7 +3388,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3371
3388
|
"aria-labelledby": a || void 0,
|
|
3372
3389
|
role: "group"
|
|
3373
3390
|
}, t.map((e) => {
|
|
3374
|
-
let t =
|
|
3391
|
+
let t = re(e, o, r, a);
|
|
3375
3392
|
return !Hn(e) && !Un(e) && !Gn(e) && o++, t;
|
|
3376
3393
|
}));
|
|
3377
3394
|
}));
|
|
@@ -3388,7 +3405,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3388
3405
|
},
|
|
3389
3406
|
...O()
|
|
3390
3407
|
}, t.map((e) => {
|
|
3391
|
-
let t =
|
|
3408
|
+
let t = re(e, o);
|
|
3392
3409
|
return !Hn(e) && !Un(e) && !Gn(e) && o++, t;
|
|
3393
3410
|
}));
|
|
3394
3411
|
}, ae = (e, t) => {
|
|
@@ -3401,8 +3418,8 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3401
3418
|
label: y.label,
|
|
3402
3419
|
size: oe,
|
|
3403
3420
|
type: y.type
|
|
3404
|
-
})) : c, ce = y ? /* @__PURE__ */ e.createElement("span", { className: `${
|
|
3405
|
-
className: `${
|
|
3421
|
+
})) : c, ce = y ? /* @__PURE__ */ e.createElement("span", { className: `${V}__accordion-label` }, c, /* @__PURE__ */ e.createElement(wn, {
|
|
3422
|
+
className: `${V}__tally`,
|
|
3406
3423
|
label: y.label,
|
|
3407
3424
|
size: "s",
|
|
3408
3425
|
type: y.type
|
|
@@ -3412,7 +3429,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3412
3429
|
"aria-controls": G,
|
|
3413
3430
|
"aria-expanded": M,
|
|
3414
3431
|
"aria-haspopup": "true",
|
|
3415
|
-
className: Z([`${
|
|
3432
|
+
className: Z([`${V}__trigger`, H ? `${V}__trigger--navbar` : null]),
|
|
3416
3433
|
disabled: n,
|
|
3417
3434
|
displayType: "icon-end",
|
|
3418
3435
|
iconName: "angleDown",
|
|
@@ -3422,8 +3439,8 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3422
3439
|
size: _,
|
|
3423
3440
|
statusDot: v,
|
|
3424
3441
|
type: "button",
|
|
3425
|
-
variant:
|
|
3426
|
-
...A({ onClick:
|
|
3442
|
+
variant: U,
|
|
3443
|
+
...A({ onClick: ne })
|
|
3427
3444
|
})), i) {
|
|
3428
3445
|
let t = On(c);
|
|
3429
3446
|
Y = /* @__PURE__ */ e.createElement(Mn, {
|
|
@@ -3432,7 +3449,7 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3432
3449
|
"aria-expanded": M,
|
|
3433
3450
|
"aria-haspopup": "true",
|
|
3434
3451
|
ariaLabel: t,
|
|
3435
|
-
className: `${
|
|
3452
|
+
className: `${V}__trigger ${V}__trigger--icon-only`,
|
|
3436
3453
|
disabled: n,
|
|
3437
3454
|
hasTooltip: !1,
|
|
3438
3455
|
iconName: r,
|
|
@@ -3440,25 +3457,25 @@ var Tn = ({ className: t, componentWidth: n, isLoading: r, loadingText: i = "Loa
|
|
|
3440
3457
|
size: _,
|
|
3441
3458
|
type: "button",
|
|
3442
3459
|
variant: "standard",
|
|
3443
|
-
...A({ onClick:
|
|
3460
|
+
...A({ onClick: ne })
|
|
3444
3461
|
});
|
|
3445
3462
|
}
|
|
3446
|
-
let le = i ? /* @__PURE__ */ e.createElement("span", { className: `${
|
|
3463
|
+
let le = i ? /* @__PURE__ */ e.createElement("span", { className: `${V}__icon-label` }, /* @__PURE__ */ e.createElement(Q, { iconName: r }), " ", c) : ce, ue = M ? `${V}--expanded` : null;
|
|
3447
3464
|
return /* @__PURE__ */ e.createElement("span", {
|
|
3448
3465
|
className: Z([
|
|
3449
|
-
|
|
3466
|
+
V,
|
|
3450
3467
|
ue,
|
|
3451
3468
|
t
|
|
3452
3469
|
]),
|
|
3453
3470
|
"data-testid": x,
|
|
3454
3471
|
...T
|
|
3455
|
-
},
|
|
3472
|
+
}, B ? /* @__PURE__ */ e.createElement(Ln, {
|
|
3456
3473
|
disabled: n,
|
|
3457
3474
|
label: le
|
|
3458
3475
|
}, /* @__PURE__ */ e.createElement("ul", {
|
|
3459
|
-
className: `${
|
|
3476
|
+
className: `${V}__mobile-menu`,
|
|
3460
3477
|
role: "menu"
|
|
3461
|
-
}, l.map((e, t) =>
|
|
3478
|
+
}, l.map((e, t) => J(e, t)))) : /* @__PURE__ */ e.createElement(e.Fragment, null, Y, /* @__PURE__ */ e.createElement(b, { id: P }, j && /* @__PURE__ */ e.createElement(S, null, ie(l)))));
|
|
3462
3479
|
}, Xn = i(null), Zn = () => {
|
|
3463
3480
|
let e = l(Xn);
|
|
3464
3481
|
if (!e) throw Error("Dropdown sub-components must be used within a <Dropdown> provider.");
|
|
@@ -4308,18 +4325,18 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4308
4325
|
}, message: p, onBlur: m, onFocus: h, onOptionSelect: _, options: v, required: y = !1, showLabel: b = !0, showSelectedIcon: x = !0, size: C = "s", tooltipText: w = null, validationMessage: T, validationStatus: E, value: D, ...O }) => {
|
|
4309
4326
|
let k = on(c, l), A = "pds-select", j = t ? `${A}--auto-width` : null, M = C === "s" ? null : `${A}--${C}`, N = i ? $.disabled : null, P = y && !i ? $.required : null, F = E === "error" ? $.error : null, I = E === "success" ? $.success : null, L = null;
|
|
4310
4327
|
E === "error" && (L = "error"), E === "success" && (L = "success");
|
|
4311
|
-
let R = T || p, z = D !== void 0,
|
|
4328
|
+
let R = T || p, z = D !== void 0, ee = r !== void 0, B = ((e) => e.reduce((e, t) => _n(t) ? [...e, ...t.options] : [...e, t], []))(v), V = (e) => B.findIndex((t) => t.value === e), H = z && V(D) >= 0 ? V(D) : null, U = ee ? V(r) : null, [W, G] = g((H || U) ?? null), { activeIndex: K, floatingStyles: q, getFloatingProps: te, getItemProps: ne, getReferenceProps: re, isMounted: J, listRef: ie, refs: ae, setIsOpen: Y, transitionStyles: oe } = In({
|
|
4312
4329
|
enableClick: !i,
|
|
4313
4330
|
enableTypeahead: !0,
|
|
4314
4331
|
role: "listbox",
|
|
4315
4332
|
selectedIndex: W,
|
|
4316
4333
|
variant: "input"
|
|
4317
|
-
}), se = Bn("var(--pds-z-index-dropdown)"), ce = W === null ? void 0 :
|
|
4318
|
-
let t =
|
|
4334
|
+
}), se = Bn("var(--pds-z-index-dropdown)"), ce = W === null ? void 0 : B[W]?.label, le = W === null ? void 0 : B[W]?.icon, ue = W === null ? void 0 : B[W]?.value, de = (e) => {
|
|
4335
|
+
let t = B[e];
|
|
4319
4336
|
z || (G(e), Y(!1)), _ && _(t);
|
|
4320
4337
|
};
|
|
4321
4338
|
u(() => {
|
|
4322
|
-
z && (G(
|
|
4339
|
+
z && (G(V(D)), Y(!1));
|
|
4323
4340
|
}, [D]);
|
|
4324
4341
|
let fe = () => {
|
|
4325
4342
|
m && m(ue);
|
|
@@ -4349,7 +4366,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4349
4366
|
"aria-disabled": t?.disabled,
|
|
4350
4367
|
"aria-selected": r === W && r === K,
|
|
4351
4368
|
tabIndex: r === K ? 0 : -1,
|
|
4352
|
-
...!t?.disabled &&
|
|
4369
|
+
...!t?.disabled && ne({
|
|
4353
4370
|
onClick() {
|
|
4354
4371
|
de(r);
|
|
4355
4372
|
},
|
|
@@ -4373,7 +4390,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4373
4390
|
"aria-disabled": t?.disabled,
|
|
4374
4391
|
"aria-selected": r === W && r === K,
|
|
4375
4392
|
tabIndex: r === K ? 0 : -1,
|
|
4376
|
-
...!t?.disabled &&
|
|
4393
|
+
...!t?.disabled && ne({
|
|
4377
4394
|
onClick() {
|
|
4378
4395
|
de(r);
|
|
4379
4396
|
},
|
|
@@ -4401,7 +4418,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4401
4418
|
}, t && !c && /* @__PURE__ */ e.createElement("div", {
|
|
4402
4419
|
"aria-hidden": "true",
|
|
4403
4420
|
className: `${A}__sizer`
|
|
4404
|
-
},
|
|
4421
|
+
}, B.map((t) => /* @__PURE__ */ e.createElement("span", {
|
|
4405
4422
|
key: t.value,
|
|
4406
4423
|
className: `${A}__input-wrapper`
|
|
4407
4424
|
}, E !== void 0 && /* @__PURE__ */ e.createElement(fn, { variant: "error" }), /* @__PURE__ */ e.createElement("span", { className: `${A}__input-inner` }, /* @__PURE__ */ e.createElement("span", { className: `${A}__option-text` }, t.icon && he(t.icon, `${A}__icon`), t.label), /* @__PURE__ */ e.createElement(Q, {
|
|
@@ -4421,7 +4438,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4421
4438
|
className: `${A}__input-wrapper`,
|
|
4422
4439
|
id: s,
|
|
4423
4440
|
tabIndex: 0,
|
|
4424
|
-
...
|
|
4441
|
+
...re({
|
|
4425
4442
|
onClick: me,
|
|
4426
4443
|
onBlur: fe,
|
|
4427
4444
|
onFocus: pe
|
|
@@ -4429,7 +4446,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4429
4446
|
}, L && /* @__PURE__ */ e.createElement(fn, { variant: L }), /* @__PURE__ */ e.createElement("span", { className: `${A}__input-inner` }, /* @__PURE__ */ e.createElement("span", { className: `${A}__option-text` }, (le || !ce && o) && he(le || o, `${A}__icon`), /* @__PURE__ */ e.createElement("span", { className: `${A}__option-label-text` }, ce ?? f.selectOptionText)), /* @__PURE__ */ e.createElement(Q, {
|
|
4430
4447
|
className: `${A}__trigger-icon`,
|
|
4431
4448
|
iconName: "angleDown"
|
|
4432
|
-
}))),
|
|
4449
|
+
}))), J && /* @__PURE__ */ e.createElement(S, null, /* @__PURE__ */ e.createElement("div", {
|
|
4433
4450
|
ref: ae.setFloating,
|
|
4434
4451
|
className: `pds-dropdown__panel ${A}__dropdown ${a ? `${A}__dropdown--has-footer` : ""}`,
|
|
4435
4452
|
style: {
|
|
@@ -4752,7 +4769,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4752
4769
|
let t = Math.abs(e);
|
|
4753
4770
|
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);
|
|
4754
4771
|
}, Hr = ({ barRadius: t = 2, chartHeight: n, chartWidth: r, className: i, colorPalette: a = "categorical", data: o = [], isLoading: s = !1, isThumbnail: l = !1, labelStrings: d = {}, layout: f = "horizontal", legendVariant: p = "inline", onTimePeriodChange: m, selectedTimePeriod: _, series: v = [], showAccessibleTable: y, showAxisLines: b, showGrid: x, showLegend: S, showTooltip: C, timePeriodOptions: w, tooltipContent: O, variant: A = "stacked", xAxisLabel: j, xAxisTickInterval: M, yAxisDomain: P, yAxisFormatter: F = Vr, yAxisLabel: I, yAxisTickInterval: L, ...R }) => {
|
|
4755
|
-
let { accessibleTableDescription: z = "Bar chart data", emptyStateHeading:
|
|
4772
|
+
let { accessibleTableDescription: z = "Bar chart data", emptyStateHeading: ee = "No data available", emptyStateMessage: B, legendTableHeader: V, loadingLabel: U = "Loading chart data" } = d, W = h(null), te = Er(a, Mr(W, a)), ne = n ?? (l ? 60 : 360), re = r ?? (l ? 60 : void 0), J = x ?? !l, ie = b ?? !l, Y = S ?? !l, ue = C ?? !l, de = y ?? !0, [fe, pe] = g(null), me = h(fe);
|
|
4756
4773
|
fe && (me.current = fe);
|
|
4757
4774
|
let he = h({ getBoundingClientRect: () => ({
|
|
4758
4775
|
bottom: 0,
|
|
@@ -4763,7 +4780,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4763
4780
|
width: 0,
|
|
4764
4781
|
x: 0,
|
|
4765
4782
|
y: 0
|
|
4766
|
-
}) }), { context: ge, floatingStyles:
|
|
4783
|
+
}) }), { context: ge, floatingStyles: _e, refs: ve, update: X } = N({
|
|
4767
4784
|
middleware: [
|
|
4768
4785
|
D(8),
|
|
4769
4786
|
E(),
|
|
@@ -4772,7 +4789,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4772
4789
|
open: !!fe,
|
|
4773
4790
|
placement: "top",
|
|
4774
4791
|
whileElementsMounted: T
|
|
4775
|
-
}), { isMounted: ye, styles: be } =
|
|
4792
|
+
}), { isMounted: ye, styles: be } = H(ge, {
|
|
4776
4793
|
duration: {
|
|
4777
4794
|
close: 150,
|
|
4778
4795
|
open: 150
|
|
@@ -4780,8 +4797,8 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4780
4797
|
initial: { opacity: 0 }
|
|
4781
4798
|
});
|
|
4782
4799
|
u(() => {
|
|
4783
|
-
|
|
4784
|
-
}, [
|
|
4800
|
+
ve.setReference(he.current);
|
|
4801
|
+
}, [ve]), u(() => {
|
|
4785
4802
|
let e = () => pe(null);
|
|
4786
4803
|
return window.addEventListener("scroll", e, !0), () => window.removeEventListener("scroll", e, !0);
|
|
4787
4804
|
}, []);
|
|
@@ -4795,23 +4812,23 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4795
4812
|
width: 0,
|
|
4796
4813
|
x: e.clientX,
|
|
4797
4814
|
y: e.clientY
|
|
4798
|
-
}),
|
|
4799
|
-
}, [
|
|
4815
|
+
}), X();
|
|
4816
|
+
}, [X]), we = c(() => {
|
|
4800
4817
|
pe(null);
|
|
4801
4818
|
}, []);
|
|
4802
4819
|
if (s) return /* @__PURE__ */ e.createElement("div", {
|
|
4803
4820
|
ref: W,
|
|
4804
4821
|
"aria-busy": "true",
|
|
4805
|
-
"aria-label":
|
|
4822
|
+
"aria-label": U,
|
|
4806
4823
|
className: Z([
|
|
4807
4824
|
xe,
|
|
4808
4825
|
`${xe}--loading`,
|
|
4809
4826
|
i ?? ""
|
|
4810
4827
|
]),
|
|
4811
|
-
style: { maxWidth:
|
|
4828
|
+
style: { maxWidth: re },
|
|
4812
4829
|
...R
|
|
4813
4830
|
}, /* @__PURE__ */ e.createElement(Br, {
|
|
4814
|
-
height:
|
|
4831
|
+
height: ne,
|
|
4815
4832
|
legendVariant: p,
|
|
4816
4833
|
showLegend: Y
|
|
4817
4834
|
}));
|
|
@@ -4823,13 +4840,13 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4823
4840
|
i ?? ""
|
|
4824
4841
|
]),
|
|
4825
4842
|
style: {
|
|
4826
|
-
height:
|
|
4827
|
-
maxWidth:
|
|
4843
|
+
height: ne,
|
|
4844
|
+
maxWidth: re
|
|
4828
4845
|
},
|
|
4829
4846
|
...R
|
|
4830
4847
|
}, /* @__PURE__ */ e.createElement(Sr, {
|
|
4831
|
-
heading:
|
|
4832
|
-
message:
|
|
4848
|
+
heading: ee,
|
|
4849
|
+
message: B
|
|
4833
4850
|
}));
|
|
4834
4851
|
let Te = f === "vertical", Ee = (e) => A === "grouped" || A === "stacked" && e === v.length - 1 ? Te ? [
|
|
4835
4852
|
0,
|
|
@@ -4883,7 +4900,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4883
4900
|
return /* @__PURE__ */ e.createElement("div", {
|
|
4884
4901
|
ref: W,
|
|
4885
4902
|
className: Z([xe, i ?? ""]),
|
|
4886
|
-
style:
|
|
4903
|
+
style: re ? { maxWidth: re } : void 0,
|
|
4887
4904
|
...R
|
|
4888
4905
|
}, !l && w && w.length > 0 && /* @__PURE__ */ e.createElement("div", { className: `${xe}__header` }, /* @__PURE__ */ e.createElement(wr, {
|
|
4889
4906
|
autoWidth: !0,
|
|
@@ -4902,12 +4919,12 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4902
4919
|
onMouseMove: ue && !O ? Ce : void 0,
|
|
4903
4920
|
style: {
|
|
4904
4921
|
contain: "layout size",
|
|
4905
|
-
height:
|
|
4922
|
+
height: ne
|
|
4906
4923
|
}
|
|
4907
4924
|
}, /* @__PURE__ */ e.createElement(oe, {
|
|
4908
4925
|
debounce: 150,
|
|
4909
|
-
height:
|
|
4910
|
-
minHeight:
|
|
4926
|
+
height: ne,
|
|
4927
|
+
minHeight: ne,
|
|
4911
4928
|
minWidth: 50,
|
|
4912
4929
|
width: "100%"
|
|
4913
4930
|
}, /* @__PURE__ */ e.createElement(K, {
|
|
@@ -4927,7 +4944,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4927
4944
|
right: 4,
|
|
4928
4945
|
top: 20
|
|
4929
4946
|
}
|
|
4930
|
-
},
|
|
4947
|
+
}, J && /* @__PURE__ */ e.createElement(q, {
|
|
4931
4948
|
horizontal: !Te,
|
|
4932
4949
|
stroke: "var(--pds-color-border-default)",
|
|
4933
4950
|
strokeDasharray: "3 3",
|
|
@@ -4998,11 +5015,11 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
4998
5015
|
shape: A === "stacked" ? De(n) : void 0,
|
|
4999
5016
|
stackId: Se
|
|
5000
5017
|
}))))), ue && !O && ye && me.current && /* @__PURE__ */ e.createElement("div", {
|
|
5001
|
-
ref:
|
|
5018
|
+
ref: ve.setFloating,
|
|
5002
5019
|
className: "recharts-default-tooltip",
|
|
5003
5020
|
role: "tooltip",
|
|
5004
5021
|
style: {
|
|
5005
|
-
...
|
|
5022
|
+
..._e,
|
|
5006
5023
|
...be,
|
|
5007
5024
|
pointerEvents: "none",
|
|
5008
5025
|
zIndex: "var(--pds-z-index-notifications)"
|
|
@@ -5015,7 +5032,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5015
5032
|
data: o,
|
|
5016
5033
|
series: v,
|
|
5017
5034
|
seriesColors: te,
|
|
5018
|
-
tableHeader:
|
|
5035
|
+
tableHeader: V,
|
|
5019
5036
|
valueFormatter: F,
|
|
5020
5037
|
variant: p
|
|
5021
5038
|
}), de && /* @__PURE__ */ e.createElement(Fr, {
|
|
@@ -5030,7 +5047,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5030
5047
|
default: return;
|
|
5031
5048
|
}
|
|
5032
5049
|
}, Wr = ({ 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: m, 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 = Vr, yAxisLabel: k, yAxisTickInterval: A, ...j }) => {
|
|
5033
|
-
let { accessibleTableDescription: M = "Line chart data", emptyStateHeading: N = "No data available", emptyStateMessage: P, legendTableHeader: F, loadingLabel: I = "Loading chart data" } = l, L = h(null), R = Er(a, Mr(L, a)), z = n ?? (c ? 60 : 360),
|
|
5050
|
+
let { accessibleTableDescription: M = "Line chart data", emptyStateHeading: N = "No data available", emptyStateMessage: P, legendTableHeader: F, loadingLabel: I = "Loading chart data" } = l, L = h(null), R = Er(a, Mr(L, a)), z = n ?? (c ? 60 : 360), ee = r ?? (c ? 60 : void 0), B = b ?? !c, V = v ?? !c, H = x ?? !c, U = S ?? !c, W = y ?? !c, G = _ ?? !0, K = "pds-line-chart";
|
|
5034
5051
|
return s ? /* @__PURE__ */ e.createElement("div", {
|
|
5035
5052
|
ref: L,
|
|
5036
5053
|
"aria-busy": "true",
|
|
@@ -5040,12 +5057,12 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5040
5057
|
`${K}--loading`,
|
|
5041
5058
|
i ?? ""
|
|
5042
5059
|
]),
|
|
5043
|
-
style: { maxWidth:
|
|
5060
|
+
style: { maxWidth: ee },
|
|
5044
5061
|
...j
|
|
5045
5062
|
}, /* @__PURE__ */ e.createElement(Br, {
|
|
5046
5063
|
height: z,
|
|
5047
5064
|
legendVariant: u,
|
|
5048
|
-
showLegend:
|
|
5065
|
+
showLegend: H
|
|
5049
5066
|
})) : !o || o.length === 0 ? /* @__PURE__ */ e.createElement("div", {
|
|
5050
5067
|
ref: L,
|
|
5051
5068
|
className: Z([
|
|
@@ -5055,7 +5072,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5055
5072
|
]),
|
|
5056
5073
|
style: {
|
|
5057
5074
|
height: z,
|
|
5058
|
-
maxWidth:
|
|
5075
|
+
maxWidth: ee
|
|
5059
5076
|
},
|
|
5060
5077
|
...j
|
|
5061
5078
|
}, /* @__PURE__ */ e.createElement(Sr, {
|
|
@@ -5064,7 +5081,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5064
5081
|
})) : /* @__PURE__ */ e.createElement("div", {
|
|
5065
5082
|
ref: L,
|
|
5066
5083
|
className: Z([K, i ?? ""]),
|
|
5067
|
-
style:
|
|
5084
|
+
style: ee ? { maxWidth: ee } : void 0,
|
|
5068
5085
|
...j
|
|
5069
5086
|
}, !c && C && C.length > 0 && /* @__PURE__ */ e.createElement("div", { className: `${K}__header` }, /* @__PURE__ */ e.createElement(wr, {
|
|
5070
5087
|
autoWidth: !0,
|
|
@@ -5089,7 +5106,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5089
5106
|
minHeight: z,
|
|
5090
5107
|
minWidth: 50,
|
|
5091
5108
|
width: "100%"
|
|
5092
|
-
}, /* @__PURE__ */ e.createElement(
|
|
5109
|
+
}, /* @__PURE__ */ e.createElement(re, {
|
|
5093
5110
|
accessibilityLayer: !1,
|
|
5094
5111
|
data: o,
|
|
5095
5112
|
margin: c ? {
|
|
@@ -5103,40 +5120,40 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5103
5120
|
right: 4,
|
|
5104
5121
|
top: 20
|
|
5105
5122
|
}
|
|
5106
|
-
},
|
|
5123
|
+
}, B && /* @__PURE__ */ e.createElement(q, {
|
|
5107
5124
|
stroke: "var(--pds-color-border-default)",
|
|
5108
5125
|
strokeDasharray: "3 3"
|
|
5109
5126
|
}), /* @__PURE__ */ e.createElement(ce, {
|
|
5110
|
-
axisLine:
|
|
5127
|
+
axisLine: V,
|
|
5111
5128
|
dataKey: "label",
|
|
5112
|
-
hide: !
|
|
5129
|
+
hide: !V,
|
|
5113
5130
|
interval: E,
|
|
5114
|
-
label: T &&
|
|
5131
|
+
label: T && V ? {
|
|
5115
5132
|
...Pr,
|
|
5116
5133
|
offset: -15,
|
|
5117
5134
|
position: "insideBottom",
|
|
5118
5135
|
value: T
|
|
5119
5136
|
} : void 0,
|
|
5120
|
-
tick:
|
|
5137
|
+
tick: V ? Nr : !1,
|
|
5121
5138
|
tickLine: !1,
|
|
5122
5139
|
tickMargin: 10
|
|
5123
5140
|
}), /* @__PURE__ */ e.createElement(le, {
|
|
5124
|
-
axisLine:
|
|
5141
|
+
axisLine: V,
|
|
5125
5142
|
domain: D,
|
|
5126
|
-
hide: !
|
|
5143
|
+
hide: !V,
|
|
5127
5144
|
interval: A,
|
|
5128
|
-
label: k &&
|
|
5145
|
+
label: k && V ? {
|
|
5129
5146
|
...Pr,
|
|
5130
5147
|
angle: -90,
|
|
5131
5148
|
dx: -44,
|
|
5132
5149
|
position: "center",
|
|
5133
5150
|
value: k
|
|
5134
5151
|
} : void 0,
|
|
5135
|
-
tick:
|
|
5152
|
+
tick: V ? Nr : !1,
|
|
5136
5153
|
tickFormatter: O,
|
|
5137
5154
|
tickLine: !1,
|
|
5138
5155
|
tickMargin: 6
|
|
5139
|
-
}),
|
|
5156
|
+
}), U && /* @__PURE__ */ e.createElement(se, { content: (t) => {
|
|
5140
5157
|
if (!t.active || !t.payload?.length) return null;
|
|
5141
5158
|
let n = t.payload.map((e) => ({
|
|
5142
5159
|
color: String(e.color ?? ""),
|
|
@@ -5154,7 +5171,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5154
5171
|
className: "recharts-tooltip-item__color",
|
|
5155
5172
|
style: { backgroundColor: t.color }
|
|
5156
5173
|
}), t.name, /* @__PURE__ */ e.createElement("span", { className: "recharts-tooltip-item-separator" }, " ", ":", " "), O(t.value))));
|
|
5157
|
-
} }), g.map((t, n) => /* @__PURE__ */ e.createElement(
|
|
5174
|
+
} }), g.map((t, n) => /* @__PURE__ */ e.createElement(ne, {
|
|
5158
5175
|
key: t.dataKey,
|
|
5159
5176
|
activeDot: W ? { r: 6 } : !1,
|
|
5160
5177
|
dataKey: t.dataKey,
|
|
@@ -5208,7 +5225,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5208
5225
|
strokeDasharray: Ur(t.strokeStyle ?? "dashed"),
|
|
5209
5226
|
x: t.atLabel
|
|
5210
5227
|
});
|
|
5211
|
-
})))),
|
|
5228
|
+
})))), H && /* @__PURE__ */ e.createElement(Ir, {
|
|
5212
5229
|
ariaHidden: u === "table" && G,
|
|
5213
5230
|
data: o,
|
|
5214
5231
|
series: g,
|
|
@@ -5305,7 +5322,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5305
5322
|
minHeight: w,
|
|
5306
5323
|
minWidth: 50,
|
|
5307
5324
|
width: "100%"
|
|
5308
|
-
}, /* @__PURE__ */ e.createElement(ie, { accessibilityLayer: !1 }, /* @__PURE__ */ e.createElement(
|
|
5325
|
+
}, /* @__PURE__ */ e.createElement(ie, { accessibilityLayer: !1 }, /* @__PURE__ */ e.createElement(J, {
|
|
5309
5326
|
cx: "50%",
|
|
5310
5327
|
cy: "50%",
|
|
5311
5328
|
data: A,
|
|
@@ -5364,7 +5381,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5364
5381
|
width: 0,
|
|
5365
5382
|
x: 0,
|
|
5366
5383
|
y: 0
|
|
5367
|
-
}) }), { context:
|
|
5384
|
+
}) }), { context: ee, floatingStyles: B, refs: V, update: U } = N({
|
|
5368
5385
|
middleware: [
|
|
5369
5386
|
D(8),
|
|
5370
5387
|
E(),
|
|
@@ -5373,7 +5390,7 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5373
5390
|
open: !!I,
|
|
5374
5391
|
placement: "top",
|
|
5375
5392
|
whileElementsMounted: T
|
|
5376
|
-
}), { isMounted: W, styles: G } =
|
|
5393
|
+
}), { isMounted: W, styles: G } = H(ee, {
|
|
5377
5394
|
duration: {
|
|
5378
5395
|
close: 150,
|
|
5379
5396
|
open: 150
|
|
@@ -5381,8 +5398,8 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5381
5398
|
initial: { opacity: 0 }
|
|
5382
5399
|
});
|
|
5383
5400
|
u(() => {
|
|
5384
|
-
|
|
5385
|
-
}, [
|
|
5401
|
+
V.setReference(z.current);
|
|
5402
|
+
}, [V]);
|
|
5386
5403
|
let K = c((e) => {
|
|
5387
5404
|
z.current.getBoundingClientRect = () => ({
|
|
5388
5405
|
bottom: e.clientY,
|
|
@@ -5393,8 +5410,8 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5393
5410
|
width: 0,
|
|
5394
5411
|
x: e.clientX,
|
|
5395
5412
|
y: e.clientY
|
|
5396
|
-
}),
|
|
5397
|
-
}, [
|
|
5413
|
+
}), U();
|
|
5414
|
+
}, [U]), q = c(() => {
|
|
5398
5415
|
L(null);
|
|
5399
5416
|
}, []);
|
|
5400
5417
|
return o ? /* @__PURE__ */ e.createElement("div", {
|
|
@@ -5452,11 +5469,11 @@ var cr = ({ className: t = "pds-dropdown__selected-icon" }) => /* @__PURE__ */ e
|
|
|
5452
5469
|
}
|
|
5453
5470
|
});
|
|
5454
5471
|
})), M && W && R.current && /* @__PURE__ */ e.createElement("div", {
|
|
5455
|
-
ref:
|
|
5472
|
+
ref: V.setFloating,
|
|
5456
5473
|
className: "recharts-default-tooltip",
|
|
5457
5474
|
role: "tooltip",
|
|
5458
5475
|
style: {
|
|
5459
|
-
...
|
|
5476
|
+
...B,
|
|
5460
5477
|
...G,
|
|
5461
5478
|
pointerEvents: "none",
|
|
5462
5479
|
zIndex: "var(--pds-z-index-notifications)"
|
|
@@ -7053,9 +7070,9 @@ var Zr = {
|
|
|
7053
7070
|
title: x ? o : void 0
|
|
7054
7071
|
}, o)));
|
|
7055
7072
|
}, fi = o(({ checked: t, className: n, defaultChecked: r, disabled: i, id: a, indeterminate: o, inputProps: s, inputWidth: l, inputWidthMin: u, label: d, message: f, name: p, nestingLevel: m = 0, onBlur: h, onChange: _, onFocus: v, required: y, showLabel: b = !0, size: x = "s", validationMessage: S, validationStatus: C, value: w, ...T }, E) => {
|
|
7056
|
-
let D = on(l, u), O = "pds-checkbox", k = i ? $.disabled : null, A = C === "error" ? $.error : null, j = m > 0 ? `${O}--indent-${m}` : null, M = y && !i ? $.required : null, N = x === "s" ? null : `${O}--${x}`, P = C === "success" ? $.success : null, F = S || f, I = t !== void 0, [L, R] = g(r === void 0 ? !1 : r), z = t || L,
|
|
7073
|
+
let D = on(l, u), O = "pds-checkbox", k = i ? $.disabled : null, A = C === "error" ? $.error : null, j = m > 0 ? `${O}--indent-${m}` : null, M = y && !i ? $.required : null, N = x === "s" ? null : `${O}--${x}`, P = C === "success" ? $.success : null, F = S || f, I = t !== void 0, [L, R] = g(r === void 0 ? !1 : r), z = t || L, ee = (e) => {
|
|
7057
7074
|
I || R(e.target.checked), _ && _(e);
|
|
7058
|
-
},
|
|
7075
|
+
}, B = `${O}__box`, V = o ? null : z ? `${B}--checked` : null, H = o ? `${B}--indeterminate` : null, U = c(() => {
|
|
7059
7076
|
if (o) return /* @__PURE__ */ e.createElement("svg", {
|
|
7060
7077
|
"aria-hidden": "true",
|
|
7061
7078
|
className: `${O}__icon ${O}__icon--indeterminate`,
|
|
@@ -7106,7 +7123,7 @@ var Zr = {
|
|
|
7106
7123
|
"aria-invalid": C === "error" ? !0 : null,
|
|
7107
7124
|
disabled: i,
|
|
7108
7125
|
onBlur: h,
|
|
7109
|
-
onChange:
|
|
7126
|
+
onChange: ee,
|
|
7110
7127
|
onFocus: v,
|
|
7111
7128
|
required: y,
|
|
7112
7129
|
...s
|
|
@@ -7114,10 +7131,10 @@ var Zr = {
|
|
|
7114
7131
|
className: `${O}__label`,
|
|
7115
7132
|
htmlFor: a
|
|
7116
7133
|
}, /* @__PURE__ */ e.createElement("div", { className: Z([
|
|
7134
|
+
B,
|
|
7117
7135
|
V,
|
|
7118
|
-
H
|
|
7119
|
-
|
|
7120
|
-
]) }, /* @__PURE__ */ e.createElement(ee, null)), /* @__PURE__ */ e.createElement("div", { className: Z([`${O}__label-text`, b ? "" : "visually-hidden"]) }, d, " ", y && !i && /* @__PURE__ */ e.createElement(cn, null)))), F && /* @__PURE__ */ e.createElement(un, {
|
|
7136
|
+
H
|
|
7137
|
+
]) }, /* @__PURE__ */ e.createElement(U, null)), /* @__PURE__ */ e.createElement("div", { className: Z([`${O}__label-text`, b ? "" : "visually-hidden"]) }, d, " ", y && !i && /* @__PURE__ */ e.createElement(cn, null)))), F && /* @__PURE__ */ e.createElement(un, {
|
|
7121
7138
|
validationMessageHasDecorators: !0,
|
|
7122
7139
|
hasValidationMessage: !!S,
|
|
7123
7140
|
id: a,
|
|
@@ -7229,16 +7246,16 @@ var Zr = {
|
|
|
7229
7246
|
inputInstructions: "Type to search options",
|
|
7230
7247
|
searchShortcut: "Press / to focus the search field",
|
|
7231
7248
|
triggerButton: "Toggle dropdown menu"
|
|
7232
|
-
}, loadingText: b = "Loading results...", message: x, noResultsText: C = "No results found", onBlur: w, onChange: O, onClear: k, onFocus: j, onOptionSelect: M, options: P, placeholder: F, required: I = !1, showLabel: L = !0, showUnfilteredOptions: R = !1, size: z = "s", tooltipText:
|
|
7233
|
-
let K = on(f, p), q = "pds-combobox", te = z === "s" ? null : `${q}--${z}`,
|
|
7234
|
-
s && (ae = "search"),
|
|
7235
|
-
let Y =
|
|
7249
|
+
}, loadingText: b = "Loading results...", message: x, noResultsText: C = "No results found", onBlur: w, onChange: O, onClear: k, onFocus: j, onOptionSelect: M, options: P, placeholder: F, required: I = !1, showLabel: L = !0, showUnfilteredOptions: R = !1, size: z = "s", tooltipText: ee = null, validationMessage: B, validationStatus: V, value: U, ...W }, G) => {
|
|
7250
|
+
let K = on(f, p), q = "pds-combobox", te = z === "s" ? null : `${q}--${z}`, ne = r ? $.disabled : null, re = I && !r ? $.required : null, J = V === "error" ? $.error : null, ie = V === "success" ? $.success : null, ae = null;
|
|
7251
|
+
s && (ae = "search"), V === "error" && (ae = "error"), V === "success" && (ae = "success");
|
|
7252
|
+
let Y = B || x, oe = U !== void 0, se = n !== void 0, ce = (e) => {
|
|
7236
7253
|
let t = P.find((t) => t.value === e);
|
|
7237
7254
|
return t ? t.label : "";
|
|
7238
|
-
}, [le, ue] = g(se ? n : void 0), [de, pe] = g(oe ?
|
|
7255
|
+
}, [le, ue] = g(se ? n : void 0), [de, pe] = g(oe ? U ?? "" : se ? ce(n) : ""), me = l && !de;
|
|
7239
7256
|
u(() => {
|
|
7240
|
-
oe && pe(
|
|
7241
|
-
}, [oe,
|
|
7257
|
+
oe && pe(U ?? "");
|
|
7258
|
+
}, [oe, U]);
|
|
7242
7259
|
let he = h(null), ge = (e) => e.map(({ label: e, optionDisplay: t, searchIndex: n, value: r, ...i }) => {
|
|
7243
7260
|
let a = r || e, o = [e, r];
|
|
7244
7261
|
return n && o.push(...n), {
|
|
@@ -7248,7 +7265,7 @@ var Zr = {
|
|
|
7248
7265
|
optionDisplay: t,
|
|
7249
7266
|
...i
|
|
7250
7267
|
};
|
|
7251
|
-
}),
|
|
7268
|
+
}), _e = m(() => {
|
|
7252
7269
|
let e = ge(P);
|
|
7253
7270
|
if (!de && !R) return [];
|
|
7254
7271
|
let t = (de ?? "").toLowerCase();
|
|
@@ -7257,10 +7274,10 @@ var Zr = {
|
|
|
7257
7274
|
P,
|
|
7258
7275
|
de,
|
|
7259
7276
|
R
|
|
7260
|
-
]), { getInputProps:
|
|
7277
|
+
]), { getInputProps: ve, getItemProps: X, getMenuProps: ye, highlightedIndex: be, isOpen: xe, openMenu: Se, reset: Ce } = fe({
|
|
7261
7278
|
id: d,
|
|
7262
7279
|
inputId: `input-${d}`,
|
|
7263
|
-
items:
|
|
7280
|
+
items: _e,
|
|
7264
7281
|
itemToString: (e) => e ? e.label : "",
|
|
7265
7282
|
inputValue: de,
|
|
7266
7283
|
onInputValueChange: ({ inputValue: e }) => {
|
|
@@ -7310,7 +7327,7 @@ var Zr = {
|
|
|
7310
7327
|
}
|
|
7311
7328
|
})
|
|
7312
7329
|
]
|
|
7313
|
-
}), { isMounted: De, styles: Oe } =
|
|
7330
|
+
}), { isMounted: De, styles: Oe } = H(we, {
|
|
7314
7331
|
duration: {
|
|
7315
7332
|
open: 300,
|
|
7316
7333
|
close: 150
|
|
@@ -7328,10 +7345,10 @@ var Zr = {
|
|
|
7328
7345
|
w?.(le);
|
|
7329
7346
|
}, Pe = (e) => {
|
|
7330
7347
|
R && Se(), j?.(le);
|
|
7331
|
-
}, Fe = () =>
|
|
7348
|
+
}, Fe = () => _e.map((t, n) => /* @__PURE__ */ e.createElement(vn, {
|
|
7332
7349
|
key: t.value,
|
|
7333
7350
|
className: be === n ? "pds-dropdown__item--focused" : "",
|
|
7334
|
-
...
|
|
7351
|
+
...X({
|
|
7335
7352
|
item: t,
|
|
7336
7353
|
index: n
|
|
7337
7354
|
})
|
|
@@ -7341,9 +7358,9 @@ var Zr = {
|
|
|
7341
7358
|
$.base,
|
|
7342
7359
|
q,
|
|
7343
7360
|
te,
|
|
7344
|
-
J,
|
|
7345
7361
|
ne,
|
|
7346
7362
|
re,
|
|
7363
|
+
J,
|
|
7347
7364
|
ie,
|
|
7348
7365
|
t ?? ""
|
|
7349
7366
|
]),
|
|
@@ -7355,12 +7372,12 @@ var Zr = {
|
|
|
7355
7372
|
label: v,
|
|
7356
7373
|
required: I,
|
|
7357
7374
|
showLabel: L,
|
|
7358
|
-
tooltipText:
|
|
7375
|
+
tooltipText: ee
|
|
7359
7376
|
}), /* @__PURE__ */ e.createElement("span", {
|
|
7360
7377
|
ref: Ae,
|
|
7361
7378
|
"aria-describedby": Y ? `${d}__message` : null,
|
|
7362
7379
|
"aria-disabled": r ? !0 : null,
|
|
7363
|
-
"aria-invalid":
|
|
7380
|
+
"aria-invalid": V === "error" ? !0 : null,
|
|
7364
7381
|
"aria-required": I ? !0 : null,
|
|
7365
7382
|
className: Z([`${q}__input-wrapper`, me ? `${q}__input-wrapper--has-search-shortcut` : null]),
|
|
7366
7383
|
id: d
|
|
@@ -7369,7 +7386,7 @@ var Zr = {
|
|
|
7369
7386
|
autoComplete: "off",
|
|
7370
7387
|
className: `${q}__input`,
|
|
7371
7388
|
id: `input-${d}`,
|
|
7372
|
-
...
|
|
7389
|
+
...ve({
|
|
7373
7390
|
"aria-label": y.inputInstructions,
|
|
7374
7391
|
disabled: r,
|
|
7375
7392
|
placeholder: F,
|
|
@@ -7405,19 +7422,19 @@ var Zr = {
|
|
|
7405
7422
|
...Oe,
|
|
7406
7423
|
zIndex: ke
|
|
7407
7424
|
} : { display: "none" }
|
|
7408
|
-
}, De && _ && /* @__PURE__ */ e.createElement("div", { className: `${q}__loading` }, b), De && !_ &&
|
|
7425
|
+
}, De && _ && /* @__PURE__ */ e.createElement("div", { className: `${q}__loading` }, b), De && !_ && _e.length === 0 && /* @__PURE__ */ e.createElement("div", { className: "pds-dropdown__no-results" }, C), /* @__PURE__ */ e.createElement("ul", {
|
|
7409
7426
|
className: `${q}__options`,
|
|
7410
7427
|
...ye(),
|
|
7411
|
-
style: De && (i || !_ &&
|
|
7428
|
+
style: De && (i || !_ && _e.length > 0) ? void 0 : { display: "none" }
|
|
7412
7429
|
}, De && !_ && Fe(), De && i && /* @__PURE__ */ e.createElement("li", {
|
|
7413
7430
|
className: "pds-dropdown__footer",
|
|
7414
7431
|
role: "presentation"
|
|
7415
7432
|
}, i)))), Y && /* @__PURE__ */ e.createElement(un, {
|
|
7416
|
-
hasValidationMessage: !!
|
|
7433
|
+
hasValidationMessage: !!B,
|
|
7417
7434
|
id: d,
|
|
7418
7435
|
message: Y,
|
|
7419
7436
|
validationMessageHasDecorators: !1,
|
|
7420
|
-
validationStatus:
|
|
7437
|
+
validationStatus: V
|
|
7421
7438
|
}));
|
|
7422
7439
|
}), gi = (e, t, n) => {
|
|
7423
7440
|
let r = n.toLowerCase();
|
|
@@ -7433,24 +7450,24 @@ var Zr = {
|
|
|
7433
7450
|
inputInstructions: "Type to search options",
|
|
7434
7451
|
triggerButton: "Toggle dropdown menu"
|
|
7435
7452
|
}, loadingText: f = "Loading results...", noResultsText: p = "No results found", onChange: _, options: v, placeholder: y = "Filter", required: b = !1, showAllTags: x = !1, showLabel: C = !0, size: w = "s", ...O }) => {
|
|
7436
|
-
let k = on(s, c), j = "pds-combobox-multi", P = w === "s" ? null : `${j}--${w}`, F = r ? $.disabled : null, I = b && !r ? $.required : null, L = x ? `${j}--show-all-tags` : null, [R,
|
|
7453
|
+
let k = on(s, c), j = "pds-combobox-multi", P = w === "s" ? null : `${j}--${w}`, F = r ? $.disabled : null, I = b && !r ? $.required : null, L = x ? `${j}--show-all-tags` : null, [R, ee] = g(""), [V, H] = g(o), [U, W] = g(null), [G, K] = g(!1), q = m(() => gi(v, V, R), [
|
|
7437
7454
|
v,
|
|
7438
|
-
|
|
7455
|
+
V,
|
|
7439
7456
|
R
|
|
7440
7457
|
]), te = m(() => t?.items?.map((e) => ({
|
|
7441
7458
|
...e,
|
|
7442
|
-
isAlreadySelected:
|
|
7443
|
-
})) || [], [t?.items,
|
|
7444
|
-
|
|
7445
|
-
}, { getDropdownProps:
|
|
7446
|
-
selectedItems:
|
|
7459
|
+
isAlreadySelected: V.some((t) => t.id === e.id)
|
|
7460
|
+
})) || [], [t?.items, V]), ne = (e) => {
|
|
7461
|
+
H(e), _?.(e);
|
|
7462
|
+
}, { getDropdownProps: re, getSelectedItemProps: J, removeSelectedItem: ie } = pe({
|
|
7463
|
+
selectedItems: V,
|
|
7447
7464
|
onStateChange: ({ selectedItems: e, type: t }) => {
|
|
7448
7465
|
if (!r) switch (t) {
|
|
7449
7466
|
case pe.stateChangeTypes.SelectedItemKeyDownBackspace:
|
|
7450
7467
|
case pe.stateChangeTypes.SelectedItemKeyDownDelete:
|
|
7451
7468
|
case pe.stateChangeTypes.DropdownKeyDownBackspace:
|
|
7452
7469
|
case pe.stateChangeTypes.FunctionRemoveSelectedItem:
|
|
7453
|
-
|
|
7470
|
+
ne(e || []);
|
|
7454
7471
|
break;
|
|
7455
7472
|
default: break;
|
|
7456
7473
|
}
|
|
@@ -7478,10 +7495,10 @@ var Zr = {
|
|
|
7478
7495
|
case fe.stateChangeTypes.InputKeyDownEnter:
|
|
7479
7496
|
case fe.stateChangeTypes.ItemClick:
|
|
7480
7497
|
case fe.stateChangeTypes.InputBlur:
|
|
7481
|
-
n && (n.isAlreadySelected ?
|
|
7498
|
+
n && (n.isAlreadySelected ? ne(V.filter((e) => e.id !== n.id)) : ne([...V, n]), ee(""), W(null));
|
|
7482
7499
|
break;
|
|
7483
7500
|
case fe.stateChangeTypes.InputChange:
|
|
7484
|
-
|
|
7501
|
+
ee(e || ""), W(null);
|
|
7485
7502
|
break;
|
|
7486
7503
|
case fe.stateChangeTypes.ToggleButtonClick:
|
|
7487
7504
|
case fe.stateChangeTypes.FunctionOpenMenu:
|
|
@@ -7513,7 +7530,7 @@ var Zr = {
|
|
|
7513
7530
|
}
|
|
7514
7531
|
})
|
|
7515
7532
|
]
|
|
7516
|
-
}), { context:
|
|
7533
|
+
}), { context: _e, floatingStyles: ve, refs: X } = N({
|
|
7517
7534
|
open: G,
|
|
7518
7535
|
onOpenChange: K,
|
|
7519
7536
|
whileElementsMounted: T,
|
|
@@ -7526,33 +7543,33 @@ var Zr = {
|
|
|
7526
7543
|
Object.assign(e.floating.style, { width: `${t.reference.width}px` });
|
|
7527
7544
|
} })
|
|
7528
7545
|
]
|
|
7529
|
-
}), { getFloatingProps: ye } = z([M(
|
|
7546
|
+
}), { getFloatingProps: ye } = z([M(_e)]), be = Bn("var(--pds-z-index-dropdown)"), xe = (e) => {
|
|
7530
7547
|
if (e.stopPropagation(), r) return;
|
|
7531
7548
|
let t = !G;
|
|
7532
7549
|
K(t), t && ue && ae();
|
|
7533
7550
|
}, Se = (e) => {
|
|
7534
|
-
r || (e.isAlreadySelected ?
|
|
7551
|
+
r || (e.isAlreadySelected ? ne(V.filter((t) => t.id !== e.id)) : ne([...V, e]));
|
|
7535
7552
|
}, Ce = () => {
|
|
7536
7553
|
K(!1), t?.onClose?.();
|
|
7537
7554
|
}, we = () => {
|
|
7538
7555
|
t?.onRefresh?.();
|
|
7539
7556
|
}, Te = () => {
|
|
7540
|
-
if (
|
|
7557
|
+
if (U === null) W(V.length - 1);
|
|
7541
7558
|
else {
|
|
7542
|
-
let e = [...
|
|
7543
|
-
e.splice(
|
|
7559
|
+
let e = [...V];
|
|
7560
|
+
e.splice(U, 1), ne(e), W(null);
|
|
7544
7561
|
}
|
|
7545
7562
|
}, Ee = h(!1), De = () => {
|
|
7546
7563
|
r || (Ee.current ? ae() : de());
|
|
7547
7564
|
}, Oe = (e) => {
|
|
7548
7565
|
Ee.current = ue, !r && e.currentTarget.setAttribute("data-focus-method", "mouse");
|
|
7549
7566
|
}, ke = (e) => {
|
|
7550
|
-
e.currentTarget.setAttribute("data-focus-method", "keyboard"), !r && ((e.key === "Backspace" || e.key === "Delete") && !R &&
|
|
7567
|
+
e.currentTarget.setAttribute("data-focus-method", "keyboard"), !r && ((e.key === "Backspace" || e.key === "Delete") && !R && V.length > 0 && (e.preventDefault(), Te()), e.key === "Enter" && U !== null && (e.preventDefault(), Te()), !ue && (e.key === "Enter" || e.key === "ArrowDown") && (e.preventDefault(), de()));
|
|
7551
7568
|
}, Ae = Y({
|
|
7552
|
-
...
|
|
7569
|
+
...re({ preventKeyAction: ue }),
|
|
7553
7570
|
disabled: r,
|
|
7554
7571
|
onKeyDown: ke
|
|
7555
|
-
}), je =
|
|
7572
|
+
}), je = V.length === 2 ? /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-item` }, V.length - 1) : V.length === 3 ? /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-layer` }), /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-item` }, V.length - 1)) : V.length > 3 ? /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-layer` }), /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-layer` }), /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-item` }, V.length - 1)) : "", Me = re(), Ne = B([Me.ref, ge.setFloating]);
|
|
7556
7573
|
return /* @__PURE__ */ e.createElement("div", {
|
|
7557
7574
|
className: Z([
|
|
7558
7575
|
$.base,
|
|
@@ -7573,7 +7590,7 @@ var Zr = {
|
|
|
7573
7590
|
showLabel: C
|
|
7574
7591
|
}), /* @__PURE__ */ e.createElement("div", {
|
|
7575
7592
|
ref: (e) => {
|
|
7576
|
-
ge.setReference(e),
|
|
7593
|
+
ge.setReference(e), X.setReference(e);
|
|
7577
7594
|
},
|
|
7578
7595
|
"aria-disabled": r ? !0 : null,
|
|
7579
7596
|
"aria-required": b ? !0 : null,
|
|
@@ -7582,13 +7599,13 @@ var Zr = {
|
|
|
7582
7599
|
onKeyDown: ke,
|
|
7583
7600
|
onMouseDown: Oe,
|
|
7584
7601
|
tabIndex: r ? -1 : 0
|
|
7585
|
-
},
|
|
7602
|
+
}, V.length > 1 && !x && /* @__PURE__ */ e.createElement("div", { className: `${j}__counter` }, /* @__PURE__ */ e.createElement("span", { className: `${j}__counter-wrapper` }, je)), V.length > 0 && /* @__PURE__ */ e.createElement("div", { className: `${j}__items-wrapper` }, V.map((t, n) => /* @__PURE__ */ e.createElement("span", {
|
|
7586
7603
|
key: `selected-item-${n}`,
|
|
7587
7604
|
className: `
|
|
7588
7605
|
${j}__selected-item
|
|
7589
|
-
${n ===
|
|
7606
|
+
${n === U ? `${j}__selected-item--marked-for-deletion` : ""}
|
|
7590
7607
|
`,
|
|
7591
|
-
...
|
|
7608
|
+
...J({
|
|
7592
7609
|
selectedItem: t,
|
|
7593
7610
|
index: n
|
|
7594
7611
|
}),
|
|
@@ -7663,10 +7680,10 @@ var Zr = {
|
|
|
7663
7680
|
className: "pds-dropdown__footer",
|
|
7664
7681
|
role: "presentation"
|
|
7665
7682
|
}, i)))), G && t && /* @__PURE__ */ e.createElement(S, null, /* @__PURE__ */ e.createElement("div", {
|
|
7666
|
-
ref:
|
|
7683
|
+
ref: X.setFloating,
|
|
7667
7684
|
className: `${j}__aux-panel`,
|
|
7668
7685
|
style: {
|
|
7669
|
-
...
|
|
7686
|
+
...ve,
|
|
7670
7687
|
zIndex: be
|
|
7671
7688
|
},
|
|
7672
7689
|
...ye()
|
|
@@ -7730,20 +7747,20 @@ var Zr = {
|
|
|
7730
7747
|
},
|
|
7731
7748
|
shouldForceLeadingZeros: !0,
|
|
7732
7749
|
value: m(() => yi(R), [R])
|
|
7733
|
-
}),
|
|
7750
|
+
}), ee = h(null), { fieldProps: B } = Le({
|
|
7734
7751
|
"aria-describedby": N ? `${o}__message` : void 0,
|
|
7735
7752
|
"aria-labelledby": `${o}-label`,
|
|
7736
7753
|
isDisabled: i
|
|
7737
|
-
}, z,
|
|
7754
|
+
}, z, ee), V = h(x);
|
|
7738
7755
|
u(() => {
|
|
7739
|
-
let e =
|
|
7740
|
-
if (
|
|
7756
|
+
let e = V.current;
|
|
7757
|
+
if (V.current = x, !x || !e || x === e) return;
|
|
7741
7758
|
let n = z.value;
|
|
7742
7759
|
if (!n) return;
|
|
7743
7760
|
let r = Ce(we(Se(t ?? Te(e), n), e), x), i = bi(new he(r.hour, r.minute));
|
|
7744
7761
|
i && (P || L(i), p && p(i));
|
|
7745
7762
|
}, [x]);
|
|
7746
|
-
let
|
|
7763
|
+
let H = m(() => {
|
|
7747
7764
|
if (!x) return;
|
|
7748
7765
|
let e = (t ?? Te(x)).toDate(x);
|
|
7749
7766
|
try {
|
|
@@ -7758,7 +7775,7 @@ var Zr = {
|
|
|
7758
7775
|
t,
|
|
7759
7776
|
F,
|
|
7760
7777
|
x
|
|
7761
|
-
]), { focusProps:
|
|
7778
|
+
]), { focusProps: U, isFocusVisible: W } = Pe({ within: !0 }), G = z.value !== null;
|
|
7762
7779
|
return /* @__PURE__ */ e.createElement("div", {
|
|
7763
7780
|
className: Z([
|
|
7764
7781
|
$.base,
|
|
@@ -7779,8 +7796,8 @@ var Zr = {
|
|
|
7779
7796
|
showLabel: y,
|
|
7780
7797
|
tooltipText: S
|
|
7781
7798
|
}), /* @__PURE__ */ e.createElement("div", {
|
|
7782
|
-
...Oe(
|
|
7783
|
-
ref:
|
|
7799
|
+
...Oe(B, U),
|
|
7800
|
+
ref: ee,
|
|
7784
7801
|
className: Z([`${D}__input-wrapper`, W ? `${D}__input-wrapper--focus-visible` : null]),
|
|
7785
7802
|
id: o
|
|
7786
7803
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
@@ -7795,7 +7812,7 @@ var Zr = {
|
|
|
7795
7812
|
baseClass: D,
|
|
7796
7813
|
segment: t,
|
|
7797
7814
|
state: z
|
|
7798
|
-
})),
|
|
7815
|
+
})), H && G && /* @__PURE__ */ e.createElement("div", { className: `${D}__timezone` }, H))), N && /* @__PURE__ */ e.createElement(un, {
|
|
7799
7816
|
hasValidationMessage: !!C,
|
|
7800
7817
|
id: o,
|
|
7801
7818
|
message: N,
|
|
@@ -7804,7 +7821,7 @@ var Zr = {
|
|
|
7804
7821
|
}));
|
|
7805
7822
|
}, Ci = (e, t = ye()) => {
|
|
7806
7823
|
if (!e) return;
|
|
7807
|
-
let n =
|
|
7824
|
+
let n = X(e, t);
|
|
7808
7825
|
return new me(n.year, n.month, n.day);
|
|
7809
7826
|
}, wi = (e, t = ye()) => e ? e.toDate(t) : void 0, Ti = (e) => String(e).padStart(2, "0"), Ei = (e) => {
|
|
7810
7827
|
let t = e ? /^(\d{1,2}):(\d{2})$/.exec(e) : null;
|
|
@@ -7813,7 +7830,7 @@ var Zr = {
|
|
|
7813
7830
|
if (!(n > 23 || r > 59)) return new he(n, r);
|
|
7814
7831
|
}, Di = (e, t = ye()) => {
|
|
7815
7832
|
if (!e) return;
|
|
7816
|
-
let n =
|
|
7833
|
+
let n = X(e, t);
|
|
7817
7834
|
return `${Ti(n.hour)}:${Ti(n.minute)}`;
|
|
7818
7835
|
}, Oi = (e, t, n = ye()) => {
|
|
7819
7836
|
if (!e) return;
|
|
@@ -7821,11 +7838,11 @@ var Zr = {
|
|
|
7821
7838
|
return r ? Se(e, r).toDate(n) : wi(e, n);
|
|
7822
7839
|
}, ki = "00:00", Ai = "23:59", ji = (e, t, n = ye()) => {
|
|
7823
7840
|
if (!e) return "";
|
|
7824
|
-
let r =
|
|
7841
|
+
let r = X(e, n);
|
|
7825
7842
|
return Ee(new Date(r.year, r.month - 1, r.day), "PP", { locale: t });
|
|
7826
7843
|
}, Mi = (e, t) => {
|
|
7827
7844
|
let n = Te(t).year;
|
|
7828
|
-
return e.some((e) => !!e &&
|
|
7845
|
+
return e.some((e) => !!e && X(e, t).year !== n);
|
|
7829
7846
|
}, Ni = (e, { hourCycle: t, includeYear: n, localeString: r, timeZone: i = ye() }) => e ? new Intl.DateTimeFormat(r, {
|
|
7830
7847
|
day: "numeric",
|
|
7831
7848
|
hour: t === 24 ? "2-digit" : "numeric",
|
|
@@ -7871,24 +7888,24 @@ var Zr = {
|
|
|
7871
7888
|
};
|
|
7872
7889
|
case "current-week": return {
|
|
7873
7890
|
from: wi(xe(i, r), n),
|
|
7874
|
-
to: wi(
|
|
7891
|
+
to: wi(ve(i, r), n)
|
|
7875
7892
|
};
|
|
7876
7893
|
case "current-month": return {
|
|
7877
7894
|
from: wi(be(i), n),
|
|
7878
|
-
to: wi(
|
|
7895
|
+
to: wi(_e(i), n)
|
|
7879
7896
|
};
|
|
7880
7897
|
case "last-week": {
|
|
7881
7898
|
let e = i.subtract({ weeks: 1 });
|
|
7882
7899
|
return {
|
|
7883
7900
|
from: wi(xe(e, r), n),
|
|
7884
|
-
to: wi(
|
|
7901
|
+
to: wi(ve(e, r), n)
|
|
7885
7902
|
};
|
|
7886
7903
|
}
|
|
7887
7904
|
case "last-month": {
|
|
7888
7905
|
let e = i.subtract({ months: 1 });
|
|
7889
7906
|
return {
|
|
7890
7907
|
from: wi(be(e), n),
|
|
7891
|
-
to: wi(
|
|
7908
|
+
to: wi(_e(e), n)
|
|
7892
7909
|
};
|
|
7893
7910
|
}
|
|
7894
7911
|
default: return {
|
|
@@ -7955,178 +7972,190 @@ var Zr = {
|
|
|
7955
7972
|
state: r,
|
|
7956
7973
|
timeZone: i
|
|
7957
7974
|
}) : /* @__PURE__ */ e.createElement("td", { key: o }))))));
|
|
7958
|
-
}, Ri = ({ allowCustomRange: t = !0, allowDateRangeSelection: n = !0, className: r, defaultPresetLabel: i,
|
|
7959
|
-
let
|
|
7975
|
+
}, Ri = ({ allowCustomRange: t = !0, allowDateRangeSelection: n = !0, className: r, defaultPresetLabel: i, defaultTimeZoneMode: a = "utc", disabled: o = !1, footerNote: s, hourCycle: c = 12, id: l, inputWidth: d, inputWidthMin: f, label: p, locale: _, maxDate: v, message: y, minDate: b, mode: x = "single", onChange: C, onTimeZoneChange: w, placeholder: T, presets: E, required: D = !1, showLabel: O = !0, showPresetCalendar: k = !0, showTime: A = !1, showTimeZoneSwitcher: j = !1, showTodayButton: M = !0, timeZone: N = ye(), tooltipText: P, translationStrings: F, validationMessage: I, validationStatus: L, value: R, visibleMonths: z = 2, ...ee }) => {
|
|
7976
|
+
let B = x === "range", V = {
|
|
7960
7977
|
...Fi,
|
|
7961
|
-
...
|
|
7962
|
-
},
|
|
7963
|
-
|
|
7964
|
-
let { locale:
|
|
7978
|
+
...F
|
|
7979
|
+
}, H = B && !!E && E.length > 0;
|
|
7980
|
+
j && !A && process.env.NODE_ENV !== "production" && console.warn("[Datepicker] `showTimeZoneSwitcher` has no effect unless `showTime` is also true."), E && E.length > 0 && !B && process.env.NODE_ENV !== "production" && console.warn("[Datepicker] `presets` requires `mode=\"range\"` — every preset computes a date range."), !t && !H && process.env.NODE_ENV !== "production" && console.warn("[Datepicker] `allowCustomRange` has no effect unless `presets` is also set."), i !== void 0 && !(H && E?.some((e) => e.label === i)) && process.env.NODE_ENV !== "production" && console.warn(`[Datepicker] \`defaultPresetLabel\` "${i}" matches no entry in \`presets\` — nothing is seeded as active.`);
|
|
7981
|
+
let { locale: U } = Fe(), W = _?.code ?? U, G = m(() => B ? E?.find((e) => e.label === i) : void 0, [
|
|
7965
7982
|
i,
|
|
7966
|
-
|
|
7967
|
-
|
|
7968
|
-
]),
|
|
7983
|
+
B,
|
|
7984
|
+
E
|
|
7985
|
+
]), K = (e) => {
|
|
7969
7986
|
let t = Pi(e, {
|
|
7970
|
-
locale:
|
|
7971
|
-
timeZone:
|
|
7987
|
+
locale: W,
|
|
7988
|
+
timeZone: N
|
|
7972
7989
|
}), n = e.hours !== void 0 || e.minutes !== void 0;
|
|
7973
|
-
return !
|
|
7974
|
-
from: Oi(Ci(t.from,
|
|
7975
|
-
to: Oi(Ci(t.to,
|
|
7990
|
+
return !A || n ? t : {
|
|
7991
|
+
from: Oi(Ci(t.from, N), ki, N),
|
|
7992
|
+
to: Oi(Ci(t.to, N), Ai, N)
|
|
7976
7993
|
};
|
|
7977
|
-
}, [
|
|
7978
|
-
id: `${
|
|
7979
|
-
label:
|
|
7980
|
-
onChange: (e) =>
|
|
7994
|
+
}, [q, te] = g(() => R ?? (G ? K(G) : void 0)), [ne, re] = g(a), J = j ? ne === "utc" ? "UTC" : ye() : N, [ie, ae] = g(G?.label), [Y, oe] = g(k), se = !H || Y, ce = !H || k || t, le = z === 1 ? B && A ? 400 : 280 : 550, ue = h(null), de = ie === void 0 && (B ? !!q?.from : !!q), fe = (e, t) => B && A ? e ?? t : e, [pe, me] = g(() => fe(Di(B ? q?.from : q, J), ki)), [he, _e] = g(() => fe(Di(q?.to, J), Ai)), ve = on(d, f), X = "pds-datepicker", be = o ? $.disabled : null, xe = D && !o ? $.required : null, Se = L === "error" ? $.error : null, Ce = L === "success" ? $.success : null, we = I || y, Ee = /* @__PURE__ */ e.createElement("div", { className: `${X}__timezone-switcher` }, /* @__PURE__ */ e.createElement("span", { className: `${X}__timezone-switcher-label` }, V.timeZoneSwitcherLabel), /* @__PURE__ */ e.createElement(ur, {
|
|
7995
|
+
id: `${l}-timezone-switcher`,
|
|
7996
|
+
label: V.timeZoneSwitcherLabel || "",
|
|
7997
|
+
onChange: (e) => {
|
|
7998
|
+
let t = e;
|
|
7999
|
+
re(t), w?.(t === "utc" ? "UTC" : ye(), t);
|
|
8000
|
+
},
|
|
7981
8001
|
options: [{
|
|
7982
|
-
label:
|
|
8002
|
+
label: V.localTimeZoneLabel || "",
|
|
7983
8003
|
value: "local"
|
|
7984
8004
|
}, {
|
|
7985
|
-
label:
|
|
8005
|
+
label: V.utcTimeZoneLabel || "",
|
|
7986
8006
|
value: "utc"
|
|
7987
8007
|
}],
|
|
7988
8008
|
size: "s",
|
|
7989
|
-
value:
|
|
7990
|
-
})), { floatingStyles:
|
|
8009
|
+
value: ne
|
|
8010
|
+
})), { floatingStyles: Oe, getFloatingProps: je, getReferenceProps: Me, isMounted: Ne, isOpen: Pe, refs: Le, setIsOpen: Be } = In({
|
|
7991
8011
|
enableListNavigation: !1,
|
|
7992
8012
|
offsetValue: 8,
|
|
7993
8013
|
placement: "bottom-start",
|
|
7994
8014
|
role: "dialog",
|
|
7995
8015
|
shiftPadding: 16,
|
|
7996
8016
|
variant: "default"
|
|
7997
|
-
}),
|
|
7998
|
-
|
|
7999
|
-
|
|
8017
|
+
}), Ve = Bn("var(--pds-z-index-overlay)"), He = Ci(b, J), Ue = Ci(v, J), We = (e, t, n = !1) => {
|
|
8018
|
+
te(e), ae(t), C?.(e), !B && n && setTimeout(() => {
|
|
8019
|
+
Be(!1);
|
|
8000
8020
|
}, 300);
|
|
8001
|
-
},
|
|
8021
|
+
}, Ge = Re({
|
|
8002
8022
|
createCalendar: ge,
|
|
8003
|
-
locale:
|
|
8004
|
-
maxValue:
|
|
8005
|
-
minValue:
|
|
8023
|
+
locale: W,
|
|
8024
|
+
maxValue: Ue,
|
|
8025
|
+
minValue: He,
|
|
8006
8026
|
onChange: (e) => {
|
|
8007
|
-
|
|
8027
|
+
B || We(Oi(e, A ? pe : void 0, J), void 0, !A);
|
|
8008
8028
|
},
|
|
8009
|
-
value:
|
|
8010
|
-
}),
|
|
8029
|
+
value: B ? null : Ci(q, J) ?? null
|
|
8030
|
+
}), Ke = h(null), qe = ze({
|
|
8011
8031
|
createCalendar: ge,
|
|
8012
|
-
locale:
|
|
8013
|
-
maxValue:
|
|
8014
|
-
minValue:
|
|
8015
|
-
visibleDuration: { months:
|
|
8032
|
+
locale: W,
|
|
8033
|
+
maxValue: Ue,
|
|
8034
|
+
minValue: He,
|
|
8035
|
+
visibleDuration: { months: z },
|
|
8016
8036
|
onChange: (e) => {
|
|
8017
|
-
|
|
8018
|
-
from: Oi(e.start,
|
|
8019
|
-
to: Oi(e.end,
|
|
8037
|
+
B && e && We({
|
|
8038
|
+
from: Oi(e.start, A ? pe : void 0, J),
|
|
8039
|
+
to: Oi(e.end, A ? he : void 0, J)
|
|
8020
8040
|
});
|
|
8021
8041
|
},
|
|
8022
|
-
value:
|
|
8023
|
-
let e =
|
|
8042
|
+
value: B ? (() => {
|
|
8043
|
+
let e = q, t = Ci(e?.from, J), n = Ci(e?.to, J);
|
|
8024
8044
|
return t && n ? {
|
|
8025
8045
|
start: t,
|
|
8026
8046
|
end: n
|
|
8027
8047
|
} : null;
|
|
8028
8048
|
})() : null
|
|
8029
|
-
}),
|
|
8049
|
+
}), Je = B ? qe : Ge, { calendarProps: Ye, nextButtonProps: Xe, prevButtonProps: Ze } = Ae({}, Ge), { calendarProps: Qe, nextButtonProps: $e, prevButtonProps: et } = Ie({}, qe, Ke), tt = B ? Qe : Ye, nt = B ? $e : Xe, rt = B ? et : Ze, it = (e) => new Intl.DateTimeFormat(W, {
|
|
8030
8050
|
month: "long",
|
|
8031
8051
|
year: "numeric"
|
|
8032
|
-
}).format(e.toDate(ye())),
|
|
8033
|
-
|
|
8034
|
-
},
|
|
8035
|
-
|
|
8036
|
-
},
|
|
8052
|
+
}).format(e.toDate(ye())), at = B ? Array.from({ length: z }, (e, t) => t) : [0], ot = at.map((e) => it(Je.visibleRange.start.add({ months: e }))), st = h(null), ct = h(null), { buttonProps: lt } = ke(rt, st), { buttonProps: ut } = ke(nt, ct), dt = () => {
|
|
8053
|
+
te(void 0), ae(void 0), C?.(void 0), A && (me(B ? ki : void 0), _e(B ? Ai : void 0)), B ? qe.setValue(null) : Ge.setValue(null);
|
|
8054
|
+
}, ft = () => !B || !qe.anchorDate ? !1 : (qe.selectDate(qe.anchorDate), !0), pt = () => {
|
|
8055
|
+
ft(), Be(!1);
|
|
8056
|
+
}, mt = () => {
|
|
8037
8057
|
let e = Te(J);
|
|
8038
|
-
|
|
8039
|
-
},
|
|
8058
|
+
Je.setFocusedDate(e), B ? (qe.setValue(null), te(void 0), ae(void 0), C?.(void 0)) : (Ge.setValue(e), We(Oi(e, A ? pe : void 0, J), void 0, !A));
|
|
8059
|
+
}, ht = (e) => {
|
|
8040
8060
|
let t = Pi(e, {
|
|
8041
|
-
locale:
|
|
8061
|
+
locale: W,
|
|
8042
8062
|
timeZone: J
|
|
8043
8063
|
}), n = e.hours !== void 0 || e.minutes !== void 0;
|
|
8044
|
-
|
|
8045
|
-
from: Oi(Ci(t.from, J),
|
|
8046
|
-
to: Oi(Ci(t.to, J),
|
|
8064
|
+
oe(k), A && n ? (me(Di(t.from, J)), _e(Di(t.to, J)), We(t, e.label)) : We(A ? {
|
|
8065
|
+
from: Oi(Ci(t.from, J), pe, J),
|
|
8066
|
+
to: Oi(Ci(t.to, J), he, J)
|
|
8047
8067
|
} : t, e.label);
|
|
8048
8068
|
let r = Ci(t.from, J);
|
|
8049
|
-
r &&
|
|
8050
|
-
|
|
8069
|
+
r && Je.setFocusedDate(r), k || setTimeout(() => {
|
|
8070
|
+
Be(!1);
|
|
8051
8071
|
}, 300);
|
|
8052
|
-
},
|
|
8053
|
-
if (
|
|
8054
|
-
let t =
|
|
8055
|
-
t?.from && t?.to
|
|
8056
|
-
|
|
8057
|
-
|
|
8058
|
-
|
|
8072
|
+
}, gt = (e, t) => Di(e, J) === t, _t = (e) => {
|
|
8073
|
+
if (me(e), B) {
|
|
8074
|
+
let t = q;
|
|
8075
|
+
if (t?.from && t?.to) {
|
|
8076
|
+
if (gt(t.from, e)) return;
|
|
8077
|
+
We({
|
|
8078
|
+
from: Oi(Ci(t.from, J), e, J),
|
|
8079
|
+
to: t.to
|
|
8080
|
+
});
|
|
8081
|
+
}
|
|
8059
8082
|
} else {
|
|
8060
|
-
let t =
|
|
8061
|
-
|
|
8083
|
+
let t = q;
|
|
8084
|
+
if (t) {
|
|
8085
|
+
if (gt(t, e)) return;
|
|
8086
|
+
We(Oi(Ci(t, J), e, J));
|
|
8087
|
+
}
|
|
8062
8088
|
}
|
|
8063
|
-
},
|
|
8064
|
-
|
|
8065
|
-
let t =
|
|
8066
|
-
t?.from && t?.to
|
|
8067
|
-
|
|
8068
|
-
|
|
8069
|
-
|
|
8070
|
-
|
|
8089
|
+
}, vt = (e) => {
|
|
8090
|
+
_e(e);
|
|
8091
|
+
let t = q;
|
|
8092
|
+
if (t?.from && t?.to) {
|
|
8093
|
+
if (gt(t.to, e)) return;
|
|
8094
|
+
We({
|
|
8095
|
+
from: t.from,
|
|
8096
|
+
to: Oi(Ci(t.to, J), e, J)
|
|
8097
|
+
});
|
|
8098
|
+
}
|
|
8099
|
+
}, yt = h(R);
|
|
8071
8100
|
u(() => {
|
|
8072
|
-
|
|
8073
|
-
}, [
|
|
8074
|
-
if (
|
|
8075
|
-
let e =
|
|
8076
|
-
|
|
8077
|
-
} else
|
|
8101
|
+
yt.current !== R && (yt.current = R, te(R));
|
|
8102
|
+
}, [R]), u(() => {
|
|
8103
|
+
if (A) if (B) {
|
|
8104
|
+
let e = q;
|
|
8105
|
+
me(Di(e?.from, J) ?? ki), _e(Di(e?.to, J) ?? Ai);
|
|
8106
|
+
} else me(Di(q, J));
|
|
8078
8107
|
}, [
|
|
8079
|
-
|
|
8108
|
+
q,
|
|
8080
8109
|
J,
|
|
8081
|
-
|
|
8082
|
-
|
|
8110
|
+
B,
|
|
8111
|
+
A
|
|
8083
8112
|
]), u(() => {
|
|
8084
|
-
n ||
|
|
8113
|
+
n || ft();
|
|
8085
8114
|
}, [
|
|
8086
|
-
|
|
8115
|
+
B,
|
|
8087
8116
|
n,
|
|
8088
|
-
|
|
8117
|
+
qe.anchorDate
|
|
8089
8118
|
]), u(() => {
|
|
8090
|
-
if (
|
|
8091
|
-
let e = Ci(
|
|
8092
|
-
|
|
8119
|
+
if (Pe) {
|
|
8120
|
+
let e = Ci(B ? q?.from : q, J);
|
|
8121
|
+
Je.setFocusedDate(e ?? Te(J)), oe(k);
|
|
8093
8122
|
}
|
|
8094
|
-
}, [
|
|
8095
|
-
|
|
8096
|
-
}, [
|
|
8097
|
-
let
|
|
8098
|
-
hourCycle:
|
|
8099
|
-
includeYear:
|
|
8100
|
-
localeString:
|
|
8123
|
+
}, [Pe]), u(() => {
|
|
8124
|
+
ue.current && (ue.current.inert = !se);
|
|
8125
|
+
}, [se]);
|
|
8126
|
+
let bt = E?.find((e) => e.label === ie), xt = bt && (bt.showLabelInTrigger ?? (bt.hours !== void 0 || bt.minutes !== void 0)) ? bt.label : void 0, St = Mi(B ? [q?.from, q?.to] : [q], J), Ct = (e) => A ? Ni(e, {
|
|
8127
|
+
hourCycle: c,
|
|
8128
|
+
includeYear: St,
|
|
8129
|
+
localeString: W,
|
|
8101
8130
|
timeZone: J
|
|
8102
|
-
}) : ji(e,
|
|
8103
|
-
if (
|
|
8104
|
-
if (
|
|
8105
|
-
let t =
|
|
8106
|
-
return t?.from ? t.to ? /* @__PURE__ */ e.createElement(e.Fragment, null,
|
|
8131
|
+
}) : ji(e, _, J), wt = () => {
|
|
8132
|
+
if (xt !== void 0) return xt;
|
|
8133
|
+
if (B) {
|
|
8134
|
+
let t = q;
|
|
8135
|
+
return t?.from ? t.to ? /* @__PURE__ */ e.createElement(e.Fragment, null, Ct(t.from), /* @__PURE__ */ e.createElement("span", { className: `${X}__separator` }, " – "), Ct(t.to)) : Ct(t.from) : T || "";
|
|
8107
8136
|
} else {
|
|
8108
|
-
let e =
|
|
8109
|
-
return e ?
|
|
8137
|
+
let e = q;
|
|
8138
|
+
return e ? Ct(e) : T || "";
|
|
8110
8139
|
}
|
|
8111
|
-
},
|
|
8112
|
-
if (
|
|
8113
|
-
let e =
|
|
8114
|
-
return !e?.from && t ? `${
|
|
8140
|
+
}, Tt = () => xt === void 0 ? B ? !q?.from : !q : !1, Et = () => {
|
|
8141
|
+
if (B) {
|
|
8142
|
+
let e = q, t = qe.anchorDate;
|
|
8143
|
+
return !e?.from && t ? `${V.selectedStartDate}${ji(wi(t, J), _, J)}${V.pleaseSelectEndDate}` : e?.from ? e.to ? `${V.selectedDateRange}${Ct(e.from)}${V.to}${Ct(e.to)}` : `${V.selectedStartDate}${Ct(e.from)}${V.pleaseSelectEndDate}` : V.noDateRangeSelected || "";
|
|
8115
8144
|
} else {
|
|
8116
|
-
let e =
|
|
8117
|
-
return e ? `${
|
|
8145
|
+
let e = q;
|
|
8146
|
+
return e ? `${V.selectedDate}${Ct(e)}` : V.noDateSelected || "";
|
|
8118
8147
|
}
|
|
8119
|
-
},
|
|
8120
|
-
|
|
8121
|
-
ref:
|
|
8148
|
+
}, Dt = B ? q : void 0, Ot = /* @__PURE__ */ e.createElement("div", {
|
|
8149
|
+
...tt,
|
|
8150
|
+
ref: B ? Ke : void 0,
|
|
8122
8151
|
className: `${X}__calendar`
|
|
8123
|
-
}, /* @__PURE__ */ e.createElement("div", { className: `${X}__grids` },
|
|
8152
|
+
}, /* @__PURE__ */ e.createElement("div", { className: `${X}__grids` }, at.map((t, n) => /* @__PURE__ */ e.createElement("div", {
|
|
8124
8153
|
key: t,
|
|
8125
8154
|
className: `${X}__month`
|
|
8126
8155
|
}, /* @__PURE__ */ e.createElement("div", { className: `${X}__nav` }, n === 0 ? /* @__PURE__ */ e.createElement("button", {
|
|
8127
|
-
...
|
|
8128
|
-
ref:
|
|
8129
|
-
"aria-label":
|
|
8156
|
+
...lt,
|
|
8157
|
+
ref: st,
|
|
8158
|
+
"aria-label": V.previousMonthLabel,
|
|
8130
8159
|
className: `${X}__nav-button`,
|
|
8131
8160
|
type: "button"
|
|
8132
8161
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
@@ -8138,10 +8167,10 @@ var Zr = {
|
|
|
8138
8167
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
8139
8168
|
iconName: "angleLeft",
|
|
8140
8169
|
size: "m"
|
|
8141
|
-
})), /* @__PURE__ */ e.createElement("div", { className: `${X}__nav-title` },
|
|
8142
|
-
...
|
|
8143
|
-
ref:
|
|
8144
|
-
"aria-label":
|
|
8170
|
+
})), /* @__PURE__ */ e.createElement("div", { className: `${X}__nav-title` }, ot[n]), n === at.length - 1 ? /* @__PURE__ */ e.createElement("button", {
|
|
8171
|
+
...ut,
|
|
8172
|
+
ref: ct,
|
|
8173
|
+
"aria-label": V.nextMonthLabel,
|
|
8145
8174
|
className: `${X}__nav-button`,
|
|
8146
8175
|
type: "button"
|
|
8147
8176
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
@@ -8156,159 +8185,159 @@ var Zr = {
|
|
|
8156
8185
|
}))), /* @__PURE__ */ e.createElement(Li, {
|
|
8157
8186
|
baseClass: X,
|
|
8158
8187
|
monthOffset: t,
|
|
8159
|
-
state:
|
|
8188
|
+
state: Je,
|
|
8160
8189
|
timeZone: J
|
|
8161
|
-
})))),
|
|
8162
|
-
anchorDate: Ci(
|
|
8163
|
-
hourCycle:
|
|
8164
|
-
id: `${
|
|
8165
|
-
label:
|
|
8166
|
-
onChange:
|
|
8190
|
+
})))), A && /* @__PURE__ */ e.createElement("div", { className: `${X}__time-section` }, B ? /* @__PURE__ */ e.createElement("div", { className: `${X}__time-fields` }, /* @__PURE__ */ e.createElement(Si, {
|
|
8191
|
+
anchorDate: Ci(Dt?.from, J),
|
|
8192
|
+
hourCycle: c,
|
|
8193
|
+
id: `${l}-start-time`,
|
|
8194
|
+
label: V.startTimeLabel || "",
|
|
8195
|
+
onChange: _t,
|
|
8167
8196
|
size: "s",
|
|
8168
8197
|
timeZone: J,
|
|
8169
|
-
value:
|
|
8198
|
+
value: pe
|
|
8170
8199
|
}), /* @__PURE__ */ e.createElement(Si, {
|
|
8171
|
-
anchorDate: Ci(
|
|
8172
|
-
hourCycle:
|
|
8173
|
-
id: `${
|
|
8174
|
-
label:
|
|
8175
|
-
onChange:
|
|
8200
|
+
anchorDate: Ci(Dt?.to, J),
|
|
8201
|
+
hourCycle: c,
|
|
8202
|
+
id: `${l}-end-time`,
|
|
8203
|
+
label: V.endTimeLabel || "",
|
|
8204
|
+
onChange: vt,
|
|
8176
8205
|
size: "s",
|
|
8177
8206
|
timeZone: J,
|
|
8178
|
-
value:
|
|
8179
|
-
})) :
|
|
8180
|
-
anchorDate: Ci(
|
|
8181
|
-
hourCycle:
|
|
8182
|
-
id: `${
|
|
8183
|
-
label:
|
|
8184
|
-
onChange:
|
|
8207
|
+
value: he
|
|
8208
|
+
})) : q && /* @__PURE__ */ e.createElement("div", { className: `${X}__time-fields` }, /* @__PURE__ */ e.createElement(Si, {
|
|
8209
|
+
anchorDate: Ci(q, J),
|
|
8210
|
+
hourCycle: c,
|
|
8211
|
+
id: `${l}-time`,
|
|
8212
|
+
label: V.timeLabel || "",
|
|
8213
|
+
onChange: _t,
|
|
8185
8214
|
size: "s",
|
|
8186
8215
|
timeZone: J,
|
|
8187
|
-
value:
|
|
8188
|
-
})),
|
|
8216
|
+
value: pe
|
|
8217
|
+
})), j && !H && Ee), s && /* @__PURE__ */ e.createElement("div", { className: `${X}__footer-note` }, s), /* @__PURE__ */ e.createElement("div", { className: `${X}__actions` }, M && /* @__PURE__ */ e.createElement(kn, {
|
|
8189
8218
|
className: `${X}__action-button ${X}__action-button--today`,
|
|
8190
|
-
label:
|
|
8191
|
-
onClick:
|
|
8219
|
+
label: V.todayButton,
|
|
8220
|
+
onClick: mt,
|
|
8192
8221
|
size: "xs",
|
|
8193
8222
|
type: "button",
|
|
8194
8223
|
variant: "secondary"
|
|
8195
8224
|
}), /* @__PURE__ */ e.createElement("div", { className: `${X}__actions-group` }, /* @__PURE__ */ e.createElement(kn, {
|
|
8196
8225
|
className: `${X}__action-button ${X}__action-button--clear`,
|
|
8197
|
-
label:
|
|
8198
|
-
onClick:
|
|
8226
|
+
label: V.clearButton,
|
|
8227
|
+
onClick: dt,
|
|
8199
8228
|
size: "xs",
|
|
8200
8229
|
type: "button",
|
|
8201
8230
|
variant: "secondary"
|
|
8202
|
-
}), (
|
|
8231
|
+
}), (B || A) && /* @__PURE__ */ e.createElement(kn, {
|
|
8203
8232
|
className: `${X}__action-button ${X}__action-button--done`,
|
|
8204
|
-
label:
|
|
8205
|
-
onClick:
|
|
8233
|
+
label: V.doneButton,
|
|
8234
|
+
onClick: pt,
|
|
8206
8235
|
size: "xs",
|
|
8207
8236
|
type: "button",
|
|
8208
8237
|
variant: "highlight"
|
|
8209
8238
|
}))));
|
|
8210
|
-
return /* @__PURE__ */ e.createElement(De, { locale:
|
|
8239
|
+
return /* @__PURE__ */ e.createElement(De, { locale: W }, /* @__PURE__ */ e.createElement("div", {
|
|
8211
8240
|
className: Z([
|
|
8212
8241
|
$.base,
|
|
8213
8242
|
X,
|
|
8214
|
-
_e,
|
|
8215
8243
|
be,
|
|
8216
|
-
|
|
8244
|
+
Se,
|
|
8217
8245
|
xe,
|
|
8246
|
+
Ce,
|
|
8218
8247
|
r ?? ""
|
|
8219
8248
|
]),
|
|
8220
|
-
style:
|
|
8221
|
-
...
|
|
8249
|
+
style: d ? ve : null,
|
|
8250
|
+
...ee
|
|
8222
8251
|
}, /* @__PURE__ */ e.createElement(ln, {
|
|
8223
|
-
disabled:
|
|
8224
|
-
id:
|
|
8225
|
-
label:
|
|
8226
|
-
required:
|
|
8227
|
-
showLabel:
|
|
8228
|
-
tooltipText:
|
|
8252
|
+
disabled: o,
|
|
8253
|
+
id: l,
|
|
8254
|
+
label: p,
|
|
8255
|
+
required: D,
|
|
8256
|
+
showLabel: O,
|
|
8257
|
+
tooltipText: P
|
|
8229
8258
|
}), /* @__PURE__ */ e.createElement("div", { className: `${X}__input-wrapper` }, /* @__PURE__ */ e.createElement("button", {
|
|
8230
|
-
ref:
|
|
8231
|
-
"aria-describedby":
|
|
8232
|
-
"aria-expanded":
|
|
8259
|
+
ref: Le.setReference,
|
|
8260
|
+
"aria-describedby": we ? `${l}__message` : null,
|
|
8261
|
+
"aria-expanded": Pe,
|
|
8233
8262
|
"aria-haspopup": "dialog",
|
|
8234
|
-
"aria-invalid":
|
|
8235
|
-
className: Z([`${X}__trigger`,
|
|
8236
|
-
disabled:
|
|
8263
|
+
"aria-invalid": L === "error" ? !0 : null,
|
|
8264
|
+
className: Z([`${X}__trigger`, Pe ? `${X}__trigger--open` : null]),
|
|
8265
|
+
disabled: o,
|
|
8237
8266
|
type: "button",
|
|
8238
|
-
...
|
|
8267
|
+
...Me()
|
|
8239
8268
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
8240
8269
|
className: `${X}__trigger-icon`,
|
|
8241
8270
|
iconName: "calendarDays"
|
|
8242
|
-
}), /* @__PURE__ */ e.createElement("span", { className: Z([`${X}__trigger-text`,
|
|
8243
|
-
hasValidationMessage: !!
|
|
8244
|
-
id:
|
|
8245
|
-
message:
|
|
8246
|
-
validationStatus:
|
|
8247
|
-
}),
|
|
8248
|
-
ref:
|
|
8271
|
+
}), /* @__PURE__ */ e.createElement("span", { className: Z([`${X}__trigger-text`, Tt() ? `${X}__trigger-text--placeholder` : null]) }, wt()))), we && /* @__PURE__ */ e.createElement(un, {
|
|
8272
|
+
hasValidationMessage: !!I,
|
|
8273
|
+
id: l,
|
|
8274
|
+
message: we,
|
|
8275
|
+
validationStatus: L
|
|
8276
|
+
}), Ne && /* @__PURE__ */ e.createElement(S, null, /* @__PURE__ */ e.createElement("div", {
|
|
8277
|
+
ref: Le.setFloating,
|
|
8249
8278
|
className: `${X}__popover`,
|
|
8250
8279
|
style: {
|
|
8251
|
-
...
|
|
8252
|
-
zIndex:
|
|
8280
|
+
...Oe,
|
|
8281
|
+
zIndex: Ve
|
|
8253
8282
|
},
|
|
8254
|
-
...
|
|
8255
|
-
},
|
|
8256
|
-
"aria-label":
|
|
8283
|
+
...je()
|
|
8284
|
+
}, H && /* @__PURE__ */ e.createElement("div", { className: Z([`${X}__presets`, se ? null : `${X}__presets--collapsed`]) }, /* @__PURE__ */ e.createElement("div", {
|
|
8285
|
+
"aria-label": V.presetsGroupLabel,
|
|
8257
8286
|
className: `${X}__preset-list`,
|
|
8258
8287
|
role: "group"
|
|
8259
|
-
},
|
|
8288
|
+
}, E?.map((t) => /* @__PURE__ */ e.createElement("button", {
|
|
8260
8289
|
key: t.label,
|
|
8261
|
-
"aria-pressed":
|
|
8262
|
-
className: Z([`${X}__preset-item`,
|
|
8263
|
-
onClick: () =>
|
|
8290
|
+
"aria-pressed": ie === t.label,
|
|
8291
|
+
className: Z([`${X}__preset-item`, ie === t.label ? `${X}__preset-item--active` : null]),
|
|
8292
|
+
onClick: () => ht(t),
|
|
8264
8293
|
type: "button"
|
|
8265
8294
|
}, t.label)), t && /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("div", {
|
|
8266
8295
|
"aria-hidden": "true",
|
|
8267
8296
|
className: `${X}__preset-divider`
|
|
8268
8297
|
}), /* @__PURE__ */ e.createElement("button", {
|
|
8269
|
-
"aria-pressed":
|
|
8270
|
-
className: Z([`${X}__preset-item`,
|
|
8298
|
+
"aria-pressed": de,
|
|
8299
|
+
className: Z([`${X}__preset-item`, de ? `${X}__preset-item--active` : null]),
|
|
8271
8300
|
onClick: () => {
|
|
8272
|
-
|
|
8301
|
+
ae(void 0), oe(!0);
|
|
8273
8302
|
},
|
|
8274
8303
|
type: "button"
|
|
8275
|
-
},
|
|
8304
|
+
}, V.customPresetLabel, !k && /* @__PURE__ */ e.createElement(Q, {
|
|
8276
8305
|
iconName: "angleRight",
|
|
8277
8306
|
size: "xs"
|
|
8278
|
-
})))),
|
|
8307
|
+
})))), A && j && Ee), /* @__PURE__ */ e.createElement("div", {
|
|
8279
8308
|
"aria-atomic": "true",
|
|
8280
8309
|
"aria-live": "polite",
|
|
8281
8310
|
className: "visually-hidden"
|
|
8282
|
-
},
|
|
8283
|
-
ref:
|
|
8311
|
+
}, Et()), H ? ce && /* @__PURE__ */ e.createElement("div", {
|
|
8312
|
+
ref: ue,
|
|
8284
8313
|
className: `${X}__calendar-wrapper`,
|
|
8285
|
-
style: { flexBasis:
|
|
8314
|
+
style: { flexBasis: se ? le : 0 }
|
|
8286
8315
|
}, /* @__PURE__ */ e.createElement("div", {
|
|
8287
8316
|
className: `${X}__calendar-wrapper-inner`,
|
|
8288
|
-
style: { width:
|
|
8289
|
-
},
|
|
8317
|
+
style: { width: le }
|
|
8318
|
+
}, Ot)) : Ot))));
|
|
8290
8319
|
}, zi = o(({ accept: t, className: n, defaultValue: r, disabled: i = !1, fieldLabel: a, id: o, inputProps: s, inputWidth: c, inputWidthMin: l, labelStrings: d = {
|
|
8291
8320
|
chooseFile: "Choose file",
|
|
8292
8321
|
clearButton: "Clear selected file"
|
|
8293
8322
|
}, message: f, multiple: p = !1, onClear: m, onFileChange: h, required: _ = !1, showFullPath: v, showLabel: y = !0, size: b = "s", tooltipText: x = null, validationMessage: S, validationStatus: C, ...w }, T) => {
|
|
8294
8323
|
let [E, D] = g(!1), [O, k] = g(!!(Ve && r)), A = on(c, l), j = "pds-file-upload", M = b === "s" ? null : `${j}--${b}`, N = i ? $.disabled : null, P = _ && !i ? $.required : null, F = C === "error" ? $.error : null, I = C === "success" ? $.success : null, L = O ? `${j}--safari-default` : null, R = null;
|
|
8295
8324
|
C === "error" && (R = "error"), C === "success" && (R = "success");
|
|
8296
|
-
let z = S || f,
|
|
8325
|
+
let z = S || f, ee = r ? [r] : null, B = r ? r.split("/").pop() : null, V = v ? r : B, H = r ? new File(ee, V) : null;
|
|
8297
8326
|
u(() => {
|
|
8298
8327
|
let e = new DataTransfer();
|
|
8299
|
-
if (
|
|
8328
|
+
if (H && e.items.add(H), e.files.length > 0) {
|
|
8300
8329
|
let t = document.getElementById(`${o}--input`);
|
|
8301
|
-
t.files = e.files, Ve && (t.dataset.file = `${
|
|
8330
|
+
t.files = e.files, Ve && (t.dataset.file = `${V}`), D(!0);
|
|
8302
8331
|
}
|
|
8303
8332
|
}, [r, v]);
|
|
8304
|
-
let
|
|
8333
|
+
let U = () => {
|
|
8305
8334
|
let e = document.getElementById(`${o}--input`);
|
|
8306
8335
|
if (!e || !r) return;
|
|
8307
8336
|
let t = new DataTransfer();
|
|
8308
|
-
t.items.add(
|
|
8337
|
+
t.items.add(H), e.files = t.files, D(!0);
|
|
8309
8338
|
}, W = (e) => {
|
|
8310
8339
|
if (e.target.files.length === 0) {
|
|
8311
|
-
r ?
|
|
8340
|
+
r ? U() : D(!1);
|
|
8312
8341
|
return;
|
|
8313
8342
|
}
|
|
8314
8343
|
Ve && r && (r === e.target.value ? k(!0) : k(!1)), h && h(e.target.files), D(!0);
|
|
@@ -8567,22 +8596,22 @@ var Zr = {
|
|
|
8567
8596
|
tagRemove: "Remove {value}",
|
|
8568
8597
|
tagsListLabel: "Current tags"
|
|
8569
8598
|
}, validationMessage: x, validationStatus: S, ...C }, w) => {
|
|
8570
|
-
let T = on(o, s), E = "pds-tags-input", D = _ === "s" ? null : `${E}--${_}`, O = r ? $.disabled : null, k = p && !r ? $.required : null, A = S === "error" ? $.error : null, j = S === "success" ? $.success : null, M = x || u, [N, P] = g(""), [F, I] = g(null), [L, R] = g(null), [z,
|
|
8571
|
-
|
|
8599
|
+
let T = on(o, s), E = "pds-tags-input", D = _ === "s" ? null : `${E}--${_}`, O = r ? $.disabled : null, k = p && !r ? $.required : null, A = S === "error" ? $.error : null, j = S === "success" ? $.success : null, M = x || u, [N, P] = g(""), [F, I] = g(null), [L, R] = g(null), [z, ee] = g(null), [B, V] = g(null), [H, U] = g(""), W = h(null), G = v.length > 0 ? t : f, K = (e) => {
|
|
8600
|
+
U(e), setTimeout(() => U(""), 1e3);
|
|
8572
8601
|
}, q = (e) => {
|
|
8573
8602
|
d(e);
|
|
8574
8603
|
}, te = (e) => {
|
|
8575
8604
|
I(e);
|
|
8576
|
-
},
|
|
8577
|
-
I(null), R(null),
|
|
8578
|
-
},
|
|
8579
|
-
F === null || F === e || (R(e),
|
|
8580
|
-
},
|
|
8605
|
+
}, ne = () => {
|
|
8606
|
+
I(null), R(null), ee(null);
|
|
8607
|
+
}, re = (e, t) => {
|
|
8608
|
+
F === null || F === e || (R(e), ee(t));
|
|
8609
|
+
}, J = (e) => {
|
|
8581
8610
|
if (e.preventDefault(), F === null || L === null || z === null) return;
|
|
8582
8611
|
let t = v.findIndex((e) => e.id === F), n = v.findIndex((e) => e.id === L);
|
|
8583
8612
|
if (t === -1 || n === -1) return;
|
|
8584
8613
|
let r = [...v], [i] = r.splice(t, 1), a = n;
|
|
8585
|
-
a = z === "after" ? t < n ? n : n + 1 : n, r.splice(a, 0, i), q(r), K("Tag reordered"), I(null), R(null),
|
|
8614
|
+
a = z === "after" ? t < n ? n : n + 1 : n, r.splice(a, 0, i), q(r), K("Tag reordered"), I(null), R(null), ee(null);
|
|
8586
8615
|
}, ie = (e, t) => {
|
|
8587
8616
|
let n = [...v], [r] = n.splice(e, 1);
|
|
8588
8617
|
n.splice(t, 0, r), K(`${r.value} moved to position ${t + 1} of ${v.length}`), q(n);
|
|
@@ -8590,7 +8619,7 @@ var Zr = {
|
|
|
8590
8619
|
let t = v.find((t) => t.id === e);
|
|
8591
8620
|
q(v.filter((t) => t.id !== e)), t && K(`${t.value} removed`);
|
|
8592
8621
|
}, Y = () => {
|
|
8593
|
-
|
|
8622
|
+
V(null), setTimeout(() => {
|
|
8594
8623
|
W.current?.focus();
|
|
8595
8624
|
}, 0);
|
|
8596
8625
|
}, oe = (e) => {
|
|
@@ -8604,7 +8633,7 @@ var Zr = {
|
|
|
8604
8633
|
} else if (e.key === "Backspace" && !N && v.length > 0) {
|
|
8605
8634
|
let e = v[v.length - 1];
|
|
8606
8635
|
q(v.slice(0, -1)), K(`${e.value} removed`);
|
|
8607
|
-
} else e.key === "ArrowLeft" && !N && v.length > 0 && (e.preventDefault(),
|
|
8636
|
+
} else e.key === "ArrowLeft" && !N && v.length > 0 && (e.preventDefault(), V(v.length - 1));
|
|
8608
8637
|
};
|
|
8609
8638
|
return /* @__PURE__ */ e.createElement("div", {
|
|
8610
8639
|
className: Z([
|
|
@@ -8630,7 +8659,7 @@ var Zr = {
|
|
|
8630
8659
|
"aria-atomic": "true",
|
|
8631
8660
|
"aria-live": "polite",
|
|
8632
8661
|
className: "visually-hidden"
|
|
8633
|
-
},
|
|
8662
|
+
}, H), /* @__PURE__ */ e.createElement("div", {
|
|
8634
8663
|
"aria-labelledby": `${i}-label`,
|
|
8635
8664
|
className: `${E}__input-wrapper`,
|
|
8636
8665
|
role: "group",
|
|
@@ -8639,7 +8668,7 @@ var Zr = {
|
|
|
8639
8668
|
"aria-label": b.tagsListLabel,
|
|
8640
8669
|
className: `${E}__tags`,
|
|
8641
8670
|
onDragOver: c ? (e) => e.preventDefault() : void 0,
|
|
8642
|
-
onDrop: c ?
|
|
8671
|
+
onDrop: c ? J : void 0,
|
|
8643
8672
|
role: "list"
|
|
8644
8673
|
}, v.map((t, n) => {
|
|
8645
8674
|
let i = null;
|
|
@@ -8649,17 +8678,17 @@ var Zr = {
|
|
|
8649
8678
|
}, /* @__PURE__ */ e.createElement(Ui, {
|
|
8650
8679
|
disabled: r,
|
|
8651
8680
|
dropTargetDirection: i,
|
|
8652
|
-
focusedIndex:
|
|
8681
|
+
focusedIndex: B,
|
|
8653
8682
|
index: n,
|
|
8654
8683
|
isDragging: F === t.id,
|
|
8655
8684
|
isSortable: c,
|
|
8656
|
-
onDragEnd:
|
|
8657
|
-
onDragOver:
|
|
8685
|
+
onDragEnd: ne,
|
|
8686
|
+
onDragOver: re,
|
|
8658
8687
|
onDragStart: te,
|
|
8659
8688
|
onFocusInput: Y,
|
|
8660
8689
|
onKeyboardMove: ie,
|
|
8661
8690
|
onRemove: ae,
|
|
8662
|
-
setFocusedIndex:
|
|
8691
|
+
setFocusedIndex: V,
|
|
8663
8692
|
tag: t,
|
|
8664
8693
|
totalTags: v.length,
|
|
8665
8694
|
translationStrings: b
|
|
@@ -8698,9 +8727,9 @@ var Zr = {
|
|
|
8698
8727
|
visibilityToggleHide: "Hide input value",
|
|
8699
8728
|
visibilityToggleShow: "Show input value"
|
|
8700
8729
|
}, validationMessage: w, validationStatus: T, value: E, ...D }, O) => {
|
|
8701
|
-
let k = on(o, s), A = "pds-textarea", j = c ? "pds-is-resizable" : null, M = i ? $.disabled : null, N = _ && !i ? $.required : null, P = T === "error" ? $.error : null, F = T === "success" ? $.success : null, I = b === "s" ? null : `${A}--${b}`, L = h ? $.readonly : null, R = w || u, z = E != null && f !== void 0, [
|
|
8702
|
-
z ||
|
|
8703
|
-
},
|
|
8730
|
+
let k = on(o, s), A = "pds-textarea", j = c ? "pds-is-resizable" : null, M = i ? $.disabled : null, N = _ && !i ? $.required : null, P = T === "error" ? $.error : null, F = T === "success" ? $.success : null, I = b === "s" ? null : `${A}--${b}`, L = h ? $.readonly : null, R = w || u, z = E != null && f !== void 0, [ee, B] = g(r === void 0 ? "" : r), V = E || ee, H = (e) => {
|
|
8731
|
+
z || B(e.target.value), f && f(e);
|
|
8732
|
+
}, U = (e) => {
|
|
8704
8733
|
d && d(e);
|
|
8705
8734
|
}, W = (e) => {
|
|
8706
8735
|
h && e.preventDefault();
|
|
@@ -8728,7 +8757,7 @@ var Zr = {
|
|
|
8728
8757
|
showLabel: y,
|
|
8729
8758
|
tooltipText: S
|
|
8730
8759
|
}), n && /* @__PURE__ */ e.createElement(hn, {
|
|
8731
|
-
currentLength:
|
|
8760
|
+
currentLength: V.length,
|
|
8732
8761
|
id: a,
|
|
8733
8762
|
maxLength: n,
|
|
8734
8763
|
overLimitMessage: C.counterOverLimit
|
|
@@ -8740,15 +8769,15 @@ var Zr = {
|
|
|
8740
8769
|
disabled: i,
|
|
8741
8770
|
id: a,
|
|
8742
8771
|
name: a,
|
|
8743
|
-
onBlur:
|
|
8744
|
-
onChange:
|
|
8772
|
+
onBlur: U,
|
|
8773
|
+
onChange: H,
|
|
8745
8774
|
onFocus: p,
|
|
8746
8775
|
onMouseDown: W,
|
|
8747
8776
|
placeholder: m,
|
|
8748
8777
|
readOnly: h,
|
|
8749
8778
|
required: _,
|
|
8750
8779
|
rows: v,
|
|
8751
|
-
value: z ? E :
|
|
8780
|
+
value: z ? E : ee,
|
|
8752
8781
|
...x
|
|
8753
8782
|
})), R && /* @__PURE__ */ e.createElement(un, {
|
|
8754
8783
|
validationMessageHasDecorators: !0,
|
|
@@ -8765,11 +8794,11 @@ var Zr = {
|
|
|
8765
8794
|
visibilityToggleHide: "Hide input value",
|
|
8766
8795
|
visibilityToggleShow: "Show input value"
|
|
8767
8796
|
}, type: k = "text", validationMessage: A, validationStatus: j, value: M, ...N }, P) => {
|
|
8768
|
-
let F = on(d, f), I = "pds-text-input", L = a ? $.disabled : null, R = S && !a ? $.required : null, z = j === "error" ? $.error : null,
|
|
8769
|
-
k === "search" && (
|
|
8770
|
-
let W = A || m, G = M !== void 0, [K, q] = g(i === void 0 ? "" : i), te = M || K,
|
|
8797
|
+
let F = on(d, f), I = "pds-text-input", L = a ? $.disabled : null, R = S && !a ? $.required : null, z = j === "error" ? $.error : null, ee = j === "success" ? $.success : null, B = x ? $.readonly : null, V = E === "s" ? null : `${I}--${E}`, H = c && k === "url" ? `${I}--has-url-prefix` : null, U = null;
|
|
8798
|
+
k === "search" && (U = "search"), k === "search" && C === "filter" && (U = "filter"), j === "error" && (U = "error"), j === "success" && (U = "success");
|
|
8799
|
+
let W = A || m, G = M !== void 0, [K, q] = g(i === void 0 ? "" : i), te = M || K, ne = s && k === "search" && !te, re = (e) => {
|
|
8771
8800
|
x && e.preventDefault();
|
|
8772
|
-
},
|
|
8801
|
+
}, J = (e) => {
|
|
8773
8802
|
if (T && Y && oe(!1), c && k === "url") {
|
|
8774
8803
|
let t = sn(e.target.value), n = {
|
|
8775
8804
|
...e,
|
|
@@ -8804,13 +8833,13 @@ var Zr = {
|
|
|
8804
8833
|
className: Z([
|
|
8805
8834
|
$.base,
|
|
8806
8835
|
I,
|
|
8807
|
-
|
|
8836
|
+
V,
|
|
8808
8837
|
L,
|
|
8809
8838
|
R,
|
|
8810
8839
|
z,
|
|
8840
|
+
ee,
|
|
8811
8841
|
B,
|
|
8812
|
-
|
|
8813
|
-
U,
|
|
8842
|
+
H,
|
|
8814
8843
|
n ?? ""
|
|
8815
8844
|
]),
|
|
8816
8845
|
style: d ? F : null,
|
|
@@ -8828,8 +8857,8 @@ var Zr = {
|
|
|
8828
8857
|
}, `${O.visibilityStatus} ${Y ? "visible" : "hidden"}.`), /* @__PURE__ */ e.createElement("div", { className: Z([
|
|
8829
8858
|
`${I}__input-wrapper`,
|
|
8830
8859
|
c && k === "url" ? `${I}__input-wrapper--has-prefix` : null,
|
|
8831
|
-
|
|
8832
|
-
]) },
|
|
8860
|
+
ne ? `${I}__input-wrapper--has-search-shortcut` : null
|
|
8861
|
+
]) }, U && /* @__PURE__ */ e.createElement(fn, { variant: U }), c && k === "url" && /* @__PURE__ */ e.createElement(Ki, null), /* @__PURE__ */ e.createElement("input", {
|
|
8833
8862
|
ref: P,
|
|
8834
8863
|
"aria-describedby": W ? `${l}__message` : null,
|
|
8835
8864
|
"aria-invalid": j === "error" ? !0 : null,
|
|
@@ -8838,10 +8867,10 @@ var Zr = {
|
|
|
8838
8867
|
disabled: a,
|
|
8839
8868
|
id: l,
|
|
8840
8869
|
name: l,
|
|
8841
|
-
onBlur:
|
|
8870
|
+
onBlur: J,
|
|
8842
8871
|
onChange: ie,
|
|
8843
8872
|
onFocus: y,
|
|
8844
|
-
onMouseDown:
|
|
8873
|
+
onMouseDown: re,
|
|
8845
8874
|
placeholder: b,
|
|
8846
8875
|
readOnly: x,
|
|
8847
8876
|
required: S,
|
|
@@ -8862,7 +8891,7 @@ var Zr = {
|
|
|
8862
8891
|
}, /* @__PURE__ */ e.createElement(Q, {
|
|
8863
8892
|
iconName: Y ? "eyeSlash" : "eye",
|
|
8864
8893
|
size: "m"
|
|
8865
|
-
})),
|
|
8894
|
+
})), ne && /* @__PURE__ */ e.createElement(pn, {
|
|
8866
8895
|
inputId: l,
|
|
8867
8896
|
shortcutLabel: O.searchShortcut
|
|
8868
8897
|
}), r && k !== "password" && /* @__PURE__ */ e.createElement(hn, {
|
|
@@ -9467,7 +9496,7 @@ var Zr = {
|
|
|
9467
9496
|
]),
|
|
9468
9497
|
role: i ? "menuitem" : void 0,
|
|
9469
9498
|
tabIndex: i ? b === r ? 0 : -1 : void 0,
|
|
9470
|
-
...i ?
|
|
9499
|
+
...i ? B({ onKeyDown: (e) => G(e, r) }) : null
|
|
9471
9500
|
}, t.linkContent))), [v, y] = g(!1), [b, x] = g(null), C = h([]), w = h(v), A = h(!1), { context: j, floatingStyles: P, refs: F } = N({
|
|
9472
9501
|
placement: "right-start",
|
|
9473
9502
|
open: v,
|
|
@@ -9494,7 +9523,7 @@ var Zr = {
|
|
|
9494
9523
|
i,
|
|
9495
9524
|
F.reference
|
|
9496
9525
|
]);
|
|
9497
|
-
let { getFloatingProps: R, getItemProps:
|
|
9526
|
+
let { getFloatingProps: R, getItemProps: B, getReferenceProps: H } = z([
|
|
9498
9527
|
L(j, {
|
|
9499
9528
|
move: !1,
|
|
9500
9529
|
delay: {
|
|
@@ -9504,8 +9533,8 @@ var Zr = {
|
|
|
9504
9533
|
handleClose: O()
|
|
9505
9534
|
}),
|
|
9506
9535
|
M(j),
|
|
9507
|
-
|
|
9508
|
-
|
|
9536
|
+
V(j, { role: "menu" }),
|
|
9537
|
+
ee(j, {
|
|
9509
9538
|
listRef: C,
|
|
9510
9539
|
activeIndex: b,
|
|
9511
9540
|
onNavigate: x,
|
|
@@ -9513,7 +9542,7 @@ var Zr = {
|
|
|
9513
9542
|
openOnArrowKeyDown: !0,
|
|
9514
9543
|
focusItemOnOpen: !1
|
|
9515
9544
|
})
|
|
9516
|
-
]),
|
|
9545
|
+
]), U = (e) => {
|
|
9517
9546
|
i && s && (e.key === "ArrowRight" || e.key === " " || e.key === "Spacebar") && (e.preventDefault(), y(!0));
|
|
9518
9547
|
}, W = (e) => {
|
|
9519
9548
|
(C.current[e]?.querySelector("a"))?.click(), y(!1);
|
|
@@ -9542,9 +9571,9 @@ var Zr = {
|
|
|
9542
9571
|
i ? `${f}--collapsed` : null,
|
|
9543
9572
|
n ? `${f}--active` : null
|
|
9544
9573
|
]),
|
|
9545
|
-
...
|
|
9574
|
+
...H({
|
|
9546
9575
|
onClick: q,
|
|
9547
|
-
onKeyDown:
|
|
9576
|
+
onKeyDown: U
|
|
9548
9577
|
})
|
|
9549
9578
|
}, s ? /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("div", { className: `${f}-wrapper` }, da(d, o, s, t), !i && /* @__PURE__ */ e.createElement("button", {
|
|
9550
9579
|
"aria-expanded": r,
|
|
@@ -10076,11 +10105,11 @@ var Zr = {
|
|
|
10076
10105
|
],
|
|
10077
10106
|
whileElementsMounted: T,
|
|
10078
10107
|
strategy: "fixed"
|
|
10079
|
-
}), R = j(F, { event: "mousedown" }),
|
|
10080
|
-
|
|
10081
|
-
|
|
10108
|
+
}), R = j(F, { event: "mousedown" }), B = M(F), U = V(F, { role: "menu" }), W = h([]), { getFloatingProps: G, getItemProps: K, getReferenceProps: q } = z([
|
|
10109
|
+
B,
|
|
10110
|
+
U,
|
|
10082
10111
|
R,
|
|
10083
|
-
|
|
10112
|
+
ee(F, {
|
|
10084
10113
|
listRef: W,
|
|
10085
10114
|
activeIndex: m,
|
|
10086
10115
|
onNavigate: _,
|
|
@@ -10089,7 +10118,7 @@ var Zr = {
|
|
|
10089
10118
|
focusItemOnOpen: !1,
|
|
10090
10119
|
focusItemOnHover: !0
|
|
10091
10120
|
})
|
|
10092
|
-
]), { isMounted: te, styles:
|
|
10121
|
+
]), { isMounted: te, styles: ne } = H(F, {
|
|
10093
10122
|
duration: {
|
|
10094
10123
|
open: 300,
|
|
10095
10124
|
close: 150
|
|
@@ -10097,7 +10126,7 @@ var Zr = {
|
|
|
10097
10126
|
initial: { opacity: 0 },
|
|
10098
10127
|
open: { opacity: 1 },
|
|
10099
10128
|
close: { opacity: 0 }
|
|
10100
|
-
}),
|
|
10129
|
+
}), re = Bn("var(--pds-z-index-dropdown)"), J = /* @__PURE__ */ e.createElement(li, {
|
|
10101
10130
|
hasUserFallback: !0,
|
|
10102
10131
|
className: `${A}__avatar`,
|
|
10103
10132
|
imageSrc: u,
|
|
@@ -10163,7 +10192,7 @@ var Zr = {
|
|
|
10163
10192
|
iconName: t.iconName,
|
|
10164
10193
|
size: "m"
|
|
10165
10194
|
}));
|
|
10166
|
-
}), ue = /* @__PURE__ */ e.createElement("span", { className: `${A}__toggle-left` },
|
|
10195
|
+
}), ue = /* @__PURE__ */ e.createElement("span", { className: `${A}__toggle-left` }, J, f ?? l);
|
|
10167
10196
|
return /* @__PURE__ */ e.createElement("span", {
|
|
10168
10197
|
className: Z([A, n ?? ""]),
|
|
10169
10198
|
...p
|
|
@@ -10176,15 +10205,15 @@ var Zr = {
|
|
|
10176
10205
|
className: `${A}__trigger`,
|
|
10177
10206
|
type: "button",
|
|
10178
10207
|
...q()
|
|
10179
|
-
},
|
|
10208
|
+
}, J), te && /* @__PURE__ */ e.createElement(S, null, /* @__PURE__ */ e.createElement("div", {
|
|
10180
10209
|
ref: L.setFloating,
|
|
10181
10210
|
className: `${A}__dropdown`,
|
|
10182
10211
|
style: {
|
|
10183
10212
|
...I,
|
|
10184
|
-
zIndex:
|
|
10213
|
+
zIndex: re
|
|
10185
10214
|
},
|
|
10186
10215
|
...G()
|
|
10187
|
-
}, /* @__PURE__ */ e.createElement("div", { style: { ...
|
|
10216
|
+
}, /* @__PURE__ */ e.createElement("div", { style: { ...ne } }, /* @__PURE__ */ e.createElement("ul", {
|
|
10188
10217
|
className: P,
|
|
10189
10218
|
role: "menu"
|
|
10190
10219
|
}, ie, /* @__PURE__ */ e.createElement("li", { role: "separator" }), ae, ce))))));
|
|
@@ -10208,9 +10237,9 @@ var Zr = {
|
|
|
10208
10237
|
role: "menu"
|
|
10209
10238
|
}), R = Bn("var(--pds-z-index-dropdown)"), z = u.find((e) => e.isActive);
|
|
10210
10239
|
z || (z = u[0]);
|
|
10211
|
-
let
|
|
10240
|
+
let ee = h(null);
|
|
10212
10241
|
p(() => {
|
|
10213
|
-
let e =
|
|
10242
|
+
let e = ee.current, t = e?.parentElement;
|
|
10214
10243
|
if (!e || !t) return;
|
|
10215
10244
|
let n = () => {
|
|
10216
10245
|
t.style.width = "";
|
|
@@ -10221,17 +10250,17 @@ var Zr = {
|
|
|
10221
10250
|
};
|
|
10222
10251
|
n(), document.fonts?.ready.then(n);
|
|
10223
10252
|
}, [z?.displayName]);
|
|
10224
|
-
let
|
|
10253
|
+
let B = m(() => {
|
|
10225
10254
|
if (!f) return u;
|
|
10226
10255
|
let e = f.toLowerCase();
|
|
10227
10256
|
return u.filter((t) => t.displayName?.toLowerCase().includes(e));
|
|
10228
|
-
}, [u, f]),
|
|
10257
|
+
}, [u, f]), V = m(() => {
|
|
10229
10258
|
if (!v) return u;
|
|
10230
10259
|
let e = v.toLowerCase();
|
|
10231
10260
|
return u.filter((t) => t.displayName?.toLowerCase().includes(e));
|
|
10232
|
-
}, [u, v]),
|
|
10261
|
+
}, [u, v]), H = (e) => {
|
|
10233
10262
|
e.preventDefault(), e.key === "Enter" && (P.current[O]?.querySelector("a") || P.current[O]?.querySelector("button"))?.click(), e.key === "Tab" && (e.shiftKey ? x ? document.getElementById("workspace-filter")?.focus() : I(!1) : r ? b.current?.querySelector("a")?.focus() : I(!1));
|
|
10234
|
-
},
|
|
10263
|
+
}, U = B.map((t, n) => {
|
|
10235
10264
|
let r = `${T}__item`, i = t.workspaceId, a = t.isRestricted && t.onRestrictedSelection, o = t.workspaceLink?.type, s = t.isUnprivileged ? null : (e) => {
|
|
10236
10265
|
P.current[n] = e;
|
|
10237
10266
|
};
|
|
@@ -10247,7 +10276,7 @@ var Zr = {
|
|
|
10247
10276
|
t.isRestricted ? `${r}--restricted` : null
|
|
10248
10277
|
]),
|
|
10249
10278
|
id: i,
|
|
10250
|
-
onKeyDown:
|
|
10279
|
+
onKeyDown: H,
|
|
10251
10280
|
role: "menuitem",
|
|
10252
10281
|
tabIndex: O === n ? 0 : -1,
|
|
10253
10282
|
...j()
|
|
@@ -10257,7 +10286,7 @@ var Zr = {
|
|
|
10257
10286
|
},
|
|
10258
10287
|
type: "button"
|
|
10259
10288
|
}, /* @__PURE__ */ e.createElement(Aa, { workspace: t })) : o ? /* @__PURE__ */ e.createElement(o, Object.assign({}, t.workspaceLink.props, { onClick: () => I(!1) }), /* @__PURE__ */ e.createElement(Aa, { workspace: t })) : null);
|
|
10260
|
-
}), W =
|
|
10289
|
+
}), W = V.map((t) => {
|
|
10261
10290
|
let n = `${T}__item`, r = t.workspaceId, i = t.isRestricted && t.onRestrictedSelection, a = t.workspaceLink?.type;
|
|
10262
10291
|
return /* @__PURE__ */ e.createElement("li", {
|
|
10263
10292
|
key: `${r}-accordion`,
|
|
@@ -10327,7 +10356,7 @@ var Zr = {
|
|
|
10327
10356
|
className: `${T}__trigger`,
|
|
10328
10357
|
type: "button",
|
|
10329
10358
|
...M()
|
|
10330
|
-
}, K(
|
|
10359
|
+
}, K(ee), /* @__PURE__ */ e.createElement(Q, {
|
|
10331
10360
|
className: `${T}__trigger-icon`,
|
|
10332
10361
|
iconName: "angleDown",
|
|
10333
10362
|
size: "m"
|
|
@@ -10355,7 +10384,7 @@ var Zr = {
|
|
|
10355
10384
|
}, /* @__PURE__ */ e.createElement("li", {
|
|
10356
10385
|
className: `pds-dropdown__heading ${T}__item-heading`,
|
|
10357
10386
|
role: "presentation"
|
|
10358
|
-
}, s),
|
|
10387
|
+
}, s), U.length === 0 ? /* @__PURE__ */ e.createElement("p", { className: "pds-dropdown__no-results" }, l) : U), G))));
|
|
10359
10388
|
}, Ma = {
|
|
10360
10389
|
info: "circleInfo",
|
|
10361
10390
|
warning: "triangleExclamation",
|
|
@@ -10664,9 +10693,9 @@ var Zr = {
|
|
|
10664
10693
|
}, [T]);
|
|
10665
10694
|
let z = c(() => {
|
|
10666
10695
|
O(!1);
|
|
10667
|
-
}, []),
|
|
10696
|
+
}, []), ee = c(() => {
|
|
10668
10697
|
D || E(!1);
|
|
10669
|
-
}, [D]),
|
|
10698
|
+
}, [D]), B = c(() => {
|
|
10670
10699
|
a || z();
|
|
10671
10700
|
}, [a, z]);
|
|
10672
10701
|
u(() => {
|
|
@@ -10676,18 +10705,18 @@ var Zr = {
|
|
|
10676
10705
|
};
|
|
10677
10706
|
return document.addEventListener("keydown", e), () => document.removeEventListener("keydown", e);
|
|
10678
10707
|
}, [T, z]);
|
|
10679
|
-
let
|
|
10708
|
+
let V = c(() => {
|
|
10680
10709
|
if (I.current) {
|
|
10681
10710
|
I.current = !1;
|
|
10682
10711
|
return;
|
|
10683
10712
|
}
|
|
10684
10713
|
z();
|
|
10685
|
-
}, [z]),
|
|
10714
|
+
}, [z]), H = c((e) => {
|
|
10686
10715
|
F.current = {
|
|
10687
10716
|
startY: e.clientY,
|
|
10688
10717
|
startHeight: N.current?.getBoundingClientRect().height ?? 0
|
|
10689
10718
|
}, M(!0), P.current?.setPointerCapture(e.pointerId);
|
|
10690
|
-
}, []),
|
|
10719
|
+
}, []), U = c((e) => {
|
|
10691
10720
|
let t = F.current, n = N.current;
|
|
10692
10721
|
if (!t || !n) return;
|
|
10693
10722
|
let r = e.clientY - t.startY, i = C ? window.innerHeight * .96 : t.startHeight;
|
|
@@ -10710,7 +10739,7 @@ var Zr = {
|
|
|
10710
10739
|
}
|
|
10711
10740
|
}, /* @__PURE__ */ e.createElement("div", { className: `${x}__wrapper` }, /* @__PURE__ */ e.createElement("div", {
|
|
10712
10741
|
className: Z([`${x}__scrim`, D ? `${x}__scrim--visible` : null]),
|
|
10713
|
-
onClick:
|
|
10742
|
+
onClick: B
|
|
10714
10743
|
}), /* @__PURE__ */ e.createElement("div", {
|
|
10715
10744
|
ref: N,
|
|
10716
10745
|
"aria-label": t || (typeof m == "string" ? m : void 0),
|
|
@@ -10721,7 +10750,7 @@ var Zr = {
|
|
|
10721
10750
|
j ? `${x}--dragging` : null,
|
|
10722
10751
|
r
|
|
10723
10752
|
]),
|
|
10724
|
-
onTransitionEnd:
|
|
10753
|
+
onTransitionEnd: ee,
|
|
10725
10754
|
role: "dialog",
|
|
10726
10755
|
style: w,
|
|
10727
10756
|
..._
|
|
@@ -10729,9 +10758,9 @@ var Zr = {
|
|
|
10729
10758
|
ref: P,
|
|
10730
10759
|
"aria-label": f,
|
|
10731
10760
|
className: `${x}__grabber`,
|
|
10732
|
-
onClick:
|
|
10733
|
-
onPointerDown:
|
|
10734
|
-
onPointerMove:
|
|
10761
|
+
onClick: V,
|
|
10762
|
+
onPointerDown: H,
|
|
10763
|
+
onPointerMove: U,
|
|
10735
10764
|
onPointerUp: W,
|
|
10736
10765
|
type: "button"
|
|
10737
10766
|
}), /* @__PURE__ */ e.createElement("span", {
|
|
@@ -10839,7 +10868,7 @@ var Zr = {
|
|
|
10839
10868
|
e || l();
|
|
10840
10869
|
},
|
|
10841
10870
|
open: c
|
|
10842
|
-
}), { getFloatingProps: v } = z([M(g, { outsidePressEvent: "mousedown" }),
|
|
10871
|
+
}), { getFloatingProps: v } = z([M(g, { outsidePressEvent: "mousedown" }), V(g, { role: "dialog" })]), { isMounted: b, styles: C } = H(g, {
|
|
10843
10872
|
duration: {
|
|
10844
10873
|
close: 200,
|
|
10845
10874
|
open: 250
|
|
@@ -10915,8 +10944,8 @@ var Zr = {
|
|
|
10915
10944
|
}), P = j(O), F = M(O, { outsidePressEvent: "mousedown" }), { getFloatingProps: I } = z([
|
|
10916
10945
|
P,
|
|
10917
10946
|
o ? void 0 : F,
|
|
10918
|
-
|
|
10919
|
-
]), { isMounted: L, styles: R } =
|
|
10947
|
+
V(O)
|
|
10948
|
+
]), { isMounted: L, styles: R } = H(O, {
|
|
10920
10949
|
duration: {
|
|
10921
10950
|
open: 300,
|
|
10922
10951
|
close: 300
|
|
@@ -11566,7 +11595,7 @@ var Zr = {
|
|
|
11566
11595
|
}, [d]), u(() => {
|
|
11567
11596
|
f(C);
|
|
11568
11597
|
}, [C]);
|
|
11569
|
-
let A = typeof a, P = "pds-popover", F = Z([`${P}__trigger-custom`, A === "string" ? `${P}__trigger-text` : ""]), I = a ? s : 0, L = h(null), { context: R, floatingStyles:
|
|
11598
|
+
let A = typeof a, P = "pds-popover", F = Z([`${P}__trigger-custom`, A === "string" ? `${P}__trigger-text` : ""]), I = a ? s : 0, L = h(null), { context: R, floatingStyles: ee, middlewareData: B, refs: U } = N({
|
|
11570
11599
|
placement: l,
|
|
11571
11600
|
open: C,
|
|
11572
11601
|
onOpenChange(e) {
|
|
@@ -11585,21 +11614,21 @@ var Zr = {
|
|
|
11585
11614
|
}, { getFloatingProps: K, getReferenceProps: q } = z([
|
|
11586
11615
|
j(R),
|
|
11587
11616
|
M(R),
|
|
11588
|
-
|
|
11589
|
-
]), te =
|
|
11617
|
+
V(R)
|
|
11618
|
+
]), te = B.arrow?.x ?? 0, ne = B.arrow?.y ?? 0, re = te + Do / 2, J = ne + Eo, { isMounted: ie } = H(R, {
|
|
11590
11619
|
initial: { transform: "scale(0)" },
|
|
11591
11620
|
common: ({ side: e }) => ({ transformOrigin: {
|
|
11592
|
-
top: `${
|
|
11593
|
-
bottom: `${
|
|
11594
|
-
left: `calc(100% + ${Eo}px) ${
|
|
11595
|
-
right: `-8px ${
|
|
11621
|
+
top: `${re}px calc(100% + ${Eo}px)`,
|
|
11622
|
+
bottom: `${re}px -8px`,
|
|
11623
|
+
left: `calc(100% + ${Eo}px) ${J}px`,
|
|
11624
|
+
right: `-8px ${J}px`
|
|
11596
11625
|
}[e] })
|
|
11597
11626
|
});
|
|
11598
11627
|
return /* @__PURE__ */ e.createElement("div", {
|
|
11599
11628
|
className: Z([P, t]),
|
|
11600
11629
|
...x
|
|
11601
11630
|
}, /* @__PURE__ */ e.createElement("span", {
|
|
11602
|
-
ref:
|
|
11631
|
+
ref: U.setReference,
|
|
11603
11632
|
className: `${P}__trigger`,
|
|
11604
11633
|
role: "button",
|
|
11605
11634
|
tabIndex: 0,
|
|
@@ -11614,10 +11643,10 @@ var Zr = {
|
|
|
11614
11643
|
initialFocus: -1,
|
|
11615
11644
|
modal: o
|
|
11616
11645
|
}, /* @__PURE__ */ e.createElement("div", {
|
|
11617
|
-
ref:
|
|
11646
|
+
ref: U.setFloating,
|
|
11618
11647
|
className: Z([`${P}__container`, n]),
|
|
11619
11648
|
style: {
|
|
11620
|
-
...
|
|
11649
|
+
...ee,
|
|
11621
11650
|
zIndex: W
|
|
11622
11651
|
},
|
|
11623
11652
|
...K()
|
|
@@ -11966,24 +11995,24 @@ function Yo(e) {
|
|
|
11966
11995
|
//#endregion
|
|
11967
11996
|
//#region src/components/SortableList/SortableList.tsx
|
|
11968
11997
|
var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ children: n, className: r, columns: i, defaultItems: a, getItemLabel: o = (e) => String(e.id), isDragEnabled: l, isItemLocked: u = () => !1, isNestingLocked: d = () => !1, items: p, maxDepth: _ = 0, onReorder: v, renderRow: y, reorderMode: b = "always", screenReaderInstructions: x, ...S }, C) {
|
|
11969
|
-
let w = "pds-sortable-list", [T, E] = g(null), D = h(null), [O, k] = g(!1), A = h(!1), [j, M] = g(null), N = h(0), P = h(0), F = h("pointer"), I = h(0), L = h(null), [R, z] = g(0),
|
|
11998
|
+
let w = "pds-sortable-list", [T, E] = g(null), D = h(null), [O, k] = g(!1), A = h(!1), [j, M] = g(null), N = h(0), P = h(0), F = h("pointer"), I = h(0), L = h(null), [R, z] = g(0), ee = h(0), [B, V] = g(0), H = h(0), U = c((e, t) => {
|
|
11970
11999
|
if (_ > 0 && (e.key === "ArrowLeft" || e.key === "ArrowRight")) {
|
|
11971
12000
|
e.preventDefault();
|
|
11972
|
-
let n = e.key === "ArrowRight" ? 1 : -1, r =
|
|
11973
|
-
return
|
|
12001
|
+
let n = e.key === "ArrowRight" ? 1 : -1, r = ee.current, i = Math.max(-_, Math.min(_, r + n)), a = i - r;
|
|
12002
|
+
return ee.current = i, z(i), {
|
|
11974
12003
|
x: t.currentCoordinates.x + a * Xo,
|
|
11975
12004
|
y: t.currentCoordinates.y
|
|
11976
12005
|
};
|
|
11977
12006
|
}
|
|
11978
12007
|
return rt(e, t);
|
|
11979
|
-
}, [_]), W = b === "always" || b === "toggle" && (l ?? !1), { currentItems: G, expandItem: K, flatNodes: q, handleReorder: te, resetToSnapshot:
|
|
12008
|
+
}, [_]), W = b === "always" || b === "toggle" && (l ?? !1), { currentItems: G, expandItem: K, flatNodes: q, handleReorder: te, resetToSnapshot: ne, sortableIds: re, toggleExpand: J } = qo({
|
|
11980
12009
|
defaultItems: a,
|
|
11981
12010
|
isDragEnabled: W,
|
|
11982
12011
|
items: p,
|
|
11983
12012
|
onReorder: v
|
|
11984
12013
|
});
|
|
11985
|
-
f(C, () => ({ resetToSnapshot:
|
|
11986
|
-
let ie = tt(et(Qe, { activationConstraint: { distance: 5 } }), et(Xe, { coordinateGetter:
|
|
12014
|
+
f(C, () => ({ resetToSnapshot: ne }), [ne]);
|
|
12015
|
+
let ie = tt(et(Qe, { activationConstraint: { distance: 5 } }), et(Xe, { coordinateGetter: U })), ae = W ? `${w}--reorder-active` : null, Y = m(() => new Set(q.filter((e) => u(e.data)).map((e) => e.id)), [q, u]), oe = m(() => new Set(q.filter((e) => d(e.data)).map((e) => e.id)), [q, d]), se = c((e) => {
|
|
11987
12016
|
if (_ === 0 || oe.has(String(e))) return !1;
|
|
11988
12017
|
let t = q.find((t) => t.id === e);
|
|
11989
12018
|
return !t || t.depth >= _ ? !1 : t.hasChildren ? !t.isExpanded : !0;
|
|
@@ -12005,11 +12034,11 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12005
12034
|
j
|
|
12006
12035
|
]).size > 0, ue = m(() => T ? q.find((e) => e.id === T) ?? null : null, [T, q]), de = m(() => T ? Wo(G, String(T)) ?? null : null, [T, G]), fe = m(() => {
|
|
12007
12036
|
let e = ue?.depth ?? 0;
|
|
12008
|
-
return !T || !j || O || _ === 0 ? e : Go(q, String(T), String(j),
|
|
12037
|
+
return !T || !j || O || _ === 0 ? e : Go(q, String(T), String(j), B * Xo, Xo, _);
|
|
12009
12038
|
}, [
|
|
12010
12039
|
T,
|
|
12011
12040
|
ue,
|
|
12012
|
-
|
|
12041
|
+
B,
|
|
12013
12042
|
q,
|
|
12014
12043
|
O,
|
|
12015
12044
|
_,
|
|
@@ -12027,8 +12056,8 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12027
12056
|
fe
|
|
12028
12057
|
]), me = c((e) => {
|
|
12029
12058
|
let { active: t } = e, n = F.current === "keyboard", r = q.find((e) => e.id === t.id);
|
|
12030
|
-
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,
|
|
12031
|
-
}, [q,
|
|
12059
|
+
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, H.current = 0, V(0), ee.current = 0, z(0), r?.hasChildren && r?.isExpanded && (J(String(t.id)), L.current = String(t.id));
|
|
12060
|
+
}, [q, J]), he = c((e) => {
|
|
12032
12061
|
let t = $e(e);
|
|
12033
12062
|
if (!t.length || !D.current || Y.size === 0) return t;
|
|
12034
12063
|
let n = q.findIndex((e) => e.id === D.current);
|
|
@@ -12039,7 +12068,7 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12039
12068
|
if (n === -1 || r === -1) return [e];
|
|
12040
12069
|
if (Y.has(String(t))) {
|
|
12041
12070
|
if (n > r) continue;
|
|
12042
|
-
let e = !oe.has(String(t)), i = _ > 0 &&
|
|
12071
|
+
let e = !oe.has(String(t)), i = _ > 0 && H.current > 0;
|
|
12043
12072
|
if (!se(t) && (!e || !i)) continue;
|
|
12044
12073
|
}
|
|
12045
12074
|
let [i, a] = n < r ? [n + 1, r - 1] : [r + 1, n - 1];
|
|
@@ -12060,14 +12089,14 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12060
12089
|
}
|
|
12061
12090
|
}
|
|
12062
12091
|
M(t);
|
|
12063
|
-
}, [q, Y]),
|
|
12092
|
+
}, [q, Y]), _e = c((e) => {
|
|
12064
12093
|
let t = e.delta.x;
|
|
12065
12094
|
if (P.current = t, A.current || _ === 0) return;
|
|
12066
|
-
let n = Math.floor(t / Xo), r =
|
|
12067
|
-
(n > r || n < r && t < r * Xo - Xo * .4) && (
|
|
12068
|
-
}, [_]),
|
|
12069
|
-
let { active: t, over: n } = e, r = A.current, i =
|
|
12070
|
-
E(null), D.current = null, k(!1), A.current = !1, M(null),
|
|
12095
|
+
let n = Math.floor(t / Xo), r = H.current;
|
|
12096
|
+
(n > r || n < r && t < r * Xo - Xo * .4) && (H.current = n, V(n));
|
|
12097
|
+
}, [_]), ve = c((e) => {
|
|
12098
|
+
let { active: t, over: n } = e, r = A.current, i = ee.current, a = H.current;
|
|
12099
|
+
E(null), D.current = null, k(!1), A.current = !1, M(null), H.current = 0, V(0), L.current && (K(L.current), L.current = null);
|
|
12071
12100
|
let o = q.findIndex((e) => e.id === t.id), s = r ? i * Xo : a * Xo, c = !n || t.id === n.id, l = n?.id ?? null;
|
|
12072
12101
|
if (r && i > 0 && c && o > 0 && (l = q[o - 1].id), !l || t.id === l) {
|
|
12073
12102
|
if (o === -1) return;
|
|
@@ -12118,8 +12147,8 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12118
12147
|
Y,
|
|
12119
12148
|
_,
|
|
12120
12149
|
oe
|
|
12121
|
-
]),
|
|
12122
|
-
E(null), D.current = null, k(!1), A.current = !1, M(null), P.current = 0,
|
|
12150
|
+
]), X = c(() => {
|
|
12151
|
+
E(null), D.current = null, k(!1), A.current = !1, M(null), P.current = 0, H.current = 0, V(0), ee.current = 0, z(0), L.current && (K(L.current), L.current = null);
|
|
12123
12152
|
}, [K]), ye = m(() => ({
|
|
12124
12153
|
onDragStart({ active: e }) {
|
|
12125
12154
|
let t = q.find((t) => t.id === e.id), n = Wo(G, String(e.id));
|
|
@@ -12155,14 +12184,14 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12155
12184
|
},
|
|
12156
12185
|
collisionDetection: he,
|
|
12157
12186
|
measuring: Zo,
|
|
12158
|
-
onDragCancel:
|
|
12159
|
-
onDragEnd:
|
|
12160
|
-
onDragMove:
|
|
12187
|
+
onDragCancel: X,
|
|
12188
|
+
onDragEnd: ve,
|
|
12189
|
+
onDragMove: _e,
|
|
12161
12190
|
onDragOver: ge,
|
|
12162
12191
|
onDragStart: me,
|
|
12163
12192
|
sensors: ie
|
|
12164
12193
|
}, /* @__PURE__ */ e.createElement(nt, {
|
|
12165
|
-
items:
|
|
12194
|
+
items: re,
|
|
12166
12195
|
strategy: ce
|
|
12167
12196
|
}, /* @__PURE__ */ e.createElement("div", {
|
|
12168
12197
|
className: Z([
|
|
@@ -12186,7 +12215,7 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12186
12215
|
isDragging: t.id === T,
|
|
12187
12216
|
isExpanded: t.isExpanded,
|
|
12188
12217
|
isLocked: Y.has(t.id),
|
|
12189
|
-
toggleExpand: () =>
|
|
12218
|
+
toggleExpand: () => J(t.id)
|
|
12190
12219
|
}, r = y(t.data, n), a = t.id === T, o = {
|
|
12191
12220
|
columns: i,
|
|
12192
12221
|
depth: t.depth,
|
|
@@ -12197,7 +12226,7 @@ var Xo = 24, Zo = { droppable: { strategy: Ze.Always } }, Qo = o(function({ chil
|
|
|
12197
12226
|
isProjectedParent: t.id === pe && !oe.has(t.id),
|
|
12198
12227
|
isExpanded: t.isExpanded,
|
|
12199
12228
|
...Y.has(t.id) ? { isLocked: !0 } : {},
|
|
12200
|
-
onToggleExpand: () =>
|
|
12229
|
+
onToggleExpand: () => J(t.id),
|
|
12201
12230
|
...a && !O && _ > 0 ? { projectedDepthDelta: fe - t.depth } : {}
|
|
12202
12231
|
};
|
|
12203
12232
|
return s(r) ? e.cloneElement(r, {
|
|
@@ -12574,51 +12603,51 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12574
12603
|
className: Z([a, t ?? ""]),
|
|
12575
12604
|
...i
|
|
12576
12605
|
}, /* @__PURE__ */ e.createElement("ol", { className: `${a}__steps` }, r && c));
|
|
12577
|
-
}, fs = ({ className: t, closeDetailPanelLabel: n = "Close detail panel", columns: r, currentPage: i, defaultSortKey: a, defaultSortOrder: o = "asc", density: s = "standard", detailPanelNav: c = !0, detailPanelTitle: l, detailPanelWidth: f, emptyState: p, emptyStateHeading: _ = "No results found.", emptyStateMessage: v, footer: y, getDetailPanelPositionLabel: b = (e, t) => `${e} of ${t}`, getPageSizeLabel: x = (e) => `Show ${e} rows per page`, getRowClassName: S, getRowId: C, getRowSelectDisabledReason: w, getSelectRowLabel: T = (e, t) => `Select row ${t}`, getSortLabel: E = (e) => `Sort by ${e}`, hasDesktopDetailPanel: D = !1, hasMobileCards: O = !1, hasMobileDetailSheet: k = !0, hasPanel: A = !1, inspectedRowId: j, isLoading: M = !1, isRowSelectable: N = () => !0, itemsPerPage: P, loadingRowCount: F = 5, maxHeight: I, minHeight: L, nextDetailPanelRowLabel: R = "Next row", onDetailPanelNext: z, onDetailPanelPrev:
|
|
12578
|
-
let le = "pds-table", ue = d(), de = d(), fe = h(null), pe = va() === "sm" && O, me = A && !pe, he = r.some((e) => e.cardVisible) ? r.filter((e) => e.cardVisible) : r.slice(0, 1), ge =
|
|
12606
|
+
}, fs = ({ className: t, closeDetailPanelLabel: n = "Close detail panel", columns: r, currentPage: i, defaultSortKey: a, defaultSortOrder: o = "asc", density: s = "standard", detailPanelNav: c = !0, detailPanelTitle: l, detailPanelWidth: f, emptyState: p, emptyStateHeading: _ = "No results found.", emptyStateMessage: v, footer: y, getDetailPanelPositionLabel: b = (e, t) => `${e} of ${t}`, getPageSizeLabel: x = (e) => `Show ${e} rows per page`, getRowClassName: S, getRowId: C, getRowSelectDisabledReason: w, getSelectRowLabel: T = (e, t) => `Select row ${t}`, getSortLabel: E = (e) => `Sort by ${e}`, hasDesktopDetailPanel: D = !1, hasMobileCards: O = !1, hasMobileDetailSheet: k = !0, hasPanel: A = !1, inspectedRowId: j, isLoading: M = !1, isRowSelectable: N = () => !0, itemsPerPage: P, loadingRowCount: F = 5, maxHeight: I, minHeight: L, nextDetailPanelRowLabel: R = "Next row", onDetailPanelNext: z, onDetailPanelPrev: ee, onPageChange: B, onPageSizeChange: V, onRowInspect: H, onRowSelectionChange: U, onSort: W, pageSizeOptions: G, pageSizeSelectLabel: K = "Rows per page", paginationLabels: q, prevDetailPanelRowLabel: te = "Previous row", renderDetailPanel: ne, renderDetailPanelFooter: re, rowData: J, selectAllLabel: ie = "Select all rows", selectedRows: ae, sortKey: Y, sortOrder: oe, totalItemCount: se, ...ce }) => {
|
|
12607
|
+
let le = "pds-table", ue = d(), de = d(), fe = h(null), pe = va() === "sm" && O, me = A && !pe, he = r.some((e) => e.cardVisible) ? r.filter((e) => e.cardVisible) : r.slice(0, 1), ge = ne !== void 0 || H === void 0 && k, _e = ne !== void 0 || H !== void 0 || k, ve = W !== void 0, X = B !== void 0, ye = V !== void 0, be = X || P !== void 0 || G !== void 0, xe = J.length > 0 || X && (se ?? 0) > 0, [Se, Ce] = g({
|
|
12579
12608
|
key: a ?? "",
|
|
12580
12609
|
order: a === void 0 ? "asc" : o
|
|
12581
12610
|
}), we = m(() => {
|
|
12582
|
-
if (
|
|
12611
|
+
if (ve || Se.key === "") return J;
|
|
12583
12612
|
let e = r.find((e) => e.id === Se.key)?.sortKey ?? Se.key;
|
|
12584
|
-
return [...
|
|
12613
|
+
return [...J].sort((t, n) => {
|
|
12585
12614
|
let r = String(t[e]).localeCompare(String(n[e]));
|
|
12586
12615
|
return Se.order === "asc" ? r : -r;
|
|
12587
12616
|
});
|
|
12588
12617
|
}, [
|
|
12589
|
-
|
|
12618
|
+
J,
|
|
12590
12619
|
Se,
|
|
12591
|
-
|
|
12620
|
+
ve,
|
|
12592
12621
|
r
|
|
12593
|
-
]), [Te, Ee] = g(1), [De, Oe] = g(P ?? G?.[0] ?? 10), [ke, Ae] = g(null), je = j ?? ke, Me = !!je && !!
|
|
12622
|
+
]), [Te, Ee] = g(1), [De, Oe] = g(P ?? G?.[0] ?? 10), [ke, Ae] = g(null), je = j ?? ke, Me = !!je && !!ne && D && !pe, Ne = pe && ge && !!je, [Pe, Fe] = g(null);
|
|
12594
12623
|
u(() => {
|
|
12595
12624
|
je && Fe(je);
|
|
12596
12625
|
}, [je]);
|
|
12597
|
-
let Ie =
|
|
12598
|
-
ye ?
|
|
12626
|
+
let Ie = X ? P ?? 10 : De, Le = (e) => {
|
|
12627
|
+
ye ? V(e) : Oe(e), X || Ee(1);
|
|
12599
12628
|
};
|
|
12600
12629
|
u(() => {
|
|
12601
|
-
|
|
12602
|
-
}, [
|
|
12603
|
-
process.env.NODE_ENV !== "production" && i !== void 0 && !
|
|
12630
|
+
X || Ee(1);
|
|
12631
|
+
}, [J.length, X]), u(() => {
|
|
12632
|
+
process.env.NODE_ENV !== "production" && i !== void 0 && !B && console.warn("[Table] `currentPage` was provided without `onPageChange`. Controlled pagination requires both props. The table is running in uncontrolled mode.");
|
|
12604
12633
|
}, []);
|
|
12605
|
-
let Re =
|
|
12634
|
+
let Re = U !== void 0, ze = ae !== void 0, [Be, Ve] = g(/* @__PURE__ */ new Set()), He = ze ? new Set(ae) : Be, Ue = m(() => new Map(J.map((e, t) => [e, t])), [J]), We = (e, t) => C ? C(e) : String(Ue.get(e) ?? t), Ge = m(() => we.findIndex((e, t) => (C ? C(e) : String(Ue.get(e) ?? t)) === je), [
|
|
12606
12635
|
we,
|
|
12607
12636
|
je,
|
|
12608
12637
|
C,
|
|
12609
12638
|
Ue
|
|
12610
12639
|
]), Ke = Ge >= 0 ? we[Ge] : null, qe = (e, t) => {
|
|
12611
|
-
(pe ? ge :
|
|
12640
|
+
(pe ? ge : ne !== void 0 && D) && j === void 0 && Ae(t), H?.(e, t);
|
|
12612
12641
|
}, Je = () => {
|
|
12613
12642
|
j === void 0 && Ae(null);
|
|
12614
12643
|
}, Ye = () => {
|
|
12615
12644
|
if (we.length === 0) return;
|
|
12616
12645
|
let e = (Ge - 1 + we.length) % we.length, t = we[e], n = We(t, e);
|
|
12617
|
-
j === void 0 && Ae(n),
|
|
12646
|
+
j === void 0 && Ae(n), H?.(t, n), ee?.(t, n);
|
|
12618
12647
|
}, Xe = () => {
|
|
12619
12648
|
if (we.length === 0) return;
|
|
12620
12649
|
let e = (Ge + 1) % we.length, t = we[e], n = We(t, e);
|
|
12621
|
-
j === void 0 && Ae(n),
|
|
12650
|
+
j === void 0 && Ae(n), H?.(t, n), z?.(t, n);
|
|
12622
12651
|
}, Ze = je ?? Pe, Qe = m(() => we.findIndex((e, t) => (C ? C(e) : String(Ue.get(e) ?? t)) === Ze), [
|
|
12623
12652
|
we,
|
|
12624
12653
|
Ze,
|
|
@@ -12660,23 +12689,23 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12660
12689
|
Me,
|
|
12661
12690
|
le
|
|
12662
12691
|
]);
|
|
12663
|
-
let rt =
|
|
12692
|
+
let rt = ve ? Y ?? "" : Se.key, it = ve ? oe ?? "asc" : Se.order, at = m(() => {
|
|
12664
12693
|
if (M) return [];
|
|
12665
12694
|
let e = we;
|
|
12666
|
-
if (!
|
|
12695
|
+
if (!X && be && Ie) {
|
|
12667
12696
|
let t = (Te - 1) * Ie;
|
|
12668
12697
|
e = e.slice(t, t + Ie);
|
|
12669
12698
|
}
|
|
12670
12699
|
return e;
|
|
12671
12700
|
}, [
|
|
12672
12701
|
we,
|
|
12673
|
-
|
|
12702
|
+
X,
|
|
12674
12703
|
be,
|
|
12675
12704
|
Te,
|
|
12676
12705
|
Ie,
|
|
12677
12706
|
M
|
|
12678
12707
|
]), ot = (e) => {
|
|
12679
|
-
|
|
12708
|
+
ve ? W(e, Y === e && oe === "asc" ? "desc" : "asc") : Ce((t) => ({
|
|
12680
12709
|
key: e,
|
|
12681
12710
|
order: t.key === e && t.order === "asc" ? "desc" : "asc"
|
|
12682
12711
|
}));
|
|
@@ -12690,10 +12719,10 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12690
12719
|
return N(t, r) && e.push(r), e;
|
|
12691
12720
|
}, []), ut = lt.length > 0 && lt.every((e) => He.has(e)), dt = !ut && lt.some((e) => He.has(e)), ft = (e) => {
|
|
12692
12721
|
let t = new Set(He);
|
|
12693
|
-
t.has(e) ? t.delete(e) : t.add(e), ze || Ve(t),
|
|
12722
|
+
t.has(e) ? t.delete(e) : t.add(e), ze || Ve(t), U?.(Array.from(t));
|
|
12694
12723
|
}, pt = () => {
|
|
12695
12724
|
let e = new Set(He);
|
|
12696
|
-
ut || dt ? lt.forEach((t) => e.delete(t)) : lt.forEach((t) => e.add(t)), ze || Ve(e),
|
|
12725
|
+
ut || dt ? lt.forEach((t) => e.delete(t)) : lt.forEach((t) => e.add(t)), ze || Ve(e), U?.(Array.from(e));
|
|
12697
12726
|
}, mt = (t) => /* @__PURE__ */ e.createElement("tr", { key: `skeleton-${t}` }, Re && /* @__PURE__ */ e.createElement("td", { className: "pds-table__checkbox-cell" }, /* @__PURE__ */ e.createElement(Rr, {
|
|
12698
12727
|
shape: "rounded",
|
|
12699
12728
|
size: {
|
|
@@ -12714,7 +12743,7 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12714
12743
|
iconName: "emptySet",
|
|
12715
12744
|
message: v
|
|
12716
12745
|
}))), gt = (t, n) => {
|
|
12717
|
-
let i = We(t, n), a =
|
|
12746
|
+
let i = We(t, n), a = H !== void 0 && ne === void 0 || ne !== void 0 && D, o = a && je === i, s = N(t, i), c = s ? void 0 : w?.(t, i), l = T(t, n + 1), u = c ? `${l} (${c})` : l;
|
|
12718
12747
|
return /* @__PURE__ */ e.createElement("tr", {
|
|
12719
12748
|
key: `row-${i}`,
|
|
12720
12749
|
"aria-selected": a ? o : void 0,
|
|
@@ -12748,7 +12777,7 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12748
12777
|
iconName: "emptySet",
|
|
12749
12778
|
message: v
|
|
12750
12779
|
})), bt = (t, n) => {
|
|
12751
|
-
let r = We(t, n), i = !Re &&
|
|
12780
|
+
let r = We(t, n), i = !Re && _e && je === r, a = Re && He.has(r), [o, ...s] = he, c = N(t, r), l = c ? void 0 : w?.(t, r), u = T(t, n + 1), d = l ? `${u} (${l})` : u, f = /* @__PURE__ */ e.createElement("div", { className: `${le}__card-main` }, Re && /* @__PURE__ */ e.createElement("span", {
|
|
12752
12781
|
"aria-hidden": "true",
|
|
12753
12782
|
className: "pds-checkbox"
|
|
12754
12783
|
}, /* @__PURE__ */ e.createElement("span", { className: Z(["pds-checkbox__box", a ? "pds-checkbox__box--checked" : null]) }, a && /* @__PURE__ */ e.createElement("svg", {
|
|
@@ -12758,13 +12787,13 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12758
12787
|
viewBox: "0 0 12 12",
|
|
12759
12788
|
width: "12",
|
|
12760
12789
|
xmlns: "http://www.w3.org/2000/svg"
|
|
12761
|
-
}, /* @__PURE__ */ e.createElement("path", { d: "M9.85474 3.64666C10.1032 3.32078 10.0258 2.86817 9.67727 2.63583C9.32878 2.4035 8.84476 2.47591 8.5963 2.80179L4.8694 7.65977L3.32056 6.21143C3.01724 5.9278 2.52677 5.9278 2.22669 6.21143C1.9266 6.49506 1.92337 6.9537 2.22346 7.23734L4.41765 9.28916C4.57899 9.44003 4.80164 9.51546 5.02751 9.49736C5.25338 9.47925 5.4599 9.37063 5.59219 9.19864L9.85151 3.64666H9.85474Z" })))), /* @__PURE__ */ e.createElement("div", { className: `${le}__card-body` }, o && /* @__PURE__ */ e.createElement("div", { className: `${le}__card-title` }, t[o.id]), s.length > 0 && /* @__PURE__ */ e.createElement("div", { className: `${le}__card-meta` }, s.map((n) => /* @__PURE__ */ e.createElement(e.Fragment, { key: n.id }, /* @__PURE__ */ e.createElement("span", null, /* @__PURE__ */ e.createElement("span", { className: "visually-hidden" }, On(n.header), ":", " "), t[n.id]))))), !Re &&
|
|
12790
|
+
}, /* @__PURE__ */ e.createElement("path", { d: "M9.85474 3.64666C10.1032 3.32078 10.0258 2.86817 9.67727 2.63583C9.32878 2.4035 8.84476 2.47591 8.5963 2.80179L4.8694 7.65977L3.32056 6.21143C3.01724 5.9278 2.52677 5.9278 2.22669 6.21143C1.9266 6.49506 1.92337 6.9537 2.22346 7.23734L4.41765 9.28916C4.57899 9.44003 4.80164 9.51546 5.02751 9.49736C5.25338 9.47925 5.4599 9.37063 5.59219 9.19864L9.85151 3.64666H9.85474Z" })))), /* @__PURE__ */ e.createElement("div", { className: `${le}__card-body` }, o && /* @__PURE__ */ e.createElement("div", { className: `${le}__card-title` }, t[o.id]), s.length > 0 && /* @__PURE__ */ e.createElement("div", { className: `${le}__card-meta` }, s.map((n) => /* @__PURE__ */ e.createElement(e.Fragment, { key: n.id }, /* @__PURE__ */ e.createElement("span", null, /* @__PURE__ */ e.createElement("span", { className: "visually-hidden" }, On(n.header), ":", " "), t[n.id]))))), !Re && _e && /* @__PURE__ */ e.createElement(Q, {
|
|
12762
12791
|
className: `${le}__card-chevron`,
|
|
12763
12792
|
iconName: "angleRight",
|
|
12764
12793
|
size: "m"
|
|
12765
12794
|
})), p = Z([
|
|
12766
12795
|
`${le}__card`,
|
|
12767
|
-
Re ? `${le}__card--selectable` :
|
|
12796
|
+
Re ? `${le}__card--selectable` : _e ? `${le}__row--inspectable` : null,
|
|
12768
12797
|
i || a ? `${le}__row--inspected` : null,
|
|
12769
12798
|
S?.(t, r) ?? null
|
|
12770
12799
|
]);
|
|
@@ -12777,7 +12806,7 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12777
12806
|
role: "checkbox",
|
|
12778
12807
|
title: l,
|
|
12779
12808
|
type: "button"
|
|
12780
|
-
}, f)) : /* @__PURE__ */ e.createElement("li", { key: `card-${r}` },
|
|
12809
|
+
}, f)) : /* @__PURE__ */ e.createElement("li", { key: `card-${r}` }, _e ? /* @__PURE__ */ e.createElement("button", {
|
|
12781
12810
|
className: p,
|
|
12782
12811
|
onClick: () => qe(t, r),
|
|
12783
12812
|
type: "button"
|
|
@@ -12845,17 +12874,17 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12845
12874
|
size: "s",
|
|
12846
12875
|
value: String(Ie)
|
|
12847
12876
|
}), /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__pagination-controls" }, /* @__PURE__ */ e.createElement(lo, {
|
|
12848
|
-
currentPage:
|
|
12877
|
+
currentPage: X ? i ?? 1 : Te,
|
|
12849
12878
|
itemsPerPage: Ie,
|
|
12850
12879
|
labelStrings: q,
|
|
12851
|
-
onPageChange:
|
|
12880
|
+
onPageChange: X ? B : Ee,
|
|
12852
12881
|
pageControlType: pe ? "static" : "dropdown",
|
|
12853
|
-
totalItemCount:
|
|
12854
|
-
}))), y && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__footer" }, y)),
|
|
12882
|
+
totalItemCount: X ? se ?? 0 : J.length
|
|
12883
|
+
}))), y && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__footer" }, y)), ne && /* @__PURE__ */ e.createElement("div", { className: Z(["pds-table-wrapper__detail-panel", Me ? "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" }, l && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-title" }, l), /* @__PURE__ */ e.createElement(Pn, {
|
|
12855
12884
|
ariaLabel: n,
|
|
12856
12885
|
onClick: Je,
|
|
12857
12886
|
size: "s"
|
|
12858
|
-
})), /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-content" }, Me && Ke &&
|
|
12887
|
+
})), /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-content" }, Me && Ke && ne(Ke, et))), Me && Ke && (re || c) && /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-footer" }, re ? re(Ke, et) : /* @__PURE__ */ e.createElement("div", { className: "pds-table-wrapper__detail-panel-nav" }, /* @__PURE__ */ e.createElement(Mn, {
|
|
12859
12888
|
hasBorder: !0,
|
|
12860
12889
|
ariaLabel: te,
|
|
12861
12890
|
disabled: !et.hasPrev,
|
|
@@ -12878,10 +12907,10 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
12878
12907
|
e || Je();
|
|
12879
12908
|
},
|
|
12880
12909
|
title: l
|
|
12881
|
-
}, $e && (
|
|
12910
|
+
}, $e && (ne ? ne($e, tt) : _t($e)), $e && (re || c) && /* @__PURE__ */ e.createElement("div", {
|
|
12882
12911
|
className: `${le}-wrapper__mobile-sheet-nav`,
|
|
12883
12912
|
slot: "footer"
|
|
12884
|
-
},
|
|
12913
|
+
}, re ? re($e, tt) : /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement(Mn, {
|
|
12885
12914
|
hasBorder: !0,
|
|
12886
12915
|
ariaLabel: te,
|
|
12887
12916
|
disabled: !tt.hasPrev,
|
|
@@ -13218,14 +13247,14 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
13218
13247
|
expandSidebar: "Press ] to expand sidebar",
|
|
13219
13248
|
skipToContent: "Skip to main content",
|
|
13220
13249
|
...f
|
|
13221
|
-
}, I = y?.id ?? "app-layout-main", L = v == null ? void 0 : typeof v == "number" ? `${v}px` : v, R = k == null ? void 0 : typeof k == "number" ? `${k}px` : k, z = j ? `${w}rem` : `${T}`,
|
|
13250
|
+
}, I = y?.id ?? "app-layout-main", L = v == null ? void 0 : typeof v == "number" ? `${v}px` : v, R = k == null ? void 0 : typeof k == "number" ? `${k}px` : k, z = j ? `${w}rem` : `${T}`, ee = {
|
|
13222
13251
|
backgroundColor: C || void 0,
|
|
13223
13252
|
maxWidth: j ? void 0 : `${E}rem`,
|
|
13224
13253
|
minWidth: j ? `${w}rem` : `${D}rem`,
|
|
13225
13254
|
width: z
|
|
13226
|
-
},
|
|
13227
|
-
if (!
|
|
13228
|
-
if (
|
|
13255
|
+
}, B = h(!1), V = va(), H = V === "sm", U = () => {
|
|
13256
|
+
if (!H) {
|
|
13257
|
+
if (B.current = !1, x) {
|
|
13229
13258
|
x();
|
|
13230
13259
|
return;
|
|
13231
13260
|
}
|
|
@@ -13233,13 +13262,13 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
13233
13262
|
}
|
|
13234
13263
|
};
|
|
13235
13264
|
u(() => {
|
|
13236
|
-
|
|
13237
|
-
}, [
|
|
13238
|
-
let W = d && s && !
|
|
13265
|
+
V === "sm" && !j ? (B.current = !0, x ? x() : M(!0)) : V !== "sm" && B.current && (B.current = !1, x ? x() : M(!1));
|
|
13266
|
+
}, [V]);
|
|
13267
|
+
let W = d && s && !H;
|
|
13239
13268
|
nn("[", (e) => {
|
|
13240
|
-
e.preventDefault(), j ||
|
|
13269
|
+
e.preventDefault(), j || U();
|
|
13241
13270
|
}, { enabled: W }), nn("]", (e) => {
|
|
13242
|
-
e.preventDefault(), j &&
|
|
13271
|
+
e.preventDefault(), j && U();
|
|
13243
13272
|
}, { enabled: W });
|
|
13244
13273
|
let G = h(null);
|
|
13245
13274
|
p(() => {
|
|
@@ -13261,14 +13290,14 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
13261
13290
|
r.disconnect(), i?.disconnect(), window.removeEventListener("resize", t);
|
|
13262
13291
|
};
|
|
13263
13292
|
}, [R]);
|
|
13264
|
-
let K = gt(t), q = K.__unslotted, te = K.header,
|
|
13293
|
+
let K = gt(t), q = K.__unslotted, te = K.header, ne = K.footer, re = K.sidebar, J = K.identity, ie = K["content-top"], ae = K.navigation, Y = K["content-bottom"], oe = J || ie || ae || Y, se = oe ? /* @__PURE__ */ e.createElement(e.Fragment, null, (J || o) && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-identity` }, J, o && !j && /* @__PURE__ */ e.createElement(Mn, {
|
|
13265
13294
|
hasBorder: !0,
|
|
13266
13295
|
ariaLabel: F.drawerToggle,
|
|
13267
13296
|
className: `${N}__drawer-toggle`,
|
|
13268
13297
|
iconName: "sidebar",
|
|
13269
13298
|
onClick: b,
|
|
13270
13299
|
size: "s"
|
|
13271
|
-
})), ie && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-content-top` }, ie), ae && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-navigation` }, ae), Y && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-content-bottom` }, Y)) :
|
|
13300
|
+
})), ie && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-content-top` }, ie), ae && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-navigation` }, ae), Y && /* @__PURE__ */ e.createElement("div", { className: `${N}__sidebar-content-bottom` }, Y)) : re, ce = a(_, {
|
|
13272
13301
|
...y,
|
|
13273
13302
|
className: Z([`${N}__main`, y?.className]),
|
|
13274
13303
|
id: I,
|
|
@@ -13283,18 +13312,18 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
13283
13312
|
}, q)), le = /* @__PURE__ */ e.createElement("div", {
|
|
13284
13313
|
className: `${N}__content-column`,
|
|
13285
13314
|
style: { backgroundColor: m || void 0 }
|
|
13286
|
-
}, ce,
|
|
13315
|
+
}, ce, ne && /* @__PURE__ */ e.createElement("div", { className: `${N}__footer` }, /* @__PURE__ */ e.createElement("div", {
|
|
13287
13316
|
className: `${N}__footer-inner`,
|
|
13288
13317
|
style: { maxWidth: L }
|
|
13289
|
-
},
|
|
13318
|
+
}, ne))), ue = /* @__PURE__ */ e.createElement(e.Fragment, null, (re || oe) && /* @__PURE__ */ e.createElement("div", {
|
|
13290
13319
|
...O,
|
|
13291
13320
|
className: Z([
|
|
13292
13321
|
`${N}__sidebar`,
|
|
13293
13322
|
j ? `${N}__sidebar--collapsed` : null,
|
|
13294
13323
|
O?.className
|
|
13295
13324
|
]),
|
|
13296
|
-
style:
|
|
13297
|
-
}, s && !
|
|
13325
|
+
style: ee
|
|
13326
|
+
}, s && !H && /* @__PURE__ */ e.createElement(an, {
|
|
13298
13327
|
disableTapTrigger: !0,
|
|
13299
13328
|
className: `${N}__sidebar-toggle-tooltip`,
|
|
13300
13329
|
content: j ? F.expandSidebar : F.collapseSidebar,
|
|
@@ -13302,7 +13331,7 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
13302
13331
|
"aria-expanded": !j,
|
|
13303
13332
|
"aria-label": j ? F.expandSidebar : F.collapseSidebar,
|
|
13304
13333
|
className: `${N}__sidebar-toggle-button`,
|
|
13305
|
-
onClick:
|
|
13334
|
+
onClick: U,
|
|
13306
13335
|
type: "button"
|
|
13307
13336
|
}, /* @__PURE__ */ e.createElement("span", { className: `${N}__sidebar-toggle-icon` }, /* @__PURE__ */ e.createElement(Q, {
|
|
13308
13337
|
iconName: "angleLeft",
|
|
@@ -13441,32 +13470,54 @@ var es = ({ children: t, className: n, columns: r, depth: i = 0, hasChildren: a
|
|
|
13441
13470
|
]),
|
|
13442
13471
|
...o
|
|
13443
13472
|
}, /* @__PURE__ */ e.createElement("div", { className: m.join(" ").trim() }, _), /* @__PURE__ */ e.createElement("div", { className: h.join(" ").trim() }, v));
|
|
13444
|
-
}, Ls = ({ alignContent: t = "flex-start", alignItems: n = "stretch",
|
|
13445
|
-
let
|
|
13473
|
+
}, Ls = ({ alignContent: t = "flex-start", alignItems: n = "stretch", asContainer: r = !1, children: i, className: a, containerAlignContent: o, containerAlignItems: s, containerFlexDirection: c, containerFlexWrap: l, containerGap: u, containerJustifyContent: d, containerQueryPriority: f = "container", flexDirection: p = "row", flexWrap: m = "nowrap", gap: h = "xl", justifyContent: g = "flex-start", mobileAlignContent: _, mobileAlignItems: v, mobileFlexDirection: y, mobileFlexWrap: b, mobileGap: x, mobileJustifyContent: S, stackBelow: C, style: w, ...T }) => {
|
|
13474
|
+
let E = "pds-flex", D = `${E}-container`, O = {
|
|
13446
13475
|
"--pds-flex-align-content": t,
|
|
13447
13476
|
"--pds-flex-align-items": n,
|
|
13448
|
-
"--pds-flex-direction":
|
|
13449
|
-
"--pds-flex-justify-content":
|
|
13450
|
-
"--pds-flex-wrap":
|
|
13451
|
-
"--pds-flex-align-content-mobile":
|
|
13452
|
-
"--pds-flex-align-items-mobile":
|
|
13453
|
-
"--pds-flex-direction-mobile":
|
|
13454
|
-
"--pds-flex-justify-content-mobile":
|
|
13455
|
-
"--pds-flex-wrap-mobile":
|
|
13456
|
-
|
|
13477
|
+
"--pds-flex-direction": p,
|
|
13478
|
+
"--pds-flex-justify-content": g,
|
|
13479
|
+
"--pds-flex-wrap": m,
|
|
13480
|
+
"--pds-flex-align-content-mobile": _ ?? t,
|
|
13481
|
+
"--pds-flex-align-items-mobile": v ?? n,
|
|
13482
|
+
"--pds-flex-direction-mobile": y ?? p,
|
|
13483
|
+
"--pds-flex-justify-content-mobile": S ?? g,
|
|
13484
|
+
"--pds-flex-wrap-mobile": b ?? m,
|
|
13485
|
+
"--pds-flex-align-content-container": o ?? t,
|
|
13486
|
+
"--pds-flex-align-items-container": s ?? n,
|
|
13487
|
+
"--pds-flex-direction-container": c ?? p,
|
|
13488
|
+
"--pds-flex-justify-content-container": d ?? g,
|
|
13489
|
+
"--pds-flex-wrap-container": l ?? m
|
|
13490
|
+
}, k = x ?? h, A = h === "none" ? null : `${E}-gap--${h}`, j = k === h ? null : `${E}-gap-mobile--${k}`, M = u ?? h, N = Z([
|
|
13491
|
+
D,
|
|
13492
|
+
A,
|
|
13493
|
+
j,
|
|
13494
|
+
C && M !== h ? `${E}-gap-container--${M}` : null,
|
|
13495
|
+
C && f === "mobile" ? `${D}--priority-mobile` : null
|
|
13496
|
+
]);
|
|
13497
|
+
if (!C && !r) return /* @__PURE__ */ e.createElement("div", {
|
|
13498
|
+
className: Z([N, a ?? ""]),
|
|
13499
|
+
style: {
|
|
13500
|
+
...O,
|
|
13501
|
+
...w
|
|
13502
|
+
},
|
|
13503
|
+
...T
|
|
13504
|
+
}, i);
|
|
13505
|
+
let P = `${D}-query`, F = C ? `${P}--stack-${C}` : null;
|
|
13457
13506
|
return /* @__PURE__ */ e.createElement("div", {
|
|
13458
13507
|
className: Z([
|
|
13459
|
-
|
|
13460
|
-
|
|
13461
|
-
|
|
13462
|
-
i ?? ""
|
|
13508
|
+
P,
|
|
13509
|
+
F,
|
|
13510
|
+
a ?? ""
|
|
13463
13511
|
]),
|
|
13512
|
+
style: w,
|
|
13513
|
+
...T
|
|
13514
|
+
}, /* @__PURE__ */ e.createElement("div", {
|
|
13515
|
+
className: N,
|
|
13464
13516
|
style: {
|
|
13465
|
-
|
|
13466
|
-
...
|
|
13467
|
-
}
|
|
13468
|
-
|
|
13469
|
-
}, r);
|
|
13517
|
+
width: "100%",
|
|
13518
|
+
...O
|
|
13519
|
+
}
|
|
13520
|
+
}, i));
|
|
13470
13521
|
}, Rs = [
|
|
13471
13522
|
"light",
|
|
13472
13523
|
"dark",
|