@onewelcome/react-lib-components 0.2.1 → 0.2.4
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/Breadcrumbs/Breadcrumbs.d.ts +4 -4
- package/dist/Button/BaseButton.d.ts +4 -4
- package/dist/Button/Button.d.ts +3 -3
- package/dist/Button/IconButton.d.ts +4 -4
- package/dist/ContextMenu/ContextMenu.d.ts +5 -5
- package/dist/ContextMenu/ContextMenuItem.d.ts +2 -2
- package/dist/DataGrid/DataGrid.d.ts +6 -6
- package/dist/DataGrid/DataGridActions/DataGridActions.d.ts +4 -4
- package/dist/DataGrid/DataGridActions/DataGridColumnsToggle.d.ts +3 -3
- package/dist/DataGrid/DataGridBody/DataGridBody.d.ts +3 -3
- package/dist/DataGrid/DataGridBody/DataGridCell.d.ts +2 -2
- package/dist/DataGrid/DataGridBody/DataGridRow.d.ts +3 -3
- package/dist/DataGrid/DataGridHeader/DataGridHeader.d.ts +3 -3
- package/dist/DataGrid/DataGridHeader/DataGridHeaderCell.d.ts +3 -3
- package/dist/DataGrid/datagrid.interfaces.d.ts +1 -1
- package/dist/Form/Checkbox/Checkbox.d.ts +5 -5
- package/dist/Form/Fieldset/Fieldset.d.ts +3 -3
- package/dist/Form/Form.d.ts +1 -1
- package/dist/Form/FormControl/FormControl.d.ts +3 -3
- package/dist/Form/FormGroup/FormGroup.d.ts +5 -5
- package/dist/Form/FormHelperText/FormHelperText.d.ts +3 -3
- package/dist/Form/FormSelectorWrapper/FormSelectorWrapper.d.ts +6 -6
- package/dist/Form/Input/Input.d.ts +5 -5
- package/dist/Form/Label/Label.d.ts +2 -2
- package/dist/Form/Radio/Radio.d.ts +5 -5
- package/dist/Form/Select/Option.d.ts +2 -2
- package/dist/Form/Select/Select.d.ts +5 -5
- package/dist/Form/Textarea/Textarea.d.ts +6 -6
- package/dist/Form/Toggle/Toggle.d.ts +3 -3
- package/dist/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.d.ts +4 -4
- package/dist/Form/Wrapper/InputWrapper/InputWrapper.d.ts +4 -4
- package/dist/Form/Wrapper/RadioWrapper/RadioWrapper.d.ts +4 -4
- package/dist/Form/Wrapper/SelectWrapper/SelectWrapper.d.ts +4 -4
- package/dist/Form/Wrapper/TextareaWrapper/TextareaWrapper.d.ts +4 -4
- package/dist/Form/Wrapper/Wrapper/Wrapper.d.ts +6 -6
- package/dist/Form/form.interfaces.d.ts +2 -2
- package/dist/Icon/Icon.d.ts +3 -3
- package/dist/Link/Link.d.ts +7 -7
- package/dist/Notifications/BaseModal/BaseModal.d.ts +4 -4
- package/dist/Notifications/BaseModal/BaseModalActions/BaseModalActions.d.ts +2 -2
- package/dist/Notifications/BaseModal/BaseModalContent/BaseModalContent.d.ts +2 -2
- package/dist/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.d.ts +2 -2
- package/dist/Notifications/Dialog/Dialog.d.ts +5 -5
- package/dist/Notifications/Dialog/DialogActions/DialogActions.d.ts +3 -3
- package/dist/Notifications/Dialog/DialogTitle/DialogTitle.d.ts +2 -2
- package/dist/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.d.ts +3 -3
- package/dist/Notifications/DiscardChangesModal/DiscardChangesModal.d.ts +7 -7
- package/dist/Notifications/Modal/Modal.d.ts +1 -1
- package/dist/Notifications/Modal/ModalActions/ModalActions.d.ts +1 -1
- package/dist/Notifications/Modal/ModalContent/ModalContent.d.ts +1 -1
- package/dist/Notifications/Modal/ModalHeader/ModalHeader.d.ts +1 -1
- package/dist/Notifications/SlideInModal/SlideInModal.d.ts +3 -3
- package/dist/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.d.ts +3 -3
- package/dist/Notifications/Snackbar/SnackbarItem/SnackbarItem.d.ts +2 -2
- package/dist/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.d.ts +3 -3
- package/dist/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.d.ts +2 -2
- package/dist/Notifications/Snackbar/interfaces.d.ts +2 -2
- package/dist/Pagination/Pagination.d.ts +3 -3
- package/dist/Popover/Popover.d.ts +3 -3
- package/dist/Skeleton/Skeleton.d.ts +3 -3
- package/dist/StatusIndicator/StatusIndicator.d.ts +5 -5
- package/dist/Tabs/Tab.d.ts +1 -1
- package/dist/Tabs/TabButton.d.ts +2 -2
- package/dist/Tabs/TabPanel.d.ts +2 -2
- package/dist/Tabs/Tabs.d.ts +4 -4
- package/dist/TextEllipsis/TextEllipsis.d.ts +2 -2
- package/dist/Tiles/Tile.d.ts +5 -5
- package/dist/Tiles/Tiles.d.ts +2 -2
- package/dist/Tooltip/Tooltip.d.ts +3 -3
- package/dist/Typography/Typography.d.ts +3 -3
- package/dist/Wizard/BaseWizardSteps/BaseWizardSteps.d.ts +2 -2
- package/dist/Wizard/Wizard.d.ts +3 -3
- package/dist/Wizard/WizardActions/WizardActions.d.ts +2 -2
- package/dist/Wizard/WizardStateProvider.d.ts +2 -2
- package/dist/Wizard/WizardSteps/WizardSteps.d.ts +2 -2
- package/dist/Wizard/wizardStateReducer.d.ts +5 -5
- package/dist/_BaseStyling_/BaseStyling.d.ts +1 -1
- package/dist/hooks/usePosition.d.ts +5 -5
- package/dist/hooks/useRepeater.d.ts +1 -1
- package/dist/hooks/useScroll.d.ts +1 -1
- package/dist/hooks/useSpacing.d.ts +1 -1
- package/dist/hooks/useWrapper.d.ts +1 -1
- package/dist/index.d.ts +55 -55
- package/dist/interfaces.d.ts +1 -1
- package/dist/react-lib-components.cjs.development.js +683 -581
- package/dist/react-lib-components.cjs.development.js.map +1 -1
- package/dist/react-lib-components.cjs.production.min.js +1 -1
- package/dist/react-lib-components.cjs.production.min.js.map +1 -1
- package/dist/react-lib-components.esm.js +683 -581
- package/dist/react-lib-components.esm.js.map +1 -1
- package/package.json +27 -16
- package/src/Breadcrumbs/Breadcrumbs.test.tsx +15 -15
- package/src/Breadcrumbs/Breadcrumbs.tsx +11 -11
- package/src/Button/BaseButton.module.scss +1 -1
- package/src/Button/BaseButton.test.tsx +27 -27
- package/src/Button/BaseButton.tsx +8 -8
- package/src/Button/Button.module.scss +5 -5
- package/src/Button/Button.test.tsx +39 -39
- package/src/Button/Button.tsx +10 -10
- package/src/Button/IconButton.module.scss +5 -5
- package/src/Button/IconButton.test.tsx +29 -29
- package/src/Button/IconButton.tsx +11 -11
- package/src/ContextMenu/ContextMenu.test.tsx +97 -76
- package/src/ContextMenu/ContextMenu.tsx +48 -42
- package/src/ContextMenu/ContextMenuItem.module.scss +1 -1
- package/src/ContextMenu/ContextMenuItem.tsx +8 -5
- package/src/DataGrid/DataGrid.test.tsx +193 -193
- package/src/DataGrid/DataGrid.tsx +26 -26
- package/src/DataGrid/DataGridActions/DataGridActions.test.tsx +63 -63
- package/src/DataGrid/DataGridActions/DataGridActions.tsx +15 -15
- package/src/DataGrid/DataGridActions/DataGridColumnsToggle.module.scss +1 -1
- package/src/DataGrid/DataGridActions/DataGridColumnsToggle.test.tsx +21 -21
- package/src/DataGrid/DataGridActions/DataGridColumnsToggle.tsx +20 -20
- package/src/DataGrid/DataGridBody/DataGridBody.test.tsx +40 -40
- package/src/DataGrid/DataGridBody/DataGridBody.tsx +10 -10
- package/src/DataGrid/DataGridBody/DataGridCell.module.scss +1 -1
- package/src/DataGrid/DataGridBody/DataGridCell.test.tsx +25 -25
- package/src/DataGrid/DataGridBody/DataGridCell.tsx +6 -6
- package/src/DataGrid/DataGridBody/DataGridRow.test.tsx +38 -38
- package/src/DataGrid/DataGridBody/DataGridRow.tsx +9 -9
- package/src/DataGrid/DataGridHeader/DataGridHeader.module.scss +1 -2
- package/src/DataGrid/DataGridHeader/DataGridHeader.test.tsx +119 -119
- package/src/DataGrid/DataGridHeader/DataGridHeader.tsx +13 -13
- package/src/DataGrid/DataGridHeader/DataGridHeaderCell.module.scss +2 -0
- package/src/DataGrid/DataGridHeader/DataGridHeaderCell.test.tsx +51 -51
- package/src/DataGrid/DataGridHeader/DataGridHeaderCell.tsx +14 -14
- package/src/DataGrid/datagrid.interfaces.ts +1 -1
- package/src/Form/Checkbox/Checkbox.test.tsx +74 -74
- package/src/Form/Checkbox/Checkbox.tsx +27 -27
- package/src/Form/Fieldset/Fieldset.module.scss +1 -1
- package/src/Form/Fieldset/Fieldset.test.tsx +35 -35
- package/src/Form/Fieldset/Fieldset.tsx +27 -27
- package/src/Form/Form.test.tsx +18 -18
- package/src/Form/Form.tsx +3 -3
- package/src/Form/FormControl/FormControl.test.tsx +22 -22
- package/src/Form/FormControl/FormControl.tsx +10 -10
- package/src/Form/FormGroup/FormGroup.test.tsx +37 -37
- package/src/Form/FormGroup/FormGroup.tsx +16 -16
- package/src/Form/FormHelperText/FormHelperText.test.tsx +18 -18
- package/src/Form/FormHelperText/FormHelperText.tsx +7 -7
- package/src/Form/FormSelectorWrapper/FormSelectorWrapper.test.tsx +15 -15
- package/src/Form/FormSelectorWrapper/FormSelectorWrapper.tsx +14 -14
- package/src/Form/Input/Input.module.scss +20 -44
- package/src/Form/Input/Input.test.tsx +121 -73
- package/src/Form/Input/Input.tsx +96 -35
- package/src/Form/Label/Label.test.tsx +13 -13
- package/src/Form/Label/Label.tsx +6 -6
- package/src/Form/Radio/Radio.test.tsx +35 -35
- package/src/Form/Radio/Radio.tsx +17 -17
- package/src/Form/Select/Option.test.tsx +10 -10
- package/src/Form/Select/Option.tsx +8 -8
- package/src/Form/Select/Select.module.scss +7 -9
- package/src/Form/Select/Select.test.tsx +144 -141
- package/src/Form/Select/Select.tsx +79 -78
- package/src/Form/Textarea/Textarea.module.scss +8 -18
- package/src/Form/Textarea/Textarea.test.tsx +27 -27
- package/src/Form/Textarea/Textarea.tsx +33 -13
- package/src/Form/Toggle/Toggle.module.scss +1 -1
- package/src/Form/Toggle/Toggle.test.tsx +22 -22
- package/src/Form/Toggle/Toggle.tsx +10 -10
- package/src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.test.tsx +39 -39
- package/src/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.tsx +12 -12
- package/src/Form/Wrapper/InputWrapper/InputWrapper.module.scss +2 -8
- package/src/Form/Wrapper/InputWrapper/InputWrapper.test.tsx +55 -55
- package/src/Form/Wrapper/InputWrapper/InputWrapper.tsx +30 -35
- package/src/Form/Wrapper/RadioWrapper/RadioWrapper.test.tsx +35 -35
- package/src/Form/Wrapper/RadioWrapper/RadioWrapper.tsx +12 -12
- package/src/Form/Wrapper/SelectWrapper/SelectWrapper.test.tsx +55 -55
- package/src/Form/Wrapper/SelectWrapper/SelectWrapper.tsx +12 -12
- package/src/Form/Wrapper/TextareaWrapper/TextareaWrapper.module.scss +2 -11
- package/src/Form/Wrapper/TextareaWrapper/TextareaWrapper.test.tsx +50 -50
- package/src/Form/Wrapper/TextareaWrapper/TextareaWrapper.tsx +22 -22
- package/src/Form/Wrapper/Wrapper/Wrapper.module.scss +2 -2
- package/src/Form/Wrapper/Wrapper/Wrapper.test.tsx +11 -11
- package/src/Form/Wrapper/Wrapper/Wrapper.tsx +17 -17
- package/src/Form/form.interfaces.ts +2 -2
- package/src/Icon/Icon.module.scss +71 -71
- package/src/Icon/Icon.test.tsx +18 -18
- package/src/Icon/Icon.tsx +70 -70
- package/src/Link/Link.module.scss +5 -5
- package/src/Link/Link.test.tsx +76 -76
- package/src/Link/Link.tsx +27 -27
- package/src/Link/types.d.ts +2 -2
- package/src/Notifications/BaseModal/BaseModal.module.scss +1 -1
- package/src/Notifications/BaseModal/BaseModal.test.tsx +53 -53
- package/src/Notifications/BaseModal/BaseModal.tsx +16 -16
- package/src/Notifications/BaseModal/BaseModalActions/BaseModalActions.test.tsx +13 -13
- package/src/Notifications/BaseModal/BaseModalActions/BaseModalActions.tsx +5 -5
- package/src/Notifications/BaseModal/BaseModalContent/BaseModalContent.test.tsx +16 -16
- package/src/Notifications/BaseModal/BaseModalContent/BaseModalContent.tsx +5 -5
- package/src/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.test.tsx +19 -19
- package/src/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.tsx +10 -10
- package/src/Notifications/Dialog/Dialog.test.tsx +35 -35
- package/src/Notifications/Dialog/Dialog.tsx +19 -19
- package/src/Notifications/Dialog/DialogActions/DialogActions.test.tsx +14 -14
- package/src/Notifications/Dialog/DialogActions/DialogActions.tsx +6 -6
- package/src/Notifications/Dialog/DialogTitle/DialogTitle.test.tsx +12 -12
- package/src/Notifications/Dialog/DialogTitle/DialogTitle.tsx +6 -6
- package/src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.test.tsx +20 -20
- package/src/Notifications/DiscardChangesModal/DiscardChangesDialog/DiscardChangesDialog.tsx +7 -7
- package/src/Notifications/DiscardChangesModal/DiscardChangesModal.test.tsx +36 -36
- package/src/Notifications/DiscardChangesModal/DiscardChangesModal.tsx +8 -8
- package/src/Notifications/Modal/Modal.test.tsx +6 -6
- package/src/Notifications/Modal/Modal.tsx +1 -1
- package/src/Notifications/Modal/ModalActions/ModalActions.tsx +2 -2
- package/src/Notifications/Modal/ModalContent/ModalContent.tsx +2 -2
- package/src/Notifications/Modal/ModalHeader/ModalHeader.tsx +2 -2
- package/src/Notifications/SlideInModal/SlideInModal.test.tsx +16 -16
- package/src/Notifications/SlideInModal/SlideInModal.tsx +16 -11
- package/src/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.test.tsx +16 -16
- package/src/Notifications/Snackbar/SnackbarContainer/SnackbarContainer.tsx +6 -6
- package/src/Notifications/Snackbar/SnackbarItem/SnackbarItem.module.scss +2 -2
- package/src/Notifications/Snackbar/SnackbarItem/SnackbarItem.test.tsx +17 -17
- package/src/Notifications/Snackbar/SnackbarItem/SnackbarItem.tsx +23 -23
- package/src/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.test.tsx +32 -32
- package/src/Notifications/Snackbar/SnackbarProvider/SnackbarProvider.tsx +18 -18
- package/src/Notifications/Snackbar/SnackbarProvider/SnackbarStateProvider.tsx +3 -3
- package/src/Notifications/Snackbar/interfaces.ts +2 -2
- package/src/Notifications/Snackbar/useSnackbar.ts +2 -2
- package/src/Pagination/Pagination.module.scss +2 -0
- package/src/Pagination/Pagination.test.tsx +47 -47
- package/src/Pagination/Pagination.tsx +35 -35
- package/src/Popover/Popover.test.tsx +19 -19
- package/src/Popover/Popover.tsx +7 -7
- package/src/Skeleton/Skeleton.module.scss +2 -2
- package/src/Skeleton/Skeleton.test.tsx +29 -29
- package/src/Skeleton/Skeleton.tsx +10 -10
- package/src/StatusIndicator/StatusIndicator.test.tsx +38 -38
- package/src/StatusIndicator/StatusIndicator.tsx +9 -9
- package/src/Tabs/Tab.test.tsx +13 -13
- package/src/Tabs/Tab.tsx +1 -1
- package/src/Tabs/TabButton.test.tsx +28 -28
- package/src/Tabs/TabButton.tsx +7 -7
- package/src/Tabs/TabPanel.test.tsx +30 -30
- package/src/Tabs/TabPanel.tsx +4 -4
- package/src/Tabs/Tabs.test.tsx +93 -93
- package/src/Tabs/Tabs.tsx +25 -25
- package/src/TextEllipsis/TextEllipsis.test.tsx +22 -22
- package/src/TextEllipsis/TextEllipsis.tsx +6 -6
- package/src/Tiles/Tile.module.scss +1 -1
- package/src/Tiles/Tile.test.tsx +42 -42
- package/src/Tiles/Tile.tsx +22 -22
- package/src/Tiles/Tiles.test.tsx +30 -30
- package/src/Tiles/Tiles.tsx +9 -9
- package/src/Tooltip/Tooltip.test.tsx +35 -35
- package/src/Tooltip/Tooltip.tsx +21 -21
- package/src/Typography/Typography.module.scss +1 -1
- package/src/Typography/Typography.test.tsx +49 -49
- package/src/Typography/Typography.tsx +42 -42
- package/src/Wizard/BaseWizardSteps/BaseWizardSteps.module.scss +1 -1
- package/src/Wizard/BaseWizardSteps/BaseWizardSteps.test.tsx +26 -26
- package/src/Wizard/BaseWizardSteps/BaseWizardSteps.tsx +24 -24
- package/src/Wizard/Wizard.test.tsx +56 -56
- package/src/Wizard/Wizard.tsx +6 -6
- package/src/Wizard/WizardActions/WizardActions.test.tsx +34 -34
- package/src/Wizard/WizardActions/WizardActions.tsx +14 -14
- package/src/Wizard/WizardStateProvider.tsx +3 -3
- package/src/Wizard/WizardSteps/WizardSteps.test.tsx +27 -27
- package/src/Wizard/WizardSteps/WizardSteps.tsx +7 -7
- package/src/Wizard/wizardStateReducer.ts +9 -9
- package/src/_BaseStyling_/BaseStyling.test.tsx +14 -14
- package/src/_BaseStyling_/BaseStyling.tsx +50 -50
- package/src/hooks/useAnimation.test.tsx +12 -12
- package/src/hooks/useAnimation.ts +4 -4
- package/src/hooks/useBodyClick.test.tsx +8 -8
- package/src/hooks/useBodyClick.ts +3 -3
- package/src/hooks/useFormSelector.test.ts +17 -17
- package/src/hooks/useFormSelector.ts +4 -4
- package/src/hooks/usePosition.test.tsx +215 -215
- package/src/hooks/usePosition.ts +73 -72
- package/src/hooks/useRepeater.test.tsx +26 -26
- package/src/hooks/useRepeater.ts +5 -5
- package/src/hooks/useScroll.test.tsx +5 -5
- package/src/hooks/useScroll.ts +3 -3
- package/src/hooks/useSpacing.test.ts +40 -40
- package/src/hooks/useSpacing.ts +3 -3
- package/src/hooks/useWrapper.test.ts +12 -12
- package/src/hooks/useWrapper.ts +10 -10
- package/src/index.ts +67 -67
- package/src/interfaces.ts +1 -1
- package/src/mixins.module.scss +76 -27
- package/src/types.d.ts +1 -1
- package/src/util/helper.test.tsx +25 -25
- package/src/util/helper.tsx +64 -64
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import React, { ComponentPropsWithRef, Fragment } from
|
|
2
|
-
import { Icon, Icons } from
|
|
3
|
-
import { ColumnName, Direction } from
|
|
4
|
-
import classes from
|
|
1
|
+
import React, { ComponentPropsWithRef, Fragment } from "react";
|
|
2
|
+
import { Icon, Icons } from "../../Icon/Icon";
|
|
3
|
+
import { ColumnName, Direction } from "../datagrid.interfaces";
|
|
4
|
+
import classes from "./DataGridHeaderCell.module.scss";
|
|
5
5
|
|
|
6
|
-
export interface Props extends ComponentPropsWithRef<
|
|
6
|
+
export interface Props extends ComponentPropsWithRef<"th"> {
|
|
7
7
|
headline: string;
|
|
8
8
|
name: ColumnName;
|
|
9
9
|
disableSorting?: boolean;
|
|
@@ -12,8 +12,8 @@ export interface Props extends ComponentPropsWithRef<'th'> {
|
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
const ariaSortMapping = {
|
|
15
|
-
ASC:
|
|
16
|
-
DESC:
|
|
15
|
+
ASC: "ascending",
|
|
16
|
+
DESC: "descending"
|
|
17
17
|
} as const;
|
|
18
18
|
|
|
19
19
|
export const DataGridHeaderCell = React.forwardRef<HTMLTableCellElement, Props>(
|
|
@@ -24,19 +24,19 @@ export const DataGridHeaderCell = React.forwardRef<HTMLTableCellElement, Props>(
|
|
|
24
24
|
|
|
25
25
|
const sortingIndicator = () => {
|
|
26
26
|
const getSortingIndicatorClasses = (direction: Direction) => {
|
|
27
|
-
const sortingIndicatorClasses = [classes[
|
|
27
|
+
const sortingIndicatorClasses = [classes["indicator"]];
|
|
28
28
|
activeSortDirection &&
|
|
29
29
|
sortingIndicatorClasses.push(
|
|
30
|
-
activeSortDirection === direction ? classes[
|
|
30
|
+
activeSortDirection === direction ? classes["active"] : classes["hidden"]
|
|
31
31
|
);
|
|
32
32
|
return sortingIndicatorClasses;
|
|
33
33
|
};
|
|
34
34
|
|
|
35
35
|
return (
|
|
36
36
|
<Fragment>
|
|
37
|
-
<Icon className={getSortingIndicatorClasses(
|
|
37
|
+
<Icon className={getSortingIndicatorClasses("ASC").join(" ")} icon={Icons.TriangleUp} />
|
|
38
38
|
<Icon
|
|
39
|
-
className={getSortingIndicatorClasses(
|
|
39
|
+
className={getSortingIndicatorClasses("DESC").join(" ")}
|
|
40
40
|
icon={Icons.TriangleDown}
|
|
41
41
|
/>
|
|
42
42
|
</Fragment>
|
|
@@ -45,9 +45,9 @@ export const DataGridHeaderCell = React.forwardRef<HTMLTableCellElement, Props>(
|
|
|
45
45
|
|
|
46
46
|
const innerContent = (
|
|
47
47
|
<Fragment>
|
|
48
|
-
<span className={classes[
|
|
48
|
+
<span className={classes["headline"]}>{headline}</span>
|
|
49
49
|
{!disableSorting && (
|
|
50
|
-
<div className={classes[
|
|
50
|
+
<div className={classes["sorting-indicator-container"]}>{sortingIndicator()}</div>
|
|
51
51
|
)}
|
|
52
52
|
</Fragment>
|
|
53
53
|
);
|
|
@@ -56,7 +56,7 @@ export const DataGridHeaderCell = React.forwardRef<HTMLTableCellElement, Props>(
|
|
|
56
56
|
<th
|
|
57
57
|
{...rest}
|
|
58
58
|
ref={ref}
|
|
59
|
-
className={classes[
|
|
59
|
+
className={classes["header-cell"]}
|
|
60
60
|
aria-sort={activeSortDirection && ariaSortMapping[activeSortDirection]}
|
|
61
61
|
>
|
|
62
62
|
{disableSorting ? (
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import React, { useEffect, useRef } from
|
|
2
|
-
import { Checkbox, Props } from
|
|
3
|
-
import { render } from
|
|
4
|
-
import userEvent from
|
|
5
|
-
import { Toggle } from
|
|
1
|
+
import React, { useEffect, useRef } from "react";
|
|
2
|
+
import { Checkbox, Props } from "./Checkbox";
|
|
3
|
+
import { render } from "@testing-library/react";
|
|
4
|
+
import userEvent from "@testing-library/user-event";
|
|
5
|
+
import { Toggle } from "../Toggle/Toggle";
|
|
6
6
|
|
|
7
7
|
const onChangeHandler = jest.fn();
|
|
8
8
|
|
|
9
9
|
const defaultParams: Props = {
|
|
10
|
-
name:
|
|
11
|
-
children:
|
|
12
|
-
helperText:
|
|
13
|
-
onChange: onChangeHandler
|
|
10
|
+
name: "Testing",
|
|
11
|
+
children: "checkbox content",
|
|
12
|
+
helperText: "example helper",
|
|
13
|
+
onChange: onChangeHandler
|
|
14
14
|
};
|
|
15
15
|
|
|
16
16
|
const createCheckbox = (params?: (defaultParams: Props) => Props) => {
|
|
@@ -19,25 +19,25 @@ const createCheckbox = (params?: (defaultParams: Props) => Props) => {
|
|
|
19
19
|
parameters = params(defaultParams);
|
|
20
20
|
}
|
|
21
21
|
const queries = render(<Checkbox {...parameters} data-testid="checkbox" />);
|
|
22
|
-
const checkbox = queries.getByTestId(
|
|
22
|
+
const checkbox = queries.getByTestId("checkbox");
|
|
23
23
|
|
|
24
24
|
return {
|
|
25
25
|
...queries,
|
|
26
|
-
checkbox
|
|
26
|
+
checkbox
|
|
27
27
|
};
|
|
28
28
|
};
|
|
29
29
|
|
|
30
|
-
describe(
|
|
31
|
-
it(
|
|
30
|
+
describe("Checkbox should render", () => {
|
|
31
|
+
it("renders without crashing", () => {
|
|
32
32
|
const { checkbox } = createCheckbox();
|
|
33
33
|
expect(checkbox).toBeTruthy();
|
|
34
34
|
});
|
|
35
35
|
});
|
|
36
36
|
|
|
37
|
-
describe(
|
|
38
|
-
it(
|
|
37
|
+
describe("ref should work", () => {
|
|
38
|
+
it("should give back the proper data prop, this also checks if the component propagates ...rest properly", () => {
|
|
39
39
|
const ExampleComponent = ({
|
|
40
|
-
propagateRef
|
|
40
|
+
propagateRef
|
|
41
41
|
}: {
|
|
42
42
|
propagateRef?: (ref: React.RefObject<HTMLElement>) => void;
|
|
43
43
|
}) => {
|
|
@@ -53,42 +53,42 @@ describe('ref should work', () => {
|
|
|
53
53
|
};
|
|
54
54
|
|
|
55
55
|
const refCheck = (ref: React.RefObject<HTMLElement>) => {
|
|
56
|
-
expect(ref.current).toHaveAttribute(
|
|
56
|
+
expect(ref.current).toHaveAttribute("data-ref", "testing");
|
|
57
57
|
};
|
|
58
58
|
|
|
59
59
|
render(<ExampleComponent propagateRef={refCheck} />);
|
|
60
60
|
});
|
|
61
61
|
});
|
|
62
62
|
|
|
63
|
-
describe(
|
|
64
|
-
it(
|
|
63
|
+
describe("Checkbox should have proper attributes", () => {
|
|
64
|
+
it("should be unchecked", () => {
|
|
65
65
|
const { checkbox } = createCheckbox();
|
|
66
66
|
|
|
67
|
-
expect(checkbox).toHaveAttribute(
|
|
67
|
+
expect(checkbox).toHaveAttribute("aria-checked", "false");
|
|
68
68
|
});
|
|
69
69
|
|
|
70
|
-
it(
|
|
71
|
-
const { checkbox } = createCheckbox(
|
|
70
|
+
it("should be checked", () => {
|
|
71
|
+
const { checkbox } = createCheckbox(defaultParams => ({ ...defaultParams, checked: true }));
|
|
72
72
|
|
|
73
|
-
expect(checkbox).toHaveAttribute(
|
|
73
|
+
expect(checkbox).toHaveAttribute("aria-checked", "true");
|
|
74
74
|
});
|
|
75
75
|
|
|
76
|
-
it(
|
|
76
|
+
it("should call the onChange function", () => {
|
|
77
77
|
const onChangeHandler = jest.fn();
|
|
78
|
-
const { checkbox } = createCheckbox(
|
|
78
|
+
const { checkbox } = createCheckbox(defaultParams => ({
|
|
79
79
|
...defaultParams,
|
|
80
|
-
onChange: onChangeHandler
|
|
80
|
+
onChange: onChangeHandler
|
|
81
81
|
}));
|
|
82
82
|
userEvent.click(checkbox);
|
|
83
83
|
expect(onChangeHandler).toHaveBeenCalled();
|
|
84
84
|
});
|
|
85
85
|
|
|
86
|
-
it(
|
|
86
|
+
it("should be disabled", () => {
|
|
87
87
|
const onChangeHandler = jest.fn();
|
|
88
|
-
const { checkbox } = createCheckbox(
|
|
88
|
+
const { checkbox } = createCheckbox(defaultParams => ({
|
|
89
89
|
...defaultParams,
|
|
90
90
|
onChange: onChangeHandler,
|
|
91
|
-
disabled: true
|
|
91
|
+
disabled: true
|
|
92
92
|
}));
|
|
93
93
|
|
|
94
94
|
expect(checkbox).toBeDisabled();
|
|
@@ -98,64 +98,64 @@ describe('Checkbox should have proper attributes', () => {
|
|
|
98
98
|
expect(onChangeHandler).not.toHaveBeenCalled();
|
|
99
99
|
});
|
|
100
100
|
|
|
101
|
-
it(
|
|
102
|
-
const { getByTestId } = createCheckbox(
|
|
101
|
+
it("nested checkbox should be disabled", () => {
|
|
102
|
+
const { getByTestId } = createCheckbox(defaultParams => ({
|
|
103
103
|
...defaultParams,
|
|
104
104
|
indeterminate: false,
|
|
105
|
-
label:
|
|
105
|
+
label: "test",
|
|
106
106
|
children: (
|
|
107
107
|
<Checkbox data-testid="nested-checkbox" name="test" disabled={true}>
|
|
108
108
|
test
|
|
109
109
|
</Checkbox>
|
|
110
|
-
)
|
|
110
|
+
)
|
|
111
111
|
}));
|
|
112
112
|
|
|
113
|
-
const nestedCheckbox = getByTestId(
|
|
113
|
+
const nestedCheckbox = getByTestId("nested-checkbox");
|
|
114
114
|
|
|
115
115
|
expect(nestedCheckbox).toBeDisabled();
|
|
116
116
|
});
|
|
117
117
|
|
|
118
|
-
it(
|
|
118
|
+
it("should have helpertext rendered", () => {
|
|
119
119
|
const { getByText } = createCheckbox();
|
|
120
120
|
|
|
121
|
-
const helperText = getByText(
|
|
121
|
+
const helperText = getByText("example helper");
|
|
122
122
|
|
|
123
123
|
expect(helperText).toBeTruthy();
|
|
124
124
|
});
|
|
125
125
|
|
|
126
|
-
it(
|
|
127
|
-
const { checkbox, container, getByTestId } = createCheckbox(
|
|
126
|
+
it("should have the error state enabled", () => {
|
|
127
|
+
const { checkbox, container, getByTestId } = createCheckbox(defaultParams => ({
|
|
128
128
|
...defaultParams,
|
|
129
129
|
error: true,
|
|
130
|
-
errorMessage:
|
|
131
|
-
formSelectorWrapperProps: {
|
|
130
|
+
errorMessage: "This is an error",
|
|
131
|
+
formSelectorWrapperProps: { "data-testid": "checkbox-wrapper" }
|
|
132
132
|
}));
|
|
133
133
|
|
|
134
134
|
expect(checkbox).toHaveAttribute(
|
|
135
|
-
|
|
136
|
-
container.querySelector(
|
|
135
|
+
"aria-describedby",
|
|
136
|
+
container.querySelector(".error-message span:last-of-type")!.id
|
|
137
137
|
);
|
|
138
138
|
|
|
139
|
-
expect(checkbox).toHaveAttribute(
|
|
140
|
-
expect(getByTestId(
|
|
139
|
+
expect(checkbox).toHaveAttribute("aria-invalid", "true");
|
|
140
|
+
expect(getByTestId("checkbox-wrapper")).toHaveClass("error");
|
|
141
141
|
});
|
|
142
142
|
|
|
143
|
-
it(
|
|
144
|
-
const { checkbox, container } = createCheckbox(
|
|
143
|
+
it("should have a correctly linked label element", () => {
|
|
144
|
+
const { checkbox, container } = createCheckbox(defaultParams => ({
|
|
145
145
|
...defaultParams,
|
|
146
|
-
children:
|
|
146
|
+
children: "Label"
|
|
147
147
|
}));
|
|
148
148
|
|
|
149
|
-
const id = checkbox.getAttribute(
|
|
149
|
+
const id = checkbox.getAttribute("id");
|
|
150
150
|
const label = container.querySelector(`label[for=${id}]`);
|
|
151
151
|
|
|
152
152
|
expect(label).toBeTruthy();
|
|
153
|
-
expect(label).toHaveTextContent(
|
|
153
|
+
expect(label).toHaveTextContent("Label");
|
|
154
154
|
});
|
|
155
155
|
});
|
|
156
156
|
|
|
157
|
-
describe(
|
|
158
|
-
it(
|
|
157
|
+
describe("Checkbox should be interactive", () => {
|
|
158
|
+
it("should call onChange when clicked", () => {
|
|
159
159
|
const { checkbox } = createCheckbox();
|
|
160
160
|
|
|
161
161
|
expect(onChangeHandler).not.toBeCalled();
|
|
@@ -163,24 +163,24 @@ describe('Checkbox should be interactive', () => {
|
|
|
163
163
|
expect(onChangeHandler).toBeCalledTimes(1);
|
|
164
164
|
});
|
|
165
165
|
|
|
166
|
-
it(
|
|
167
|
-
const { checkbox } = createCheckbox(
|
|
166
|
+
it("should not call onChange when disabled", () => {
|
|
167
|
+
const { checkbox } = createCheckbox(defaultParams => ({ ...defaultParams, disabled: true }));
|
|
168
168
|
|
|
169
169
|
userEvent.click(checkbox);
|
|
170
170
|
expect(onChangeHandler).not.toBeCalled();
|
|
171
171
|
});
|
|
172
172
|
});
|
|
173
173
|
|
|
174
|
-
describe(
|
|
175
|
-
it(
|
|
174
|
+
describe("toggle version", () => {
|
|
175
|
+
it("should turn into a toggle", () => {
|
|
176
176
|
const { container } = render(<Toggle name="toggle">Test</Toggle>);
|
|
177
177
|
|
|
178
|
-
expect(container.querySelector(
|
|
178
|
+
expect(container.querySelector("[data-toggle]")).toBeInTheDocument();
|
|
179
179
|
});
|
|
180
180
|
});
|
|
181
181
|
|
|
182
|
-
describe(
|
|
183
|
-
it(
|
|
182
|
+
describe("missing attributes gets us errors", () => {
|
|
183
|
+
it("throws an error for missing label prop", () => {
|
|
184
184
|
// Prevent throwing an error in the console when this test is executed. We fix this and the end of this test.
|
|
185
185
|
const err = console.error;
|
|
186
186
|
console.error = jest.fn();
|
|
@@ -189,24 +189,24 @@ describe('missing attributes gets us errors', () => {
|
|
|
189
189
|
|
|
190
190
|
try {
|
|
191
191
|
// @ts-ignore: mandatory props (test for non-typescript react projects)
|
|
192
|
-
createCheckbox(
|
|
192
|
+
createCheckbox(defaultParams => ({
|
|
193
193
|
...defaultParams,
|
|
194
|
-
name:
|
|
195
|
-
children: <Checkbox name="test">Test</Checkbox
|
|
194
|
+
name: "testing",
|
|
195
|
+
children: <Checkbox name="test">Test</Checkbox>
|
|
196
196
|
}));
|
|
197
197
|
} catch (e: any) {
|
|
198
198
|
actual = e.message;
|
|
199
199
|
}
|
|
200
200
|
|
|
201
201
|
const expected =
|
|
202
|
-
|
|
202
|
+
"If you pass Checkboxes as a child component (to create nested checkbox tree) you need to pass a label to the parent checkbox.";
|
|
203
203
|
|
|
204
204
|
expect(actual).toEqual(expected);
|
|
205
205
|
|
|
206
206
|
console.error = err;
|
|
207
207
|
});
|
|
208
208
|
|
|
209
|
-
it(
|
|
209
|
+
it("throws an error for indeterminate prop", () => {
|
|
210
210
|
// Prevent throwing an error in the console when this test is executed. We fix this and the end of this test.
|
|
211
211
|
const err = console.error;
|
|
212
212
|
console.error = jest.fn();
|
|
@@ -215,24 +215,24 @@ describe('missing attributes gets us errors', () => {
|
|
|
215
215
|
|
|
216
216
|
try {
|
|
217
217
|
// @ts-ignore: mandatory props (test for non-typescript react projects)
|
|
218
|
-
createCheckbox(
|
|
218
|
+
createCheckbox(defaultParams => ({
|
|
219
219
|
...defaultParams,
|
|
220
|
-
label:
|
|
221
|
-
children: <Checkbox name="test">Test</Checkbox
|
|
220
|
+
label: "testing",
|
|
221
|
+
children: <Checkbox name="test">Test</Checkbox>
|
|
222
222
|
}));
|
|
223
223
|
} catch (e: any) {
|
|
224
224
|
actual = e.message;
|
|
225
225
|
}
|
|
226
226
|
|
|
227
227
|
const expected =
|
|
228
|
-
|
|
228
|
+
"If you have nested checkboxes you have to manage the indeterminate state by passing a boolean to the `indeterminate` prop.";
|
|
229
229
|
|
|
230
230
|
expect(actual).toEqual(expected);
|
|
231
231
|
|
|
232
232
|
console.error = err;
|
|
233
233
|
});
|
|
234
234
|
|
|
235
|
-
it(
|
|
235
|
+
it("throws an error for incorrect children prop", () => {
|
|
236
236
|
// Prevent throwing an error in the console when this test is executed. We fix this and the end of this test.
|
|
237
237
|
const err = console.error;
|
|
238
238
|
console.error = jest.fn();
|
|
@@ -241,22 +241,22 @@ describe('missing attributes gets us errors', () => {
|
|
|
241
241
|
|
|
242
242
|
try {
|
|
243
243
|
// @ts-ignore: mandatory props (test for non-typescript react projects)
|
|
244
|
-
createCheckbox(
|
|
245
|
-
name: undefined
|
|
244
|
+
createCheckbox(defaultParams => ({
|
|
245
|
+
name: undefined
|
|
246
246
|
}));
|
|
247
247
|
} catch (e: any) {
|
|
248
248
|
actual = e.message;
|
|
249
249
|
}
|
|
250
250
|
|
|
251
251
|
const expected =
|
|
252
|
-
|
|
252
|
+
"Please make sure to pass either a string or more Checkbox components as a child of your Checkbox component.";
|
|
253
253
|
|
|
254
254
|
expect(actual).toEqual(expected);
|
|
255
255
|
|
|
256
256
|
console.error = err;
|
|
257
257
|
});
|
|
258
258
|
|
|
259
|
-
it(
|
|
259
|
+
it("throws an error for missing name prop", () => {
|
|
260
260
|
// Prevent throwing an error in the console when this test is executed. We fix this and the end of this test.
|
|
261
261
|
const err = console.error;
|
|
262
262
|
console.error = jest.fn();
|
|
@@ -265,8 +265,8 @@ describe('missing attributes gets us errors', () => {
|
|
|
265
265
|
|
|
266
266
|
try {
|
|
267
267
|
// @ts-ignore: mandatory props (test for non-typescript react projects)
|
|
268
|
-
createCheckbox(
|
|
269
|
-
children:
|
|
268
|
+
createCheckbox(defaultParams => ({
|
|
269
|
+
children: "test"
|
|
270
270
|
}));
|
|
271
271
|
} catch (e: any) {
|
|
272
272
|
actual = e.message;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import React, { ComponentPropsWithRef, ReactElement, ReactNode, useEffect } from
|
|
2
|
-
import { Icon, Icons } from
|
|
3
|
-
import { Props as FormHelperTextProps } from
|
|
4
|
-
import classes from
|
|
5
|
-
import { useFormSelector } from
|
|
1
|
+
import React, { ComponentPropsWithRef, ReactElement, ReactNode, useEffect } from "react";
|
|
2
|
+
import { Icon, Icons } from "../../Icon/Icon";
|
|
3
|
+
import { Props as FormHelperTextProps } from "../FormHelperText/FormHelperText";
|
|
4
|
+
import classes from "./Checkbox.module.scss";
|
|
5
|
+
import { useFormSelector } from "../../hooks/useFormSelector";
|
|
6
6
|
import {
|
|
7
7
|
FormSelectorWrapper,
|
|
8
|
-
Props as FormSelectorWrapperProps
|
|
9
|
-
} from
|
|
10
|
-
import { FormSelector } from
|
|
8
|
+
Props as FormSelectorWrapperProps
|
|
9
|
+
} from "../FormSelectorWrapper/FormSelectorWrapper";
|
|
10
|
+
import { FormSelector } from "../form.interfaces";
|
|
11
11
|
|
|
12
|
-
const isToggle = (children: ReactNode) => (children as ReactElement)?.props?.[
|
|
12
|
+
const isToggle = (children: ReactNode) => (children as ReactElement)?.props?.["data-toggle"];
|
|
13
13
|
|
|
14
|
-
export interface Props extends ComponentPropsWithRef<
|
|
14
|
+
export interface Props extends ComponentPropsWithRef<"input">, FormSelector {
|
|
15
15
|
children: ReactNode;
|
|
16
16
|
label?: string;
|
|
17
17
|
indeterminate?: boolean;
|
|
@@ -48,7 +48,7 @@ export const Checkbox = React.forwardRef<HTMLInputElement, Props>(
|
|
|
48
48
|
parentErrorId,
|
|
49
49
|
errorMessage,
|
|
50
50
|
error,
|
|
51
|
-
parentHelperId
|
|
51
|
+
parentHelperId
|
|
52
52
|
});
|
|
53
53
|
|
|
54
54
|
useEffect(() => {
|
|
@@ -56,9 +56,9 @@ export const Checkbox = React.forwardRef<HTMLInputElement, Props>(
|
|
|
56
56
|
throw new Error("Please pass a 'name' prop to your <Checkbox> component.");
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
if (typeof children ===
|
|
59
|
+
if (typeof children === "object" && !isToggle(children) && indeterminate === undefined) {
|
|
60
60
|
throw new Error(
|
|
61
|
-
|
|
61
|
+
"If you have nested checkboxes you have to manage the indeterminate state by passing a boolean to the `indeterminate` prop."
|
|
62
62
|
);
|
|
63
63
|
}
|
|
64
64
|
}, []);
|
|
@@ -68,22 +68,22 @@ export const Checkbox = React.forwardRef<HTMLInputElement, Props>(
|
|
|
68
68
|
return label;
|
|
69
69
|
} else if (children === undefined) {
|
|
70
70
|
throw new Error(
|
|
71
|
-
|
|
71
|
+
"Please make sure to pass either a string or more Checkbox components as a child of your Checkbox component."
|
|
72
72
|
);
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
if (typeof children ===
|
|
75
|
+
if (typeof children === "string") {
|
|
76
76
|
return children;
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
throw new Error(
|
|
80
|
-
|
|
80
|
+
"If you pass Checkboxes as a child component (to create nested checkbox tree) you need to pass a label to the parent checkbox."
|
|
81
81
|
);
|
|
82
82
|
};
|
|
83
83
|
|
|
84
84
|
const renderNestedCheckboxes = () => (
|
|
85
|
-
<ul className={classes[
|
|
86
|
-
{React.Children.map(children as ReactElement[],
|
|
85
|
+
<ul className={classes["checkbox-list"]}>
|
|
86
|
+
{React.Children.map(children as ReactElement[], child => {
|
|
87
87
|
return (
|
|
88
88
|
<li>
|
|
89
89
|
<Checkbox
|
|
@@ -110,14 +110,14 @@ export const Checkbox = React.forwardRef<HTMLInputElement, Props>(
|
|
|
110
110
|
|
|
111
111
|
const renderToggle = () => React.Children.toArray(children).filter(isToggle);
|
|
112
112
|
|
|
113
|
-
const iconClasses = [classes[
|
|
113
|
+
const iconClasses = [classes["input"], disabled ? classes["disabled"] : ""];
|
|
114
114
|
|
|
115
115
|
/** Default return value is the default checkbox */
|
|
116
116
|
return (
|
|
117
117
|
<FormSelectorWrapper
|
|
118
118
|
{...formSelectorWrapperProps}
|
|
119
|
-
className={`${classes[
|
|
120
|
-
containerProps={{ className: classes[
|
|
119
|
+
className={`${classes["checkbox-wrapper"]} ${className ? className : ""}`}
|
|
120
|
+
containerProps={{ className: classes["checkbox-container"] }}
|
|
121
121
|
helperText={helperText}
|
|
122
122
|
helperProps={helperProps}
|
|
123
123
|
parentErrorId={parentErrorId}
|
|
@@ -127,18 +127,18 @@ export const Checkbox = React.forwardRef<HTMLInputElement, Props>(
|
|
|
127
127
|
disabled={disabled}
|
|
128
128
|
identifier={identifier}
|
|
129
129
|
nestedChildren={
|
|
130
|
-
typeof children ===
|
|
130
|
+
typeof children === "object" && !isToggle(children) && renderNestedCheckboxes()
|
|
131
131
|
}
|
|
132
132
|
>
|
|
133
133
|
<input
|
|
134
134
|
{...rest}
|
|
135
135
|
ref={ref}
|
|
136
136
|
disabled={disabled}
|
|
137
|
-
className={`${classes[
|
|
137
|
+
className={`${classes["native-input"]} ${error ? classes["error"] : ""}`}
|
|
138
138
|
checked={checked}
|
|
139
139
|
onChange={onChangeHandler}
|
|
140
140
|
aria-invalid={error as boolean}
|
|
141
|
-
aria-checked={indeterminate ?
|
|
141
|
+
aria-checked={indeterminate ? "mixed" : checked}
|
|
142
142
|
aria-describedby={describedBy}
|
|
143
143
|
id={`${identifier}-checkbox`}
|
|
144
144
|
name={name}
|
|
@@ -146,12 +146,12 @@ export const Checkbox = React.forwardRef<HTMLInputElement, Props>(
|
|
|
146
146
|
/>
|
|
147
147
|
{renderToggle()}
|
|
148
148
|
|
|
149
|
-
{indeterminate && <Icon className={iconClasses.join(
|
|
149
|
+
{indeterminate && <Icon className={iconClasses.join(" ")} icon={Icons.MinusSquare} />}
|
|
150
150
|
{checked && !indeterminate && (
|
|
151
|
-
<Icon className={iconClasses.join(
|
|
151
|
+
<Icon className={iconClasses.join(" ")} icon={Icons.CheckmarkSquare} />
|
|
152
152
|
)}
|
|
153
153
|
{!checked && !indeterminate && (
|
|
154
|
-
<Icon className={iconClasses.join(
|
|
154
|
+
<Icon className={iconClasses.join(" ")} icon={Icons.Square} />
|
|
155
155
|
)}
|
|
156
156
|
<label htmlFor={`${identifier}-checkbox`}>{determineLabel()}</label>
|
|
157
157
|
</FormSelectorWrapper>
|