@namroodinc/liquid-editorial 0.13.4 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -6
- package/UPGRADING.md +77 -0
- package/dist/chunks/{Avatar-UjhjcHh5.js → Avatar-BToMaTdL.js} +2 -2
- package/dist/chunks/{Avatar-UjhjcHh5.js.map → Avatar-BToMaTdL.js.map} +1 -1
- package/dist/chunks/{Avatar-BY0dAItT.cjs → Avatar-Dw7EWd_-.cjs} +2 -2
- package/dist/chunks/{Avatar-BY0dAItT.cjs.map → Avatar-Dw7EWd_-.cjs.map} +1 -1
- package/dist/chunks/{Board-CQ1GTuRB.cjs → Board-DeXtaWNO.cjs} +2 -2
- package/dist/chunks/{Board-CQ1GTuRB.cjs.map → Board-DeXtaWNO.cjs.map} +1 -1
- package/dist/chunks/{Board-DUX76d2R.js → Board-XeDG9nWP.js} +2 -2
- package/dist/chunks/{Board-DUX76d2R.js.map → Board-XeDG9nWP.js.map} +1 -1
- package/dist/chunks/{CollectionView-JRNdXHti.js → CollectionView-C0_bTO2v.js} +2 -2
- package/dist/chunks/{CollectionView-JRNdXHti.js.map → CollectionView-C0_bTO2v.js.map} +1 -1
- package/dist/chunks/{CollectionView-CIJdNwcq.cjs → CollectionView-Dbg4d_tA.cjs} +2 -2
- package/dist/chunks/{CollectionView-CIJdNwcq.cjs.map → CollectionView-Dbg4d_tA.cjs.map} +1 -1
- package/dist/chunks/{ColourField-BG5oGj9f.js → ColourField-Bb8H87fg.js} +3 -3
- package/dist/chunks/{ColourField-BG5oGj9f.js.map → ColourField-Bb8H87fg.js.map} +1 -1
- package/dist/chunks/{ColourField-DFvRASVe.cjs → ColourField-DAFzOIOq.cjs} +2 -2
- package/dist/chunks/{ColourField-DFvRASVe.cjs.map → ColourField-DAFzOIOq.cjs.map} +1 -1
- package/dist/chunks/{DatePicker-LqaePc57.js → DatePicker-COm1giw8.js} +3 -3
- package/dist/chunks/{DatePicker-LqaePc57.js.map → DatePicker-COm1giw8.js.map} +1 -1
- package/dist/chunks/{DatePicker-ClOqS6oH.cjs → DatePicker-DOg3iQYy.cjs} +2 -2
- package/dist/chunks/{DatePicker-ClOqS6oH.cjs.map → DatePicker-DOg3iQYy.cjs.map} +1 -1
- package/dist/chunks/{Drawer-DdIH9jpe.cjs → Drawer-B2dcTh5l.cjs} +2 -2
- package/dist/chunks/{Drawer-DdIH9jpe.cjs.map → Drawer-B2dcTh5l.cjs.map} +1 -1
- package/dist/chunks/{Drawer-Ck5XKT_V.js → Drawer-nUTJtwX_.js} +3 -3
- package/dist/chunks/{Drawer-Ck5XKT_V.js.map → Drawer-nUTJtwX_.js.map} +1 -1
- package/dist/chunks/EntryPicker-BwEYRtQl.cjs +2 -0
- package/dist/chunks/EntryPicker-BwEYRtQl.cjs.map +1 -0
- package/dist/chunks/{use-picker-session-BSpOwnQ-.js → EntryPicker-Ie9T47hA.js} +367 -202
- package/dist/chunks/EntryPicker-Ie9T47hA.js.map +1 -0
- package/dist/chunks/FormEditor-D1HUnjMI.cjs +2 -0
- package/dist/chunks/FormEditor-D1HUnjMI.cjs.map +1 -0
- package/dist/chunks/FormEditor-DgDV5aeR.js +30 -0
- package/dist/chunks/FormEditor-DgDV5aeR.js.map +1 -0
- package/dist/chunks/Icon-Bxvp1-td.js +102 -0
- package/dist/chunks/Icon-Bxvp1-td.js.map +1 -0
- package/dist/chunks/{Icon-3ucBRgrd.cjs → Icon-CnnTrtNb.cjs} +2 -2
- package/dist/chunks/Icon-CnnTrtNb.cjs.map +1 -0
- package/dist/chunks/Message-B0A5bz8V.cjs +2 -0
- package/dist/chunks/{Message-Ce2zjtfz.cjs.map → Message-B0A5bz8V.cjs.map} +1 -1
- package/dist/chunks/{Message-DNaudg1u.js → Message-VJTPhId7.js} +3 -3
- package/dist/chunks/{Message-DNaudg1u.js.map → Message-VJTPhId7.js.map} +1 -1
- package/dist/chunks/RichTextEditor-DPhEkDxi.js +2108 -0
- package/dist/chunks/RichTextEditor-DPhEkDxi.js.map +1 -0
- package/dist/chunks/RichTextEditor-DV7NZp_k.cjs +2 -0
- package/dist/chunks/RichTextEditor-DV7NZp_k.cjs.map +1 -0
- package/dist/chunks/{dialogLabel-DT7rCr3_.js → dialogLabel-C153NosD.js} +2 -2
- package/dist/chunks/{dialogLabel-DT7rCr3_.js.map → dialogLabel-C153NosD.js.map} +1 -1
- package/dist/chunks/{dialogLabel-_-MTckE_.cjs → dialogLabel-CNNQbtob.cjs} +2 -2
- package/dist/chunks/{dialogLabel-_-MTckE_.cjs.map → dialogLabel-CNNQbtob.cjs.map} +1 -1
- package/dist/chunks/overlayLayer-CtOTt1xB.cjs +2 -0
- package/dist/chunks/overlayLayer-CtOTt1xB.cjs.map +1 -0
- package/dist/chunks/{overlayLayer-lU4iWSjO.js → overlayLayer-Og07sIyl.js} +21 -3
- package/dist/chunks/overlayLayer-Og07sIyl.js.map +1 -0
- package/dist/chunks/{useTooltip-DnJEFBLg.js → useTooltip-Du8PutGX.js} +2 -2
- package/dist/chunks/{useTooltip-DnJEFBLg.js.map → useTooltip-Du8PutGX.js.map} +1 -1
- package/dist/chunks/{useTooltip-C7ON4nkV.cjs → useTooltip-ekdwMJFz.cjs} +2 -2
- package/dist/chunks/{useTooltip-C7ON4nkV.cjs.map → useTooltip-ekdwMJFz.cjs.map} +1 -1
- package/dist/components/AppShell/index.cjs +1 -1
- package/dist/components/AppShell/index.js +1 -1
- package/dist/components/AssetCard/index.cjs +1 -1
- package/dist/components/AssetCard/index.js +1 -1
- package/dist/components/AssetGrid/index.cjs +1 -1
- package/dist/components/AssetGrid/index.js +1 -1
- package/dist/components/Avatar/index.cjs +1 -1
- package/dist/components/Avatar/index.js +1 -1
- package/dist/components/Banner/index.cjs +1 -1
- package/dist/components/Banner/index.js +1 -1
- package/dist/components/Board/index.cjs +1 -1
- package/dist/components/Board/index.js +1 -1
- package/dist/components/Button/index.cjs +1 -1
- package/dist/components/Button/index.js +1 -1
- package/dist/components/Choice/index.cjs +1 -1
- package/dist/components/Choice/index.cjs.map +1 -1
- package/dist/components/Choice/index.js +5 -5
- package/dist/components/CollectionView/index.cjs +1 -1
- package/dist/components/CollectionView/index.js +1 -1
- package/dist/components/ColourField/index.cjs +1 -1
- package/dist/components/ColourField/index.js +1 -1
- package/dist/components/DatePicker/index.cjs +1 -1
- package/dist/components/DatePicker/index.js +1 -1
- package/dist/components/Drawer/index.cjs +1 -1
- package/dist/components/Drawer/index.js +1 -1
- package/dist/components/EditLayout/index.cjs +1 -1
- package/dist/components/EditLayout/index.js +4 -4
- package/dist/components/EntryPicker/dialog.d.cts +11 -1
- package/dist/components/EntryPicker/dialog.d.cts.map +1 -1
- package/dist/components/EntryPicker/dialog.d.ts +11 -1
- package/dist/components/EntryPicker/dialog.d.ts.map +1 -1
- package/dist/components/EntryPicker/index.cjs +1 -1
- package/dist/components/EntryPicker/index.js +1 -1
- package/dist/components/EntryPicker/use-picker-data.d.cts +1 -1
- package/dist/components/EntryPicker/use-picker-data.d.cts.map +1 -1
- package/dist/components/EntryPicker/use-picker-data.d.ts +1 -1
- package/dist/components/EntryPicker/use-picker-data.d.ts.map +1 -1
- package/dist/components/EntryPicker/use-picker-session.d.cts +4 -1
- package/dist/components/EntryPicker/use-picker-session.d.cts.map +1 -1
- package/dist/components/EntryPicker/use-picker-session.d.ts +4 -1
- package/dist/components/EntryPicker/use-picker-session.d.ts.map +1 -1
- package/dist/components/EntryPicker/use-selected-items.d.cts +2 -0
- package/dist/components/EntryPicker/use-selected-items.d.cts.map +1 -1
- package/dist/components/EntryPicker/use-selected-items.d.ts +2 -0
- package/dist/components/EntryPicker/use-selected-items.d.ts.map +1 -1
- package/dist/components/FormEditor/README.md +155 -24
- package/dist/components/FormEditor/control.d.cts +11 -2
- package/dist/components/FormEditor/control.d.cts.map +1 -1
- package/dist/components/FormEditor/control.d.ts +11 -2
- package/dist/components/FormEditor/control.d.ts.map +1 -1
- package/dist/components/FormEditor/form.d.cts +33 -0
- package/dist/components/FormEditor/form.d.cts.map +1 -0
- package/dist/components/FormEditor/form.d.ts +33 -0
- package/dist/components/FormEditor/form.d.ts.map +1 -0
- package/dist/components/FormEditor/index.cjs +1 -1
- package/dist/components/FormEditor/index.d.cts +3 -27
- package/dist/components/FormEditor/index.d.cts.map +1 -1
- package/dist/components/FormEditor/index.d.ts +3 -27
- package/dist/components/FormEditor/index.d.ts.map +1 -1
- package/dist/components/FormEditor/index.js +3 -3
- package/dist/components/FormEditor/model.d.cts +2 -0
- package/dist/components/FormEditor/model.d.cts.map +1 -1
- package/dist/components/FormEditor/model.d.ts +2 -0
- package/dist/components/FormEditor/model.d.ts.map +1 -1
- package/dist/components/FormEditor/rich-text-control.d.cts +4 -0
- package/dist/components/FormEditor/rich-text-control.d.cts.map +1 -0
- package/dist/components/FormEditor/rich-text-control.d.ts +4 -0
- package/dist/components/FormEditor/rich-text-control.d.ts.map +1 -0
- package/dist/components/Icon/icons.d.cts +11 -0
- package/dist/components/Icon/icons.d.cts.map +1 -1
- package/dist/components/Icon/icons.d.ts +11 -0
- package/dist/components/Icon/icons.d.ts.map +1 -1
- package/dist/components/Icon/index.cjs +1 -1
- package/dist/components/Icon/index.js +1 -1
- package/dist/components/ImageCropper/index.cjs +1 -1
- package/dist/components/ImageCropper/index.cjs.map +1 -1
- package/dist/components/ImageCropper/index.js +6 -6
- package/dist/components/Menu/index.cjs +1 -1
- package/dist/components/Menu/index.cjs.map +1 -1
- package/dist/components/Menu/index.d.cts +3 -2
- package/dist/components/Menu/index.d.cts.map +1 -1
- package/dist/components/Menu/index.d.ts +3 -2
- package/dist/components/Menu/index.d.ts.map +1 -1
- package/dist/components/Menu/index.js +64 -51
- package/dist/components/Menu/index.js.map +1 -1
- package/dist/components/Modal/index.cjs +1 -1
- package/dist/components/Modal/index.js +2 -2
- package/dist/components/Popover/index.cjs +1 -1
- package/dist/components/Popover/index.js +1 -1
- package/dist/components/RichTextEditor/document.d.cts +6 -2
- package/dist/components/RichTextEditor/document.d.cts.map +1 -1
- package/dist/components/RichTextEditor/document.d.ts +6 -2
- package/dist/components/RichTextEditor/document.d.ts.map +1 -1
- package/dist/components/RichTextEditor/embed-context.d.cts +5 -0
- package/dist/components/RichTextEditor/embed-context.d.cts.map +1 -1
- package/dist/components/RichTextEditor/embed-context.d.ts +5 -0
- package/dist/components/RichTextEditor/embed-context.d.ts.map +1 -1
- package/dist/components/RichTextEditor/embed-types.d.cts +6 -4
- package/dist/components/RichTextEditor/embed-types.d.cts.map +1 -1
- package/dist/components/RichTextEditor/embed-types.d.ts +6 -4
- package/dist/components/RichTextEditor/embed-types.d.ts.map +1 -1
- package/dist/components/RichTextEditor/index.cjs +1 -1
- package/dist/components/RichTextEditor/index.d.cts +8 -0
- package/dist/components/RichTextEditor/index.d.cts.map +1 -1
- package/dist/components/RichTextEditor/index.d.ts +8 -0
- package/dist/components/RichTextEditor/index.d.ts.map +1 -1
- package/dist/components/RichTextEditor/index.js +1 -2
- package/dist/components/RichTextEditor/storyblock-view.d.cts.map +1 -1
- package/dist/components/RichTextEditor/storyblock-view.d.ts.map +1 -1
- package/dist/components/RichTextEditor/style.css +44 -46
- package/dist/components/RichTextEditor/tables.d.cts +7 -0
- package/dist/components/RichTextEditor/tables.d.cts.map +1 -0
- package/dist/components/RichTextEditor/tables.d.ts +7 -0
- package/dist/components/RichTextEditor/tables.d.ts.map +1 -0
- package/dist/components/RichTextEditor/use-embeds.d.cts.map +1 -1
- package/dist/components/RichTextEditor/use-embeds.d.ts.map +1 -1
- package/dist/components/SearchField/index.cjs +1 -1
- package/dist/components/SearchField/index.js +1 -1
- package/dist/components/Select/index.cjs +1 -1
- package/dist/components/Select/index.js +2 -2
- package/dist/components/SelectionCard/index.cjs +1 -1
- package/dist/components/SelectionCard/index.cjs.map +1 -1
- package/dist/components/SelectionCard/index.js +4 -4
- package/dist/components/SelectionCard/index.js.map +1 -1
- package/dist/components/SideNav/index.cjs +1 -1
- package/dist/components/SideNav/index.js +1 -1
- package/dist/components/SortableList/index.cjs +1 -1
- package/dist/components/SortableList/index.js +1 -1
- package/dist/components/Stepper/index.cjs +1 -1
- package/dist/components/Stepper/index.js +1 -1
- package/dist/components/SubNav/index.cjs +1 -1
- package/dist/components/SubNav/index.js +1 -1
- package/dist/components/Table/index.cjs +1 -1
- package/dist/components/Table/index.js +1 -1
- package/dist/components/Time/index.cjs +1 -1
- package/dist/components/Time/index.js +1 -1
- package/dist/components/Toast/index.cjs +1 -1
- package/dist/components/Toast/index.cjs.map +1 -1
- package/dist/components/Toast/index.d.cts +16 -3
- package/dist/components/Toast/index.d.cts.map +1 -1
- package/dist/components/Toast/index.d.ts +16 -3
- package/dist/components/Toast/index.d.ts.map +1 -1
- package/dist/components/Toast/index.js +65 -31
- package/dist/components/Toast/index.js.map +1 -1
- package/dist/components/TopNav/index.cjs +1 -1
- package/dist/components/TopNav/index.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +28 -28
- package/dist/internal/Message.d.cts.map +1 -1
- package/dist/internal/Message.d.ts.map +1 -1
- package/dist/internal/dialogFocus.d.cts +6 -1
- package/dist/internal/dialogFocus.d.cts.map +1 -1
- package/dist/internal/dialogFocus.d.ts +6 -1
- package/dist/internal/dialogFocus.d.ts.map +1 -1
- package/package.json +8 -6
- package/dist/chunks/EntryPicker-B4dAsObz.cjs +0 -2
- package/dist/chunks/EntryPicker-B4dAsObz.cjs.map +0 -1
- package/dist/chunks/EntryPicker-DDXHytMN.js +0 -160
- package/dist/chunks/EntryPicker-DDXHytMN.js.map +0 -1
- package/dist/chunks/FormEditor-BGzE-rqk.cjs +0 -2
- package/dist/chunks/FormEditor-BGzE-rqk.cjs.map +0 -1
- package/dist/chunks/FormEditor-ChH4e5sB.js +0 -693
- package/dist/chunks/FormEditor-ChH4e5sB.js.map +0 -1
- package/dist/chunks/Icon-3ucBRgrd.cjs.map +0 -1
- package/dist/chunks/Icon-dPXyBYe5.js +0 -91
- package/dist/chunks/Icon-dPXyBYe5.js.map +0 -1
- package/dist/chunks/Message-Ce2zjtfz.cjs +0 -2
- package/dist/chunks/RichTextEditor-BFblqw8m.js +0 -1144
- package/dist/chunks/RichTextEditor-BFblqw8m.js.map +0 -1
- package/dist/chunks/RichTextEditor-DU9CVeRD.cjs +0 -2
- package/dist/chunks/RichTextEditor-DU9CVeRD.cjs.map +0 -1
- package/dist/chunks/overlayLayer-iGhuAByk.cjs +0 -2
- package/dist/chunks/overlayLayer-iGhuAByk.cjs.map +0 -1
- package/dist/chunks/overlayLayer-lU4iWSjO.js.map +0 -1
- package/dist/chunks/use-picker-session-BSpOwnQ-.js.map +0 -1
- package/dist/chunks/use-picker-session-ouqHBmVA.cjs +0 -2
- package/dist/chunks/use-picker-session-ouqHBmVA.cjs.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Grid as e } from "../Grid/index.js";
|
|
2
|
+
import { t } from "../../chunks/style-7Z_xRlQx.js";
|
|
3
3
|
import { forwardRef as n } from "react";
|
|
4
4
|
import { jsx as r, jsxs as i } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/SelectionCard/index.tsx
|
|
@@ -57,11 +57,11 @@ var o = n(function({ title: e, description: t, children: n, className: i, ...o }
|
|
|
57
57
|
});
|
|
58
58
|
});
|
|
59
59
|
function c({ label: n, columns: i = 2, gap: a = "md", children: o, className: s, ...c }) {
|
|
60
|
-
return /* @__PURE__ */ r(
|
|
60
|
+
return /* @__PURE__ */ r(t, {
|
|
61
61
|
...c,
|
|
62
62
|
label: n,
|
|
63
63
|
className: ["ds-selection-card-group", s].filter(Boolean).join(" "),
|
|
64
|
-
children: /* @__PURE__ */ r(
|
|
64
|
+
children: /* @__PURE__ */ r(e, {
|
|
65
65
|
columns: i,
|
|
66
66
|
gap: a,
|
|
67
67
|
className: "ds-selection-card-group__grid ds-field-group-grid",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["
|
|
1
|
+
{"version":3,"file":"index.js","names":["CardBody","className","inputRef","kind","inputProps","title","description","children","CheckboxCard","forwardRef","rest","ref","RadioCard","SelectionCardGroup","fieldProps","FieldGroup","Grid","columns"],"sources":["../../../src/components/SelectionCard/index.tsx"],"sourcesContent":["import { forwardRef, type CSSProperties, type InputHTMLAttributes, type ReactNode } from \"react\";\nimport { FieldGroup, type FieldGroupProps } from \"../Field/group\";\nimport { Grid, type GapSize } from \"../Grid\";\nimport \"../Choice/style.css\";\nimport \"./style.css\";\n\ninterface SelectionCardBase {\n /** The commitment, in the user's words. */\n title: ReactNode;\n /** One line on what picking this means. Takes nodes, so a chip or a link can sit inline. */\n description?: ReactNode;\n /** Extra content under the description — a price, a sample, a badge. */\n children?: ReactNode;\n}\n\ntype NativeInput = Omit<\n InputHTMLAttributes<HTMLInputElement>,\n \"type\" | \"size\" | \"children\" | \"title\"\n>;\n\nfunction CardBody({\n kind,\n title,\n description,\n children,\n className,\n inputProps,\n inputRef,\n}: SelectionCardBase & {\n kind: \"checkbox\" | \"radio\";\n className?: string;\n inputProps: NativeInput;\n inputRef: React.Ref<HTMLInputElement>;\n}) {\n return (\n <label\n className={[\"ds-selection-card\", \"ds-field-surface\", className].filter(Boolean).join(\" \")}\n >\n <input\n ref={inputRef}\n type={kind}\n data-kind={kind}\n className=\"ds-selection-card__control ds-indicator\"\n {...inputProps}\n />\n <span className=\"ds-selection-card__text\">\n <span className=\"ds-selection-card__title\">{title}</span>\n {description && <span className=\"ds-selection-card__description\">{description}</span>}\n {children && <span className=\"ds-selection-card__extra\">{children}</span>}\n </span>\n </label>\n );\n}\n\nexport interface CheckboxCardProps extends SelectionCardBase, NativeInput {}\n\n/**\n * A checkbox with room to explain itself. Same 20px box as the bare control —\n * the card is a bigger target, not a different decision.\n */\nexport const CheckboxCard = forwardRef<HTMLInputElement, CheckboxCardProps>(function CheckboxCard(\n { title, description, children, className, ...rest },\n ref,\n) {\n return (\n <CardBody\n kind=\"checkbox\"\n title={title}\n description={description}\n className={className}\n inputProps={rest}\n inputRef={ref}\n >\n {children}\n </CardBody>\n );\n});\n\nexport interface RadioCardProps extends SelectionCardBase, NativeInput {}\n\n/** One of a set of mutually exclusive options, each with its own explanation. */\nexport const RadioCard = forwardRef<HTMLInputElement, RadioCardProps>(function RadioCard(\n { title, description, children, className, ...rest },\n ref,\n) {\n return (\n <CardBody\n kind=\"radio\"\n title={title}\n description={description}\n className={className}\n inputProps={rest}\n inputRef={ref}\n >\n {children}\n </CardBody>\n );\n});\n\nexport interface SelectionCardGroupProps extends FieldGroupProps {\n /** Group label — the question the cards answer. */\n label: string;\n /** Cards per row at full width. Steps down inside a narrow container. */\n columns?: 1 | 2 | 3;\n /** Space between cards in both axes, using Grid's spacing scale. Defaults to `md`. */\n gap?: GapSize;\n children: ReactNode;\n}\n\n/** A grid of selection cards under one legend, spaced by the shared Grid. */\nexport function SelectionCardGroup({\n label,\n columns = 2,\n gap = \"md\",\n children,\n className,\n ...fieldProps\n}: SelectionCardGroupProps) {\n return (\n <FieldGroup\n {...fieldProps}\n label={label}\n className={[\"ds-selection-card-group\", className].filter(Boolean).join(\" \")}\n >\n <Grid\n columns={columns}\n gap={gap}\n className=\"ds-selection-card-group__grid ds-field-group-grid\"\n style={{ \"--field-group-columns\": columns } as CSSProperties}\n >\n {children}\n </Grid>\n </FieldGroup>\n );\n}\n"],"mappings":";;;;;AAoBA,SAASA,EAAS,EAChB,SACA,UACA,gBACA,aACA,cACA,eACA,eAMC;CACD,OACE,kBAAC,SAAD;EACE,WAAW;GAAC;GAAqB;GAAoBC;EAAS,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,KAAK,GAAG;EAD1F,UAAA,CAGE,kBAAC,SAAD;GACE,KAAKC;GACL,MAAMC;GACN,aAAWA;GACX,WAAU;GACV,GAAIC;EACL,CAAA,GACD,kBAAC,QAAD;GAAM,WAAU;GAAhB,UAAA;IACE,kBAAC,QAAD;KAAM,WAAU;KAA4B,UAAAC;IAAY,CAAA;IACvDC,KAAe,kBAAC,QAAD;KAAM,WAAU;KAAkC,UAAAA;IAAkB,CAAA;IACnFC,KAAY,kBAAC,QAAD;KAAM,WAAU;KAA4B;IAAe,CAAA;GACpE;EACD,CAAA,CAAA;;AAEX;AAQA,IAAaC,IAAeC,EAAgD,SAC1E,EAAE,UAAO,gBAAa,aAAU,cAAW,GAAGC,KAC9C,GACA;CACA,OACE,kBAACV,GAAD;EACE,MAAK;EACE;EACM;EACF;EACX,YAAYU;EACZ,UAAUC;EAET;CACO,CAAA;AAEd,CAAC,GAKYC,IAAYH,EAA6C,SACpE,EAAE,UAAO,gBAAa,aAAU,cAAW,GAAGC,KAC9C,GACA;CACA,OACE,kBAACV,GAAD;EACE,MAAK;EACE;EACM;EACF;EACX,YAAYU;EACZ,UAAUC;EAET;CACO,CAAA;AAEd,CAAC;AAaD,SAAgBE,EAAmB,EACjC,UACA,aAAU,GACV,SAAM,MACN,aACA,cACA,GAAGC,KACuB;CAC1B,OACE,kBAACC,GAAD;EACE,GAAID;EACG;EACP,WAAW,CAAC,2BAA2Bb,CAAS,CAAC,CAAC,OAAO,OAAO,CAAC,CAAC,KAAK,GAAG;EAE1E,UAAA,kBAACe,GAAD;GACW;GACJ;GACL,WAAU;GACV,OAAO,EAAE,yBAAyBC,EAAQ;GAEzC;EACG,CAAA;CACI,CAAA;AAEhB"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-CnnTrtNb.cjs"),t=require("../Button/index.cjs");let n=require("react"),r=require("react/jsx-runtime");var i=(0,n.createContext)({isCollapsed:!1});function a(){return(0,n.useContext)(i).isCollapsed}var o=(0,n.forwardRef)(function({isCollapsed:e,defaultCollapsed:t=!1,onCollapsedChange:a,label:o=`Main`,className:c,children:l,...u},d){let[f,p]=(0,n.useState)(t),m=e??f,h=(0,n.useCallback)(()=>{let t=!m;e===void 0&&p(t),a?.(t)},[e,m,a]),g=(0,n.useMemo)(()=>({isCollapsed:m}),[m]);return(0,r.jsx)(i.Provider,{value:g,children:(0,r.jsx)(s.Provider,{value:h,children:(0,r.jsx)(`nav`,{ref:d,"aria-label":o,"data-collapsed":m||void 0,className:[`ds-sidenav`,`ds-field-surface`,c].filter(Boolean).join(` `),...u,children:l})})})}),s=(0,n.createContext)(()=>{}),c=(0,n.forwardRef)(function({title:e,mark:a,isCollapsible:o=!0,className:c,children:l,...u},d){let{isCollapsed:f}=(0,n.useContext)(i),p=(0,n.useContext)(s);return(0,r.jsxs)(`div`,{ref:d,className:[`ds-sidenav__header`,c].filter(Boolean).join(` `),...u,children:[a&&(0,r.jsx)(`span`,{className:`ds-sidenav__mark`,children:a}),!f&&(e||l)&&(0,r.jsx)(`span`,{className:`ds-sidenav__title`,children:e??l}),o&&(0,r.jsx)(t.Button,{variant:`simple`,size:`sm`,isIconOnly:!0,iconStart:f?`chevrons-right`:`chevrons-left`,className:`ds-sidenav__toggle`,"aria-label":f?`Expand navigation`:`Collapse navigation`,"aria-expanded":!f,title:f?`Expand navigation`:`Collapse navigation`,onClick:p})]})}),l=(0,n.forwardRef)(function({label:e,className:t,children:a,...o},s){let{isCollapsed:c}=(0,n.useContext)(i);return(0,r.jsxs)(`div`,{ref:s,className:[`ds-sidenav__section`,t].filter(Boolean).join(` `),"aria-label":e,role:e?`group`:void 0,...o,children:[e&&!c&&(0,r.jsx)(`span`,{className:`ds-sidenav__section-label`,children:e}),(0,r.jsx)(`ul`,{className:`ds-sidenav__list`,children:a})]})}),u=(0,n.forwardRef)(function({icon:t,label:a,isActive:o,badge:s,className:c,...l},u){let{isCollapsed:d}=(0,n.useContext)(i);return(0,r.jsx)(`li`,{className:`ds-sidenav__row`,children:(0,r.jsxs)(`a`,{ref:u,className:[`ds-sidenav__item`,`ds-field-surface`,c].filter(Boolean).join(` `),"data-active":o||void 0,"aria-current":o?`page`:void 0,title:d?a:void 0,...l,children:[(0,r.jsx)(e.t,{name:t}),!d&&(0,r.jsx)(`span`,{className:`ds-sidenav__label`,children:a}),!d&&s&&(0,r.jsx)(`span`,{className:`ds-sidenav__badge`,children:s}),d&&(0,r.jsx)(`span`,{className:`ds-sidenav__sr`,children:a})]})})}),d=(0,n.forwardRef)(function({className:e,children:t,...n},i){return(0,r.jsx)(`div`,{ref:i,className:[`ds-sidenav__footer`,`ds-field-surface`,e].filter(Boolean).join(` `),...n,children:t})});exports.SideNav=o,exports.SideNavFooter=d,exports.SideNavHeader=c,exports.SideNavItem=u,exports.SideNavSection=l,exports.useSideNavCollapsed=a;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as e } from "../../chunks/Icon-
|
|
1
|
+
import { t as e } from "../../chunks/Icon-Bxvp1-td.js";
|
|
2
2
|
import { Button as t } from "../Button/index.js";
|
|
3
3
|
import { createContext as n, forwardRef as r, useCallback as i, useContext as a, useMemo as o, useState as s } from "react";
|
|
4
4
|
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-CnnTrtNb.cjs"),t=require("../Button/index.cjs"),n=require("../../chunks/mergeRefs-CZ-SArlE.cjs");let r=require("react"),i=require("react/jsx-runtime"),a=require("@dnd-kit/core"),o=require("@dnd-kit/modifiers"),s=require("@dnd-kit/sortable"),c=require("@dnd-kit/utilities");function l(e){return(0,r.isValidElement)(e)&&typeof e.props.id==`string`}var u=(0,r.createContext)({isDisabled:!1,hasOverlay:!1});function d(e){e?.setAttribute(`inert`,``)}function f(){let{active:e,activeNodeRect:t,measureDroppableContainers:n}=(0,a.useDndContext)(),i=e?.id,o=t?.width,s=t?.height,c=(0,r.useRef)(null);return(0,r.useEffect)(()=>{if(i==null||o===void 0){c.current=null;return}let e=`${o}x${s}`;c.current!==null&&c.current!==e&&n([]),c.current=e},[i,o,s,n]),null}var p=(0,r.forwardRef)(function({items:t,onReorder:n,isDisabled:c=!1,onDragStart:p,onDragEnd:m,onDragCancel:h,renderDragOverlay:g,className:_,children:v,...y},b){let x=(0,r.useId)(),[S,C]=(0,r.useState)(null),[w,T]=(0,r.useState)(t),[E,D]=(0,r.useState)(t);t!==E&&t.join(`\0`)!==E.join(`\0`)&&(D(t),T(t));let O=(0,a.useSensors)((0,a.useSensor)(a.PointerSensor,{activationConstraint:{distance:4}}),(0,a.useSensor)(a.KeyboardSensor,{coordinateGetter:s.sortableKeyboardCoordinates})),k=(0,r.useCallback)(e=>{let t=String(e.active.id);C(t),p?.(t)},[p]);(0,r.useEffect)(()=>{if(!S)return;let e=e=>{e.code===`Escape`&&e.preventDefault()};return window.addEventListener(`keydown`,e,!0),()=>window.removeEventListener(`keydown`,e,!0)},[S]);let A=(0,r.useCallback)(e=>{C(null);let{active:t,over:r}=e;if(m?.(String(t.id)),c||!r||t.id===r.id)return;let i=w.indexOf(String(t.id)),a=w.indexOf(String(r.id));if(i<0||a<0)return;let o=(0,s.arrayMove)(w,i,a);T(o),n?.(o)},[w,n,c,m]),j=r.Children.toArray(v),M=new Map(j.filter(l).map(e=>[e.props.id,e])),N=[...w.flatMap(e=>M.get(e)??[]),...j.filter(e=>!l(e)||!w.includes(e.props.id))],P=g!==void 0,F=(0,r.useMemo)(()=>({isDisabled:c,hasOverlay:P}),[c,P]);return(0,i.jsxs)(a.DndContext,{id:`ds-sortable-list-${x}`,sensors:O,collisionDetection:a.closestCenter,modifiers:[o.restrictToVerticalAxis],onDragStart:k,onDragEnd:A,onDragCancel:e=>{C(null),h?.(String(e.active.id))},children:[(0,i.jsx)(f,{}),(0,i.jsx)(s.SortableContext,{items:w,strategy:s.verticalListSortingStrategy,children:(0,i.jsx)(u.Provider,{value:F,children:(0,i.jsx)(`ul`,{ref:b,className:[`ds-sortable-list`,_].filter(Boolean).join(` `),...y,children:N})})}),g&&(0,i.jsx)(a.DragOverlay,{className:`ds-sortable-overlay`,style:{height:`auto`},children:S?(0,i.jsxs)(`div`,{className:`ds-sortable-item ds-field-surface`,"data-overlay":!0,"aria-hidden":`true`,ref:d,children:[(0,i.jsx)(`span`,{className:`ds-sortable-item__handle`,"aria-hidden":`true`,children:(0,i.jsx)(e.t,{name:`grip-vertical`})}),(0,i.jsx)(`div`,{className:`ds-sortable-item__content`,children:g(S)})]}):null})]})}),m=(0,r.forwardRef)(function({id:e,label:a,action:o,isDisabled:l=!1,handleDescribedBy:d,className:f,children:p,...m},h){let g=(0,r.useContext)(u),_=l||g.isDisabled,{attributes:v,listeners:y,setNodeRef:b,transform:x,transition:S,isDragging:C}=(0,s.useSortable)({id:e,disabled:_});return(0,i.jsxs)(`li`,{ref:n.t(b,h),style:{transform:c.CSS.Translate.toString(x),transition:S},className:[`ds-sortable-item`,`ds-field-surface`,f].filter(Boolean).join(` `),"data-dragging":C?g.hasOverlay?`placeholder`:`lifted`:void 0,...m,children:[(0,i.jsx)(t.Button,{variant:`simple`,size:`sm`,isIconOnly:!0,iconStart:`grip-vertical`,className:`ds-sortable-item__handle`,"aria-label":a?`Move ${a}`:`Move item`,isDisabled:_,isFocusableWhenDisabled:!0,...v,"aria-describedby":[v[`aria-describedby`],d].filter(Boolean).join(` `)||void 0,...y}),(0,i.jsx)(`div`,{className:`ds-sortable-item__content`,children:p}),o&&(0,i.jsx)(`div`,{className:`ds-sortable-item__action`,children:o})]})});exports.SortableList=p,exports.SortableListItem=m;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as e } from "../../chunks/Icon-
|
|
1
|
+
import { t as e } from "../../chunks/Icon-Bxvp1-td.js";
|
|
2
2
|
import { Button as t } from "../Button/index.js";
|
|
3
3
|
import { t as n } from "../../chunks/mergeRefs-C6_5pADN.js";
|
|
4
4
|
import { Children as r, createContext as i, forwardRef as a, isValidElement as o, useCallback as s, useContext as c, useEffect as l, useId as u, useMemo as d, useRef as f, useState as p } from "react";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-CnnTrtNb.cjs"),t=require("../Button/index.cjs");let n=require("react"),r=require("react/jsx-runtime");function i(e,t){return e<t?`complete`:e===t?`current`:`upcoming`}var a=(0,n.forwardRef)(function({steps:a,activeStep:o,size:s=`md`,orientation:c=`horizontal`,label:l=`Progress`,onStepChange:u,className:d,...f},p){let m=(0,n.useId)();return(0,r.jsx)(`nav`,{ref:p,"aria-label":l,"data-size":s,"data-orientation":c,className:[`ds-stepper`,d].filter(Boolean).join(` `),...f,children:(0,r.jsx)(`ol`,{className:`ds-stepper__list`,children:a.map((n,a)=>{let s=i(a,o),c=!!u&&s!==`upcoming`,l=(0,r.jsxs)(r.Fragment,{children:[s===`complete`?(0,r.jsx)(e.t,{name:`check`,size:16,"aria-hidden":`true`}):a+1,(0,r.jsx)(`span`,{id:`${m}-${a}-status`,className:`ds-stepper__sr`,children:s})]});return(0,r.jsxs)(`li`,{className:`ds-stepper__step`,"data-status":s,"aria-current":s===`current`?`step`:void 0,children:[(0,r.jsxs)(`span`,{className:`ds-stepper__track`,"aria-hidden":`true`,children:[(0,r.jsx)(`span`,{className:`ds-stepper__connector`,"data-side":`start`}),(0,r.jsx)(`span`,{className:`ds-stepper__connector`,"data-side":`end`})]}),c?(0,r.jsx)(t.Button,{className:`ds-stepper__marker`,variant:s===`complete`?`primary`:`active`,size:`sm`,isIconOnly:!0,"aria-labelledby":`${m}-${a}-label`,"aria-describedby":`${m}-${a}-status`,onClick:()=>u?.(a,n.id),children:l}):(0,r.jsx)(`span`,{className:`ds-stepper__marker`,children:l}),(0,r.jsxs)(`span`,{className:`ds-stepper__text`,children:[(0,r.jsx)(`span`,{id:`${m}-${a}-label`,className:`ds-stepper__label`,children:n.label}),n.description&&(0,r.jsx)(`span`,{className:`ds-stepper__description`,children:n.description})]})]},n.id)})})})});exports.Stepper=a;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as e } from "../../chunks/Icon-
|
|
1
|
+
import { t as e } from "../../chunks/Icon-Bxvp1-td.js";
|
|
2
2
|
import { Button as t } from "../Button/index.js";
|
|
3
3
|
import { forwardRef as n, useId as r } from "react";
|
|
4
4
|
import { Fragment as i, jsx as a, jsxs as o } from "react/jsx-runtime";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-CnnTrtNb.cjs"),t=require("../Button/index.cjs"),n=require("../Badge/index.cjs");let r=require("react"),i=require("react/jsx-runtime");var a=(0,r.forwardRef)(function({label:e,actions:t,className:n,children:r,...a},o){return(0,i.jsxs)(`nav`,{ref:o,"aria-label":e,className:[`ds-subnav`,n].filter(Boolean).join(` `),...a,children:[(0,i.jsx)(`ul`,{className:`ds-subnav__list`,children:r}),t&&(0,i.jsx)(`div`,{className:`ds-subnav__actions`,children:t})]})}),o=(0,r.forwardRef)(function({label:t,icon:r,isActive:a,count:o,className:s,...c},l){return(0,i.jsx)(`li`,{className:`ds-subnav__row`,children:(0,i.jsxs)(`a`,{ref:l,className:[`ds-subnav__item`,s].filter(Boolean).join(` `),"data-active":a||void 0,"aria-current":a?`page`:void 0,...c,children:[r&&(0,i.jsx)(e.t,{name:r}),t,o!==void 0&&(0,i.jsx)(n.Badge,{className:`ds-subnav__count`,shape:`count`,size:`sm`,appearance:`soft`,isCountExact:!0,children:o})]})})}),s=(0,r.forwardRef)(function({label:e,icon:r,isActive:a,count:o,disabled:s,className:c,...l},u){return(0,i.jsx)(`li`,{className:`ds-subnav__row`,children:(0,i.jsxs)(t.Button,{ref:u,variant:`simple`,iconStart:r,isDisabled:s,className:[`ds-subnav__item`,c].filter(Boolean).join(` `),"data-active":a||void 0,"aria-pressed":a,...l,children:[e,o!==void 0&&(0,i.jsx)(n.Badge,{className:`ds-subnav__count`,shape:`count`,size:`sm`,appearance:`soft`,isCountExact:!0,children:o})]})})});exports.SubNav=a,exports.SubNavButton=s,exports.SubNavItem=o;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-CnnTrtNb.cjs");let t=require("react"),n=require("react/jsx-runtime");function r(...e){return e.filter(Boolean).join(` `)}var i=(0,t.forwardRef)(function({className:e,children:t,...i},a){return(0,n.jsx)(`div`,{ref:a,className:r(`ds-table-frame`,`ds-field-surface`,e),...i,children:t})}),a=(0,t.forwardRef)(function({start:e,end:t,className:i,...a},o){return(0,n.jsxs)(`div`,{ref:o,className:r(`ds-table-toolbar`,`ds-field-surface`,i),...a,children:[(0,n.jsx)(`div`,{className:`ds-table-toolbar__group`,children:e}),(0,n.jsx)(`div`,{className:`ds-table-toolbar__group`,children:t})]})});function o(e){return t.Children.toArray(e).some(e=>(0,t.isValidElement)(e)&&(e.type!==t.Fragment||o(e.props.children)))}var s=(0,t.createContext)({emptyMessage:`No data found.`}),c=(0,t.forwardRef)(function({emptyMessage:e=`No data found.`,isEmpty:t,className:i,children:a,...o},c){return(0,n.jsx)(s.Provider,{value:{emptyMessage:e,isEmpty:t},children:(0,n.jsx)(`div`,{className:`ds-table-frame__scroll`,children:(0,n.jsx)(`table`,{...o,ref:c,className:r(`ds-table`,i),children:a})})})}),l=(0,t.forwardRef)(function({className:e,...t},r){return(0,n.jsx)(`thead`,{ref:r,className:e,...t})}),u=(0,t.forwardRef)(function({className:e,children:r,...i},a){let{emptyMessage:c,isEmpty:l}=(0,t.useContext)(s);return(0,n.jsx)(`tbody`,{ref:a,className:e,...i,children:l??!o(r)?(0,n.jsx)(d,{children:(0,n.jsx)(p,{colSpan:1e3,className:`ds-table__empty-cell`,children:(0,n.jsx)(m,{title:c,role:`status`})})}):r})}),d=(0,t.forwardRef)(function({isSelected:e=!1,isInteractive:t=!1,className:i,...a},o){return(0,n.jsx)(`tr`,{ref:o,"data-selected":e||void 0,"data-interactive":t||void 0,tabIndex:t?0:void 0,className:r(`ds-field-surface`,i),...a})}),f=(0,t.forwardRef)(function({align:e=`start`,width:t=`auto`,className:r,...i},a){return(0,n.jsx)(`th`,{ref:a,scope:`col`,"data-align":e,"data-width":t,className:r,...i})}),p=(0,t.forwardRef)(function({align:e=`start`,width:t=`auto`,emphasis:r=`default`,className:i,...a},o){return(0,n.jsx)(`td`,{ref:o,"data-align":e,"data-width":t,"data-emphasis":r==="default"?void 0:r,className:i,...a})}),m=(0,t.forwardRef)(function({icon:t=`info`,title:i=`No data found.`,description:a,action:o,className:s,...c},l){return(0,n.jsxs)(`div`,{ref:l,className:r(`ds-table-empty`,s),...c,children:[(0,n.jsx)(e.t,{name:t,size:24}),(0,n.jsx)(`span`,{style:{color:`var(--color-text)`,fontWeight:`var(--font-weight-bold)`},children:i}),a&&(0,n.jsx)(`span`,{children:a}),o]})});exports.Table=c,exports.TableBody=u,exports.TableCell=p,exports.TableEmpty=m,exports.TableFrame=i,exports.TableHead=l,exports.TableHeaderCell=f,exports.TableRow=d,exports.TableToolbar=a;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as e } from "../../chunks/Icon-
|
|
1
|
+
import { t as e } from "../../chunks/Icon-Bxvp1-td.js";
|
|
2
2
|
import { Children as t, Fragment as n, createContext as r, forwardRef as i, isValidElement as a, useContext as o } from "react";
|
|
3
3
|
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
4
4
|
//#region src/components/Table/index.tsx
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/mergeRefs-CZ-SArlE.cjs"),t=require("../../chunks/useTooltip-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/mergeRefs-CZ-SArlE.cjs"),t=require("../../chunks/useTooltip-ekdwMJFz.cjs");let n=require("react"),r=require("react/jsx-runtime");function i(...e){return e.filter(Boolean).join(` `)}var a=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`],o=6e4,s=60*o,c=24*s,l=7*c;function u(e){return String(e).padStart(2,`0`)}function d(e,t={}){let{hasYear:n=!0}=t,r=`${e.getDate()} ${a[e.getMonth()]}`;return n?`${r} ${e.getFullYear()}`:r}function f(e,t={}){let{hasTimeZone:n=!0}=t,r=`${d(e)}, ${u(e.getHours())}:${u(e.getMinutes())}`;if(!n)return r;let i=new Intl.DateTimeFormat(void 0,{timeZoneName:`short`}).formatToParts(e).find(e=>e.type===`timeZoneName`)?.value;return i?`${r} ${i}`:r}function p(e,t=new Date){let n=t.getTime()-e.getTime();if(n<0)return d(e,{hasYear:e.getFullYear()!==t.getFullYear()});if(n<o)return`Just now`;if(n<s)return`${Math.floor(n/o)}m ago`;if(n<c)return`${Math.floor(n/s)}h ago`;if(n<l){let e=Math.floor(n/c);return`${e} ${e===1?`day`:`days`} ago`}return d(e,{hasYear:e.getFullYear()!==t.getFullYear()})}var m=(0,n.forwardRef)(function({value:a,format:o=`auto`,hasTooltip:s=!0,hasTimeZone:c=!0,now:l,refreshInterval:u=3e4,className:m,tabIndex:h,title:g,onMouseEnter:_,onMouseLeave:v,onFocus:y,onBlur:b,"aria-describedby":x,...S},C){let w=a instanceof Date?a:new Date(a),T=!Number.isNaN(w.getTime()),[,E]=(0,n.useState)(0);(0,n.useEffect)(()=>{if(o===`absolute`||l)return;let e=window.setInterval(()=>E(e=>e+1),u);return()=>window.clearInterval(e)},[o,l,u]);let D=T?o===`absolute`?d(w):p(w,l??new Date):``,O=T?f(w,{hasTimeZone:c}):``,k=T&&s&&D!==O,{anchorRef:A,description:j,triggerProps:M,panel:N}=t.t(k&&O,{placement:`top`,className:`ds-time-tooltip`}),P=(0,n.useMemo)(()=>e.t(A,C),[A,C]);return T?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`time`,{ref:P,dateTime:w.toISOString(),suppressHydrationWarning:!0,className:i(`ds-time`,!k&&`ds-time--plain`,m),tabIndex:h??(k?0:void 0),"aria-describedby":[x,j].filter(Boolean).join(` `)||void 0,title:g??(k?void 0:O),...M({onMouseEnter:_,onMouseLeave:v,onFocus:y,onBlur:b}),...S,children:D}),N]}):null});exports.Time=m,exports.formatAbsoluteDate=d,exports.formatAbsoluteTime=f,exports.formatRelativeTime=p;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as e } from "../../chunks/mergeRefs-C6_5pADN.js";
|
|
2
|
-
import { t } from "../../chunks/useTooltip-
|
|
2
|
+
import { t } from "../../chunks/useTooltip-Du8PutGX.js";
|
|
3
3
|
import { forwardRef as n, useEffect as r, useMemo as i, useState as a } from "react";
|
|
4
4
|
import { Fragment as o, jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
5
5
|
//#region src/components/Time/index.tsx
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Message-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Message-B0A5bz8V.cjs");let t=require("react"),n=require("react/jsx-runtime");var r=(0,t.forwardRef)(function({tone:t=`neutral`,title:r,description:i,onDismiss:a,role:o=`status`,className:s,...c},l){return(0,n.jsx)(e.t,{"aria-atomic":!1,...c,ref:l,role:o,tone:t,title:r,appearance:`floating`,icon:`auto`,onDismiss:a,classPrefix:`ds-toast`,dismissLabel:`Dismiss notification`,className:[`ds-toast`,s].filter(Boolean).join(` `),children:i})}),i=(0,t.createContext)(null);function a({children:e}){let[r,a]=(0,t.useState)([]),s=(0,t.useRef)(0),c=(0,t.useCallback)(e=>{a(t=>t.filter(t=>t.id!==e))},[]),l=(0,t.useCallback)(e=>{a(t=>[...t,{...e,id:s.current++}])},[]),u=(0,t.useMemo)(()=>({toast:l,dismiss:c}),[l,c]);return(0,n.jsxs)(i.Provider,{value:u,children:[e,(0,n.jsx)(o,{items:r,onDismiss:c})]})}function o({items:e,onDismiss:t}){return e.length===0?null:(0,n.jsx)(`div`,{className:`ds-toast-region`,role:`region`,"aria-label":`Notifications`,children:e.map(e=>(0,n.jsx)(c,{item:e,onDismiss:t},e.id))})}var s=class extends t.Component{state={failed:!1};static getDerivedStateFromError(){return{failed:!0}}render(){return this.state.failed?this.props.fallback:this.props.children}};function c({item:e,onDismiss:i}){let[a,o]=(0,t.useState)(!1),[c,l]=(0,t.useState)(!1),u=(0,t.useRef)(e.duration??5e3),d=a||c;(0,t.useEffect)(()=>{if(d)return;let t=u.current,n=Date.now(),r=window.setTimeout(()=>i(e.id),t);return()=>{window.clearTimeout(r),u.current=t-(Date.now()-n)}},[d,e.id,i]);let f={tone:e.tone,title:e.title,onDismiss:()=>i(e.id),onPointerEnter:()=>o(!0),onPointerLeave:()=>o(!1),onFocus:()=>l(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||l(!1)}},p=(0,n.jsx)(r,{...f});return(0,n.jsx)(s,{fallback:p,children:(0,n.jsx)(t.Suspense,{fallback:p,children:(0,n.jsx)(r,{...f,description:e.description})})})}function l(){let e=(0,t.useContext)(i);if(!e)throw Error(`useToast must be used inside a <ToastProvider>.`);return e}exports.Toast=r,exports.ToastProvider=a,exports.useToast=l;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":["forwardRef","Message","createContext","useState","useRef","useCallback","useMemo","useContext","require_Message","react","react_jsx_runtime","Toast","rest","className","description","ToastContext","ToastProvider","items","setItems","nextId","dismiss","current","item","id","toast","options","value","children","ToastRegion","TimedToast","timer","onDismiss","useToast","context"],"sources":["../../../src/components/Toast/index.tsx"],"sourcesContent":["import {\n createContext,\n forwardRef,\n useCallback,\n useContext,\n useEffect,\n useMemo,\n useRef,\n useState,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { Message } from \"../../internal/Message\";\nimport \"./style.css\";\n\nexport type ToastTone = \"neutral\" | \"info\" | \"success\" | \"warning\" | \"danger\";\n\nexport interface ToastProps extends HTMLAttributes<HTMLDivElement> {\n tone?: ToastTone;\n title: string;\n description?:
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["forwardRef","Message","createContext","useState","useRef","useCallback","useMemo","Component","Suspense","useContext","require_Message","react","react_jsx_runtime","Toast","rest","className","description","ToastContext","ToastProvider","items","setItems","nextId","dismiss","current","item","id","toast","options","value","children","ToastRegion","TimedToast","DescriptionBoundary","hovered","setHovered","focused","setFocused","remaining","paused","left","started","timer","onDismiss","shared","event","titleOnly","useToast","context"],"sources":["../../../src/components/Toast/index.tsx"],"sourcesContent":["import {\n Component,\n createContext,\n forwardRef,\n Suspense,\n useCallback,\n useContext,\n useEffect,\n useMemo,\n useRef,\n useState,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { Message } from \"../../internal/Message\";\nimport \"./style.css\";\n\nexport type ToastTone = \"neutral\" | \"info\" | \"success\" | \"warning\" | \"danger\";\n\nexport interface ToastProps extends HTMLAttributes<HTMLDivElement> {\n tone?: ToastTone;\n title: string;\n /**\n * Formatted text, such as an emphasised article title. Keep links and\n * actions out: the toast disappears on its own, so use a Banner for those.\n */\n description?: ReactNode;\n /** Renders a dismiss button. Omit for a toast that only times out. */\n onDismiss?: () => void;\n}\n\n/** One fact about something that already happened. Never a question. */\nexport const Toast = forwardRef<HTMLDivElement, ToastProps>(function Toast(\n { tone = \"neutral\", title, description, onDismiss, role = \"status\", className, ...rest },\n ref,\n) {\n return (\n <Message\n // Later changes announce only the text that changed, not the whole\n // toast with its dismiss label.\n aria-atomic={false}\n {...rest}\n ref={ref}\n role={role}\n tone={tone}\n title={title}\n appearance=\"floating\"\n icon=\"auto\"\n onDismiss={onDismiss}\n classPrefix=\"ds-toast\"\n dismissLabel=\"Dismiss notification\"\n className={[\"ds-toast\", className].filter(Boolean).join(\" \")}\n >\n {description}\n </Message>\n );\n});\n\nexport interface ToastOptions {\n tone?: ToastTone;\n title: string;\n /**\n * Formatted text; keep links and actions out. It renders inside\n * `ToastProvider`, not where `toast()` was called: it sees only context\n * above the provider and stays as passed. If it throws or suspends, the\n * toast shows its title alone.\n */\n description?: ReactNode;\n /**\n * Milliseconds before it dismisses itself. Defaults to `--toast-duration`.\n * The countdown pauses while the toast is hovered or holds focus.\n */\n duration?: number;\n}\n\ninterface ToastRecord extends ToastOptions {\n id: number;\n}\n\ninterface ToastContextValue {\n toast: (options: ToastOptions) => void;\n dismiss: (id: number) => void;\n}\n\nconst ToastContext = createContext<ToastContextValue | null>(null);\n\nexport interface ToastProviderProps {\n children: ReactNode;\n}\n\n/** Mount once, near the root. Everything below it can call `useToast()`. */\nexport function ToastProvider({ children }: ToastProviderProps) {\n const [items, setItems] = useState<ToastRecord[]>([]);\n const nextId = useRef(0);\n\n const dismiss = useCallback((id: number) => {\n setItems((current) => current.filter((item) => item.id !== id));\n }, []);\n\n const toast = useCallback((options: ToastOptions) => {\n setItems((current) => [...current, { ...options, id: nextId.current++ }]);\n }, []);\n\n const value = useMemo(() => ({ toast, dismiss }), [toast, dismiss]);\n\n return (\n <ToastContext.Provider value={value}>\n {children}\n <ToastRegion\n items={items}\n onDismiss={dismiss}\n />\n </ToastContext.Provider>\n );\n}\n\nfunction ToastRegion({\n items,\n onDismiss,\n}: {\n items: ToastRecord[];\n onDismiss: (id: number) => void;\n}) {\n if (items.length === 0) {\n return null;\n }\n return (\n <div\n className=\"ds-toast-region\"\n role=\"region\"\n aria-label=\"Notifications\"\n >\n {items.map((item) => (\n <TimedToast\n key={item.id}\n item={item}\n onDismiss={onDismiss}\n />\n ))}\n </div>\n );\n}\n\n/**\n * Provider descriptions render away from the code that called `toast()`. If\n * one throws, this keeps the failure inside its toast instead of unmounting\n * everything below the provider.\n */\nclass DescriptionBoundary extends Component<\n { fallback: ReactNode; children: ReactNode },\n { failed: boolean }\n> {\n state = { failed: false };\n\n static getDerivedStateFromError() {\n return { failed: true };\n }\n\n render() {\n return this.state.failed ? this.props.fallback : this.props.children;\n }\n}\n\nfunction TimedToast({ item, onDismiss }: { item: ToastRecord; onDismiss: (id: number) => void }) {\n const [hovered, setHovered] = useState(false);\n const [focused, setFocused] = useState(false);\n const remaining = useRef(item.duration ?? 5000);\n const paused = hovered || focused;\n\n // A toast never disappears under the pointer or from under focus. The\n // countdown resumes with the time that was left.\n useEffect(() => {\n if (paused) {\n return;\n }\n const left = remaining.current;\n const started = Date.now();\n const timer = window.setTimeout(() => onDismiss(item.id), left);\n return () => {\n window.clearTimeout(timer);\n remaining.current = left - (Date.now() - started);\n };\n }, [paused, item.id, onDismiss]);\n\n const shared: ToastProps = {\n tone: item.tone,\n title: item.title,\n onDismiss: () => onDismiss(item.id),\n onPointerEnter: () => setHovered(true),\n onPointerLeave: () => setHovered(false),\n onFocus: () => setFocused(true),\n onBlur: (event) => {\n if (!event.currentTarget.contains(event.relatedTarget as Node | null)) {\n setFocused(false);\n }\n },\n };\n // Shown while the description suspends, or after it throws.\n const titleOnly = <Toast {...shared} />;\n\n return (\n <DescriptionBoundary fallback={titleOnly}>\n <Suspense fallback={titleOnly}>\n <Toast\n {...shared}\n description={item.description}\n />\n </Suspense>\n </DescriptionBoundary>\n );\n}\n\nexport function useToast(): ToastContextValue {\n const context = useContext(ToastContext);\n if (!context) {\n throw new Error(\"useToast must be used inside a <ToastProvider>.\");\n }\n return context;\n}\n"],"mappings":"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"}
|
|
@@ -3,7 +3,11 @@ export type ToastTone = "neutral" | "info" | "success" | "warning" | "danger";
|
|
|
3
3
|
export interface ToastProps extends HTMLAttributes<HTMLDivElement> {
|
|
4
4
|
tone?: ToastTone;
|
|
5
5
|
title: string;
|
|
6
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Formatted text, such as an emphasised article title. Keep links and
|
|
8
|
+
* actions out: the toast disappears on its own, so use a Banner for those.
|
|
9
|
+
*/
|
|
10
|
+
description?: ReactNode;
|
|
7
11
|
/** Renders a dismiss button. Omit for a toast that only times out. */
|
|
8
12
|
onDismiss?: () => void;
|
|
9
13
|
}
|
|
@@ -12,8 +16,17 @@ export declare const Toast: import("react").ForwardRefExoticComponent<ToastProps
|
|
|
12
16
|
export interface ToastOptions {
|
|
13
17
|
tone?: ToastTone;
|
|
14
18
|
title: string;
|
|
15
|
-
|
|
16
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Formatted text; keep links and actions out. It renders inside
|
|
21
|
+
* `ToastProvider`, not where `toast()` was called: it sees only context
|
|
22
|
+
* above the provider and stays as passed. If it throws or suspends, the
|
|
23
|
+
* toast shows its title alone.
|
|
24
|
+
*/
|
|
25
|
+
description?: ReactNode;
|
|
26
|
+
/**
|
|
27
|
+
* Milliseconds before it dismisses itself. Defaults to `--toast-duration`.
|
|
28
|
+
* The countdown pauses while the toast is hovered or holds focus.
|
|
29
|
+
*/
|
|
17
30
|
duration?: number;
|
|
18
31
|
}
|
|
19
32
|
interface ToastContextValue {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../../../src/components/Toast/index.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../../../src/components/Toast/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAWL,KAAK,cAAc,EACnB,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAEf,OAAO,aAAa,CAAC;AAErB,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,CAAC;AAE9E,MAAM,WAAW,UAAW,SAAQ,cAAc,CAAC,cAAc,CAAC;IAChE,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,sEAAsE;IACtE,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CACxB;AAED,wEAAwE;AACxE,eAAO,MAAM,KAAK,uGAwBhB,CAAC;AAEH,MAAM,WAAW,YAAY;IAC3B,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd;;;;;OAKG;IACH,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAMD,UAAU,iBAAiB;IACzB,KAAK,EAAE,CAAC,OAAO,EAAE,YAAY,KAAK,IAAI,CAAC;IACvC,OAAO,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;CAC/B;AAID,MAAM,WAAW,kBAAkB;IACjC,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED,4EAA4E;AAC5E,wBAAgB,aAAa,CAAC,EAAE,QAAQ,EAAE,EAAE,kBAAkB,+BAuB7D;AAkGD,wBAAgB,QAAQ,IAAI,iBAAiB,CAM5C"}
|
|
@@ -3,7 +3,11 @@ export type ToastTone = "neutral" | "info" | "success" | "warning" | "danger";
|
|
|
3
3
|
export interface ToastProps extends HTMLAttributes<HTMLDivElement> {
|
|
4
4
|
tone?: ToastTone;
|
|
5
5
|
title: string;
|
|
6
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Formatted text, such as an emphasised article title. Keep links and
|
|
8
|
+
* actions out: the toast disappears on its own, so use a Banner for those.
|
|
9
|
+
*/
|
|
10
|
+
description?: ReactNode;
|
|
7
11
|
/** Renders a dismiss button. Omit for a toast that only times out. */
|
|
8
12
|
onDismiss?: () => void;
|
|
9
13
|
}
|
|
@@ -12,8 +16,17 @@ export declare const Toast: import("react").ForwardRefExoticComponent<ToastProps
|
|
|
12
16
|
export interface ToastOptions {
|
|
13
17
|
tone?: ToastTone;
|
|
14
18
|
title: string;
|
|
15
|
-
|
|
16
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Formatted text; keep links and actions out. It renders inside
|
|
21
|
+
* `ToastProvider`, not where `toast()` was called: it sees only context
|
|
22
|
+
* above the provider and stays as passed. If it throws or suspends, the
|
|
23
|
+
* toast shows its title alone.
|
|
24
|
+
*/
|
|
25
|
+
description?: ReactNode;
|
|
26
|
+
/**
|
|
27
|
+
* Milliseconds before it dismisses itself. Defaults to `--toast-duration`.
|
|
28
|
+
* The countdown pauses while the toast is hovered or holds focus.
|
|
29
|
+
*/
|
|
17
30
|
duration?: number;
|
|
18
31
|
}
|
|
19
32
|
interface ToastContextValue {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Toast/index.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Toast/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAWL,KAAK,cAAc,EACnB,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AAEf,OAAO,aAAa,CAAC;AAErB,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,CAAC;AAE9E,MAAM,WAAW,UAAW,SAAQ,cAAc,CAAC,cAAc,CAAC;IAChE,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,sEAAsE;IACtE,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CACxB;AAED,wEAAwE;AACxE,eAAO,MAAM,KAAK,uGAwBhB,CAAC;AAEH,MAAM,WAAW,YAAY;IAC3B,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd;;;;;OAKG;IACH,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAMD,UAAU,iBAAiB;IACzB,KAAK,EAAE,CAAC,OAAO,EAAE,YAAY,KAAK,IAAI,CAAC;IACvC,OAAO,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;CAC/B;AAID,MAAM,WAAW,kBAAkB;IACjC,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED,4EAA4E;AAC5E,wBAAgB,aAAa,CAAC,EAAE,QAAQ,EAAE,EAAE,kBAAkB,+BAuB7D;AAkGD,wBAAgB,QAAQ,IAAI,iBAAiB,CAM5C"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { t as e } from "../../chunks/Message-
|
|
2
|
-
import {
|
|
3
|
-
import { jsx as
|
|
1
|
+
import { t as e } from "../../chunks/Message-VJTPhId7.js";
|
|
2
|
+
import { Component as t, Suspense as n, createContext as r, forwardRef as i, useCallback as a, useContext as o, useEffect as s, useMemo as c, useRef as l, useState as u } from "react";
|
|
3
|
+
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
4
4
|
//#region src/components/Toast/index.tsx
|
|
5
|
-
var
|
|
6
|
-
return /* @__PURE__ */
|
|
5
|
+
var p = i(function({ tone: t = "neutral", title: n, description: r, onDismiss: i, role: a = "status", className: o, ...s }, c) {
|
|
6
|
+
return /* @__PURE__ */ d(e, {
|
|
7
|
+
"aria-atomic": !1,
|
|
7
8
|
...s,
|
|
8
9
|
ref: c,
|
|
9
10
|
role: a,
|
|
@@ -17,55 +18,88 @@ var d = n(function({ tone: t = "neutral", title: n, description: r, onDismiss: i
|
|
|
17
18
|
className: ["ds-toast", o].filter(Boolean).join(" "),
|
|
18
19
|
children: r
|
|
19
20
|
});
|
|
20
|
-
}),
|
|
21
|
-
function
|
|
22
|
-
let [t, n] =
|
|
21
|
+
}), m = r(null);
|
|
22
|
+
function h({ children: e }) {
|
|
23
|
+
let [t, n] = u([]), r = l(0), i = a((e) => {
|
|
23
24
|
n((t) => t.filter((t) => t.id !== e));
|
|
24
|
-
}, []),
|
|
25
|
+
}, []), o = a((e) => {
|
|
25
26
|
n((t) => [...t, {
|
|
26
27
|
...e,
|
|
27
|
-
id:
|
|
28
|
+
id: r.current++
|
|
28
29
|
}]);
|
|
29
|
-
}, []),
|
|
30
|
-
toast:
|
|
31
|
-
dismiss:
|
|
32
|
-
}), [
|
|
33
|
-
return /* @__PURE__ */
|
|
34
|
-
value:
|
|
35
|
-
children: [e, /* @__PURE__ */
|
|
30
|
+
}, []), s = c(() => ({
|
|
31
|
+
toast: o,
|
|
32
|
+
dismiss: i
|
|
33
|
+
}), [o, i]);
|
|
34
|
+
return /* @__PURE__ */ f(m.Provider, {
|
|
35
|
+
value: s,
|
|
36
|
+
children: [e, /* @__PURE__ */ d(g, {
|
|
36
37
|
items: t,
|
|
37
|
-
onDismiss:
|
|
38
|
+
onDismiss: i
|
|
38
39
|
})]
|
|
39
40
|
});
|
|
40
41
|
}
|
|
41
|
-
function
|
|
42
|
-
return e.length === 0 ? null : /* @__PURE__ */
|
|
42
|
+
function g({ items: e, onDismiss: t }) {
|
|
43
|
+
return e.length === 0 ? null : /* @__PURE__ */ d("div", {
|
|
43
44
|
className: "ds-toast-region",
|
|
44
45
|
role: "region",
|
|
45
46
|
"aria-label": "Notifications",
|
|
46
|
-
children: e.map((e) => /* @__PURE__ */
|
|
47
|
+
children: e.map((e) => /* @__PURE__ */ d(v, {
|
|
47
48
|
item: e,
|
|
48
49
|
onDismiss: t
|
|
49
50
|
}, e.id))
|
|
50
51
|
});
|
|
51
52
|
}
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
return
|
|
56
|
-
}
|
|
53
|
+
var _ = class extends t {
|
|
54
|
+
state = { failed: !1 };
|
|
55
|
+
static getDerivedStateFromError() {
|
|
56
|
+
return { failed: !0 };
|
|
57
|
+
}
|
|
58
|
+
render() {
|
|
59
|
+
return this.state.failed ? this.props.fallback : this.props.children;
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
function v({ item: e, onDismiss: t }) {
|
|
63
|
+
let [r, i] = u(!1), [a, o] = u(!1), c = l(e.duration ?? 5e3), f = r || a;
|
|
64
|
+
s(() => {
|
|
65
|
+
if (f) return;
|
|
66
|
+
let n = c.current, r = Date.now(), i = window.setTimeout(() => t(e.id), n);
|
|
67
|
+
return () => {
|
|
68
|
+
window.clearTimeout(i), c.current = n - (Date.now() - r);
|
|
69
|
+
};
|
|
70
|
+
}, [
|
|
71
|
+
f,
|
|
72
|
+
e.id,
|
|
73
|
+
t
|
|
74
|
+
]);
|
|
75
|
+
let m = {
|
|
57
76
|
tone: e.tone,
|
|
58
77
|
title: e.title,
|
|
59
|
-
|
|
60
|
-
|
|
78
|
+
onDismiss: () => t(e.id),
|
|
79
|
+
onPointerEnter: () => i(!0),
|
|
80
|
+
onPointerLeave: () => i(!1),
|
|
81
|
+
onFocus: () => o(!0),
|
|
82
|
+
onBlur: (e) => {
|
|
83
|
+
e.currentTarget.contains(e.relatedTarget) || o(!1);
|
|
84
|
+
}
|
|
85
|
+
}, h = /* @__PURE__ */ d(p, { ...m });
|
|
86
|
+
return /* @__PURE__ */ d(_, {
|
|
87
|
+
fallback: h,
|
|
88
|
+
children: /* @__PURE__ */ d(n, {
|
|
89
|
+
fallback: h,
|
|
90
|
+
children: /* @__PURE__ */ d(p, {
|
|
91
|
+
...m,
|
|
92
|
+
description: e.description
|
|
93
|
+
})
|
|
94
|
+
})
|
|
61
95
|
});
|
|
62
96
|
}
|
|
63
|
-
function
|
|
64
|
-
let e =
|
|
97
|
+
function y() {
|
|
98
|
+
let e = o(m);
|
|
65
99
|
if (!e) throw Error("useToast must be used inside a <ToastProvider>.");
|
|
66
100
|
return e;
|
|
67
101
|
}
|
|
68
102
|
//#endregion
|
|
69
|
-
export {
|
|
103
|
+
export { p as Toast, h as ToastProvider, y as useToast };
|
|
70
104
|
|
|
71
105
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["Message","Toast","forwardRef","rest","className","description","ToastContext","createContext","ToastProvider","items","setItems","useState","nextId","useRef","dismiss","useCallback","current","item","id","toast","options","value","useMemo","children","ToastRegion","TimedToast","
|
|
1
|
+
{"version":3,"file":"index.js","names":["Message","Toast","forwardRef","rest","className","description","ToastContext","createContext","ToastProvider","items","setItems","useState","nextId","useRef","dismiss","useCallback","current","item","id","toast","options","value","useMemo","children","ToastRegion","TimedToast","DescriptionBoundary","Component","hovered","setHovered","focused","setFocused","remaining","paused","left","started","timer","onDismiss","shared","event","titleOnly","Suspense","useToast","context","useContext"],"sources":["../../../src/components/Toast/index.tsx"],"sourcesContent":["import {\n Component,\n createContext,\n forwardRef,\n Suspense,\n useCallback,\n useContext,\n useEffect,\n useMemo,\n useRef,\n useState,\n type HTMLAttributes,\n type ReactNode,\n} from \"react\";\nimport { Message } from \"../../internal/Message\";\nimport \"./style.css\";\n\nexport type ToastTone = \"neutral\" | \"info\" | \"success\" | \"warning\" | \"danger\";\n\nexport interface ToastProps extends HTMLAttributes<HTMLDivElement> {\n tone?: ToastTone;\n title: string;\n /**\n * Formatted text, such as an emphasised article title. Keep links and\n * actions out: the toast disappears on its own, so use a Banner for those.\n */\n description?: ReactNode;\n /** Renders a dismiss button. Omit for a toast that only times out. */\n onDismiss?: () => void;\n}\n\n/** One fact about something that already happened. Never a question. */\nexport const Toast = forwardRef<HTMLDivElement, ToastProps>(function Toast(\n { tone = \"neutral\", title, description, onDismiss, role = \"status\", className, ...rest },\n ref,\n) {\n return (\n <Message\n // Later changes announce only the text that changed, not the whole\n // toast with its dismiss label.\n aria-atomic={false}\n {...rest}\n ref={ref}\n role={role}\n tone={tone}\n title={title}\n appearance=\"floating\"\n icon=\"auto\"\n onDismiss={onDismiss}\n classPrefix=\"ds-toast\"\n dismissLabel=\"Dismiss notification\"\n className={[\"ds-toast\", className].filter(Boolean).join(\" \")}\n >\n {description}\n </Message>\n );\n});\n\nexport interface ToastOptions {\n tone?: ToastTone;\n title: string;\n /**\n * Formatted text; keep links and actions out. It renders inside\n * `ToastProvider`, not where `toast()` was called: it sees only context\n * above the provider and stays as passed. If it throws or suspends, the\n * toast shows its title alone.\n */\n description?: ReactNode;\n /**\n * Milliseconds before it dismisses itself. Defaults to `--toast-duration`.\n * The countdown pauses while the toast is hovered or holds focus.\n */\n duration?: number;\n}\n\ninterface ToastRecord extends ToastOptions {\n id: number;\n}\n\ninterface ToastContextValue {\n toast: (options: ToastOptions) => void;\n dismiss: (id: number) => void;\n}\n\nconst ToastContext = createContext<ToastContextValue | null>(null);\n\nexport interface ToastProviderProps {\n children: ReactNode;\n}\n\n/** Mount once, near the root. Everything below it can call `useToast()`. */\nexport function ToastProvider({ children }: ToastProviderProps) {\n const [items, setItems] = useState<ToastRecord[]>([]);\n const nextId = useRef(0);\n\n const dismiss = useCallback((id: number) => {\n setItems((current) => current.filter((item) => item.id !== id));\n }, []);\n\n const toast = useCallback((options: ToastOptions) => {\n setItems((current) => [...current, { ...options, id: nextId.current++ }]);\n }, []);\n\n const value = useMemo(() => ({ toast, dismiss }), [toast, dismiss]);\n\n return (\n <ToastContext.Provider value={value}>\n {children}\n <ToastRegion\n items={items}\n onDismiss={dismiss}\n />\n </ToastContext.Provider>\n );\n}\n\nfunction ToastRegion({\n items,\n onDismiss,\n}: {\n items: ToastRecord[];\n onDismiss: (id: number) => void;\n}) {\n if (items.length === 0) {\n return null;\n }\n return (\n <div\n className=\"ds-toast-region\"\n role=\"region\"\n aria-label=\"Notifications\"\n >\n {items.map((item) => (\n <TimedToast\n key={item.id}\n item={item}\n onDismiss={onDismiss}\n />\n ))}\n </div>\n );\n}\n\n/**\n * Provider descriptions render away from the code that called `toast()`. If\n * one throws, this keeps the failure inside its toast instead of unmounting\n * everything below the provider.\n */\nclass DescriptionBoundary extends Component<\n { fallback: ReactNode; children: ReactNode },\n { failed: boolean }\n> {\n state = { failed: false };\n\n static getDerivedStateFromError() {\n return { failed: true };\n }\n\n render() {\n return this.state.failed ? this.props.fallback : this.props.children;\n }\n}\n\nfunction TimedToast({ item, onDismiss }: { item: ToastRecord; onDismiss: (id: number) => void }) {\n const [hovered, setHovered] = useState(false);\n const [focused, setFocused] = useState(false);\n const remaining = useRef(item.duration ?? 5000);\n const paused = hovered || focused;\n\n // A toast never disappears under the pointer or from under focus. The\n // countdown resumes with the time that was left.\n useEffect(() => {\n if (paused) {\n return;\n }\n const left = remaining.current;\n const started = Date.now();\n const timer = window.setTimeout(() => onDismiss(item.id), left);\n return () => {\n window.clearTimeout(timer);\n remaining.current = left - (Date.now() - started);\n };\n }, [paused, item.id, onDismiss]);\n\n const shared: ToastProps = {\n tone: item.tone,\n title: item.title,\n onDismiss: () => onDismiss(item.id),\n onPointerEnter: () => setHovered(true),\n onPointerLeave: () => setHovered(false),\n onFocus: () => setFocused(true),\n onBlur: (event) => {\n if (!event.currentTarget.contains(event.relatedTarget as Node | null)) {\n setFocused(false);\n }\n },\n };\n // Shown while the description suspends, or after it throws.\n const titleOnly = <Toast {...shared} />;\n\n return (\n <DescriptionBoundary fallback={titleOnly}>\n <Suspense fallback={titleOnly}>\n <Toast\n {...shared}\n description={item.description}\n />\n </Suspense>\n </DescriptionBoundary>\n );\n}\n\nexport function useToast(): ToastContextValue {\n const context = useContext(ToastContext);\n if (!context) {\n throw new Error(\"useToast must be used inside a <ToastProvider>.\");\n }\n return context;\n}\n"],"mappings":"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"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../../chunks/Icon-CnnTrtNb.cjs");let t=require("react"),n=require("react/jsx-runtime");var r=(0,t.forwardRef)(function({brand:e,actions:t,label:r=`Product`,className:i,children:a,...o},s){return(0,n.jsxs)(`header`,{ref:s,className:[`ds-topnav`,`ds-field-surface`,i].filter(Boolean).join(` `),...o,children:[e&&(0,n.jsx)(`div`,{className:`ds-topnav__brand`,children:e}),a&&(0,n.jsx)(`nav`,{className:`ds-topnav__nav`,"aria-label":r,children:(0,n.jsx)(`ul`,{className:`ds-topnav__list`,children:a})}),t&&(0,n.jsx)(`div`,{className:`ds-topnav__actions`,children:t})]})}),i=(0,t.forwardRef)(function({label:t,icon:r,isActive:i,className:a,...o},s){return(0,n.jsx)(`li`,{className:`ds-topnav__row`,children:(0,n.jsxs)(`a`,{ref:s,className:[`ds-topnav__item`,a].filter(Boolean).join(` `),"data-active":i||void 0,"aria-current":i?`page`:void 0,...o,children:[r&&(0,n.jsx)(e.t,{name:r}),t]})})});exports.TopNav=r,exports.TopNavItem=i;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./chunks/Icon-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./chunks/Icon-CnnTrtNb.cjs"),t=require("./components/Button/index.cjs"),n=require("./chunks/Drawer-B2dcTh5l.cjs"),r=require("./chunks/overlayLayer-CtOTt1xB.cjs"),i=require("./components/SideNav/index.cjs"),a=require("./components/TopNav/index.cjs"),o=require("./components/AppShell/index.cjs"),s=require("./components/ButtonGroup/index.cjs"),c=require("./components/Badge/index.cjs"),l=require("./components/LimitReading/index.cjs"),u=require("./components/Field/index.cjs"),d=require("./components/Modal/index.cjs"),f=require("./components/TextField/index.cjs"),p=require("./chunks/RichTextEditor-DV7NZp_k.cjs"),m=require("./components/Popover/index.cjs"),h=require("./components/Menu/index.cjs"),g=require("./chunks/EntryPicker-BwEYRtQl.cjs"),_=require("./components/Skeleton/index.cjs"),v=require("./components/Banner/index.cjs"),y=require("./chunks/LoadState-BXLG-SkQ.cjs"),b=require("./components/Grid/index.cjs"),x=require("./components/FieldAffix/index.cjs"),S=require("./components/SearchField/index.cjs"),C=require("./components/Choice/index.cjs"),w=require("./components/Container/index.cjs"),T=require("./components/SortableList/index.cjs"),E=require("./chunks/NumberField-BrWFmPkW.cjs"),D=require("./components/Select/index.cjs"),O=require("./components/Switch/index.cjs"),k=require("./chunks/Slider-BfvNPjRJ.cjs"),A=require("./chunks/ColourField-DAFzOIOq.cjs"),j=require("./chunks/DatePicker-DOg3iQYy.cjs"),M=require("./components/TagsInput/index.cjs"),N=require("./components/SelectionCard/index.cjs"),P=require("./chunks/FormEditor-D1HUnjMI.cjs"),F=require("./chunks/Board-DeXtaWNO.cjs"),I=require("./chunks/Avatar-Dw7EWd_-.cjs"),L=require("./chunks/ProgressBar-C3F4HPIQ.cjs"),R=require("./components/Table/index.cjs"),z=require("./components/Toast/index.cjs"),B=require("./components/SubNav/index.cjs"),V=require("./components/Stepper/index.cjs"),H=require("./components/AssetCard/index.cjs"),U=require("./components/AssetGrid/index.cjs"),W=require("./components/ImageCropper/index.cjs"),G=require("./components/Time/index.cjs"),K=require("./components/Pagination/index.cjs"),q=require("./components/EditLayout/index.cjs"),J=require("./chunks/CollectionView-Dbg4d_tA.cjs"),Y=require("./components/EditSection/index.cjs"),X=require("./components/PageHeader/index.cjs"),Z=require("./components/MetaList/index.cjs"),Q=require("./chunks/Wizard-B_CPW1V6.cjs");exports.AppShell=o.AppShell,exports.AssetCard=H.AssetCard,exports.AssetCardSkeleton=H.AssetCardSkeleton,exports.AssetGrid=U.AssetGrid,exports.AssetGridEmpty=U.AssetGridEmpty,exports.Avatar=I.t,exports.AvatarGroup=I.n,exports.Badge=c.Badge,exports.Banner=v.Banner,exports.Board=F.t,exports.BoardCard=F.n,exports.BoardColumn=F.r,exports.Button=t.Button,exports.ButtonGroup=s.ButtonGroup,exports.Calendar=j.t,exports.Checkbox=C.Checkbox,exports.CheckboxCard=N.CheckboxCard,exports.ChoiceGroup=C.ChoiceGroup,exports.CollectionEmpty=J.n,exports.CollectionView=J.t,exports.ColourField=A.t,exports.ColourPanel=A.n,exports.Container=w.Container,exports.DateField=j.n,exports.DateRangeField=j.r,exports.Drawer=n.t,exports.EditLayout=q.EditLayout,exports.EditSection=Y.EditSection,exports.EntryPicker=g.t,exports.Field=u.Field,exports.FieldAffix=x.FieldAffix,exports.FormEditor=P.t,exports.Grid=b.Grid,exports.GridItem=b.GridItem,exports.Icon=e.t,exports.ImageCropper=W.ImageCropper,exports.LimitReading=l.LimitReading,exports.LoadError=y.r,exports.LoadState=y.t,exports.Menu=h.Menu,exports.MenuItem=h.MenuItem,exports.MenuLabel=h.MenuLabel,exports.MenuSeparator=h.MenuSeparator,exports.MetaList=Z.MetaList,exports.Modal=d.Modal,exports.NumberField=E.t,exports.NumberRangeField=E.n,exports.OverlayLayer=r.n,exports.PageHeader=X.PageHeader,exports.Pagination=K.Pagination,exports.Popover=m.Popover,exports.ProgressBar=L.t,exports.Radio=C.Radio,exports.RadioCard=N.RadioCard,exports.RangeSlider=k.t,exports.ReviewTable=Q.n,exports.RichTextEditor=p.t,exports.SearchField=S.SearchField,exports.Select=D.Select,exports.SelectionCardGroup=N.SelectionCardGroup,exports.SideNav=i.SideNav,exports.SideNavFooter=i.SideNavFooter,exports.SideNavHeader=i.SideNavHeader,exports.SideNavItem=i.SideNavItem,exports.SideNavSection=i.SideNavSection,exports.Skeleton=_.Skeleton,exports.SkeletonText=_.SkeletonText,exports.Slider=k.n,exports.SortableList=T.SortableList,exports.SortableListItem=T.SortableListItem,exports.Stack=b.Stack,exports.Stepper=V.Stepper,exports.SubNav=B.SubNav,exports.SubNavButton=B.SubNavButton,exports.SubNavItem=B.SubNavItem,exports.Switch=O.Switch,exports.Table=R.Table,exports.TableBody=R.TableBody,exports.TableCell=R.TableCell,exports.TableEmpty=R.TableEmpty,exports.TableFrame=R.TableFrame,exports.TableHead=R.TableHead,exports.TableHeaderCell=R.TableHeaderCell,exports.TableRow=R.TableRow,exports.TableToolbar=R.TableToolbar,exports.TagsInput=M.TagsInput,exports.TextArea=f.TextArea,exports.TextField=f.TextField,exports.Time=G.Time,exports.Toast=z.Toast,exports.ToastProvider=z.ToastProvider,exports.TopNav=a.TopNav,exports.TopNavItem=a.TopNavItem,exports.Wizard=Q.t,exports.cropToBlob=W.cropToBlob,exports.formatAbsoluteDate=G.formatAbsoluteDate,exports.formatAbsoluteTime=G.formatAbsoluteTime,exports.formatIsoDate=j.i,exports.formatRelativeTime=G.formatRelativeTime,exports.iconNames=e.n,exports.icons=e.r,exports.useSideNavCollapsed=i.useSideNavCollapsed,exports.useToast=z.useToast,exports.validateFormValues=p.i;
|