@hortiview/shared-components 2.17.0 → 2.18.1
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 +20 -0
- package/dist/{AlertBanner-aW6joVUm.js → AlertBanner-BFzaGOer.js} +3 -3
- package/dist/{GenericCard-IWX-Bmb_.js → GenericCard-grpa3KJR.js} +3 -3
- package/dist/{ListAreaService-Fsm3-gDM.js → ListAreaService-DfxJ7jFs.js} +5 -5
- package/dist/{_Map-D8db_GOu.js → _Map-BYxTn6ob.js} +1 -1
- package/dist/{_commonjsHelpers-B4e78b8K.js → _commonjsHelpers-ByX85dGu.js} +18 -13
- package/dist/animationframe-CqXArbwZ.js +32 -0
- package/dist/component-By6nyiBU.js +70 -0
- package/dist/{component-DEJuY56h.js → component-DYpB_4EP.js} +1 -111
- package/dist/components/AlertBanner/AlertBanner.js +4 -4
- package/dist/components/AlertBanner/LinkBanner.js +3 -3
- package/dist/components/AllowedButton/AllowedButton.js +1 -1
- package/dist/components/AllowedIconButton/AllowedIconButton.js +1 -1
- package/dist/components/BaseView/BaseView.js +14 -14
- package/dist/components/BasicHeading/BasicHeading.js +5 -5
- package/dist/components/BlockView/BlockView.js +2 -2
- package/dist/components/ButtonCard/ButtonCard.js +6 -6
- package/dist/components/ChipCard/ChipCard.js +13 -255
- package/dist/components/ConfirmationModal/ConfirmationModal.js +8 -8
- package/dist/components/ContextMenu/ContextMenu.js +12 -12
- package/dist/components/DeleteModal/DeleteModal.js +25 -25
- package/dist/components/DetailContentWrapper/DetailContentWrapper.js +1 -1
- package/dist/components/Disclaimer/Disclaimer.js +3 -3
- package/dist/components/EmptyView/EmptyView.js +3 -3
- package/dist/components/Filter/Filter.js +15 -15
- package/dist/components/FormComponents/FormCheckBox/FormCheckBox.js +1 -1
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.js +7 -22
- package/dist/components/FormComponents/FormNumber/CustomTextField.js +3 -3
- package/dist/components/FormComponents/FormNumber/FormNumber.js +1 -1
- package/dist/components/FormComponents/FormRadio/FormRadio.js +1 -1
- package/dist/components/FormComponents/FormSelect/FormSelect.d.ts +2 -2
- package/dist/components/FormComponents/FormSelect/FormSelect.js +73 -72
- package/dist/components/FormComponents/FormSelect/SelectTooltipText.js +2 -2
- package/dist/components/FormComponents/FormSlider/FormSlider.js +10 -98
- package/dist/components/FormComponents/FormText/FormText.js +2 -2
- package/dist/components/FormComponents/FormToggle/FormToggle.js +4 -4
- package/dist/components/FormattedNumberDisplay/FormattedNumberDisplay.js +1 -1
- package/dist/components/GenericTable/GenericTable.js +36 -172
- package/dist/components/GenericTable/Mobile/GenericCard.js +4 -4
- package/dist/components/GenericTable/Mobile/GenericCardList.js +4 -4
- package/dist/components/HashTabView/HashTabView.js +10 -428
- package/dist/components/HeaderFilter/HeaderFilter.js +1 -1
- package/dist/components/Iconify/Iconify.js +2 -2
- package/dist/components/InfoCard/InfoCard.js +4 -4
- package/dist/components/InfoGroup/InfoGroup.js +4 -4
- package/dist/components/ListArea/ListArea.js +6 -6
- package/dist/components/ListArea/ListAreaService.js +6 -6
- package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.js +13 -5
- package/dist/components/LoadingSpinner/Default/LoadingSpinner.js +8 -74
- package/dist/components/Modal/Modal.js +12 -122
- package/dist/components/ModulePadding/ModulePadding.js +11 -11
- package/dist/components/OfflineView/OfflineView.js +45 -7
- package/dist/components/OnboardingBanner/OnboardingBanner.js +8 -8
- package/dist/components/OverflowTooltip/OverflowTooltip.js +2 -2
- package/dist/components/SearchBar/SearchBar.js +2 -2
- package/dist/components/Select/Select.js +2 -2
- package/dist/components/Stepper/Stepper.js +1 -1
- package/dist/components/Stepper/components/StepperButton.js +1 -1
- package/dist/components/Stepper/components/StepperHeader.js +3 -3
- package/dist/components/Stepper/components/StepperItem.js +2 -2
- package/dist/{correct-is-regexp-logic-Y0ToWEjF.js → correct-is-regexp-logic-BJ-OWRrn.js} +1 -1
- package/dist/{defineProperty-BTsGZ3c1.js → defineProperty-B7N9EBBI.js} +3 -3
- package/dist/{es.string.iterator-UszlTFwY.js → es.string.iterator-DBx2A42F.js} +2 -2
- package/dist/{find-CHg-_ooq.js → find-eU9ab_u7.js} +4 -4
- package/dist/{get-DxjPG00Z.js → get-BLvvbtML.js} +3 -3
- package/dist/get-CBFiuc3f.js +7 -0
- package/dist/hooks/useBreakpoints.js +37 -3
- package/dist/hooks/useHelperText.js +1 -1
- package/dist/{identity-BVIVr9qu.js → identity-B0bbReND.js} +4 -4
- package/dist/{index-BcGujPyk.js → index-Df2FYN-K.js} +5 -26
- package/dist/{index.es-B8p8KCdj.js → index.es-B19PQgzU.js} +4 -4
- package/dist/{index.es-BYcQTTL8.js → index.es-B9BUXRQn.js} +9 -339
- package/dist/{index.es-BPv5dCFQ.js → index.es-BOG3_7IM.js} +12 -12
- package/dist/{index.es-DGoBge9W.js → index.es-BOvO8moE.js} +4 -4
- package/dist/{index.es-BoUnovl_.js → index.es-BcnmoCEg.js} +8 -74
- package/dist/{index.es-C32E1Lcb.js → index.es-BwafUoK3.js} +82 -147
- package/dist/{index.es-B1h6DPYp.js → index.es-C27R5Xae.js} +2 -2
- package/dist/{index.es-nwjKmW7-.js → index.es-C2IOpX7R.js} +34 -111
- package/dist/{index.es-Da7ok-B-.js → index.es-C6I3L4U4.js} +2 -2
- package/dist/{index.es-BHvm4m-B.js → index.es-Cg57snrN.js} +19 -261
- package/dist/{index.es-DUTChZks.js → index.es-Ci3O23C_.js} +6 -72
- package/dist/{index.es-t87yNd9Y.js → index.es-CkB4776y.js} +6 -72
- package/dist/{index.es-CeQB6igi.js → index.es-Cr1PSTyq.js} +3 -3
- package/dist/{index.es--C-VLspF.js → index.es-D1iB_QlE.js} +8 -140
- package/dist/{index.es-Dgxrk6xW.js → index.es-DEBGoIKX.js} +2 -2
- package/dist/{index.es-CWyjqoEE.js → index.es-DHnCVuQ8.js} +7 -73
- package/dist/{index.es-Bo-d_yTV.js → index.es-DHoIQ8lu.js} +2 -2
- package/dist/{index.es-SjZ_-d7U.js → index.es-DUrjyxNI.js} +5 -5
- package/dist/{index.es-Cfv794DG.js → index.es-DdeCB7LW.js} +1 -1
- package/dist/{index.es-BanVdXEd.js → index.es-DgncYOqO.js} +2 -2
- package/dist/{index.es-DOnQ26kT.js → index.es-DhlgTSuU.js} +3 -3
- package/dist/{index.es-oxil0uFe.js → index.es-Z0aF-7Cn.js} +3 -6
- package/dist/{index.es-DmRhbgqK.js → index.es-l_3PNohs.js} +2 -68
- package/dist/{isArray-B457bpaW.js → isArray-Ce1Q96lU.js} +1 -1
- package/dist/isArray-olhCpv2e.js +7 -0
- package/dist/{isEmpty-BnfHn4bl.js → isEmpty-l2xQKl4x.js} +3 -3
- package/dist/{isString-DVA49FEo.js → isString-BNdV0Jpg.js} +3 -3
- package/dist/{isTypedArray-DziahYkI.js → isTypedArray-D39qzPYE.js} +2 -2
- package/dist/{keyboard-DiKJoabs.js → keyboard-DbG3oyPU.js} +3 -25
- package/dist/main.js +15 -15
- package/dist/{map-BprzXv4m.js → map-ZSVweMI1.js} +5 -5
- package/dist/{omit-CYY_mIYv.js → omit-BWQrFyQ-.js} +7 -7
- package/dist/{orderBy-DLBJlgdL.js → orderBy-Ce85KqD6.js} +7 -7
- package/dist/{parse-int-D-3oah_F.js → parse-int-CGpIXMGa.js} +2 -2
- package/dist/{react-number-format.es-DzkMiF8j.js → react-number-format.es-pczkQ4lQ.js} +0 -1
- package/dist/{react-tooltip.min-CVsI--2Y.js → react-tooltip.min-Dkz5ltCC.js} +1 -12
- package/dist/{react.esm-Bm0cAgpZ.js → react.esm-DF7i80eN.js} +2471 -2582
- package/dist/services/UtilService.js +9 -9
- package/dist/{slicedToArray-ByMQIs5x.js → slicedToArray-DC6VAZtW.js} +4 -4
- package/dist/test-utils.js +1 -1
- package/dist/{toString-B7FIT8FE.js → toString-D5bEU-DN.js} +1 -1
- package/dist/{uniqueId-BNVTeImh.js → uniqueId-CJo-XRQb.js} +2 -2
- package/dist/{util-DA21pZXj.js → util-CBo-ipCE.js} +0 -22
- package/package.json +2 -2
- package/dist/BigLoadingSpinner-DGj9_Z5J.js +0 -16
- package/dist/OfflineView-CIwV08EQ.js +0 -48
- package/dist/animationframe-BVKDmEXe.js +0 -54
- package/dist/component-Bz_dtX1r.js +0 -114
- package/dist/components/AlertBanner/AlertBanner.test.d.ts +0 -1
- package/dist/components/AlertBanner/AlertBanner.test.js +0 -34
- package/dist/components/AlertBanner/LinkBanner.test.d.ts +0 -1
- package/dist/components/AlertBanner/LinkBanner.test.js +0 -17
- package/dist/components/Allowed/Allowed.test.d.ts +0 -1
- package/dist/components/Allowed/Allowed.test.js +0 -49
- package/dist/components/AllowedButton/AllowedButton.test.d.ts +0 -1
- package/dist/components/AllowedButton/AllowedButton.test.js +0 -126
- package/dist/components/AllowedIconButton/AllowedIconButton.test.d.ts +0 -1
- package/dist/components/AllowedIconButton/AllowedIconButton.test.js +0 -121
- package/dist/components/BaseView/BaseView.test.d.ts +0 -1
- package/dist/components/BaseView/BaseView.test.js +0 -180
- package/dist/components/BasicHeading/BasicHeading.test.d.ts +0 -1
- package/dist/components/BasicHeading/BasicHeading.test.js +0 -36
- package/dist/components/BlockView/BlockView.test.d.ts +0 -1
- package/dist/components/BlockView/BlockView.test.js +0 -47
- package/dist/components/ButtonCard/ButtonCard.test.d.ts +0 -1
- package/dist/components/ButtonCard/ButtonCard.test.js +0 -92
- package/dist/components/ChipCard/ChipCard.test.d.ts +0 -1
- package/dist/components/ChipCard/ChipCard.test.js +0 -25
- package/dist/components/ConfirmationModal/ConfirmationModal.test.d.ts +0 -1
- package/dist/components/ConfirmationModal/ConfirmationModal.test.js +0 -221
- package/dist/components/ContextMenu/ContextMenu.test.d.ts +0 -1
- package/dist/components/ContextMenu/ContextMenu.test.js +0 -96
- package/dist/components/DeleteModal/DeleteModal.test.d.ts +0 -1
- package/dist/components/DeleteModal/DeleteModal.test.js +0 -132
- package/dist/components/Disclaimer/Disclaimer.test.d.ts +0 -1
- package/dist/components/Disclaimer/Disclaimer.test.js +0 -13
- package/dist/components/EmptyView/EmptyView.test.d.ts +0 -1
- package/dist/components/EmptyView/EmptyView.test.js +0 -50
- package/dist/components/Filter/Filter.test.d.ts +0 -1
- package/dist/components/Filter/Filter.test.js +0 -166
- package/dist/components/FormComponents/FormCheckBox/FormCheckBox.test.d.ts +0 -1
- package/dist/components/FormComponents/FormCheckBox/FormCheckBox.test.js +0 -56
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.test.d.ts +0 -1
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.test.js +0 -56
- package/dist/components/FormComponents/FormNumber/FormNumber.test.d.ts +0 -1
- package/dist/components/FormComponents/FormNumber/FormNumber.test.js +0 -51
- package/dist/components/FormComponents/FormRadio/FormRadio.test.d.ts +0 -1
- package/dist/components/FormComponents/FormRadio/FormRadio.test.js +0 -73
- package/dist/components/FormComponents/FormSelect/FormSelect.test.d.ts +0 -1
- package/dist/components/FormComponents/FormSelect/FormSelect.test.js +0 -154
- package/dist/components/FormComponents/FormSlider/FormSlider.test.d.ts +0 -1
- package/dist/components/FormComponents/FormSlider/FormSlider.test.js +0 -49
- package/dist/components/FormComponents/FormText/FormText.test.d.ts +0 -1
- package/dist/components/FormComponents/FormText/FormText.test.js +0 -113
- package/dist/components/FormComponents/FormToggle/FormToggle.test.d.ts +0 -1
- package/dist/components/FormComponents/FormToggle/FormToggle.test.js +0 -54
- package/dist/components/GenericTable/GenericTable.test.d.ts +0 -1
- package/dist/components/GenericTable/GenericTable.test.js +0 -115
- package/dist/components/GenericTable/Mobile/GenericCard.test.d.ts +0 -1
- package/dist/components/GenericTable/Mobile/GenericCard.test.js +0 -76
- package/dist/components/GenericTable/Mobile/GenericCardList.test.d.ts +0 -1
- package/dist/components/GenericTable/Mobile/GenericCardList.test.js +0 -75
- package/dist/components/HashTabView/HashTabView.test.d.ts +0 -1
- package/dist/components/HashTabView/HashTabView.test.js +0 -31
- package/dist/components/HeaderFilter/HeaderFilter.test.d.ts +0 -1
- package/dist/components/HeaderFilter/HeaderFilter.test.js +0 -46
- package/dist/components/Iconify/Iconify.test.d.ts +0 -1
- package/dist/components/Iconify/Iconify.test.js +0 -28
- package/dist/components/InfoCard/InfoCard.test.d.ts +0 -1
- package/dist/components/InfoCard/InfoCard.test.js +0 -48
- package/dist/components/InfoGroup/InfoGroup.test.d.ts +0 -1
- package/dist/components/InfoGroup/InfoGroup.test.js +0 -40
- package/dist/components/ListArea/ListArea.test.d.ts +0 -1
- package/dist/components/ListArea/ListArea.test.js +0 -110
- package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.d.ts +0 -1
- package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.js +0 -15
- package/dist/components/LoadingSpinner/Default/LoadingSpinner.test.d.ts +0 -1
- package/dist/components/LoadingSpinner/Default/LoadingSpinner.test.js +0 -20
- package/dist/components/ModulePadding/ModulePadding.test.d.ts +0 -1
- package/dist/components/ModulePadding/ModulePadding.test.js +0 -22
- package/dist/components/OfflineView/OfflineView.test.d.ts +0 -1
- package/dist/components/OfflineView/OfflineView.test.js +0 -24
- package/dist/components/OnboardingBanner/OnboardingBanner.test.d.ts +0 -1
- package/dist/components/OnboardingBanner/OnboardingBanner.test.js +0 -72
- package/dist/components/OverflowTooltip/OverflowTooltip.test.d.ts +0 -1
- package/dist/components/OverflowTooltip/OverflowTooltip.test.js +0 -37
- package/dist/components/PermissionChecks/PermissionService.test.d.ts +0 -1
- package/dist/components/PermissionChecks/PermissionService.test.js +0 -91
- package/dist/components/SafeForm/SafeForm.test.d.ts +0 -1
- package/dist/components/SafeForm/SafeForm.test.js +0 -91
- package/dist/components/Scrollbar/scrollbar.test.d.ts +0 -1
- package/dist/components/Scrollbar/scrollbar.test.js +0 -15
- package/dist/components/SearchBar/SearchBar.test.d.ts +0 -1
- package/dist/components/SearchBar/SearchBar.test.js +0 -23
- package/dist/components/Select/Select.test.d.ts +0 -1
- package/dist/components/Select/Select.test.js +0 -28
- package/dist/components/Stepper/Stepper.test.d.ts +0 -1
- package/dist/components/Stepper/Stepper.test.js +0 -342
- package/dist/components/VerticalDivider/VerticalDivider.test.d.ts +0 -1
- package/dist/components/VerticalDivider/VerticalDivider.test.js +0 -15
- package/dist/get-D8IXqiys.js +0 -7
- package/dist/hooks/useBreakpoints.test.d.ts +0 -1
- package/dist/hooks/useBreakpoints.test.js +0 -11
- package/dist/index-BLPBqbdx.js +0 -11025
- package/dist/isArray-BjSPDQ4v.js +0 -7
- package/dist/magic-string.es-uPKorP4O.js +0 -663
- package/dist/services/services.test.d.ts +0 -1
- package/dist/services/services.test.js +0 -106
- package/dist/useBreakpoints-MzTZ0tCT.js +0 -45
- package/dist/vi.bdSIJ99Y-B308Q-4w.js +0 -11963
|
@@ -1,221 +0,0 @@
|
|
|
1
|
-
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { a as i, s as n } from "../../react.esm-Bm0cAgpZ.js";
|
|
3
|
-
import { ConfirmationModal as l } from "./ConfirmationModal.js";
|
|
4
|
-
import { d as m, t as a, a as e, g as t } from "../../vi.bdSIJ99Y-B308Q-4w.js";
|
|
5
|
-
m("ConfirmationModal", () => {
|
|
6
|
-
a("renders modal title, label, list content, icon, and buttons", () => {
|
|
7
|
-
i(
|
|
8
|
-
/* @__PURE__ */ o(
|
|
9
|
-
l,
|
|
10
|
-
{
|
|
11
|
-
modalTitle: "Confirm Action",
|
|
12
|
-
confirmButtonLabel: "Confirm",
|
|
13
|
-
cancelButtonLabel: "Cancel",
|
|
14
|
-
label: "Are you sure?",
|
|
15
|
-
content: ["First item", "Second item"],
|
|
16
|
-
icon: "block",
|
|
17
|
-
isOpen: !0,
|
|
18
|
-
onConfirm: e.fn(),
|
|
19
|
-
onCancel: e.fn(),
|
|
20
|
-
isConfirmationDisabled: !1
|
|
21
|
-
}
|
|
22
|
-
)
|
|
23
|
-
), t(n.getByText("Confirm Action")).toBeInTheDocument(), t(n.getByText("Are you sure?")).toBeInTheDocument(), t(n.getByText("First item")).toBeInTheDocument(), t(n.getByText("Second item")).toBeInTheDocument(), t(n.getByTestId("block")).toBeInTheDocument(), t(n.getByText("Confirm")).toBeInTheDocument(), t(n.getByText("Cancel")).toBeInTheDocument();
|
|
24
|
-
}), a("renders string content", () => {
|
|
25
|
-
i(
|
|
26
|
-
/* @__PURE__ */ o(
|
|
27
|
-
l,
|
|
28
|
-
{
|
|
29
|
-
modalTitle: "Confirm Action",
|
|
30
|
-
confirmButtonLabel: "Confirm",
|
|
31
|
-
cancelButtonLabel: "Cancel",
|
|
32
|
-
label: "Are you sure?",
|
|
33
|
-
content: ["This action cannot be undone."],
|
|
34
|
-
isOpen: !0,
|
|
35
|
-
onConfirm: e.fn(),
|
|
36
|
-
onCancel: e.fn(),
|
|
37
|
-
isConfirmationDisabled: !1
|
|
38
|
-
}
|
|
39
|
-
)
|
|
40
|
-
), t(n.getByText("This action cannot be undone.")).toBeInTheDocument();
|
|
41
|
-
}), a("calls onConfirm when confirm button is clicked", () => {
|
|
42
|
-
const r = e.fn();
|
|
43
|
-
i(
|
|
44
|
-
/* @__PURE__ */ o(
|
|
45
|
-
l,
|
|
46
|
-
{
|
|
47
|
-
modalTitle: "Confirm Action",
|
|
48
|
-
confirmButtonLabel: "Confirm",
|
|
49
|
-
cancelButtonLabel: "Cancel",
|
|
50
|
-
label: "Are you sure?",
|
|
51
|
-
isOpen: !0,
|
|
52
|
-
onConfirm: r,
|
|
53
|
-
onCancel: e.fn(),
|
|
54
|
-
isConfirmationDisabled: !1
|
|
55
|
-
}
|
|
56
|
-
)
|
|
57
|
-
), n.getByText("Confirm").click(), t(r).toHaveBeenCalled();
|
|
58
|
-
}), a("calls onCancel when cancel button is clicked", () => {
|
|
59
|
-
const r = e.fn();
|
|
60
|
-
i(
|
|
61
|
-
/* @__PURE__ */ o(
|
|
62
|
-
l,
|
|
63
|
-
{
|
|
64
|
-
modalTitle: "Confirm Action",
|
|
65
|
-
confirmButtonLabel: "Confirm",
|
|
66
|
-
cancelButtonLabel: "Cancel",
|
|
67
|
-
label: "Are you sure?",
|
|
68
|
-
isOpen: !0,
|
|
69
|
-
onConfirm: e.fn(),
|
|
70
|
-
onCancel: r
|
|
71
|
-
}
|
|
72
|
-
)
|
|
73
|
-
), n.getByText("Cancel").click(), t(r).toHaveBeenCalled();
|
|
74
|
-
}), a("disables confirm button when confirmation is disabled", () => {
|
|
75
|
-
i(
|
|
76
|
-
/* @__PURE__ */ o(
|
|
77
|
-
l,
|
|
78
|
-
{
|
|
79
|
-
modalTitle: "Confirm Action",
|
|
80
|
-
confirmButtonLabel: "Confirm",
|
|
81
|
-
cancelButtonLabel: "Cancel",
|
|
82
|
-
label: "Are you sure?",
|
|
83
|
-
isOpen: !0,
|
|
84
|
-
onConfirm: e.fn(),
|
|
85
|
-
onCancel: e.fn(),
|
|
86
|
-
isConfirmationDisabled: !0
|
|
87
|
-
}
|
|
88
|
-
)
|
|
89
|
-
), t(n.getByTestId("confirm-button")).toBeDisabled();
|
|
90
|
-
}), a("renders correctly when content is null or undefined", () => {
|
|
91
|
-
const { rerender: r } = i(
|
|
92
|
-
/* @__PURE__ */ o(
|
|
93
|
-
l,
|
|
94
|
-
{
|
|
95
|
-
modalTitle: "Confirm Action",
|
|
96
|
-
confirmButtonLabel: "Confirm",
|
|
97
|
-
cancelButtonLabel: "Cancel",
|
|
98
|
-
label: "Are you sure?",
|
|
99
|
-
content: void 0,
|
|
100
|
-
isOpen: !0,
|
|
101
|
-
onConfirm: e.fn(),
|
|
102
|
-
onCancel: e.fn()
|
|
103
|
-
}
|
|
104
|
-
)
|
|
105
|
-
);
|
|
106
|
-
t(n.queryByRole("list")).not.toBeInTheDocument(), r(
|
|
107
|
-
/* @__PURE__ */ o(
|
|
108
|
-
l,
|
|
109
|
-
{
|
|
110
|
-
modalTitle: "Confirm Action",
|
|
111
|
-
confirmButtonLabel: "Confirm",
|
|
112
|
-
cancelButtonLabel: "Cancel",
|
|
113
|
-
label: "Are you sure?",
|
|
114
|
-
content: void 0,
|
|
115
|
-
isOpen: !0,
|
|
116
|
-
onConfirm: e.fn(),
|
|
117
|
-
onCancel: e.fn()
|
|
118
|
-
}
|
|
119
|
-
)
|
|
120
|
-
), t(n.queryByRole("list")).not.toBeInTheDocument();
|
|
121
|
-
}), a("renders correctly when content is an empty array", () => {
|
|
122
|
-
i(
|
|
123
|
-
/* @__PURE__ */ o(
|
|
124
|
-
l,
|
|
125
|
-
{
|
|
126
|
-
modalTitle: "Confirm Action",
|
|
127
|
-
confirmButtonLabel: "Confirm",
|
|
128
|
-
cancelButtonLabel: "Cancel",
|
|
129
|
-
label: "Are you sure?",
|
|
130
|
-
content: [],
|
|
131
|
-
isOpen: !0,
|
|
132
|
-
onConfirm: e.fn(),
|
|
133
|
-
onCancel: e.fn()
|
|
134
|
-
}
|
|
135
|
-
)
|
|
136
|
-
), t(n.getByText("Are you sure?")).toBeInTheDocument();
|
|
137
|
-
}), a("renders ReactNode as label", () => {
|
|
138
|
-
i(
|
|
139
|
-
/* @__PURE__ */ o(
|
|
140
|
-
l,
|
|
141
|
-
{
|
|
142
|
-
modalTitle: "Confirm Action",
|
|
143
|
-
confirmButtonLabel: "Confirm",
|
|
144
|
-
cancelButtonLabel: "Cancel",
|
|
145
|
-
label: /* @__PURE__ */ o("span", { "data-testid": "custom-label", children: "Custom Label" }),
|
|
146
|
-
isOpen: !0,
|
|
147
|
-
onConfirm: e.fn(),
|
|
148
|
-
onCancel: e.fn()
|
|
149
|
-
}
|
|
150
|
-
)
|
|
151
|
-
), t(n.getByTestId("custom-label")).toBeInTheDocument(), t(n.getByText("Custom Label")).toBeInTheDocument();
|
|
152
|
-
}), a("confirm button is not disabled by default", () => {
|
|
153
|
-
i(
|
|
154
|
-
/* @__PURE__ */ o(
|
|
155
|
-
l,
|
|
156
|
-
{
|
|
157
|
-
modalTitle: "Confirm Action",
|
|
158
|
-
confirmButtonLabel: "Confirm",
|
|
159
|
-
cancelButtonLabel: "Cancel",
|
|
160
|
-
label: "Are you sure?",
|
|
161
|
-
isOpen: !0,
|
|
162
|
-
onConfirm: e.fn(),
|
|
163
|
-
onCancel: e.fn()
|
|
164
|
-
}
|
|
165
|
-
)
|
|
166
|
-
), t(n.getByTestId("confirm-button")).not.toBeDisabled();
|
|
167
|
-
}), a("confirm button can be disabled", () => {
|
|
168
|
-
i(
|
|
169
|
-
/* @__PURE__ */ o(
|
|
170
|
-
l,
|
|
171
|
-
{
|
|
172
|
-
modalTitle: "Confirm Action",
|
|
173
|
-
confirmButtonLabel: "Confirm",
|
|
174
|
-
cancelButtonLabel: "Cancel",
|
|
175
|
-
label: "Are you sure?",
|
|
176
|
-
isOpen: !0,
|
|
177
|
-
onConfirm: e.fn(),
|
|
178
|
-
onCancel: e.fn(),
|
|
179
|
-
isConfirmationDisabled: !0
|
|
180
|
-
}
|
|
181
|
-
)
|
|
182
|
-
), t(n.getByTestId("confirm-button")).toBeDisabled();
|
|
183
|
-
}), a("renders bullet points when showBulletPoints is true", () => {
|
|
184
|
-
i(
|
|
185
|
-
/* @__PURE__ */ o(
|
|
186
|
-
l,
|
|
187
|
-
{
|
|
188
|
-
modalTitle: "Bullet Modal",
|
|
189
|
-
confirmButtonLabel: "Confirm",
|
|
190
|
-
cancelButtonLabel: "Cancel",
|
|
191
|
-
label: "Choose wisely:",
|
|
192
|
-
content: ["Bullet 1", "Bullet 2"],
|
|
193
|
-
showBulletPoints: !0,
|
|
194
|
-
isOpen: !0,
|
|
195
|
-
onConfirm: e.fn(),
|
|
196
|
-
onCancel: e.fn()
|
|
197
|
-
}
|
|
198
|
-
)
|
|
199
|
-
), t(n.getByText("Bullet 1")).toBeInTheDocument(), t(n.getByText("Bullet 2")).toBeInTheDocument();
|
|
200
|
-
const r = n.getByText("Bullet 1"), s = n.getByText("Bullet 2");
|
|
201
|
-
t(Array.from(r.classList).some((c) => c.includes("bulletPoint"))).toBe(!0), t(Array.from(s.classList).some((c) => c.includes("bulletPoint"))).toBe(!0);
|
|
202
|
-
}), a("does not render bullet point class when showBulletPoints is false", () => {
|
|
203
|
-
i(
|
|
204
|
-
/* @__PURE__ */ o(
|
|
205
|
-
l,
|
|
206
|
-
{
|
|
207
|
-
modalTitle: "No Bullet Modal",
|
|
208
|
-
confirmButtonLabel: "Confirm",
|
|
209
|
-
cancelButtonLabel: "Cancel",
|
|
210
|
-
label: "Choose wisely:",
|
|
211
|
-
content: ["Item 1", "Item 2"],
|
|
212
|
-
isOpen: !0,
|
|
213
|
-
onConfirm: e.fn(),
|
|
214
|
-
onCancel: e.fn()
|
|
215
|
-
}
|
|
216
|
-
)
|
|
217
|
-
);
|
|
218
|
-
const r = n.getByText("Item 1"), s = n.getByText("Item 2");
|
|
219
|
-
t(Array.from(r.classList).some((c) => c.includes("bulletPoint"))).toBe(!1), t(Array.from(s.classList).some((c) => c.includes("bulletPoint"))).toBe(!1);
|
|
220
|
-
});
|
|
221
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
import { jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { a, s as t, f as l, w as c } from "../../react.esm-Bm0cAgpZ.js";
|
|
3
|
-
import { ContextMenu as d } from "./ContextMenu.js";
|
|
4
|
-
import { a as i, d as y, t as r, g as e } from "../../vi.bdSIJ99Y-B308Q-4w.js";
|
|
5
|
-
const g = i.fn(), B = i.fn(), p = i.fn(), m = [
|
|
6
|
-
{ primaryText: "Open", onClick: g, leadingBlock: "add", "data-testid": "open-testid" },
|
|
7
|
-
{
|
|
8
|
-
primaryText: "Delete",
|
|
9
|
-
onClick: p,
|
|
10
|
-
leadingBlock: "delete_outline",
|
|
11
|
-
"data-testid": "delete-testid"
|
|
12
|
-
},
|
|
13
|
-
{ primaryText: "Edit", onClick: B, leadingBlock: "edit", "data-testid": "edit-testid" }
|
|
14
|
-
];
|
|
15
|
-
y("ContextMenu Test", () => {
|
|
16
|
-
r("render contextMenu and close it", () => {
|
|
17
|
-
a(/* @__PURE__ */ s(d, { actions: m }));
|
|
18
|
-
const o = t.getByTestId("open-button"), n = t.getByTestId("selection-menu");
|
|
19
|
-
e(n).toBeInTheDocument(), e(n).not.toHaveClass("mdc-menu-surface--open"), l.click(o), c(() => e(n).toHaveClass("mdc-menu-surface--open")), l.click(o), c(() => e(n).not.toHaveClass("mdc-menu-surface--open"));
|
|
20
|
-
}), r("render ContextMenu and open it", async () => {
|
|
21
|
-
a(/* @__PURE__ */ s(d, { actions: m, triggerOpen: !0 }));
|
|
22
|
-
const o = t.getByTestId("open-button"), n = t.getByTestId("selection-menu");
|
|
23
|
-
e(n).toBeInTheDocument(), e(n).not.toHaveClass("mdc-menu-surface--open"), l.click(o), await c(() => e(n).toHaveClass("mdc-menu-surface--animating-open")), e(t.getByText("Open")).toBeInTheDocument(), e(t.getByText("Delete")).toBeInTheDocument(), e(t.getByText("Edit")).toBeInTheDocument();
|
|
24
|
-
const u = t.getByTestId("open-testid"), T = t.getByTestId("delete-testid"), f = t.getByTestId("edit-testid");
|
|
25
|
-
e(u).toBeInTheDocument(), e(T).toBeInTheDocument(), e(f).toBeInTheDocument(), l.click(u), e(g).toHaveBeenCalled(), e(p).not.toHaveBeenCalled(), e(B).not.toHaveBeenCalled(), l.click(T), e(p).toHaveBeenCalled(), l.click(f), e(B).toHaveBeenCalled();
|
|
26
|
-
}), r("render ContextMenu with offlineView", async () => {
|
|
27
|
-
a(
|
|
28
|
-
/* @__PURE__ */ s(
|
|
29
|
-
d,
|
|
30
|
-
{
|
|
31
|
-
actions: m,
|
|
32
|
-
triggerOpen: !0,
|
|
33
|
-
isOnline: !1,
|
|
34
|
-
offlineViewProps: {
|
|
35
|
-
"data-testid": "offline-test"
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
)
|
|
39
|
-
);
|
|
40
|
-
const o = t.getByTestId("open-button");
|
|
41
|
-
l.click(o);
|
|
42
|
-
const n = t.getByTestId("selection-menu");
|
|
43
|
-
await c(() => e(n).toHaveClass("mdc-menu-surface--animating-open")), e(t.getByTestId("offline-test")).toBeInTheDocument();
|
|
44
|
-
}), r("does not render action when isAllowed is false", async () => {
|
|
45
|
-
const o = [
|
|
46
|
-
{
|
|
47
|
-
primaryText: "Allowed Action",
|
|
48
|
-
onClick: i.fn(),
|
|
49
|
-
leadingBlock: "add",
|
|
50
|
-
"data-testid": "allowed-action",
|
|
51
|
-
isAllowed: !0
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
primaryText: "Not Allowed Action",
|
|
55
|
-
onClick: i.fn(),
|
|
56
|
-
leadingBlock: "delete_outline",
|
|
57
|
-
"data-testid": "not-allowed-action",
|
|
58
|
-
isAllowed: !1
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
primaryText: "Another Allowed Action",
|
|
62
|
-
onClick: i.fn(),
|
|
63
|
-
leadingBlock: "edit",
|
|
64
|
-
"data-testid": "another-allowed-action",
|
|
65
|
-
isAllowed: !0
|
|
66
|
-
}
|
|
67
|
-
];
|
|
68
|
-
a(/* @__PURE__ */ s(d, { actions: o, triggerOpen: !0 }));
|
|
69
|
-
const n = t.getByTestId("open-button");
|
|
70
|
-
l.click(n);
|
|
71
|
-
const u = t.getByTestId("selection-menu");
|
|
72
|
-
await c(() => e(u).toHaveClass("mdc-menu-surface--animating-open")), e(t.getByText("Allowed Action")).toBeInTheDocument(), e(t.getByText("Another Allowed Action")).toBeInTheDocument(), e(t.queryByText("Not Allowed Action")).not.toBeInTheDocument();
|
|
73
|
-
}), r("does not render component when all actions have isAllowed false", () => {
|
|
74
|
-
const o = [
|
|
75
|
-
{
|
|
76
|
-
primaryText: "Not Allowed 1",
|
|
77
|
-
onClick: i.fn(),
|
|
78
|
-
leadingBlock: "add",
|
|
79
|
-
isAllowed: !1
|
|
80
|
-
},
|
|
81
|
-
{
|
|
82
|
-
primaryText: "Not Allowed 2",
|
|
83
|
-
onClick: i.fn(),
|
|
84
|
-
leadingBlock: "delete_outline",
|
|
85
|
-
isAllowed: !1
|
|
86
|
-
},
|
|
87
|
-
{
|
|
88
|
-
primaryText: "Not Allowed 3",
|
|
89
|
-
onClick: i.fn(),
|
|
90
|
-
leadingBlock: "edit",
|
|
91
|
-
isAllowed: !1
|
|
92
|
-
}
|
|
93
|
-
];
|
|
94
|
-
a(/* @__PURE__ */ s(d, { actions: o })), e(t.queryByTestId("open-button")).not.toBeInTheDocument();
|
|
95
|
-
});
|
|
96
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
-
import { a as c, s as t } from "../../react.esm-Bm0cAgpZ.js";
|
|
3
|
-
import { DeleteModal as b } from "./DeleteModal.js";
|
|
4
|
-
import { d as a, t as s, a as o, g as e } from "../../vi.bdSIJ99Y-B308Q-4w.js";
|
|
5
|
-
a("DeleteModal Test", () => {
|
|
6
|
-
s("should render the DeleteModal properly", () => {
|
|
7
|
-
c(
|
|
8
|
-
/* @__PURE__ */ n(
|
|
9
|
-
b,
|
|
10
|
-
{
|
|
11
|
-
icon: "block",
|
|
12
|
-
open: !0,
|
|
13
|
-
setOpen: o.fn(),
|
|
14
|
-
onDelete: o.fn(),
|
|
15
|
-
title: "DELETE",
|
|
16
|
-
confirmButtonLabel: "Remove",
|
|
17
|
-
cancelButtonLabel: "Cancel",
|
|
18
|
-
deleteHeader: "Delete my block",
|
|
19
|
-
impossibleDeleteHeader: "block cant be deleted",
|
|
20
|
-
deleteBody: ["block 1", "block 2", "block 3"],
|
|
21
|
-
isDeletePossible: !0
|
|
22
|
-
}
|
|
23
|
-
)
|
|
24
|
-
), e(t.getByText("DELETE")).toBeInTheDocument(), e(t.getByTestId("block")).toBeInTheDocument(), e(t.getByText("block 1")).toBeInTheDocument(), e(t.getByText("block 2")).toBeInTheDocument(), e(t.getByText("block 3")).toBeInTheDocument(), e(t.getByText("Remove")).toBeInTheDocument(), e(t.getByText("Cancel")).toBeInTheDocument(), e(t.queryByText("block cant be deleted")).not.toBeInTheDocument();
|
|
25
|
-
}), s("should render the DeleteModal properly when isDeletePossible = false", () => {
|
|
26
|
-
c(
|
|
27
|
-
/* @__PURE__ */ n(
|
|
28
|
-
b,
|
|
29
|
-
{
|
|
30
|
-
icon: "block",
|
|
31
|
-
open: !0,
|
|
32
|
-
setOpen: o.fn(),
|
|
33
|
-
onDelete: o.fn(),
|
|
34
|
-
title: "DELETE",
|
|
35
|
-
confirmButtonLabel: "Remove",
|
|
36
|
-
cancelButtonLabel: "Cancel",
|
|
37
|
-
deleteHeader: "Delete my block",
|
|
38
|
-
impossibleDeleteHeader: "block cant be deleted",
|
|
39
|
-
deleteBody: ["block 1", "block 2", "block 3"],
|
|
40
|
-
isDeletePossible: !1
|
|
41
|
-
}
|
|
42
|
-
)
|
|
43
|
-
), e(t.getByText("DELETE")).toBeInTheDocument(), e(t.getByTestId("block")).toBeInTheDocument(), e(t.queryByText("block 1")).not.toBeInTheDocument(), e(t.queryByText("block 2")).not.toBeInTheDocument(), e(t.queryByText("block 3")).not.toBeInTheDocument(), e(t.getByText("Remove")).toBeInTheDocument(), e(t.getByText("Remove").parentElement).toBeDisabled(), e(t.getByText("Cancel")).toBeInTheDocument(), e(t.queryByText("block cant be deleted")).toBeInTheDocument();
|
|
44
|
-
}), s("should call setOpen with false when clicking on cancel button", () => {
|
|
45
|
-
const l = o.fn();
|
|
46
|
-
c(
|
|
47
|
-
/* @__PURE__ */ n(
|
|
48
|
-
b,
|
|
49
|
-
{
|
|
50
|
-
icon: "block",
|
|
51
|
-
open: !0,
|
|
52
|
-
setOpen: l,
|
|
53
|
-
onDelete: o.fn(),
|
|
54
|
-
title: "DELETE",
|
|
55
|
-
confirmButtonLabel: "Remove",
|
|
56
|
-
cancelButtonLabel: "Cancel",
|
|
57
|
-
deleteHeader: "Delete my block",
|
|
58
|
-
impossibleDeleteHeader: "block cant be deleted",
|
|
59
|
-
deleteBody: ["block 1", "block 2", "block 3"],
|
|
60
|
-
isDeletePossible: !0
|
|
61
|
-
}
|
|
62
|
-
)
|
|
63
|
-
), t.getByText("Cancel").click(), e(l).toHaveBeenCalledWith(!1);
|
|
64
|
-
}), s("should call onDelete when clicking on delete button", () => {
|
|
65
|
-
const l = o.fn();
|
|
66
|
-
c(
|
|
67
|
-
/* @__PURE__ */ n(
|
|
68
|
-
b,
|
|
69
|
-
{
|
|
70
|
-
icon: "block",
|
|
71
|
-
open: !0,
|
|
72
|
-
setOpen: o.fn(),
|
|
73
|
-
onDelete: l,
|
|
74
|
-
title: "DELETE",
|
|
75
|
-
confirmButtonLabel: "Remove",
|
|
76
|
-
cancelButtonLabel: "Cancel",
|
|
77
|
-
deleteHeader: "Delete my block",
|
|
78
|
-
impossibleDeleteHeader: "block cant be deleted",
|
|
79
|
-
deleteBody: ["block 1", "block 2", "block 3"],
|
|
80
|
-
isDeletePossible: !0
|
|
81
|
-
}
|
|
82
|
-
)
|
|
83
|
-
), t.getByText("Remove").click(), e(l).toHaveBeenCalled();
|
|
84
|
-
}), s("render DeleteModal with OfflineView", () => {
|
|
85
|
-
const l = o.fn();
|
|
86
|
-
c(
|
|
87
|
-
/* @__PURE__ */ n(
|
|
88
|
-
b,
|
|
89
|
-
{
|
|
90
|
-
icon: "block",
|
|
91
|
-
open: !0,
|
|
92
|
-
setOpen: o.fn(),
|
|
93
|
-
onDelete: l,
|
|
94
|
-
title: "DELETE",
|
|
95
|
-
confirmButtonLabel: "Remove",
|
|
96
|
-
cancelButtonLabel: "Cancel",
|
|
97
|
-
deleteHeader: "Delete my block",
|
|
98
|
-
impossibleDeleteHeader: "block cant be deleted",
|
|
99
|
-
deleteBody: ["block 1", "block 2", "block 3"],
|
|
100
|
-
isDeletePossible: !0,
|
|
101
|
-
isOnline: !1,
|
|
102
|
-
offlineViewProps: {
|
|
103
|
-
"data-testid": "offline-test"
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
)
|
|
107
|
-
), t.getByText("Remove").click(), e(l).not.toHaveBeenCalled(), e(t.getByTestId("offline-test")).toBeInTheDocument();
|
|
108
|
-
}), s("should disable delete button when isDeletePending is true", () => {
|
|
109
|
-
const l = o.fn();
|
|
110
|
-
c(
|
|
111
|
-
/* @__PURE__ */ n(
|
|
112
|
-
b,
|
|
113
|
-
{
|
|
114
|
-
icon: "block",
|
|
115
|
-
open: !0,
|
|
116
|
-
setOpen: o.fn(),
|
|
117
|
-
onDelete: l,
|
|
118
|
-
title: "DELETE",
|
|
119
|
-
confirmButtonLabel: "Remove",
|
|
120
|
-
cancelButtonLabel: "Cancel",
|
|
121
|
-
deleteHeader: "Delete my block",
|
|
122
|
-
impossibleDeleteHeader: "block cant be deleted",
|
|
123
|
-
deleteBody: ["block 1", "block 2", "block 3"],
|
|
124
|
-
isDeletePossible: !0,
|
|
125
|
-
isDeletePending: !0
|
|
126
|
-
}
|
|
127
|
-
)
|
|
128
|
-
);
|
|
129
|
-
const d = t.getByTestId("delete-button");
|
|
130
|
-
e(d).toBeDisabled(), e(t.getByTestId("loading-spinner")).toBeInTheDocument(), d.click(), e(l).not.toHaveBeenCalled();
|
|
131
|
-
});
|
|
132
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { a as r, s as t } from "../../react.esm-Bm0cAgpZ.js";
|
|
3
|
-
import { Disclaimer as s } from "./Disclaimer.js";
|
|
4
|
-
import { d as i, t as m, g as e } from "../../vi.bdSIJ99Y-B308Q-4w.js";
|
|
5
|
-
i("Disclaimer test", () => {
|
|
6
|
-
m("should render with default text", () => {
|
|
7
|
-
r(/* @__PURE__ */ o(s, { text: "disclaimer.default" })), e(t.getByText("disclaimer.default")).toBeInTheDocument();
|
|
8
|
-
}), m("should render with custom text", () => {
|
|
9
|
-
r(/* @__PURE__ */ o(s, { text: "custom-text" })), e(t.getByText("custom-text")).toBeInTheDocument(), e(t.queryByText("disclaimer.default")).not.toBeInTheDocument();
|
|
10
|
-
}), m("should render Disclaimer including the custom text", () => {
|
|
11
|
-
r(/* @__PURE__ */ o(s, { subtext: "custom-text", text: "offline-alterText" })), e(t.getByText("offline-alterText")).toBeInTheDocument(), e(t.getByText("custom-text")).toBeInTheDocument();
|
|
12
|
-
});
|
|
13
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
-
import { a as i, s as o, w as r, f as l } from "../../react.esm-Bm0cAgpZ.js";
|
|
3
|
-
import { EmptyView as T } from "./EmptyView.js";
|
|
4
|
-
import { d as m, t as s, g as t, a } from "../../vi.bdSIJ99Y-B308Q-4w.js";
|
|
5
|
-
m("EmptyView", () => {
|
|
6
|
-
s("should render", () => {
|
|
7
|
-
i(/* @__PURE__ */ n(T, {})), t(o.getByTestId("empty-view-container")).toBeInTheDocument();
|
|
8
|
-
}), s("should render with custom icon", () => {
|
|
9
|
-
i(/* @__PURE__ */ n(T, { icon: "add" })), t(o.getByText("add")).toBeInTheDocument();
|
|
10
|
-
}), s("should render with title", () => {
|
|
11
|
-
i(/* @__PURE__ */ n(T, { icon: "add", title: "TITLE" }));
|
|
12
|
-
const e = o.getByText("TITLE");
|
|
13
|
-
t(e).toBeInTheDocument();
|
|
14
|
-
}), s("should render with an action", async () => {
|
|
15
|
-
const e = a.fn();
|
|
16
|
-
i(/* @__PURE__ */ n(T, { icon: "add", action: /* @__PURE__ */ n("button", { onClick: e, children: "BUTTON" }) }));
|
|
17
|
-
const c = o.getByText("BUTTON");
|
|
18
|
-
t(c).toBeInTheDocument(), await r(() => l.click(c)), t(e).toHaveBeenCalledTimes(1);
|
|
19
|
-
}), s("should render with a title and a button", async () => {
|
|
20
|
-
const e = a.fn();
|
|
21
|
-
i(
|
|
22
|
-
/* @__PURE__ */ n(
|
|
23
|
-
T,
|
|
24
|
-
{
|
|
25
|
-
icon: "add",
|
|
26
|
-
action: /* @__PURE__ */ n("button", { onClick: e, children: "BUTTON" }),
|
|
27
|
-
title: "MY_TEXT"
|
|
28
|
-
}
|
|
29
|
-
)
|
|
30
|
-
);
|
|
31
|
-
const c = o.getByText("BUTTON");
|
|
32
|
-
t(c).toBeInTheDocument();
|
|
33
|
-
const d = o.getByText("MY_TEXT");
|
|
34
|
-
t(d).toBeInTheDocument();
|
|
35
|
-
}), s("should render with title only", async () => {
|
|
36
|
-
i(
|
|
37
|
-
/* @__PURE__ */ n(
|
|
38
|
-
T,
|
|
39
|
-
{
|
|
40
|
-
icon: "add",
|
|
41
|
-
title: "MY_TEXT"
|
|
42
|
-
}
|
|
43
|
-
)
|
|
44
|
-
);
|
|
45
|
-
const e = o.queryByText("BUTTON");
|
|
46
|
-
t(e).not.toBeInTheDocument();
|
|
47
|
-
const c = o.getByText("MY_TEXT");
|
|
48
|
-
t(c).toBeInTheDocument();
|
|
49
|
-
});
|
|
50
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|