@iress-oss/ids-components 5.20.0 → 5.20.3
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/CHANGELOG.md +378 -0
- package/README.md +1 -1
- package/dist/{AutocompleteNoResults-CogA3XZs.js → AutocompleteNoResults-B7El1R2l.js} +1 -1
- package/dist/ComboboxHiddenInput-CWfIj-Zz.js +32 -0
- package/dist/{FieldAppendToLabel-CuSREliL.js → FieldAppendToLabel-BTdzhQ7Z.js} +5 -5
- package/dist/InputBase-Hc9D8St6.js +56 -0
- package/dist/Loading.module-BjceG0Wh.js +13 -0
- package/dist/LoadingSuspense-Bwd232Nt.js +5728 -0
- package/dist/LogoFromSrc-CAdoYYud.js +59 -0
- package/dist/MenuItem.module-BQw_K5D4.js +24 -0
- package/dist/Popover.module-ZU-08mVQ.js +11 -0
- package/dist/PopoverProvider-Cvg6ObBO.js +142 -0
- package/dist/{SelectControl-D1SJlplM.js → SelectControl-WoixPfwh.js} +2 -2
- package/dist/SliderTicks-D-B1uIdS.js +74 -0
- package/dist/TabSet.module-4ohNBuQS.js +13 -0
- package/dist/Table.module-BYwGboft.js +32 -0
- package/dist/components/Alert/Alert.js +2 -2
- package/dist/components/Alert/index.js +1 -1
- package/dist/components/Autocomplete/Autocomplete.js +4 -4
- package/dist/components/Autocomplete/components/AutocompleteInstructions.js +7 -7
- package/dist/components/Autocomplete/components/AutocompleteNoResults.js +1 -1
- package/dist/components/Autocomplete/hooks/useAutocompleteSearch.js +36 -35
- 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/ButtonGroupProvider.js +22 -22
- 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 +11 -11
- package/dist/components/Checkbox/index.js +1 -1
- package/dist/components/CheckboxGroup/CheckboxGroup.js +74 -75
- 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 +4 -4
- package/dist/components/Combobox/MultiCombobox/MultiCombobox.js +4 -4
- 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 +4 -4
- package/dist/components/Combobox/hooks/useComboboxInlineCompletion.js +34 -37
- 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 +48 -48
- package/dist/components/Field/Field.js +47 -47
- package/dist/components/Field/FieldGroup/FieldGroup.js +59 -59
- package/dist/components/Field/components/FieldAppendToLabel.js +5 -5
- package/dist/components/Filter/Filter.js +4 -4
- package/dist/components/Filter/components/FilterResetButton.js +4 -4
- package/dist/components/Filter/components/FilterSearch.js +4 -4
- package/dist/components/Filter/index.js +1 -1
- package/dist/components/Form/Form.js +1 -1
- package/dist/components/Form/FormField/FormField.js +46 -49
- package/dist/components/Form/FormField/FormFieldset.js +42 -45
- package/dist/components/Form/FormField/helpers/getErrorTypeMessage.js +10 -10
- package/dist/components/Form/HookForm/HookForm.js +2 -2
- package/dist/components/Form/components/FormValidationSummary.js +15 -16
- package/dist/components/Form/index.js +1 -1
- package/dist/components/Hide/Hide.js +2 -2
- package/dist/components/Hide/helpers/composeHideClasses.js +4 -4
- package/dist/components/Hide/index.js +1 -1
- package/dist/components/Icon/Icon.js +4 -4
- package/dist/components/Icon/index.js +1 -1
- package/dist/components/Inline/Inline.js +4 -4
- 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 +37 -37
- package/dist/components/Menu/Menu.js +1 -1
- package/dist/components/Menu/MenuDivider/MenuDivider.js +4 -4
- package/dist/components/Menu/MenuHeading/MenuHeading.js +3 -3
- package/dist/components/Menu/MenuItem/MenuItem.js +1 -1
- package/dist/components/Menu/MenuItem/hooks/useMenuItemAria.js +7 -7
- package/dist/components/Menu/MenuItem/hooks/useMenuItemButtonProps.js +30 -30
- package/dist/components/Menu/MenuItem/hooks/useMenuItemComposite.js +2 -2
- package/dist/components/Menu/MenuItem/hooks/useMenuItemInteractions.js +47 -49
- package/dist/components/Menu/MenuItem/hooks/useMenuItemRole.js +5 -5
- package/dist/components/Menu/MenuText/MenuText.js +5 -5
- package/dist/components/Menu/helpers/mapMenuItems.js +21 -21
- package/dist/components/Menu/hooks/useMenuAria.js +2 -2
- package/dist/components/Menu/hooks/useMenuComposite.js +6 -6
- package/dist/components/Menu/hooks/useMenuRole.js +10 -10
- package/dist/components/Menu/hooks/useMenuStyles.js +18 -18
- package/dist/components/Menu/index.js +1 -1
- package/dist/components/Modal/Modal.js +3 -3
- package/dist/components/Modal/hooks/useIDSProvidedModal.js +8 -8
- 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 +20 -20
- package/dist/components/Popover/InputPopover/InputPopover.js +2 -2
- package/dist/components/Popover/InputPopover/InputPopoverActivator.js +40 -43
- package/dist/components/Popover/InputPopover/InputPopoverProvider.js +61 -61
- package/dist/components/Popover/Popover.js +3 -3
- package/dist/components/Popover/PopoverProvider.js +2 -2
- package/dist/components/Popover/components/NestedPopoverActivator.js +1 -1
- package/dist/components/Popover/components/PopoverActivator.js +53 -58
- package/dist/components/Popover/components/PopoverContent.js +31 -31
- package/dist/components/Popover/helpers/composeFloatingProps.js +21 -24
- package/dist/components/Popover/helpers/handlePopoverTabKey.js +2 -2
- package/dist/components/Popover/hooks/usePopover.js +1 -1
- package/dist/components/Popover/hooks/usePopoverActivatorInteractions.js +23 -26
- package/dist/components/Popover/hooks/usePopoverImperativeHandle.js +17 -17
- package/dist/components/Popover/hooks/usePopoverItem.js +13 -14
- package/dist/components/Popover/hooks/usePopoverNavigation.js +22 -22
- package/dist/components/Progress/Progress.js +2 -2
- package/dist/components/Provider/Provider.js +1 -1
- package/dist/components/Radio/Radio.js +2 -2
- package/dist/components/Radio/helpers/mapRadioGroupOptions.js +8 -8
- package/dist/components/Radio/index.js +1 -1
- package/dist/components/RadioGroup/RadioGroup.js +68 -56
- package/dist/components/RadioGroup/index.js +6 -5
- package/dist/components/Readonly/Readonly.js +5 -5
- package/dist/components/Readonly/index.js +1 -1
- package/dist/components/RichSelect/RichSelect.js +3 -3
- package/dist/components/RichSelect/SelectBody/SelectBody.js +4 -4
- package/dist/components/RichSelect/SelectCreate/SelectCreate.js +4 -4
- package/dist/components/RichSelect/SelectHeading/SelectHeading.js +4 -4
- package/dist/components/RichSelect/SelectLabel/SelectLabel.js +2 -2
- package/dist/components/RichSelect/SelectMenu/SelectMenu.js +4 -4
- package/dist/components/RichSelect/SelectMenu/SelectMenuItem.js +4 -4
- 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 +4 -4
- package/dist/components/RichSelect/index.js +1 -1
- package/dist/components/Row/Row.js +4 -4
- 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 +4 -4
- package/dist/components/Select/helpers/mapSelectOptions.js +9 -9
- package/dist/components/Select/helpers/nodesToSelectOptions.js +1 -1
- package/dist/components/Select/index.js +1 -1
- package/dist/components/Skeleton/Skeleton.js +11 -11
- package/dist/components/SkipLink/SkipLink.js +2 -2
- package/dist/components/Slideout/Slideout.js +4 -4
- package/dist/components/Slideout/components/SlideoutInner.js +3 -3
- package/dist/components/Slideout/hooks/useIDSProvidedSlideout.js +7 -7
- 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 +52 -52
- package/dist/components/TabSet/TabSet.js +24 -24
- package/dist/components/TabSet/TabSetProvider.js +30 -30
- package/dist/components/TabSet/components/TabSetItem.js +31 -32
- package/dist/components/TabSet/helpers/mapTabs.js +19 -19
- package/dist/components/Table/Table.js +3 -3
- package/dist/components/Table/TableBody/TableBody.js +91 -91
- package/dist/components/Table/TableProvider.js +2 -2
- package/dist/components/Table/components/TableEmpty.js +8 -8
- package/dist/components/Table/components/TableHeader.js +2 -2
- package/dist/components/Table/components/TableHeaderCell.js +1 -1
- package/dist/components/Table/components/TableRows.js +34 -34
- package/dist/components/Table/components/TableSortButton.js +3 -3
- package/dist/components/Table/helpers/composeIDSTableColumnDefs.js +22 -22
- package/dist/components/Table/helpers/composeIDSTableInitialSorting.js +2 -2
- package/dist/components/Table/hooks/useIDSTableColumnSort.js +6 -6
- package/dist/components/Table/hooks/useIDSTableColumnStyles.js +14 -15
- 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 +3 -3
- 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 +25 -25
- 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-DYBeYtOf.js +3464 -0
- package/dist/fuzzysort-BNka47rs.js +395 -0
- package/dist/helpers/dom/closestCrossShadow.js +16 -17
- package/dist/helpers/dom/focusableElements.js +6 -6
- package/dist/helpers/dom/getActiveElement.js +5 -6
- package/dist/helpers/formatting/formatDateTime.js +8 -7
- package/dist/helpers/label-value/composeLabelValueDescriptor.js +8 -8
- package/dist/helpers/label-value/getQueryRangeExclusive.js +1 -1
- package/dist/helpers/label-value/getValueFromLabelValues.js +5 -6
- package/dist/helpers/label-value/highlightQueryInLabel.js +4 -7
- package/dist/helpers/label-value/searchLabelValues.js +1 -1
- package/dist/helpers/responsive/getResponsiveLayoutModifiers.js +4 -4
- package/dist/helpers/transition/getTransitionDuration.js +5 -8
- package/dist/hooks/useAriaRelationship.js +19 -21
- package/dist/hooks/useBreakpoint.js +8 -11
- package/dist/hooks/useControlledState.js +40 -40
- package/dist/{index-BQfnxwrU.js → index-BaVtNOfa.js} +41 -51
- package/dist/{index-Dms7F5NM.js → index-DLnR8XTt.js} +1 -11
- package/dist/{index-2QXL0WYc.js → index-cbHCAGLB.js} +2 -7
- package/dist/{index.esm-BnSuefUA.js → index.esm-CL8gh5wr.js} +1 -5
- package/dist/main.js +159 -158
- package/dist/patterns/Loading/Loading.js +1 -1
- package/dist/patterns/Loading/LoadingSuspense.js +1 -1
- package/dist/patterns/Loading/components/ComponentLoading.js +3 -3
- package/dist/patterns/Loading/components/DefaultLoading.js +3 -3
- package/dist/patterns/Loading/components/LongLoading.js +42 -42
- package/dist/patterns/Loading/components/PageLoading.js +3 -3
- package/dist/patterns/Loading/components/StartUpLoading.js +65 -65
- package/dist/patterns/Loading/components/ValidateLoading.js +3 -3
- package/dist/patterns/Loading/index.js +1 -1
- package/dist/src/components/InputCurrency/InputCurrency.d.ts +1 -2
- package/dist/src/components/RadioGroup/RadioGroup.d.ts +5 -0
- package/dist/src/components/TabSet/TabSet.types.d.ts +1 -1
- package/dist/src/components/Table/Table.types.d.ts +1 -1
- package/dist/src/components/Table/helpers/composeIDSTableColumnDefs.d.ts +1 -1
- package/dist/src/components/Table/helpers/findColumnByKey.d.ts +1 -1
- package/dist/src/components/Toaster/hooks/useToaster.d.ts +1 -1
- package/dist/style.css +1 -1
- package/dist/useIDSButtonGroupItem-BB7Moa3N.js +29 -0
- package/package.json +67 -38
- package/dist/ComboboxHiddenInput-gTOjjF3f.js +0 -32
- package/dist/InputBase-BFK9n82f.js +0 -56
- package/dist/Loading.module-g2pe-Gfx.js +0 -13
- package/dist/LoadingSuspense-D9nGJ3gx.js +0 -5773
- package/dist/LogoFromSrc-BnImWqt6.js +0 -59
- package/dist/MenuItem.module-BxcFZeSh.js +0 -24
- package/dist/Popover.module-BKrF_xRW.js +0 -11
- package/dist/PopoverProvider-d3hhpW2k.js +0 -142
- package/dist/SliderTicks-DQN0Ka4d.js +0 -78
- package/dist/TabSet.module-FRUnHgA1.js +0 -13
- package/dist/Table.module-r-RfIeLI.js +0 -32
- package/dist/floating-ui.react-nmA48tb2.js +0 -3463
- package/dist/fuzzysort-eoXOpoo6.js +0 -395
- package/dist/useIDSButtonGroupItem-VfKx4O-O.js +0 -30
- package/dist/vite.config.d.ts +0 -2
- package/dist/vitest.config.d.ts +0 -2
- package/dist/vitest.setup.d.ts +0 -0
- /package/{LICENSE.txt → LICENSE} +0 -0
|
@@ -1,50 +1,50 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { createContext as S, useState as
|
|
3
|
-
import { idsLogger as
|
|
4
|
-
const
|
|
1
|
+
import { jsx as b } from "react/jsx-runtime";
|
|
2
|
+
import { createContext as S, useState as f, useEffect as g, useCallback as T, useMemo as y } from "react";
|
|
3
|
+
import { idsLogger as C } from "../../helpers/utility/idsLogger.js";
|
|
4
|
+
const I = S(
|
|
5
5
|
void 0
|
|
6
|
-
),
|
|
6
|
+
), A = ({
|
|
7
7
|
children: m,
|
|
8
|
-
onChange:
|
|
9
|
-
defaultSelected:
|
|
10
|
-
panel:
|
|
11
|
-
selected:
|
|
8
|
+
onChange: d,
|
|
9
|
+
defaultSelected: i,
|
|
10
|
+
panel: l,
|
|
11
|
+
selected: c
|
|
12
12
|
}) => {
|
|
13
|
-
const [
|
|
14
|
-
(e, o) => e.value ===
|
|
13
|
+
const [n, h] = f([]), [p, a] = f(i), u = c ?? p, s = n.find(
|
|
14
|
+
(e, o) => e.value === u || o === u
|
|
15
15
|
);
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
g(() => {
|
|
17
|
+
c !== void 0 && i !== void 0 && C(
|
|
18
18
|
"IressTabSet: Please use either the defaultSelected prop for uncontrolled components, or the selected prop for controlled components, rather than both. If you use both, the selected tab may become unpredictable.",
|
|
19
19
|
"warn"
|
|
20
20
|
);
|
|
21
|
-
}, [
|
|
22
|
-
const v =
|
|
23
|
-
|
|
21
|
+
}, [c, i]);
|
|
22
|
+
const v = T((e) => {
|
|
23
|
+
h((o) => {
|
|
24
24
|
if (o.some(
|
|
25
|
-
(
|
|
25
|
+
(r) => r.id === e.id || r.value === e.value
|
|
26
26
|
))
|
|
27
27
|
return o;
|
|
28
|
-
const
|
|
29
|
-
return
|
|
28
|
+
const t = o.length;
|
|
29
|
+
return a((r) => r !== void 0 ? r : e.value ?? t), [...o, { ...e, index: t, value: e.value ?? t }];
|
|
30
30
|
});
|
|
31
|
-
}, []),
|
|
31
|
+
}, []), x = y(
|
|
32
32
|
() => ({
|
|
33
|
-
items:
|
|
34
|
-
active:
|
|
35
|
-
panel:
|
|
33
|
+
items: n,
|
|
34
|
+
active: s,
|
|
35
|
+
panel: l,
|
|
36
36
|
register: v,
|
|
37
|
-
indexOf: (e, o) =>
|
|
38
|
-
isActive: (e, o) =>
|
|
37
|
+
indexOf: (e, o) => n.findIndex((t) => t.id === e || t.value === o),
|
|
38
|
+
isActive: (e, o) => s?.id === e || s?.value === o,
|
|
39
39
|
activate(e, o) {
|
|
40
|
-
|
|
40
|
+
d?.({ index: e, value: o }), a(o ?? e);
|
|
41
41
|
}
|
|
42
42
|
}),
|
|
43
|
-
[
|
|
43
|
+
[n, s, l, v, d]
|
|
44
44
|
);
|
|
45
|
-
return /* @__PURE__ */
|
|
45
|
+
return /* @__PURE__ */ b(I.Provider, { value: x, children: m });
|
|
46
46
|
};
|
|
47
47
|
export {
|
|
48
|
-
|
|
49
|
-
|
|
48
|
+
I as TabSetItemsContext,
|
|
49
|
+
A as TabSetProvider
|
|
50
50
|
};
|
|
@@ -1,45 +1,44 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { s as
|
|
3
|
-
import { a as
|
|
4
|
-
import { focusableElements as
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
children: i,
|
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { s as b } from "../../../TabSet.module-4ohNBuQS.js";
|
|
3
|
+
import { a as c } from "../../../floating-ui.react-DYBeYtOf.js";
|
|
4
|
+
import { focusableElements as u } from "../../../helpers/dom/focusableElements.js";
|
|
5
|
+
const A = (r, t, a, e) => {
|
|
6
|
+
const i = r.querySelector("[id]"), s = i?.getAttribute("id");
|
|
7
|
+
i?.removeAttribute("id"), r.removeAttribute("tabindex"), r.removeAttribute("data-active"), r.removeAttribute("aria-selected"), a.ref?.(t), t.tabIndex = e ? 0 : -1, e ? t.setAttribute("data-active", "") : t.removeAttribute("data-active"), s && t.setAttribute("id", s), t.setAttribute("aria-selected", String(e));
|
|
8
|
+
}, y = ({
|
|
9
|
+
children: r,
|
|
11
10
|
handleSelection: t,
|
|
12
|
-
index:
|
|
13
|
-
selected:
|
|
14
|
-
value:
|
|
15
|
-
...
|
|
16
|
-
}) => /* @__PURE__ */
|
|
17
|
-
|
|
11
|
+
index: a,
|
|
12
|
+
selected: e,
|
|
13
|
+
value: i,
|
|
14
|
+
...s
|
|
15
|
+
}) => /* @__PURE__ */ n(
|
|
16
|
+
c,
|
|
18
17
|
{
|
|
19
|
-
render: (
|
|
18
|
+
render: (m) => /* @__PURE__ */ n(
|
|
20
19
|
"div",
|
|
21
20
|
{
|
|
22
|
-
...
|
|
23
|
-
...
|
|
24
|
-
"aria-selected":
|
|
25
|
-
className:
|
|
26
|
-
onClick: () => t(
|
|
27
|
-
onKeyDown: (
|
|
28
|
-
ref: (
|
|
29
|
-
if (!
|
|
30
|
-
const
|
|
31
|
-
|
|
32
|
-
s,
|
|
33
|
-
c,
|
|
21
|
+
...s,
|
|
22
|
+
...m,
|
|
23
|
+
"aria-selected": e,
|
|
24
|
+
className: b.listItem,
|
|
25
|
+
onClick: () => t(a, i),
|
|
26
|
+
onKeyDown: (o) => ["Space", "Enter"].includes(o.key) && t(a, i),
|
|
27
|
+
ref: (o) => {
|
|
28
|
+
if (!o) return;
|
|
29
|
+
const d = u(o)[0];
|
|
30
|
+
d && A(
|
|
34
31
|
o,
|
|
35
|
-
|
|
32
|
+
d,
|
|
33
|
+
m,
|
|
34
|
+
e
|
|
36
35
|
);
|
|
37
36
|
},
|
|
38
|
-
children:
|
|
37
|
+
children: r
|
|
39
38
|
}
|
|
40
39
|
)
|
|
41
40
|
}
|
|
42
41
|
);
|
|
43
42
|
export {
|
|
44
|
-
|
|
43
|
+
y as TabSetItem
|
|
45
44
|
};
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { idsLogger as
|
|
3
|
-
import { LoggerLevels as
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { idsLogger as p } from "../../../helpers/utility/idsLogger.js";
|
|
3
|
+
import { LoggerLevels as l } from "../../../enums.js";
|
|
4
4
|
import { IressTab as c } from "../Tab/Tab.js";
|
|
5
5
|
import "../TabSet.js";
|
|
6
|
-
const
|
|
6
|
+
const b = (r) => (p(
|
|
7
7
|
"IressTabs: mapTabs has been deprecated and will be removed in a future version of IDS, please map and render the items array directly in your application instead.",
|
|
8
|
-
|
|
9
|
-
), r
|
|
8
|
+
l.Warn
|
|
9
|
+
), r?.length ? r.map(
|
|
10
10
|
({
|
|
11
11
|
tabName: e,
|
|
12
|
-
active:
|
|
13
|
-
tabButtonText:
|
|
14
|
-
tabButtonTestId:
|
|
15
|
-
tabButtonOnClick:
|
|
12
|
+
active: s,
|
|
13
|
+
tabButtonText: t,
|
|
14
|
+
tabButtonTestId: d,
|
|
15
|
+
tabButtonOnClick: m,
|
|
16
16
|
tabPanelContent: i,
|
|
17
|
-
tabPanelTestId:
|
|
18
|
-
},
|
|
17
|
+
tabPanelTestId: a
|
|
18
|
+
}, n) => /* @__PURE__ */ o(
|
|
19
19
|
c,
|
|
20
20
|
{
|
|
21
21
|
value: e,
|
|
22
|
-
active:
|
|
23
|
-
"data-testid":
|
|
24
|
-
onClick:
|
|
25
|
-
label:
|
|
26
|
-
children:
|
|
22
|
+
active: s,
|
|
23
|
+
"data-testid": d,
|
|
24
|
+
onClick: m,
|
|
25
|
+
label: t,
|
|
26
|
+
children: a ? /* @__PURE__ */ o("div", { "data-testid": a, children: i }) : i
|
|
27
27
|
},
|
|
28
|
-
e ||
|
|
28
|
+
e || n
|
|
29
29
|
)
|
|
30
30
|
) : null);
|
|
31
31
|
export {
|
|
32
|
-
|
|
32
|
+
b as mapTabs
|
|
33
33
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import "../../index-
|
|
2
|
+
import "../../index-cbHCAGLB.js";
|
|
3
3
|
import "./Table.types.js";
|
|
4
|
-
import "../../Table.module-
|
|
4
|
+
import "../../Table.module-BYwGboft.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import "../../helpers/utility/idsLogger.js";
|
|
7
7
|
import "../../hooks/useIdIfNeeded.js";
|
|
8
8
|
import "./components/TableEmpty.js";
|
|
9
9
|
import "../../enums.js";
|
|
10
10
|
import "../../helpers/utility/propagateTestid.js";
|
|
11
|
-
import { J as c } from "../../LoadingSuspense-
|
|
11
|
+
import { J as c } from "../../LoadingSuspense-Bwd232Nt.js";
|
|
12
12
|
import "./TableProvider.js";
|
|
13
13
|
import "./helpers/hasColumns.js";
|
|
14
14
|
import "./components/TableRows.js";
|
|
@@ -1,125 +1,125 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { propagateTestid as
|
|
3
|
-
import { c as
|
|
4
|
-
import { TableEmpty as
|
|
5
|
-
import { U as
|
|
6
|
-
import { IressTableProvider as
|
|
7
|
-
import { s as
|
|
8
|
-
import { useState as
|
|
9
|
-
import { useIdIfNeeded as
|
|
10
|
-
import { hasColumns as
|
|
11
|
-
import { useTable as
|
|
12
|
-
import { TableRows as
|
|
13
|
-
import { useAriaRelationship as
|
|
1
|
+
import { jsx as e, jsxs as C, Fragment as v } from "react/jsx-runtime";
|
|
2
|
+
import { propagateTestid as I } from "../../../helpers/utility/propagateTestid.js";
|
|
3
|
+
import { c as g } from "../../../index-cbHCAGLB.js";
|
|
4
|
+
import { TableEmpty as x } from "../components/TableEmpty.js";
|
|
5
|
+
import { U as B } from "../../../LoadingSuspense-Bwd232Nt.js";
|
|
6
|
+
import { IressTableProvider as F } from "../TableProvider.js";
|
|
7
|
+
import { s as d } from "../../../Table.module-BYwGboft.js";
|
|
8
|
+
import { useState as G, useEffect as V } from "react";
|
|
9
|
+
import { useIdIfNeeded as j } from "../../../hooks/useIdIfNeeded.js";
|
|
10
|
+
import { hasColumns as k } from "../helpers/hasColumns.js";
|
|
11
|
+
import { useTable as y } from "../hooks/useTable.js";
|
|
12
|
+
import { TableRows as A } from "../components/TableRows.js";
|
|
13
|
+
import { useAriaRelationship as E } from "../../../hooks/useAriaRelationship.js";
|
|
14
14
|
import { GlobalCSSClass as U } from "../../../enums.js";
|
|
15
15
|
const q = ({
|
|
16
|
-
caption:
|
|
17
|
-
hiddenCaption:
|
|
18
|
-
onChange:
|
|
19
|
-
open:
|
|
20
|
-
setController:
|
|
21
|
-
tableId:
|
|
16
|
+
caption: a,
|
|
17
|
+
hiddenCaption: t,
|
|
18
|
+
onChange: l,
|
|
19
|
+
open: m,
|
|
20
|
+
setController: s,
|
|
21
|
+
tableId: o
|
|
22
22
|
}) => {
|
|
23
|
-
const
|
|
24
|
-
return
|
|
23
|
+
const n = y()?.api.getVisibleFlatColumns().length;
|
|
24
|
+
return n ? /* @__PURE__ */ e("tr", { children: /* @__PURE__ */ e(
|
|
25
25
|
"th",
|
|
26
26
|
{
|
|
27
|
-
"aria-expanded":
|
|
28
|
-
colSpan:
|
|
29
|
-
className:
|
|
30
|
-
[U.SROnly]:
|
|
27
|
+
"aria-expanded": t ? void 0 : m,
|
|
28
|
+
colSpan: n,
|
|
29
|
+
className: g(d.rowGroupHeader, {
|
|
30
|
+
[U.SROnly]: t
|
|
31
31
|
}),
|
|
32
|
-
id: `${
|
|
33
|
-
onClick:
|
|
32
|
+
id: `${o}--caption`,
|
|
33
|
+
onClick: l,
|
|
34
34
|
scope: "rowgroup",
|
|
35
|
-
ref:
|
|
36
|
-
children: /* @__PURE__ */
|
|
35
|
+
ref: s,
|
|
36
|
+
children: /* @__PURE__ */ e("button", { className: d.activator, type: "button", children: a })
|
|
37
37
|
}
|
|
38
38
|
) }) : null;
|
|
39
39
|
}, z = ({
|
|
40
|
-
children:
|
|
41
|
-
setControlViaRef:
|
|
42
|
-
tableId:
|
|
40
|
+
children: a,
|
|
41
|
+
setControlViaRef: t,
|
|
42
|
+
tableId: l
|
|
43
43
|
}) => {
|
|
44
|
-
const
|
|
45
|
-
if (!
|
|
46
|
-
const
|
|
47
|
-
return /* @__PURE__ */
|
|
48
|
-
},
|
|
49
|
-
caption:
|
|
50
|
-
children:
|
|
51
|
-
columns:
|
|
52
|
-
className:
|
|
53
|
-
"data-testid":
|
|
54
|
-
empty:
|
|
55
|
-
hiddenCaption:
|
|
56
|
-
hiddenHeader:
|
|
57
|
-
onOpened:
|
|
58
|
-
onClosed:
|
|
59
|
-
open:
|
|
60
|
-
rowProps:
|
|
61
|
-
rows:
|
|
62
|
-
scope:
|
|
63
|
-
...
|
|
44
|
+
const s = y()?.api.getVisibleFlatColumns().length;
|
|
45
|
+
if (!a) return null;
|
|
46
|
+
const o = `${l}--children`;
|
|
47
|
+
return /* @__PURE__ */ e("tr", { id: o, ref: (i) => t(o)(i), children: /* @__PURE__ */ e("td", { colSpan: s, children: a }) });
|
|
48
|
+
}, oe = ({
|
|
49
|
+
caption: a,
|
|
50
|
+
children: t,
|
|
51
|
+
columns: l,
|
|
52
|
+
className: m,
|
|
53
|
+
"data-testid": s,
|
|
54
|
+
empty: o,
|
|
55
|
+
hiddenCaption: i,
|
|
56
|
+
hiddenHeader: n,
|
|
57
|
+
onOpened: T,
|
|
58
|
+
onClosed: w,
|
|
59
|
+
open: p = !1,
|
|
60
|
+
rowProps: N,
|
|
61
|
+
rows: f = [],
|
|
62
|
+
scope: S,
|
|
63
|
+
...u
|
|
64
64
|
}) => {
|
|
65
|
-
const [
|
|
66
|
-
if (
|
|
67
|
-
|
|
68
|
-
}, [
|
|
65
|
+
const [c, h] = G(p), { setController: H, setControlViaRef: b } = E("aria-controls"), r = j({ id: u.id }), O = t ?? (o && k(l)) ?? !!f?.length;
|
|
66
|
+
if (V(() => {
|
|
67
|
+
h(p);
|
|
68
|
+
}, [p]), !O)
|
|
69
69
|
return null;
|
|
70
|
-
const
|
|
71
|
-
|
|
72
|
-
},
|
|
73
|
-
return /* @__PURE__ */
|
|
70
|
+
const R = () => {
|
|
71
|
+
h(!c), c ? w?.() : T?.();
|
|
72
|
+
}, $ = c || i;
|
|
73
|
+
return /* @__PURE__ */ e(F, { columns: l, rows: f, children: /* @__PURE__ */ C(
|
|
74
74
|
"tbody",
|
|
75
75
|
{
|
|
76
|
-
"aria-labelledby": `${
|
|
77
|
-
...
|
|
78
|
-
className:
|
|
79
|
-
[
|
|
76
|
+
"aria-labelledby": `${r}--caption`,
|
|
77
|
+
...u,
|
|
78
|
+
className: g(m, {
|
|
79
|
+
[d.hiddenHeader]: n
|
|
80
80
|
}),
|
|
81
81
|
children: [
|
|
82
|
-
/* @__PURE__ */
|
|
82
|
+
/* @__PURE__ */ e(
|
|
83
83
|
q,
|
|
84
84
|
{
|
|
85
|
-
setController:
|
|
86
|
-
caption:
|
|
87
|
-
hiddenCaption:
|
|
88
|
-
onChange:
|
|
89
|
-
open:
|
|
90
|
-
tableId:
|
|
85
|
+
setController: H,
|
|
86
|
+
caption: a,
|
|
87
|
+
hiddenCaption: i,
|
|
88
|
+
onChange: R,
|
|
89
|
+
open: c,
|
|
90
|
+
tableId: r
|
|
91
91
|
}
|
|
92
92
|
),
|
|
93
|
-
|
|
94
|
-
!
|
|
95
|
-
|
|
93
|
+
$ && /* @__PURE__ */ C(v, { children: [
|
|
94
|
+
!n && /* @__PURE__ */ e(
|
|
95
|
+
B,
|
|
96
96
|
{
|
|
97
|
-
additionalHeaders: `${
|
|
98
|
-
className:
|
|
99
|
-
setControlViaRef:
|
|
100
|
-
tableId:
|
|
101
|
-
testId:
|
|
97
|
+
additionalHeaders: `${r}--caption`,
|
|
98
|
+
className: d.rowGroupColumnHeaders,
|
|
99
|
+
setControlViaRef: b,
|
|
100
|
+
tableId: r,
|
|
101
|
+
testId: I(s, "thead")
|
|
102
102
|
}
|
|
103
103
|
),
|
|
104
|
-
/* @__PURE__ */
|
|
105
|
-
|
|
104
|
+
/* @__PURE__ */ e(
|
|
105
|
+
A,
|
|
106
106
|
{
|
|
107
|
-
additionalHeaders: `${
|
|
108
|
-
tableId:
|
|
109
|
-
rowProps:
|
|
110
|
-
setControlViaRef:
|
|
111
|
-
scope:
|
|
112
|
-
hiddenHeader:
|
|
113
|
-
testId:
|
|
107
|
+
additionalHeaders: `${r}--caption`,
|
|
108
|
+
tableId: r,
|
|
109
|
+
rowProps: N,
|
|
110
|
+
setControlViaRef: b,
|
|
111
|
+
scope: S,
|
|
112
|
+
hiddenHeader: n,
|
|
113
|
+
testId: I(s, "tbody")
|
|
114
114
|
}
|
|
115
115
|
),
|
|
116
|
-
/* @__PURE__ */
|
|
117
|
-
/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ e(x, { children: o }),
|
|
117
|
+
/* @__PURE__ */ e(z, { setControlViaRef: b, tableId: r, children: t })
|
|
118
118
|
] })
|
|
119
119
|
]
|
|
120
120
|
}
|
|
121
121
|
) });
|
|
122
122
|
};
|
|
123
123
|
export {
|
|
124
|
-
|
|
124
|
+
oe as IressTableBody
|
|
125
125
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx as d } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as f, useMemo as r, useImperativeHandle as p } from "react";
|
|
3
3
|
import { composeIDSTableColumnDefs as g } from "./helpers/composeIDSTableColumnDefs.js";
|
|
4
|
-
import { u as c } from "../../index-
|
|
4
|
+
import { u as c } from "../../index-DLnR8XTt.js";
|
|
5
5
|
import { composeIDSTableInitialSorting as u } from "./helpers/composeIDSTableInitialSorting.js";
|
|
6
6
|
import { getTableContext as S } from "./TableContext.js";
|
|
7
7
|
import { findColumnByKey as b } from "./helpers/findColumnByKey.js";
|
|
8
|
-
import { g as C, a as R } from "../../index-
|
|
8
|
+
import { g as C, a as R } from "../../index-BaVtNOfa.js";
|
|
9
9
|
const T = ({ children: i, columns: e, rows: o }, a) => {
|
|
10
10
|
const m = r(() => g(o, e), [e, o]), t = c({
|
|
11
11
|
columns: m,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { s } from "../../../Table.module-
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { s } from "../../../Table.module-BYwGboft.js";
|
|
3
3
|
import { useTable as l } from "../hooks/useTable.js";
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
if (o
|
|
7
|
-
const e =
|
|
8
|
-
return e ? /* @__PURE__ */
|
|
4
|
+
const p = ({ children: t }) => {
|
|
5
|
+
const o = l();
|
|
6
|
+
if (o?.api.getSortedRowModel().rows?.length || !t) return null;
|
|
7
|
+
const e = o?.api.getVisibleFlatColumns().length;
|
|
8
|
+
return e ? /* @__PURE__ */ r("tr", { children: /* @__PURE__ */ r("td", { className: s.empty, colSpan: e, children: t }) }) : null;
|
|
9
9
|
};
|
|
10
10
|
export {
|
|
11
|
-
|
|
11
|
+
p as TableEmpty
|
|
12
12
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "../../../helpers/utility/propagateTestid.js";
|
|
3
|
-
import "../../../index-
|
|
4
|
-
import { U as i } from "../../../LoadingSuspense-
|
|
3
|
+
import "../../../index-DLnR8XTt.js";
|
|
4
|
+
import { U as i } from "../../../LoadingSuspense-Bwd232Nt.js";
|
|
5
5
|
import "../hooks/useTable.js";
|
|
6
6
|
export {
|
|
7
7
|
i as TableHeader
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "../hooks/useIDSTableColumnStyles.js";
|
|
3
3
|
import "../hooks/useIDSTableColumnSort.js";
|
|
4
|
-
import { ad as a } from "../../../LoadingSuspense-
|
|
4
|
+
import { ad as a } from "../../../LoadingSuspense-Bwd232Nt.js";
|
|
5
5
|
import "../hooks/useTable.js";
|
|
6
6
|
export {
|
|
7
7
|
a as TableHeaderCell
|
|
@@ -1,49 +1,49 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { f as
|
|
3
|
-
import { TableBodyCell as
|
|
4
|
-
import { useTable as
|
|
5
|
-
import { propagateTestid as
|
|
6
|
-
const
|
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { f as c } from "../../../index-DLnR8XTt.js";
|
|
3
|
+
import { TableBodyCell as f } from "./TableBodyCell.js";
|
|
4
|
+
import { useTable as u } from "../hooks/useTable.js";
|
|
5
|
+
import { propagateTestid as b } from "../../../helpers/utility/propagateTestid.js";
|
|
6
|
+
const h = ({
|
|
7
7
|
additionalHeaders: a,
|
|
8
|
-
hiddenHeader:
|
|
9
|
-
rowProps:
|
|
10
|
-
setControlViaRef:
|
|
11
|
-
scope:
|
|
12
|
-
tableId:
|
|
13
|
-
testId:
|
|
8
|
+
hiddenHeader: m,
|
|
9
|
+
rowProps: o = {},
|
|
10
|
+
setControlViaRef: s,
|
|
11
|
+
scope: p = "row",
|
|
12
|
+
tableId: i,
|
|
13
|
+
testId: l
|
|
14
14
|
}) => {
|
|
15
|
-
const
|
|
16
|
-
return
|
|
15
|
+
const d = u()?.api.getSortedRowModel().rows;
|
|
16
|
+
return d?.length ? d.map((t) => /* @__PURE__ */ n(
|
|
17
17
|
"tr",
|
|
18
18
|
{
|
|
19
|
-
"data-testid":
|
|
20
|
-
id: `${
|
|
21
|
-
ref: (
|
|
22
|
-
const
|
|
23
|
-
|
|
19
|
+
"data-testid": l?.replace("tbody", "row"),
|
|
20
|
+
id: `${i}--rows--${t.id}`,
|
|
21
|
+
ref: (e) => {
|
|
22
|
+
const r = `${i}--rows--${t.id}`;
|
|
23
|
+
s?.(r)(e);
|
|
24
24
|
},
|
|
25
|
-
...typeof
|
|
26
|
-
children:
|
|
27
|
-
|
|
25
|
+
...typeof o == "function" ? o(t) : o,
|
|
26
|
+
children: t.getVisibleCells().map((e, r) => /* @__PURE__ */ n(
|
|
27
|
+
f,
|
|
28
28
|
{
|
|
29
29
|
additionalHeaders: a,
|
|
30
|
-
"data-testid":
|
|
31
|
-
|
|
32
|
-
`row_${
|
|
30
|
+
"data-testid": b(
|
|
31
|
+
l?.replace("tbody", "cell"),
|
|
32
|
+
`row_${t.id}__col_${e.column.id}`
|
|
33
33
|
),
|
|
34
|
-
cellApi:
|
|
35
|
-
hiddenHeader:
|
|
36
|
-
index:
|
|
37
|
-
scope:
|
|
38
|
-
tableId:
|
|
39
|
-
children:
|
|
34
|
+
cellApi: e,
|
|
35
|
+
hiddenHeader: m,
|
|
36
|
+
index: r,
|
|
37
|
+
scope: p,
|
|
38
|
+
tableId: i,
|
|
39
|
+
children: c(e.column.columnDef.cell, e.getContext())
|
|
40
40
|
},
|
|
41
|
-
|
|
41
|
+
e.id
|
|
42
42
|
))
|
|
43
43
|
},
|
|
44
|
-
|
|
44
|
+
t.id
|
|
45
45
|
)) : null;
|
|
46
46
|
};
|
|
47
47
|
export {
|
|
48
|
-
|
|
48
|
+
h as TableRows
|
|
49
49
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import { ac as a } from "../../../LoadingSuspense-
|
|
3
|
-
import "../../../Table.module-
|
|
4
|
-
import "../../../index-
|
|
2
|
+
import { ac as a } from "../../../LoadingSuspense-Bwd232Nt.js";
|
|
3
|
+
import "../../../Table.module-BYwGboft.js";
|
|
4
|
+
import "../../../index-cbHCAGLB.js";
|
|
5
5
|
export {
|
|
6
6
|
a as TableSortButton
|
|
7
7
|
};
|