@iress-oss/ids-components 5.13.1 → 5.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/dist/{AutocompleteNoResults-Bk7q5K89.js → AutocompleteNoResults-D-7ik_op.js} +1 -1
- package/dist/{ComboboxHiddenInput-BRgHrfvH.js → ComboboxHiddenInput-Bo5hqUzo.js} +6 -6
- package/dist/{FieldAppendToLabel-B7A85TG1.js → FieldAppendToLabel-kSkgzhQp.js} +4 -4
- package/dist/{InputBase-K0leqZnv.js → InputBase-2wLvSYMJ.js} +2 -2
- package/dist/Loading.module-nxv4vxd0.js +13 -0
- package/dist/LoadingSuspense-BDiikfSh.js +5691 -0
- package/dist/LogoFromSrc-RCkIBALM.js +59 -0
- package/dist/MenuItem.module-C1hy3JLs.js +24 -0
- package/dist/Popover.module-BVuEALLH.js +11 -0
- package/dist/{SelectControl-415DMBPp.js → SelectControl-ebML3vaP.js} +2 -2
- package/dist/{SliderTicks-B6vu-MUH.js → SliderTicks-Bvc90tyk.js} +2 -2
- package/dist/TabSet.module-DLn6e1BG.js +13 -0
- package/dist/Table.module-CztzYVfs.js +32 -0
- package/dist/_commonjsHelpers-C6fGbg64.js +6 -0
- package/dist/components/Alert/Alert.js +2 -2
- package/dist/components/Alert/index.js +1 -1
- package/dist/components/Autocomplete/Autocomplete.js +3 -3
- package/dist/components/Autocomplete/components/AutocompleteNoResults.js +1 -1
- package/dist/components/Autocomplete/index.js +1 -1
- package/dist/components/Badge/Badge.js +5 -5
- package/dist/components/Button/Button.js +3 -3
- package/dist/components/Button/CloseButton/CloseButton.js +2 -2
- package/dist/components/Button/index.js +1 -1
- package/dist/components/ButtonGroup/ButtonGroup.js +3 -3
- package/dist/components/ButtonGroup/hooks/useIDSButtonGroupItem.js +2 -2
- package/dist/components/ButtonGroup/index.js +1 -1
- package/dist/components/Card/helpers/composeIDSCard.js +1 -1
- package/dist/components/Checkbox/Checkbox.js +2 -2
- package/dist/components/Checkbox/helpers/mapCheckboxGroupOptions.js +1 -1
- package/dist/components/Checkbox/index.js +1 -1
- package/dist/components/CheckboxGroup/CheckboxGroup.js +7 -7
- package/dist/components/CheckboxMark/CheckboxMark.js +1 -1
- package/dist/components/CheckboxMark/CheckboxMark.types.js +2 -2
- package/dist/components/Col/Col.js +1 -1
- package/dist/components/Combobox/Combobox.js +3 -3
- package/dist/components/Combobox/MultiCombobox/MultiCombobox.js +3 -3
- package/dist/components/Combobox/components/ComboboxHiddenInput.js +2 -2
- package/dist/components/Combobox/components/ComboboxResults.js +6 -6
- package/dist/components/Combobox/components/ComboboxResultsDescriptor.js +3 -3
- package/dist/components/Combobox/index.js +1 -1
- package/dist/components/Container/Container.js +1 -1
- package/dist/components/Divider/Divider.js +1 -1
- package/dist/components/Expander/Expander.js +2 -2
- package/dist/components/Field/Field.js +2 -2
- package/dist/components/Field/FieldGroup/FieldGroup.js +3 -3
- package/dist/components/Field/components/FieldAppendToLabel.js +4 -4
- package/dist/components/Filter/Filter.js +3 -3
- package/dist/components/Filter/components/FilterResetButton.js +3 -3
- package/dist/components/Filter/components/FilterSearch.js +3 -3
- package/dist/components/Filter/index.js +1 -1
- package/dist/components/Form/Form.js +1 -1
- package/dist/components/Form/FormField/FormField.js +3 -3
- package/dist/components/Form/FormField/FormFieldset.js +3 -3
- package/dist/components/Form/HookForm/HookForm.js +2 -2
- package/dist/components/Form/components/FormValidationSummary.js +1 -1
- package/dist/components/Form/index.js +1 -1
- package/dist/components/Hide/Hide.js +2 -2
- package/dist/components/Hide/helpers/composeHideClasses.js +5 -5
- package/dist/components/Hide/index.js +1 -1
- package/dist/components/Icon/Icon.js +3 -3
- package/dist/components/Icon/index.js +1 -1
- package/dist/components/Inline/Inline.js +3 -3
- package/dist/components/Inline/index.js +1 -1
- package/dist/components/Input/ClearButton/ClearButton.js +1 -1
- package/dist/components/Input/Input.js +3 -3
- package/dist/components/Input/InputBase/InputBase.js +2 -2
- package/dist/components/Input/index.js +1 -1
- package/dist/components/InputCurrency/InputCurrency.js +1 -1
- package/dist/components/InputCurrency/index.js +1 -1
- package/dist/components/Label/LabelBase/LabelBase.js +2 -2
- package/dist/components/Menu/Menu.js +1 -1
- package/dist/components/Menu/MenuDivider/MenuDivider.js +3 -3
- package/dist/components/Menu/MenuHeading/MenuHeading.js +3 -3
- package/dist/components/Menu/MenuItem/MenuItem.js +1 -1
- package/dist/components/Menu/MenuItem/hooks/useMenuItemButtonProps.js +2 -2
- package/dist/components/Menu/MenuItem/hooks/useMenuItemComposite.js +2 -2
- package/dist/components/Menu/MenuText/MenuText.js +4 -4
- package/dist/components/Menu/helpers/mapMenuItems.js +1 -1
- package/dist/components/Menu/hooks/useMenuStyles.js +4 -4
- package/dist/components/Menu/index.js +1 -1
- package/dist/components/Modal/Modal.js +3 -3
- package/dist/components/Modal/hooks/useModal.js +17 -14
- package/dist/components/Modal/index.js +1 -1
- package/dist/components/Navbar/Navbar.js +3 -3
- package/dist/components/Navbar/components/HomeLinkContent.js +2 -2
- package/dist/components/Navbar/components/LogoFromSrc.js +1 -1
- package/dist/components/Navbar/components/NavbarLogo.js +3 -3
- package/dist/components/Navbar/index.js +1 -1
- package/dist/components/Panel/Panel.js +1 -1
- package/dist/components/Placeholder/Placeholder.js +2 -2
- package/dist/components/Popover/InputPopover/InputPopover.js +37 -35
- package/dist/components/Popover/InputPopover/InputPopoverActivator.js +1 -1
- package/dist/components/Popover/InputPopover/InputPopoverProvider.js +55 -53
- package/dist/components/Popover/Popover.js +40 -38
- package/dist/components/Popover/PopoverProvider.js +47 -45
- package/dist/components/Popover/components/NestedPopoverActivator.js +9 -0
- package/dist/components/Popover/components/PopoverActivator.js +2 -2
- package/dist/components/Popover/components/PopoverContent.js +3 -3
- package/dist/components/Popover/helpers/composeFloatingProps.js +26 -22
- package/dist/components/Popover/helpers/handlePopoverTabKey.js +16 -13
- package/dist/components/Popover/helpers/waitUntilTrue.js +12 -0
- package/dist/components/Popover/hooks/usePopoverActivatorInteractions.js +25 -17
- package/dist/components/Popover/hooks/usePopoverItem.js +1 -1
- package/dist/components/Popover/hooks/usePopoverNavigation.js +1 -1
- package/dist/components/Progress/Progress.js +2 -2
- package/dist/components/Radio/Radio.js +2 -2
- package/dist/components/Radio/helpers/mapRadioGroupOptions.js +1 -1
- package/dist/components/Radio/index.js +1 -1
- package/dist/components/RadioGroup/RadioGroup.js +4 -4
- package/dist/components/Readonly/Readonly.js +4 -4
- package/dist/components/Readonly/index.js +1 -1
- package/dist/components/RichSelect/RichSelect.js +2 -2
- package/dist/components/RichSelect/SelectBody/SelectBody.js +5 -5
- package/dist/components/RichSelect/SelectCreate/SelectCreate.js +3 -3
- package/dist/components/RichSelect/SelectHeading/SelectHeading.js +3 -3
- package/dist/components/RichSelect/SelectLabel/SelectLabel.js +2 -2
- package/dist/components/RichSelect/SelectMenu/SelectMenu.js +3 -3
- package/dist/components/RichSelect/SelectMenu/SelectMenuItem.js +3 -3
- package/dist/components/RichSelect/SelectSearch/SelectSearch.js +3 -3
- package/dist/components/RichSelect/SelectSearchInput/SelectSearchInput.js +2 -2
- package/dist/components/RichSelect/SelectTags/SelectTags.js +3 -3
- package/dist/components/RichSelect/components/SelectActivator.js +1 -1
- package/dist/components/RichSelect/components/SelectOptions.js +3 -3
- package/dist/components/RichSelect/index.js +1 -1
- package/dist/components/Row/Row.js +3 -3
- package/dist/components/Row/index.js +1 -1
- package/dist/components/Select/Select.js +3 -3
- package/dist/components/Select/components/SelectControl.js +2 -2
- package/dist/components/Select/components/SelectReadonly.js +3 -3
- package/dist/components/Select/helpers/mapSelectOptions.js +1 -1
- package/dist/components/Select/helpers/nodesToSelectOptions.js +1 -1
- package/dist/components/Select/index.js +1 -1
- package/dist/components/Skeleton/Skeleton.js +3 -3
- package/dist/components/SkipLink/SkipLink.js +2 -2
- package/dist/components/Slideout/Slideout.js +3 -3
- package/dist/components/Slideout/components/SlideoutInner.js +2 -2
- package/dist/components/Slideout/hooks/useSlideout.js +17 -14
- package/dist/components/Slideout/index.js +1 -1
- package/dist/components/Slider/Slider.js +3 -3
- package/dist/components/Slider/components/SliderTicks.js +2 -2
- package/dist/components/Slider/index.js +1 -1
- package/dist/components/Spinner/Spinner.js +2 -2
- package/dist/components/Spinner/index.js +1 -1
- package/dist/components/Stack/Stack.js +1 -1
- package/dist/components/TabSet/Tab/Tab.js +2 -2
- package/dist/components/TabSet/TabSet.js +3 -3
- package/dist/components/TabSet/components/TabSetItem.js +2 -2
- package/dist/components/Table/Table.js +3 -3
- package/dist/components/Table/TableBody/TableBody.js +16 -16
- package/dist/components/Table/components/TableEmpty.js +1 -1
- package/dist/components/Table/components/TableHeader.js +1 -1
- package/dist/components/Table/components/TableHeaderCell.js +2 -2
- package/dist/components/Table/components/TableSortButton.js +4 -4
- package/dist/components/Table/hooks/useIDSTableColumnStyles.js +2 -2
- package/dist/components/Table/index.js +1 -1
- package/dist/components/Tag/Tag.js +2 -2
- package/dist/components/Tag/TagInput/TagInput.js +1 -1
- package/dist/components/Tag/components/TagListInput/TagListInput.js +2 -2
- package/dist/components/Tag/index.js +1 -1
- package/dist/components/Text/Text.js +1 -1
- package/dist/components/Toaster/Toast/Toast.js +2 -2
- package/dist/components/Toaster/Toast/ToastAnimated.js +3 -3
- package/dist/components/Toaster/Toast/ToastIcon.js +1 -1
- package/dist/components/Toaster/Toaster.js +4 -4
- package/dist/components/Toaster/ToasterProvider.js +1 -1
- package/dist/components/Toaster/hooks/useToaster.js +1 -1
- package/dist/components/Toaster/index.js +1 -1
- package/dist/components/Toggle/Toggle.js +4 -4
- package/dist/components/Tooltip/Tooltip.js +3 -3
- package/dist/components/ValidationMessage/ValidationBase/ValidationBase.js +2 -2
- package/dist/components/ValidationMessage/ValidationSummary/ValidationSummary.js +2 -2
- package/dist/constants.js +1 -1
- package/dist/{floating-ui.react-D_ysmiM3.js → floating-ui.react-RKRjRgyj.js} +972 -961
- package/dist/fuzzysort-eoXOpoo6.js +395 -0
- package/dist/helpers/label-value/getQueryRangeExclusive.js +1 -1
- package/dist/helpers/label-value/highlightQueryInLabel.js +1 -1
- package/dist/helpers/label-value/searchLabelValues.js +1 -1
- package/dist/index-2QXL0WYc.js +45 -0
- package/dist/main.js +309 -308
- package/dist/patterns/Loading/Loading.js +4 -3
- package/dist/patterns/Loading/LoadingSuspense.js +7 -0
- package/dist/patterns/Loading/components/ComponentLoading.js +3 -3
- package/dist/patterns/Loading/components/DefaultLoading.js +4 -4
- package/dist/patterns/Loading/components/LongLoading.js +132 -0
- package/dist/patterns/Loading/components/PageLoading.js +4 -4
- package/dist/patterns/Loading/components/StartUpLoading.js +105 -9
- package/dist/patterns/Loading/components/ValidateLoading.js +3 -3
- package/dist/patterns/Loading/hooks/useEstimatedProgressValue.js +29 -0
- package/dist/patterns/Loading/hooks/useShouldRenderLoading.js +19 -15
- package/dist/patterns/Loading/hooks/useShowIndicator.js +20 -0
- package/dist/patterns/Loading/hooks/useSuspenseResource.js +27 -0
- package/dist/patterns/Loading/index.js +3 -2
- package/dist/src/components/Popover/Popover.types.d.ts +1 -0
- package/dist/src/components/Popover/components/NestedPopoverActivator.d.ts +5 -0
- package/dist/src/components/Popover/helpers/handlePopoverTabKey.d.ts +1 -1
- package/dist/src/components/Popover/helpers/waitUntilTrue.d.ts +1 -0
- package/dist/src/components/RichSelect/RichSelect.types.d.ts +14 -0
- package/dist/src/components/RichSelect/components/SelectOptions.d.ts +2 -2
- package/dist/src/patterns/Loading/Loading.d.ts +7 -2
- package/dist/src/patterns/Loading/LoadingSuspense.d.ts +73 -0
- package/dist/src/patterns/Loading/components/LongLoading.d.ts +60 -0
- package/dist/src/patterns/Loading/components/StartUpLoading.d.ts +1 -1
- package/dist/src/patterns/Loading/hooks/useEstimatedProgressValue.d.ts +11 -0
- package/dist/src/patterns/Loading/hooks/useShouldRenderLoading.d.ts +2 -1
- package/dist/src/patterns/Loading/hooks/useShowIndicator.d.ts +9 -0
- package/dist/src/patterns/Loading/hooks/useSuspenseResource.d.ts +17 -0
- package/dist/src/patterns/Loading/index.d.ts +1 -0
- package/dist/style.css +1 -1
- package/dist/{useIDSButtonGroupItem-Dzgv35ni.js → useIDSButtonGroupItem-D278MaLC.js} +2 -2
- package/package.json +9 -9
- package/dist/Loading-CZ64hUvP.js +0 -5638
- package/dist/LogoFromSrc-tAhdMB9Y.js +0 -59
- package/dist/MenuItem.module-Br0lJU3k.js +0 -24
- package/dist/Popover.module-COHnD5HM.js +0 -11
- package/dist/StartUpLoading-DpO7RfDY.js +0 -145
- package/dist/TabSet.module-Bje9oAao.js +0 -13
- package/dist/Table.module-CSNtX5ab.js +0 -32
- package/dist/_commonjsHelpers-DaMA6jEr.js +0 -8
- package/dist/fuzzysort-CuIReeYY.js +0 -393
- package/dist/index-Cu0xwYjD.js +0 -42
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import "
|
|
3
|
-
import { Q as
|
|
2
|
+
import "./components/StartUpLoading.js";
|
|
3
|
+
import { Q as s } from "../../LoadingSuspense-BDiikfSh.js";
|
|
4
4
|
import "./hooks/useShouldRenderLoading.js";
|
|
5
|
+
import "./components/LongLoading.js";
|
|
5
6
|
export {
|
|
6
|
-
|
|
7
|
+
s as IressLoading
|
|
7
8
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import "../../../components/Skeleton/Skeleton.js";
|
|
4
|
-
import {
|
|
5
|
-
import "../../../
|
|
6
|
-
import "../../../index-
|
|
4
|
+
import { ah as e } from "../../../LoadingSuspense-BDiikfSh.js";
|
|
5
|
+
import "../../../Loading.module-nxv4vxd0.js";
|
|
6
|
+
import "../../../index-2QXL0WYc.js";
|
|
7
7
|
import "../../../components/Text/Text.js";
|
|
8
8
|
export {
|
|
9
9
|
e as ComponentLoading
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import {
|
|
3
|
+
import { af as f } from "../../../LoadingSuspense-BDiikfSh.js";
|
|
4
4
|
import "../../../components/Text/Text.js";
|
|
5
|
-
import "../../../index-
|
|
6
|
-
import "../../../
|
|
5
|
+
import "../../../index-2QXL0WYc.js";
|
|
6
|
+
import "../../../Loading.module-nxv4vxd0.js";
|
|
7
7
|
export {
|
|
8
|
-
|
|
8
|
+
f as DefaultLoading
|
|
9
9
|
};
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { jsx as c, jsxs as g } from "react/jsx-runtime";
|
|
2
|
+
import { IressStack as w } from "../../../components/Stack/Stack.js";
|
|
3
|
+
import { useMemo as f, useId as y } from "react";
|
|
4
|
+
import { c as h } from "../../../index-2QXL0WYc.js";
|
|
5
|
+
import { l as m } from "../../../Loading.module-nxv4vxd0.js";
|
|
6
|
+
import { IressText as M } from "../../../components/Text/Text.js";
|
|
7
|
+
import { IressPanel as S } from "../../../components/Panel/Panel.js";
|
|
8
|
+
import { IressProgress as j } from "../../../components/Progress/Progress.js";
|
|
9
|
+
import { GlobalCSSClass as L } from "../../../enums.js";
|
|
10
|
+
import { propagateTestid as O } from "../../../helpers/utility/propagateTestid.js";
|
|
11
|
+
import { useShowIndicator as C } from "../hooks/useShowIndicator.js";
|
|
12
|
+
import { useEstimatedProgressValue as G } from "../hooks/useEstimatedProgressValue.js";
|
|
13
|
+
const P = "ids-long-loading--root-v5140", V = "ids-long-loading--panel-v5140", B = "ids-long-loading--dots-v5140", E = "ids-long-loading--check-list-v5140", R = "ids-long-loading--check-list-item-v5140", T = "ids-long-loading--check-list-item__done-v5140", U = "ids-long-loading--checked-v5140", $ = "ids-long-loading--checked__circle-v5140", q = "ids-long-loading--checked__check-v5140", s = {
|
|
14
|
+
root: P,
|
|
15
|
+
panel: V,
|
|
16
|
+
dots: B,
|
|
17
|
+
checkList: E,
|
|
18
|
+
checkListItem: R,
|
|
19
|
+
checkListItem__done: T,
|
|
20
|
+
checked: U,
|
|
21
|
+
checked__circle: $,
|
|
22
|
+
checked__check: q
|
|
23
|
+
}, z = () => {
|
|
24
|
+
const t = y();
|
|
25
|
+
return /* @__PURE__ */ g(
|
|
26
|
+
"svg",
|
|
27
|
+
{
|
|
28
|
+
className: s.checked,
|
|
29
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
30
|
+
viewBox: "0 0 52 52",
|
|
31
|
+
"aria-labelledby": t,
|
|
32
|
+
children: [
|
|
33
|
+
/* @__PURE__ */ c("title", { id: t, children: "Finished: " }),
|
|
34
|
+
/* @__PURE__ */ c(
|
|
35
|
+
"circle",
|
|
36
|
+
{
|
|
37
|
+
className: s.checked__circle,
|
|
38
|
+
cx: "26",
|
|
39
|
+
cy: "26",
|
|
40
|
+
r: "25",
|
|
41
|
+
fill: "none"
|
|
42
|
+
}
|
|
43
|
+
),
|
|
44
|
+
/* @__PURE__ */ c(
|
|
45
|
+
"path",
|
|
46
|
+
{
|
|
47
|
+
className: s.checked__check,
|
|
48
|
+
fill: "none",
|
|
49
|
+
d: "M14.1 27.2l7.1 7.2 16.7-16.8"
|
|
50
|
+
}
|
|
51
|
+
)
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
);
|
|
55
|
+
}, ce = ({
|
|
56
|
+
children: t,
|
|
57
|
+
className: v,
|
|
58
|
+
error: k,
|
|
59
|
+
estimatedFinishTime: r = 1e4,
|
|
60
|
+
loaded: d,
|
|
61
|
+
messageList: l = {},
|
|
62
|
+
progress: N,
|
|
63
|
+
renderProgress: u = (a) => /* @__PURE__ */ c(j, { ...a }),
|
|
64
|
+
timeout: n,
|
|
65
|
+
...p
|
|
66
|
+
}) => {
|
|
67
|
+
const a = C(
|
|
68
|
+
d,
|
|
69
|
+
n == null ? void 0 : n.message,
|
|
70
|
+
(n == null ? void 0 : n.loaded) ?? 1300
|
|
71
|
+
), I = Math.max(...Object.keys(l).map(Number)) + 500, o = G(
|
|
72
|
+
r,
|
|
73
|
+
d,
|
|
74
|
+
N,
|
|
75
|
+
I
|
|
76
|
+
), _ = f(() => {
|
|
77
|
+
const e = Object.keys(l), i = e.findIndex(
|
|
78
|
+
(x) => Number(x) > o
|
|
79
|
+
);
|
|
80
|
+
return d ? "" : e[i] ?? e[e.length - 1];
|
|
81
|
+
}, [l, d, o]), b = f(() => Object.entries(l).map(([e, i]) => ({
|
|
82
|
+
timecode: Number(e),
|
|
83
|
+
message: i,
|
|
84
|
+
current: e === _,
|
|
85
|
+
finished: o >= Number(e)
|
|
86
|
+
})), [l, _, o]);
|
|
87
|
+
return /* @__PURE__ */ c(
|
|
88
|
+
"div",
|
|
89
|
+
{
|
|
90
|
+
className: h(s.root, v, m["fade-in"], {
|
|
91
|
+
[m["fade-in--active"]]: a
|
|
92
|
+
}),
|
|
93
|
+
...p,
|
|
94
|
+
children: /* @__PURE__ */ c(
|
|
95
|
+
S,
|
|
96
|
+
{
|
|
97
|
+
"data-testid": O(p["data-testid"], "panel"),
|
|
98
|
+
className: h(s.panel, {
|
|
99
|
+
[m.error]: !!k
|
|
100
|
+
}),
|
|
101
|
+
children: k ?? /* @__PURE__ */ g(w, { gutter: "md", children: [
|
|
102
|
+
t,
|
|
103
|
+
u({
|
|
104
|
+
className: s.progress,
|
|
105
|
+
min: 0,
|
|
106
|
+
max: r,
|
|
107
|
+
value: Math.min(o, r),
|
|
108
|
+
sectionTitle: `${Math.min(o, r) / r * 100}% loaded`
|
|
109
|
+
}),
|
|
110
|
+
/* @__PURE__ */ c(M, { variant: "lead", noGutter: !0, children: /* @__PURE__ */ c("ul", { className: s.checkList, children: b.map((e) => /* @__PURE__ */ g(
|
|
111
|
+
"li",
|
|
112
|
+
{
|
|
113
|
+
className: h(s.checkListItem, {
|
|
114
|
+
[s.checkListItem__done]: e.finished
|
|
115
|
+
}),
|
|
116
|
+
children: [
|
|
117
|
+
e.finished && /* @__PURE__ */ c(z, {}),
|
|
118
|
+
e.message,
|
|
119
|
+
e.current && /* @__PURE__ */ c("span", { className: s.dots, children: /* @__PURE__ */ c("span", { className: L.SROnly, children: "..." }) })
|
|
120
|
+
]
|
|
121
|
+
},
|
|
122
|
+
e.timecode
|
|
123
|
+
)) }) })
|
|
124
|
+
] })
|
|
125
|
+
}
|
|
126
|
+
)
|
|
127
|
+
}
|
|
128
|
+
);
|
|
129
|
+
};
|
|
130
|
+
export {
|
|
131
|
+
ce as LongLoading
|
|
132
|
+
};
|
|
@@ -3,12 +3,12 @@ import "react";
|
|
|
3
3
|
import "../../../components/Stack/Stack.js";
|
|
4
4
|
import "../../../components/Skeleton/Skeleton.js";
|
|
5
5
|
import "../../../components/Container/Container.js";
|
|
6
|
-
import {
|
|
6
|
+
import { ai as s } from "../../../LoadingSuspense-BDiikfSh.js";
|
|
7
7
|
import "../../../components/Col/Col.js";
|
|
8
8
|
import "../../../components/Divider/Divider.js";
|
|
9
9
|
import "../../../components/Card/Card.js";
|
|
10
|
-
import "../../../index-
|
|
11
|
-
import "../../../
|
|
10
|
+
import "../../../index-2QXL0WYc.js";
|
|
11
|
+
import "../../../Loading.module-nxv4vxd0.js";
|
|
12
12
|
export {
|
|
13
|
-
|
|
13
|
+
s as PageLoading
|
|
14
14
|
};
|
|
@@ -1,11 +1,107 @@
|
|
|
1
|
-
import "react/jsx-runtime";
|
|
2
|
-
import "../../../components/Stack/Stack.js";
|
|
3
|
-
import "react";
|
|
4
|
-
import "../../../components/Progress/Progress.js";
|
|
5
|
-
import "../../../index-
|
|
6
|
-
import {
|
|
7
|
-
import "../../../components/Text/Text.js";
|
|
8
|
-
import "../../../helpers/utility/propagateTestid.js";
|
|
1
|
+
import { jsx as a, jsxs as w } from "react/jsx-runtime";
|
|
2
|
+
import { IressStack as j } from "../../../components/Stack/Stack.js";
|
|
3
|
+
import { useState as y, useEffect as u, useRef as I, useMemo as T } from "react";
|
|
4
|
+
import { IressProgress as k } from "../../../components/Progress/Progress.js";
|
|
5
|
+
import { c as M } from "../../../index-2QXL0WYc.js";
|
|
6
|
+
import { l as n } from "../../../Loading.module-nxv4vxd0.js";
|
|
7
|
+
import { IressText as v } from "../../../components/Text/Text.js";
|
|
8
|
+
import { propagateTestid as O } from "../../../helpers/utility/propagateTestid.js";
|
|
9
|
+
import { useShowIndicator as E } from "../hooks/useShowIndicator.js";
|
|
10
|
+
import { useEstimatedProgressValue as R } from "../hooks/useEstimatedProgressValue.js";
|
|
11
|
+
const H = "ids-start-up-loading--root-v5140", P = "ids-start-up-loading--progress-v5140", h = {
|
|
12
|
+
root: H,
|
|
13
|
+
progress: P
|
|
14
|
+
}, U = ({
|
|
15
|
+
children: g,
|
|
16
|
+
messageList: e,
|
|
17
|
+
progressValue: c,
|
|
18
|
+
screenReaderText: s,
|
|
19
|
+
show: t,
|
|
20
|
+
...l
|
|
21
|
+
}) => {
|
|
22
|
+
const o = I(null), d = T(() => {
|
|
23
|
+
const r = Object.keys(e ?? {}).filter(
|
|
24
|
+
(f) => Number(f) <= c
|
|
25
|
+
);
|
|
26
|
+
return r[r.length - 1];
|
|
27
|
+
}, [e, c]);
|
|
28
|
+
u(() => {
|
|
29
|
+
o.current && (o.current.classList.remove(n["slide-next"]), o.current.offsetHeight, o.current.classList.add(n["slide-next"]));
|
|
30
|
+
}, [d]);
|
|
31
|
+
const p = t ? g : s;
|
|
32
|
+
return /* @__PURE__ */ a(
|
|
33
|
+
v,
|
|
34
|
+
{
|
|
35
|
+
align: "center",
|
|
36
|
+
className: M(h.message, n["fade-in"], {
|
|
37
|
+
[n["fade-in--active"]]: t
|
|
38
|
+
}),
|
|
39
|
+
...l,
|
|
40
|
+
children: /* @__PURE__ */ a("div", { ref: o, children: d ? e == null ? void 0 : e[Number(d)] : p })
|
|
41
|
+
}
|
|
42
|
+
);
|
|
43
|
+
}, K = ({
|
|
44
|
+
className: g,
|
|
45
|
+
children: e = /* @__PURE__ */ a(v, { mode: "muted", children: "One moment please..." }),
|
|
46
|
+
"data-testid": c,
|
|
47
|
+
estimatedFinishTime: s = 3e3,
|
|
48
|
+
loaded: t,
|
|
49
|
+
messageList: l,
|
|
50
|
+
progress: o,
|
|
51
|
+
renderProgress: d = (m) => /* @__PURE__ */ a(k, { ...m }),
|
|
52
|
+
screenReaderText: p = "Loading...",
|
|
53
|
+
timeout: r,
|
|
54
|
+
...f
|
|
55
|
+
}) => {
|
|
56
|
+
const m = E(
|
|
57
|
+
t,
|
|
58
|
+
r == null ? void 0 : r.progress,
|
|
59
|
+
r == null ? void 0 : r.loaded
|
|
60
|
+
), [x, N] = y(!1), S = Math.max(...Object.keys(l ?? {}).map(Number)) + 500, i = R(
|
|
61
|
+
s,
|
|
62
|
+
t,
|
|
63
|
+
o,
|
|
64
|
+
S
|
|
65
|
+
);
|
|
66
|
+
return u(() => {
|
|
67
|
+
const b = setTimeout(
|
|
68
|
+
() => N(!0),
|
|
69
|
+
(r == null ? void 0 : r.message) ?? 2500
|
|
70
|
+
);
|
|
71
|
+
return () => {
|
|
72
|
+
clearTimeout(b);
|
|
73
|
+
};
|
|
74
|
+
}, [r == null ? void 0 : r.message]), /* @__PURE__ */ a(
|
|
75
|
+
"div",
|
|
76
|
+
{
|
|
77
|
+
"data-testid": c,
|
|
78
|
+
className: M(h.root, g, n["fade-in"], {
|
|
79
|
+
[n["fade-in--active"]]: m
|
|
80
|
+
}),
|
|
81
|
+
...f,
|
|
82
|
+
children: /* @__PURE__ */ w(j, { gutter: "md", ...f, children: [
|
|
83
|
+
d({
|
|
84
|
+
className: h.progress,
|
|
85
|
+
min: 0,
|
|
86
|
+
max: s,
|
|
87
|
+
value: Math.min(i, s),
|
|
88
|
+
sectionTitle: `${Math.min(i, s) / s * 100}% loaded`
|
|
89
|
+
}),
|
|
90
|
+
/* @__PURE__ */ a(
|
|
91
|
+
U,
|
|
92
|
+
{
|
|
93
|
+
"data-testid": O(c, "message"),
|
|
94
|
+
messageList: l,
|
|
95
|
+
progressValue: i,
|
|
96
|
+
screenReaderText: p,
|
|
97
|
+
show: x,
|
|
98
|
+
children: e
|
|
99
|
+
}
|
|
100
|
+
)
|
|
101
|
+
] })
|
|
102
|
+
}
|
|
103
|
+
);
|
|
104
|
+
};
|
|
9
105
|
export {
|
|
10
|
-
|
|
106
|
+
K as StartUpLoading
|
|
11
107
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import {
|
|
3
|
-
import "../../../index-
|
|
2
|
+
import { ag as d } from "../../../LoadingSuspense-BDiikfSh.js";
|
|
3
|
+
import "../../../index-2QXL0WYc.js";
|
|
4
4
|
import "react";
|
|
5
5
|
import "../../../components/Text/Text.js";
|
|
6
|
-
import "../../../
|
|
6
|
+
import "../../../Loading.module-nxv4vxd0.js";
|
|
7
7
|
export {
|
|
8
8
|
d as ValidateLoading
|
|
9
9
|
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { useState as A, useMemo as E, useEffect as V } from "react";
|
|
2
|
+
const l = (r, u = !1, n, t = 0) => {
|
|
3
|
+
const [o, c] = A(n ?? 0), f = E(() => !u && !n && w(o, r, t), [
|
|
4
|
+
r,
|
|
5
|
+
t,
|
|
6
|
+
u,
|
|
7
|
+
n,
|
|
8
|
+
o
|
|
9
|
+
]);
|
|
10
|
+
return V(() => {
|
|
11
|
+
if (!f && o < r) {
|
|
12
|
+
c(r);
|
|
13
|
+
return;
|
|
14
|
+
}
|
|
15
|
+
const q = performance.now(), P = () => {
|
|
16
|
+
const x = Math.max(performance.now() - q, 0), a = o + x;
|
|
17
|
+
c(a), w(a, r, t) && requestAnimationFrame(P);
|
|
18
|
+
};
|
|
19
|
+
requestAnimationFrame(P);
|
|
20
|
+
}, [
|
|
21
|
+
r,
|
|
22
|
+
f,
|
|
23
|
+
t,
|
|
24
|
+
o
|
|
25
|
+
]), n !== void 0 ? u ? r : n : o;
|
|
26
|
+
}, w = (r, u, n) => r < u || r < n;
|
|
27
|
+
export {
|
|
28
|
+
l as useEstimatedProgressValue
|
|
29
|
+
};
|
|
@@ -1,20 +1,24 @@
|
|
|
1
|
-
import { useState as
|
|
2
|
-
const
|
|
3
|
-
const [i, n
|
|
4
|
-
return
|
|
5
|
-
const
|
|
6
|
-
e ||
|
|
7
|
-
},
|
|
8
|
-
return () => clearTimeout(
|
|
9
|
-
}, [
|
|
1
|
+
import { useState as i, useRef as m, useEffect as f } from "react";
|
|
2
|
+
const p = (e, o = 500, r = 250, c = 250) => {
|
|
3
|
+
const [s, t] = i(r === 0), n = m(0);
|
|
4
|
+
return f(() => {
|
|
5
|
+
const u = setTimeout(() => {
|
|
6
|
+
e || (t(!0), n.current = performance.now());
|
|
7
|
+
}, r);
|
|
8
|
+
return () => clearTimeout(u);
|
|
9
|
+
}, [r, e]), f(() => {
|
|
10
10
|
if (e !== !0)
|
|
11
11
|
return;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
12
|
+
if (!n.current || performance.now() - n.current < c) {
|
|
13
|
+
t(!1);
|
|
14
|
+
return;
|
|
15
|
+
}
|
|
16
|
+
const u = setTimeout(() => {
|
|
17
|
+
t(!1);
|
|
18
|
+
}, o);
|
|
19
|
+
return () => clearTimeout(u);
|
|
20
|
+
}, [e, o, c]), e !== !0 || s;
|
|
17
21
|
};
|
|
18
22
|
export {
|
|
19
|
-
|
|
23
|
+
p as useShouldRenderLoading
|
|
20
24
|
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { useState as c, useEffect as s } from "react";
|
|
2
|
+
const m = (e = !1, o = 500, r = 200) => {
|
|
3
|
+
const [n, u] = c(!1);
|
|
4
|
+
return s(() => {
|
|
5
|
+
if (e !== !0)
|
|
6
|
+
return;
|
|
7
|
+
const t = setTimeout(() => u(!1), r);
|
|
8
|
+
return () => {
|
|
9
|
+
clearTimeout(t);
|
|
10
|
+
};
|
|
11
|
+
}, [e, r]), s(() => {
|
|
12
|
+
const t = setTimeout(() => u(!0), o);
|
|
13
|
+
return () => {
|
|
14
|
+
clearTimeout(t);
|
|
15
|
+
};
|
|
16
|
+
}, [o]), n;
|
|
17
|
+
};
|
|
18
|
+
export {
|
|
19
|
+
m as useShowIndicator
|
|
20
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { useMemo as c } from "react";
|
|
2
|
+
const a = (e) => {
|
|
3
|
+
let r = "pending", n, o;
|
|
4
|
+
const u = e.then(
|
|
5
|
+
(t) => {
|
|
6
|
+
r = "success", n = t;
|
|
7
|
+
},
|
|
8
|
+
(t) => {
|
|
9
|
+
r = "error", o = t;
|
|
10
|
+
}
|
|
11
|
+
);
|
|
12
|
+
return {
|
|
13
|
+
read() {
|
|
14
|
+
if (r === "pending") throw u;
|
|
15
|
+
if (r === "error") throw o;
|
|
16
|
+
return n;
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
}, s = /* @__PURE__ */ new WeakMap(), d = (e) => c(() => (s.has(e) || s.set(e, a(e())), s.get(e)), [e]).read(), i = (e, r = 1e3) => {
|
|
20
|
+
setTimeout(() => {
|
|
21
|
+
s.delete(e);
|
|
22
|
+
}, r);
|
|
23
|
+
};
|
|
24
|
+
export {
|
|
25
|
+
i as uncacheSuspenseResource,
|
|
26
|
+
d as useSuspenseResource
|
|
27
|
+
};
|
|
@@ -142,6 +142,7 @@ export interface PopoverContextValue extends PopoverStateHookReturn, PopoverAria
|
|
|
142
142
|
interactions: ReturnType<typeof useInteractions>;
|
|
143
143
|
list: MutableRefObject<(HTMLElement | null)[]>;
|
|
144
144
|
type?: PopoverTypes;
|
|
145
|
+
setActiveIndex: (value: number | null) => void;
|
|
145
146
|
setShowWithReason: (flag: boolean, e?: Event, reason?: OpenChangeReason) => void;
|
|
146
147
|
setVirtualFocus?: (node: PopoverVirtualNode | null) => void;
|
|
147
148
|
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PropsWithChildren } from 'react';
|
|
2
|
+
import { PopoverContextValue } from '../Popover.types';
|
|
3
|
+
export declare const NestedPopoverActivator: ({ children, parentPopover, }: PropsWithChildren & {
|
|
4
|
+
parentPopover?: PopoverContextValue;
|
|
5
|
+
}) => string | number | boolean | Iterable<import('react').ReactNode> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
@@ -5,4 +5,4 @@ import { KeyboardEvent } from 'react';
|
|
|
5
5
|
* @param popover {PopoverContextValue} The popover context value, usually retrieved from the usePopover hook.
|
|
6
6
|
* @param e {KeyboardEvent} The keyboard event object that triggered the tab key press.
|
|
7
7
|
*/
|
|
8
|
-
export declare const handlePopoverTabKey: (popover: PopoverContextValue, e: KeyboardEvent) => void
|
|
8
|
+
export declare const handlePopoverTabKey: (popover: PopoverContextValue, e: KeyboardEvent) => Promise<void>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const waitUntilTrue: (condition: () => boolean, timeout?: number, interval?: number) => Promise<void>;
|
|
@@ -7,6 +7,12 @@ export interface IressRichSelectProps extends Omit<AutocompleteSearchHookProps,
|
|
|
7
7
|
* @default bottom-start
|
|
8
8
|
*/
|
|
9
9
|
align?: FloatingUIAligns;
|
|
10
|
+
/**
|
|
11
|
+
* By default, the RichSelect will automatically highlight the first option in the list when it is opened.
|
|
12
|
+
* Set this to false to disable that behaviour.
|
|
13
|
+
* @default true
|
|
14
|
+
*/
|
|
15
|
+
autoHighlight?: boolean;
|
|
10
16
|
/**
|
|
11
17
|
* Value of selected option for uncontrolled select.
|
|
12
18
|
*/
|
|
@@ -74,6 +80,14 @@ export interface IressRichSelectProps extends Omit<AutocompleteSearchHookProps,
|
|
|
74
80
|
*/
|
|
75
81
|
width?: FormElementWidths;
|
|
76
82
|
virtualFocus?: boolean;
|
|
83
|
+
/**
|
|
84
|
+
* Header showed in option panel when expanded.
|
|
85
|
+
*/
|
|
86
|
+
header?: ReactNode;
|
|
87
|
+
/**
|
|
88
|
+
* Footer showed in option panel when expanded.
|
|
89
|
+
*/
|
|
90
|
+
footer?: ReactNode;
|
|
77
91
|
}
|
|
78
92
|
export interface IressSelectActivatorProps {
|
|
79
93
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IressRichSelectProps, SelectOptionsRenderProps } from '../RichSelect.types';
|
|
2
|
-
interface SelectOptionsProps extends Pick<IressRichSelectProps, 'multiSelect' | 'onChange' | 'options' | 'renderOptions' | 'value' | 'initialOptions'>, Omit<SelectOptionsRenderProps, 'close'> {
|
|
2
|
+
interface SelectOptionsProps extends Pick<IressRichSelectProps, 'autoHighlight' | 'multiSelect' | 'onChange' | 'options' | 'renderOptions' | 'value' | 'initialOptions'>, Omit<SelectOptionsRenderProps, 'close'> {
|
|
3
3
|
setShow: (show: boolean) => void;
|
|
4
4
|
}
|
|
5
|
-
export declare const SelectOptions: ({ debouncedQuery, error, initialOptions: initialOptionsProp, loading, multiSelect, onChange, options, query, renderOptions, results, setQuery, setShow, setValue, show, value, }: SelectOptionsProps) => string | number | boolean | Iterable<import('react').ReactNode> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
5
|
+
export declare const SelectOptions: ({ autoHighlight, debouncedQuery, error, initialOptions: initialOptionsProp, loading, multiSelect, onChange, options, query, renderOptions, results, setQuery, setShow, setValue, show, value, }: SelectOptionsProps) => string | number | boolean | Iterable<import('react').ReactNode> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
6
6
|
export {};
|
|
@@ -3,7 +3,8 @@ import { DefaultLoadingProps } from './components/DefaultLoading';
|
|
|
3
3
|
import { ValidateLoadingProps } from './components/ValidateLoading';
|
|
4
4
|
import { ComponentLoadingProps } from './components/ComponentLoading';
|
|
5
5
|
import { PageLoadingProps } from './components/PageLoading';
|
|
6
|
-
|
|
6
|
+
import { LongLoadingProps } from './components/LongLoading';
|
|
7
|
+
export type IressLoadingProps = StartUpLoadingProps | ValidateLoadingProps | PageLoadingProps | ComponentLoadingProps | LongLoadingProps | DefaultLoadingProps;
|
|
7
8
|
/**
|
|
8
9
|
* A pattern component that has in-built loading states for different contexts, designed to provide a consistent user experience across Iress applications.
|
|
9
10
|
*
|
|
@@ -12,6 +13,10 @@ export type IressLoadingProps = StartUpLoadingProps | ValidateLoadingProps | Pag
|
|
|
12
13
|
* - `component`: Loading pattern for a component that is expected to take some time to load, but has content around it that can be loaded before it (hence not part of page pattern). It also supports updating the state of the component via a slightly different UI. Examples:
|
|
13
14
|
* - Charts that can be updated in real-time
|
|
14
15
|
* - Tables that load many records and may update in real-time
|
|
16
|
+
* - `long`: Loading pattern for a component that is expected to take longer than 10 seconds to load. It displays a checklist of items that are being loaded. Examples:
|
|
17
|
+
* - Calling multiple slow APIs to load data
|
|
18
|
+
* - Loading results from AI
|
|
19
|
+
* - Processing a large amount of data as a queue (eg. bulk uploading or large media file uploads)
|
|
15
20
|
* - `page`: Loading pattern for a page, with out-of-the-box skeleton templates. Examples:
|
|
16
21
|
* - Dashboard page with multiple filters/panels
|
|
17
22
|
* - Search page with multiple filters and search results
|
|
@@ -38,5 +43,5 @@ export declare const IressLoading: {
|
|
|
38
43
|
* @param delay - Once a component has loaded, how long should the loading indicator be displayed for.
|
|
39
44
|
* @returns A boolean value that determines whether the `IressLoading` component is safe to be removed.
|
|
40
45
|
*/
|
|
41
|
-
shouldRender: (isLoaded: boolean, delay?: number, startFrom?: number) => boolean;
|
|
46
|
+
shouldRender: (isLoaded: boolean, delay?: number, startFrom?: number, avoidDelayTimeout?: number) => boolean;
|
|
42
47
|
};
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { StartUpLoadingProps } from './components/StartUpLoading';
|
|
3
|
+
import { ValidateLoadingProps } from './components/ValidateLoading';
|
|
4
|
+
import { PageLoadingProps } from './components/PageLoading';
|
|
5
|
+
import { ComponentLoadingProps } from './components/ComponentLoading';
|
|
6
|
+
import { LongLoadingProps } from './components/LongLoading';
|
|
7
|
+
import { DefaultLoadingProps } from './components/DefaultLoading';
|
|
8
|
+
export type IressLoadingSuspenseProps = (Omit<StartUpLoadingProps, 'loaded'> | ValidateLoadingProps | Omit<PageLoadingProps, 'loaded'> | Omit<ComponentLoadingProps, 'loaded'> | Omit<LongLoadingProps, 'loaded'> | DefaultLoadingProps) & {
|
|
9
|
+
/**
|
|
10
|
+
* The content that will be rendered inside the Suspense boundary.
|
|
11
|
+
* Typically includes lazy-loaded components and components that use the `use` or `IressLoadingSuspense.use` hook.
|
|
12
|
+
*/
|
|
13
|
+
children?: ReactNode;
|
|
14
|
+
/**
|
|
15
|
+
* Duration (in milliseconds) to delay unmounting the fallback
|
|
16
|
+
* to allow the fade-out animation to complete.
|
|
17
|
+
* By default it uses the default delay of the pattern.
|
|
18
|
+
*/
|
|
19
|
+
delay?: number;
|
|
20
|
+
/**
|
|
21
|
+
* By default it uses the default delay of the pattern.
|
|
22
|
+
*/
|
|
23
|
+
onLoaded?: () => void;
|
|
24
|
+
/**
|
|
25
|
+
* Duration (in milliseconds) before showing the loading pattern.
|
|
26
|
+
* Default is 500ms, meaning a user will not even see the loading indicator if the page loads before this time.
|
|
27
|
+
*/
|
|
28
|
+
startFrom?: number;
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* A pattern component that has in-built loading states for different contexts, designed to provide a consistent user experience across Iress applications.
|
|
32
|
+
*
|
|
33
|
+
* The `pattern` prop is used to determine the type of loading state to display. The following patterns are available:
|
|
34
|
+
*
|
|
35
|
+
* - `component`: Loading pattern for a component that is expected to take some time to load, but has content around it that can be loaded before it (hence not part of page pattern). It also supports updating the state of the component via a slightly different UI. Examples:
|
|
36
|
+
* - Charts that can be updated in real-time
|
|
37
|
+
* - Tables that load many records and may update in real-time
|
|
38
|
+
* - `long`: Loading pattern for a component that is expected to take longer than 10 seconds to load. It displays a checklist of items that are being loaded. Examples:
|
|
39
|
+
* - Calling multiple slow APIs to load data
|
|
40
|
+
* - Loading results from AI
|
|
41
|
+
* - Processing a large amount of data as a queue (eg. bulk uploading or large media file uploads)
|
|
42
|
+
* - `page`: Loading pattern for a page, with out-of-the-box skeleton templates. Examples:
|
|
43
|
+
* - Dashboard page with multiple filters/panels
|
|
44
|
+
* - Search page with multiple filters and search results
|
|
45
|
+
* - Detail page for a record
|
|
46
|
+
* - Form page
|
|
47
|
+
* - Article page
|
|
48
|
+
* - `start-up`: Loading pattern when the application is first loaded. Examples:
|
|
49
|
+
* - Loading an application for the first time
|
|
50
|
+
* - Switching from a different application to a new application
|
|
51
|
+
* - Switching from a client's website to an Iress application
|
|
52
|
+
* - Switching themes
|
|
53
|
+
* - `validate`: Loading pattern when validating user input. Examples:
|
|
54
|
+
* - Submitting a form
|
|
55
|
+
* - Saving a record
|
|
56
|
+
*
|
|
57
|
+
* If no `pattern` is provided, it will use the default experience, which only displays a message after a certain amount of time to help stop drop-offs due to uncommon loading times.
|
|
58
|
+
*/
|
|
59
|
+
export declare const IressLoadingSuspense: {
|
|
60
|
+
({ children, delay: delayProp, onLoaded, pattern, startFrom: startFromProp, ...restProps }: IressLoadingSuspenseProps): import("react/jsx-runtime").JSX.Element;
|
|
61
|
+
/**
|
|
62
|
+
* A polyfill for the `use` hook in React 19. It allows you to suspend a component until the resource (Promise) is resolved.
|
|
63
|
+
* **Note:** For those using React 19, import the `use` hook from React instead of using this polyfill.
|
|
64
|
+
* @see https://react.dev/reference/react/use
|
|
65
|
+
*/
|
|
66
|
+
use: <T>(fetcher: () => Promise<T>) => T;
|
|
67
|
+
/**
|
|
68
|
+
* Uncache the resource (Promise) that is being used in the `use` hook.
|
|
69
|
+
* **Note:** For those using React 19, import the `use` hook from React instead of using this method.
|
|
70
|
+
* @see https://react.dev/reference/react/use
|
|
71
|
+
*/
|
|
72
|
+
uncache: (fetcher: () => Promise<unknown>, timeout?: number) => void;
|
|
73
|
+
};
|