@onewelcome/react-lib-components 14.0.0-experiment.1 → 14.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Breadcrumbs/Breadcrumbs.module.scss.cjs.js +2 -2
- package/dist/components/Breadcrumbs/Breadcrumbs.module.scss.es.js +5 -5
- package/dist/components/Button/BaseButton.module.scss.cjs.js +2 -2
- package/dist/components/Button/BaseButton.module.scss.es.js +4 -4
- package/dist/components/Button/Button.cjs.js +1 -1
- package/dist/components/Button/Button.cjs.js.map +1 -1
- package/dist/components/Button/Button.es.js +11 -2
- package/dist/components/Button/Button.es.js.map +1 -1
- package/dist/components/Button/Button.module.scss.cjs.js +2 -2
- package/dist/components/Button/Button.module.scss.es.js +17 -17
- package/dist/components/Button/IconButton.module.scss.cjs.js +2 -2
- package/dist/components/Button/IconButton.module.scss.es.js +18 -18
- package/dist/components/ContextMenu/ContextMenu.cjs.js.map +1 -1
- package/dist/components/ContextMenu/ContextMenu.es.js.map +1 -1
- package/dist/components/ContextMenu/ContextMenu.module.scss.cjs.js +2 -2
- package/dist/components/ContextMenu/ContextMenu.module.scss.es.js +6 -6
- package/dist/components/ContextMenu/ContextMenuDivider.module.scss.cjs.js +2 -2
- package/dist/components/ContextMenu/ContextMenuDivider.module.scss.es.js +2 -2
- package/dist/components/ContextMenu/ContextMenuItem.cjs.js.map +1 -1
- package/dist/components/ContextMenu/ContextMenuItem.es.js.map +1 -1
- package/dist/components/ContextMenu/ContextMenuItem.module.scss.cjs.js +2 -2
- package/dist/components/ContextMenu/ContextMenuItem.module.scss.es.js +3 -3
- package/dist/components/ContextMenu/ContextMenuService.cjs.js +1 -1
- package/dist/components/ContextMenu/ContextMenuService.cjs.js.map +1 -1
- package/dist/components/ContextMenu/ContextMenuService.es.js +20 -17
- package/dist/components/ContextMenu/ContextMenuService.es.js.map +1 -1
- package/dist/components/DataGrid/DataGrid.cjs.js +1 -1
- package/dist/components/DataGrid/DataGrid.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGrid.es.js +102 -59
- package/dist/components/DataGrid/DataGrid.es.js.map +1 -1
- package/dist/components/DataGrid/DataGrid.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGrid.module.scss.es.js +8 -6
- package/dist/components/DataGrid/DataGrid.module.scss.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridActions/DataGridActions.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridActions/DataGridActions.module.scss.es.js +6 -6
- package/dist/components/DataGrid/DataGridActions/DataGridColumnsToggle.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridActions/DataGridColumnsToggle.module.scss.es.js +7 -7
- package/dist/components/DataGrid/DataGridBody/DataGridBody.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridBody.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridBody.es.js +4 -2
- package/dist/components/DataGrid/DataGridBody/DataGridBody.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridBody.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridBody/DataGridBody.module.scss.es.js +2 -2
- package/dist/components/DataGrid/DataGridBody/DataGridCell/DataGridCell.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridBody/DataGridCell/DataGridCell.module.scss.es.js +5 -5
- package/dist/components/DataGrid/DataGridBody/DataGridDrawer/DataGridDrawer.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridBody/DataGridDrawer/DataGridDrawer.module.scss.es.js +4 -4
- package/dist/components/DataGrid/DataGridBody/DataGridDrawer/DataGridDrawerItem.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridBody/DataGridDrawer/DataGridDrawerItem.module.scss.es.js +5 -5
- package/dist/components/DataGrid/DataGridBody/DataGridRow/DataGridRow.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridRow/DataGridRow.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridRow/DataGridRow.es.js +2 -1
- package/dist/components/DataGrid/DataGridBody/DataGridRow/DataGridRow.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridRow/DataGridRow.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridBody/DataGridRow/DataGridRow.module.scss.es.js +24 -24
- package/dist/components/DataGrid/DataGridBody/DataGridRow/useNestedRow.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridRow/useNestedRow.es.js +1 -1
- package/dist/components/DataGrid/DataGridBody/DataGridRow/useNestedRow.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilter.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilter.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilter.es.js +4 -4
- package/dist/components/DataGrid/DataGridFilters/DataGridFilter.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilter.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridFilters/DataGridFilter.module.scss.es.js +9 -9
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterPopover.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterPopover.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterService.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterService.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterService.es.js +17 -21
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterService.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterTag.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterTag.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterTag.es.js +15 -4
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterTag.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterValueSelect.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterValueSelect.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterValueSelect.es.js +54 -6
- package/dist/components/DataGrid/DataGridFilters/DataGridFilterValueSelect.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilters.interfaces.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridFilters.interfaces.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridToolbar.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridToolbar.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridToolbar.es.js +4 -4
- package/dist/components/DataGrid/DataGridFilters/DataGridToolbar.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DataGridToolbar.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridFilters/DataGridToolbar.module.scss.es.js +10 -10
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePicker.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePicker.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePicker.es.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePicker.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePicker.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePicker.module.scss.es.js +17 -17
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePickerCalendarSection.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePickerCalendarSection.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePickerCalendarSection.es.js +45 -24
- package/dist/components/DataGrid/DataGridFilters/DateTimePicker/DateTimePickerCalendarSection.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/useFiltersReducer.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridFilters/useFiltersReducer.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridFilters/useFiltersReducer.es.js +7 -9
- package/dist/components/DataGrid/DataGridFilters/useFiltersReducer.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.es.js +6 -2
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.module.scss.es.js +7 -4
- package/dist/components/DataGrid/DataGridHeader/DataGridHeader.module.scss.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.cjs.js +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.cjs.js.map +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.es.js +14 -12
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.es.js.map +1 -1
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.module.scss.cjs.js +2 -2
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.module.scss.es.js +11 -10
- package/dist/components/DataGrid/DataGridHeader/DataGridHeaderCell.module.scss.es.js.map +1 -1
- package/dist/components/DatePicker/DatePicker.module.scss.cjs.js +2 -2
- package/dist/components/DatePicker/DatePicker.module.scss.es.js +31 -31
- package/dist/components/Form/Checkbox/Checkbox.cjs.js.map +1 -1
- package/dist/components/Form/Checkbox/Checkbox.es.js.map +1 -1
- package/dist/components/Form/Checkbox/Checkbox.module.scss.cjs.js +2 -2
- package/dist/components/Form/Checkbox/Checkbox.module.scss.es.js +13 -13
- package/dist/components/Form/Fieldset/Fieldset.cjs.js +1 -1
- package/dist/components/Form/Fieldset/Fieldset.cjs.js.map +1 -1
- package/dist/components/Form/Fieldset/Fieldset.es.js +3 -2
- package/dist/components/Form/Fieldset/Fieldset.es.js.map +1 -1
- package/dist/components/Form/Fieldset/Fieldset.module.scss.cjs.js +2 -2
- package/dist/components/Form/Fieldset/Fieldset.module.scss.es.js +8 -5
- package/dist/components/Form/Fieldset/Fieldset.module.scss.es.js.map +1 -1
- package/dist/components/Form/FileUpload/FileItem/FileItem.cjs.js +1 -1
- package/dist/components/Form/FileUpload/FileItem/FileItem.cjs.js.map +1 -1
- package/dist/components/Form/FileUpload/FileItem/FileItem.es.js +1 -1
- package/dist/components/Form/FileUpload/FileItem/FileItem.es.js.map +1 -1
- package/dist/components/Form/FileUpload/FileItem/FileItem.module.scss.cjs.js +2 -2
- package/dist/components/Form/FileUpload/FileItem/FileItem.module.scss.es.js +18 -18
- package/dist/components/Form/FileUpload/FileUpload.cjs.js +1 -1
- package/dist/components/Form/FileUpload/FileUpload.cjs.js.map +1 -1
- package/dist/components/Form/FileUpload/FileUpload.es.js +6 -6
- package/dist/components/Form/FileUpload/FileUpload.es.js.map +1 -1
- package/dist/components/Form/FileUpload/FileUpload.module.scss.cjs.js +2 -2
- package/dist/components/Form/FileUpload/FileUpload.module.scss.es.js +16 -16
- package/dist/components/Form/Form.module.scss.cjs.js +2 -2
- package/dist/components/Form/Form.module.scss.es.js +2 -2
- package/dist/components/Form/FormControl/FormControl.cjs.js +1 -1
- package/dist/components/Form/FormControl/FormControl.cjs.js.map +1 -1
- package/dist/components/Form/FormControl/FormControl.es.js +3 -3
- package/dist/components/Form/FormControl/FormControl.es.js.map +1 -1
- package/dist/components/Form/FormControl/FormControl.module.scss.cjs.js +2 -2
- package/dist/components/Form/FormControl/FormControl.module.scss.es.js +13 -13
- package/dist/components/Form/FormErrorText/FormErrorText.module.scss.cjs.js +2 -2
- package/dist/components/Form/FormErrorText/FormErrorText.module.scss.es.js +9 -6
- package/dist/components/Form/FormErrorText/FormErrorText.module.scss.es.js.map +1 -1
- package/dist/components/Form/FormGroup/FormGroup.cjs.js.map +1 -1
- package/dist/components/Form/FormGroup/FormGroup.es.js.map +1 -1
- package/dist/components/Form/FormGroup/FormGroup.module.scss.cjs.js +2 -2
- package/dist/components/Form/FormGroup/FormGroup.module.scss.es.js +3 -3
- package/dist/components/Form/FormHelperText/FormHelperText.module.scss.cjs.js +2 -2
- package/dist/components/Form/FormHelperText/FormHelperText.module.scss.es.js +4 -4
- package/dist/components/Form/FormSelectorWrapper/FormSelectorWrapper.cjs.js +1 -1
- package/dist/components/Form/FormSelectorWrapper/FormSelectorWrapper.cjs.js.map +1 -1
- package/dist/components/Form/FormSelectorWrapper/FormSelectorWrapper.es.js +4 -1
- package/dist/components/Form/FormSelectorWrapper/FormSelectorWrapper.es.js.map +1 -1
- package/dist/components/Form/FormSelectorWrapper/FormSelectorWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/FormSelectorWrapper/FormSelectorWrapper.module.scss.es.js +6 -6
- package/dist/components/Form/Input/Input.cjs.js +1 -1
- package/dist/components/Form/Input/Input.cjs.js.map +1 -1
- package/dist/components/Form/Input/Input.es.js +48 -5
- package/dist/components/Form/Input/Input.es.js.map +1 -1
- package/dist/components/Form/Input/Input.module.scss.cjs.js +2 -2
- package/dist/components/Form/Input/Input.module.scss.es.js +8 -8
- package/dist/components/Form/Label/Label.module.scss.cjs.js +2 -2
- package/dist/components/Form/Label/Label.module.scss.es.js +2 -2
- package/dist/components/Form/Radio/Radio.cjs.js.map +1 -1
- package/dist/components/Form/Radio/Radio.es.js +1 -1
- package/dist/components/Form/Radio/Radio.es.js.map +1 -1
- package/dist/components/Form/Radio/Radio.module.scss.cjs.js +2 -2
- package/dist/components/Form/Radio/Radio.module.scss.es.js +11 -11
- package/dist/components/Form/Select/MultiSelect/MultiOption.cjs.js +1 -1
- package/dist/components/Form/Select/MultiSelect/MultiOption.cjs.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/MultiOption.es.js +11 -10
- package/dist/components/Form/Select/MultiSelect/MultiOption.es.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/MultiSelect.cjs.js +1 -1
- package/dist/components/Form/Select/MultiSelect/MultiSelect.cjs.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/MultiSelect.es.js +236 -57
- package/dist/components/Form/Select/MultiSelect/MultiSelect.es.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/MultiSelect.module.scss.cjs.js +2 -2
- package/dist/components/Form/Select/MultiSelect/MultiSelect.module.scss.es.js +20 -15
- package/dist/components/Form/Select/MultiSelect/MultiSelect.module.scss.es.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/SelectButton.module.scss.cjs.js +2 -2
- package/dist/components/Form/Select/MultiSelect/SelectButton.module.scss.es.js +2 -2
- package/dist/components/Form/Select/MultiSelect/SelectedOptions.cjs.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/SelectedOptions.es.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/SelectedOptions.module.scss.cjs.js +2 -2
- package/dist/components/Form/Select/MultiSelect/SelectedOptions.module.scss.es.js +4 -4
- package/dist/components/Form/Select/MultiSelect/useArrowNavigation.cjs.js +1 -1
- package/dist/components/Form/Select/MultiSelect/useArrowNavigation.cjs.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/useArrowNavigation.es.js +134 -32
- package/dist/components/Form/Select/MultiSelect/useArrowNavigation.es.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/useSearch.cjs.js +1 -1
- package/dist/components/Form/Select/MultiSelect/useSearch.cjs.js.map +1 -1
- package/dist/components/Form/Select/MultiSelect/useSearch.es.js +73 -55
- package/dist/components/Form/Select/MultiSelect/useSearch.es.js.map +1 -1
- package/dist/components/Form/Select/Select.interfaces.cjs.js.map +1 -1
- package/dist/components/Form/Select/Select.interfaces.es.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/Option.cjs.js +1 -1
- package/dist/components/Form/Select/SingleSelect/Option.cjs.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/Option.es.js +16 -9
- package/dist/components/Form/Select/SingleSelect/Option.es.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/Select.cjs.js +1 -1
- package/dist/components/Form/Select/SingleSelect/Select.cjs.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/Select.es.js +202 -46
- package/dist/components/Form/Select/SingleSelect/Select.es.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/Select.module.scss.cjs.js +2 -2
- package/dist/components/Form/Select/SingleSelect/Select.module.scss.es.js +21 -17
- package/dist/components/Form/Select/SingleSelect/Select.module.scss.es.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/useArrowNavigation.cjs.js +1 -1
- package/dist/components/Form/Select/SingleSelect/useArrowNavigation.cjs.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/useArrowNavigation.es.js +176 -89
- package/dist/components/Form/Select/SingleSelect/useArrowNavigation.es.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/useSearch.cjs.js +1 -1
- package/dist/components/Form/Select/SingleSelect/useSearch.cjs.js.map +1 -1
- package/dist/components/Form/Select/SingleSelect/useSearch.es.js +48 -36
- package/dist/components/Form/Select/SingleSelect/useSearch.es.js.map +1 -1
- package/dist/components/Form/Select/useAddNewBtn.cjs.js +1 -1
- package/dist/components/Form/Select/useAddNewBtn.cjs.js.map +1 -1
- package/dist/components/Form/Select/useAddNewBtn.es.js +8 -6
- package/dist/components/Form/Select/useAddNewBtn.es.js.map +1 -1
- package/dist/components/Form/Select/useAddNewBtn.module.scss.cjs.js +2 -2
- package/dist/components/Form/Select/useAddNewBtn.module.scss.es.js +4 -4
- package/dist/components/Form/Select/useBaseSearch.cjs.js +2 -0
- package/dist/components/Form/Select/useBaseSearch.cjs.js.map +1 -0
- package/dist/components/Form/Select/useBaseSearch.es.js +85 -0
- package/dist/components/Form/Select/useBaseSearch.es.js.map +1 -0
- package/dist/components/Form/Select/useSelectPositionList.cjs.js +1 -1
- package/dist/components/Form/Select/useSelectPositionList.cjs.js.map +1 -1
- package/dist/components/Form/Select/useSelectPositionList.es.js +18 -5
- package/dist/components/Form/Select/useSelectPositionList.es.js.map +1 -1
- package/dist/components/Form/Textarea/Textarea.cjs.js +1 -1
- package/dist/components/Form/Textarea/Textarea.cjs.js.map +1 -1
- package/dist/components/Form/Textarea/Textarea.es.js +4 -0
- package/dist/components/Form/Textarea/Textarea.es.js.map +1 -1
- package/dist/components/Form/Textarea/Textarea.module.scss.cjs.js +2 -2
- package/dist/components/Form/Textarea/Textarea.module.scss.es.js +6 -6
- package/dist/components/Form/Toggle/Toggle.cjs.js +1 -1
- package/dist/components/Form/Toggle/Toggle.cjs.js.map +1 -1
- package/dist/components/Form/Toggle/Toggle.es.js +5 -3
- package/dist/components/Form/Toggle/Toggle.es.js.map +1 -1
- package/dist/components/Form/Toggle/Toggle.module.scss.cjs.js +2 -2
- package/dist/components/Form/Toggle/Toggle.module.scss.es.js +18 -18
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.cjs.js +1 -1
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.cjs.js.map +1 -1
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.es.js +25 -17
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.es.js.map +1 -1
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.module.scss.es.js +8 -4
- package/dist/components/Form/Wrapper/CheckboxWrapper/CheckboxWrapper.module.scss.es.js.map +1 -1
- package/dist/components/Form/Wrapper/InputWrapper/InputWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/InputWrapper/InputWrapper.module.scss.es.js +5 -5
- package/dist/components/Form/Wrapper/MultiSelectWrapper/MultiSelectWrapper.cjs.js.map +1 -1
- package/dist/components/Form/Wrapper/MultiSelectWrapper/MultiSelectWrapper.es.js.map +1 -1
- package/dist/components/Form/Wrapper/MultiSelectWrapper/MultiSelectWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/MultiSelectWrapper/MultiSelectWrapper.module.scss.es.js +3 -3
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.cjs.js +1 -1
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.cjs.js.map +1 -1
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.es.js +41 -22
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.es.js.map +1 -1
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.module.scss.es.js +8 -4
- package/dist/components/Form/Wrapper/RadioWrapper/RadioWrapper.module.scss.es.js.map +1 -1
- package/dist/components/Form/Wrapper/SelectWrapper/SelectWrapper.cjs.js.map +1 -1
- package/dist/components/Form/Wrapper/SelectWrapper/SelectWrapper.es.js.map +1 -1
- package/dist/components/Form/Wrapper/SelectWrapper/SelectWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/SelectWrapper/SelectWrapper.module.scss.es.js +3 -3
- package/dist/components/Form/Wrapper/TextareaWrapper/TextareaWrapper.cjs.js +1 -1
- package/dist/components/Form/Wrapper/TextareaWrapper/TextareaWrapper.cjs.js.map +1 -1
- package/dist/components/Form/Wrapper/TextareaWrapper/TextareaWrapper.es.js +2 -0
- package/dist/components/Form/Wrapper/TextareaWrapper/TextareaWrapper.es.js.map +1 -1
- package/dist/components/Form/Wrapper/TextareaWrapper/TextareaWrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/TextareaWrapper/TextareaWrapper.module.scss.es.js +8 -8
- package/dist/components/Form/Wrapper/Wrapper/Wrapper.cjs.js +1 -1
- package/dist/components/Form/Wrapper/Wrapper/Wrapper.cjs.js.map +1 -1
- package/dist/components/Form/Wrapper/Wrapper/Wrapper.es.js +1 -1
- package/dist/components/Form/Wrapper/Wrapper/Wrapper.es.js.map +1 -1
- package/dist/components/Form/Wrapper/Wrapper/Wrapper.module.scss.cjs.js +2 -2
- package/dist/components/Form/Wrapper/Wrapper/Wrapper.module.scss.es.js +6 -6
- package/dist/components/Icon/Icon.cjs.js +1 -1
- package/dist/components/Icon/Icon.cjs.js.map +1 -1
- package/dist/components/Icon/Icon.es.js +3 -1
- package/dist/components/Icon/Icon.es.js.map +1 -1
- package/dist/components/Icon/Icon.module.scss.cjs.js +2 -2
- package/dist/components/Icon/Icon.module.scss.es.js +109 -107
- package/dist/components/Icon/Icon.module.scss.es.js.map +1 -1
- package/dist/components/Layout/ActionBar/ActionBar.cjs.js +2 -0
- package/dist/components/Layout/ActionBar/ActionBar.cjs.js.map +1 -0
- package/dist/components/Layout/ActionBar/ActionBar.es.js +122 -0
- package/dist/components/Layout/ActionBar/ActionBar.es.js.map +1 -0
- package/dist/components/Layout/ActionBar/ActionBar.module.scss.cjs.js +3 -0
- package/dist/components/Layout/ActionBar/ActionBar.module.scss.cjs.js.map +1 -0
- package/dist/components/Layout/ActionBar/ActionBar.module.scss.es.js +24 -0
- package/dist/components/Layout/ActionBar/ActionBar.module.scss.es.js.map +1 -0
- package/dist/components/Layout/Card/Card.module.scss.cjs.js +2 -2
- package/dist/components/Layout/Card/Card.module.scss.es.js +12 -12
- package/dist/components/Layout/ContentHeader/ContentHeader.cjs.js +1 -1
- package/dist/components/Layout/ContentHeader/ContentHeader.cjs.js.map +1 -1
- package/dist/components/Layout/ContentHeader/ContentHeader.es.js +66 -41
- package/dist/components/Layout/ContentHeader/ContentHeader.es.js.map +1 -1
- package/dist/components/Layout/ContentHeader/ContentHeader.module.scss.cjs.js +2 -2
- package/dist/components/Layout/ContentHeader/ContentHeader.module.scss.es.js +28 -13
- package/dist/components/Layout/ContentHeader/ContentHeader.module.scss.es.js.map +1 -1
- package/dist/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.scss.cjs.js +2 -2
- package/dist/components/Layout/FormPage/FormWithStepper/FormSection/FormSection.module.scss.es.js +4 -4
- package/dist/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.scss.cjs.js +2 -2
- package/dist/components/Layout/FormPage/FormWithStepper/FormStepper/FormStepper.module.scss.es.js +2 -2
- package/dist/components/Layout/FormPage/FormWithStepper/FormWithStepper.module.scss.cjs.js +2 -2
- package/dist/components/Layout/FormPage/FormWithStepper/FormWithStepper.module.scss.es.js +3 -3
- package/dist/components/Link/Link.cjs.js.map +1 -1
- package/dist/components/Link/Link.es.js +1 -1
- package/dist/components/Link/Link.es.js.map +1 -1
- package/dist/components/Link/Link.module.scss.cjs.js +2 -2
- package/dist/components/Link/Link.module.scss.es.js +17 -17
- package/dist/components/Notifications/Alert/AlertContainer/AlertContainer.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/Alert/AlertContainer/AlertContainer.module.scss.es.js +11 -11
- package/dist/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.cjs.js +1 -1
- package/dist/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.cjs.js.map +1 -1
- package/dist/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.es.js +7 -1
- package/dist/components/Notifications/Alert/AlertContainer/useAlertContainerHeightAnimation.es.js.map +1 -1
- package/dist/components/Notifications/Alert/AlertItem/AlertItem.cjs.js +1 -1
- package/dist/components/Notifications/Alert/AlertItem/AlertItem.cjs.js.map +1 -1
- package/dist/components/Notifications/Alert/AlertItem/AlertItem.es.js +1 -1
- package/dist/components/Notifications/Alert/AlertItem/AlertItem.es.js.map +1 -1
- package/dist/components/Notifications/Alert/AlertItem/AlertItem.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/Alert/AlertItem/AlertItem.module.scss.es.js +22 -22
- package/dist/components/Notifications/Banner/Banner.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/Banner/Banner.module.scss.es.js +9 -9
- package/dist/components/Notifications/BaseModal/BaseModal.cjs.js +1 -1
- package/dist/components/Notifications/BaseModal/BaseModal.cjs.js.map +1 -1
- package/dist/components/Notifications/BaseModal/BaseModal.es.js +1 -1
- package/dist/components/Notifications/BaseModal/BaseModal.es.js.map +1 -1
- package/dist/components/Notifications/BaseModal/BaseModal.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/BaseModal/BaseModal.module.scss.es.js +5 -5
- package/dist/components/Notifications/BaseModal/BaseModalActions/BaseModalActions.cjs.js.map +1 -1
- package/dist/components/Notifications/BaseModal/BaseModalActions/BaseModalActions.es.js.map +1 -1
- package/dist/components/Notifications/BaseModal/BaseModalActions/BaseModalActions.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/BaseModal/BaseModalActions/BaseModalActions.module.scss.es.js +4 -4
- package/dist/components/Notifications/BaseModal/BaseModalContent/BaseModalContent.cjs.js.map +1 -1
- package/dist/components/Notifications/BaseModal/BaseModalContent/BaseModalContent.es.js.map +1 -1
- package/dist/components/Notifications/BaseModal/BaseModalContent/BaseModalContent.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/BaseModal/BaseModalContent/BaseModalContent.module.scss.es.js +2 -2
- package/dist/components/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/BaseModal/BaseModalHeader/BaseModalHeader.module.scss.es.js +6 -6
- package/dist/components/Notifications/Dialog/Dialog.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/Dialog/Dialog.module.scss.es.js +4 -4
- package/dist/components/Notifications/Dialog/DialogActions/DialogActions.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/Dialog/DialogActions/DialogActions.module.scss.es.js +3 -3
- package/dist/components/Notifications/Dialog/DialogTitle/DialogTitle.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/Dialog/DialogTitle/DialogTitle.module.scss.es.js +10 -10
- package/dist/components/Notifications/DiscardChangesModal/DiscardChangesModal.cjs.js.map +1 -1
- package/dist/components/Notifications/DiscardChangesModal/DiscardChangesModal.es.js.map +1 -1
- package/dist/components/Notifications/SideSheet/SideSheet.cjs.js.map +1 -1
- package/dist/components/Notifications/SideSheet/SideSheet.es.js +1 -1
- package/dist/components/Notifications/SideSheet/SideSheet.es.js.map +1 -1
- package/dist/components/Notifications/SideSheet/SideSheet.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/SideSheet/SideSheet.module.scss.es.js +13 -13
- package/dist/components/Notifications/SideSheet/SideSheetContent/SideSheetContent.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/SideSheet/SideSheetContent/SideSheetContent.module.scss.es.js +2 -2
- package/dist/components/Notifications/SideSheet/SideSheetHeader/SideSheetHeader.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/SideSheet/SideSheetHeader/SideSheetHeader.module.scss.es.js +2 -2
- package/dist/components/Notifications/SlideInModal/SlideInModal.cjs.js.map +1 -1
- package/dist/components/Notifications/SlideInModal/SlideInModal.es.js +1 -1
- package/dist/components/Notifications/SlideInModal/SlideInModal.es.js.map +1 -1
- package/dist/components/Notifications/SlideInModal/SlideInModal.module.scss.cjs.js +2 -2
- package/dist/components/Notifications/SlideInModal/SlideInModal.module.scss.es.js +10 -10
- package/dist/components/Pagination/Pagination.cjs.js +1 -1
- package/dist/components/Pagination/Pagination.cjs.js.map +1 -1
- package/dist/components/Pagination/Pagination.es.js +118 -90
- package/dist/components/Pagination/Pagination.es.js.map +1 -1
- package/dist/components/Pagination/Pagination.module.scss.cjs.js +2 -2
- package/dist/components/Pagination/Pagination.module.scss.es.js +15 -14
- package/dist/components/Pagination/Pagination.module.scss.es.js.map +1 -1
- package/dist/components/Popover/Popover.cjs.js.map +1 -1
- package/dist/components/Popover/Popover.es.js.map +1 -1
- package/dist/components/Popover/Popover.module.scss.cjs.js +2 -2
- package/dist/components/Popover/Popover.module.scss.es.js +3 -3
- package/dist/components/ProgressBar/ProgressBar.cjs.js.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.es.js.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.module.scss.cjs.js +2 -2
- package/dist/components/ProgressBar/ProgressBar.module.scss.es.js +9 -9
- package/dist/components/Skeleton/Skeleton.module.scss.cjs.js +2 -2
- package/dist/components/Skeleton/Skeleton.module.scss.es.js +5 -5
- package/dist/components/Spinner/Spinner.module.scss.cjs.js +2 -2
- package/dist/components/Spinner/Spinner.module.scss.es.js +3 -3
- package/dist/components/Stepper/Step.module.scss.cjs.js +2 -2
- package/dist/components/Stepper/Step.module.scss.es.js +22 -22
- package/dist/components/Stepper/Stepper.module.scss.cjs.js +2 -2
- package/dist/components/Stepper/Stepper.module.scss.es.js +4 -4
- package/dist/components/Tabs/Tab.module.scss.cjs.js +2 -2
- package/dist/components/Tabs/Tab.module.scss.es.js +3 -3
- package/dist/components/Tabs/TabButton.cjs.js.map +1 -1
- package/dist/components/Tabs/TabButton.es.js.map +1 -1
- package/dist/components/Tabs/TabButton.module.scss.cjs.js +2 -2
- package/dist/components/Tabs/TabButton.module.scss.es.js +12 -12
- package/dist/components/Tabs/Tabs.cjs.js +1 -1
- package/dist/components/Tabs/Tabs.cjs.js.map +1 -1
- package/dist/components/Tabs/Tabs.es.js +1 -1
- package/dist/components/Tabs/Tabs.es.js.map +1 -1
- package/dist/components/Tabs/Tabs.module.scss.cjs.js +2 -2
- package/dist/components/Tabs/Tabs.module.scss.es.js +10 -10
- package/dist/components/Tag/RemoveButton.module.scss.cjs.js +2 -2
- package/dist/components/Tag/RemoveButton.module.scss.es.js +3 -3
- package/dist/components/Tag/Tag.cjs.js +1 -1
- package/dist/components/Tag/Tag.cjs.js.map +1 -1
- package/dist/components/Tag/Tag.es.js +7 -1
- package/dist/components/Tag/Tag.es.js.map +1 -1
- package/dist/components/Tag/Tag.module.scss.cjs.js +2 -2
- package/dist/components/Tag/Tag.module.scss.es.js +6 -6
- package/dist/components/TextEllipsis/TextEllipsis.cjs.js.map +1 -1
- package/dist/components/TextEllipsis/TextEllipsis.es.js.map +1 -1
- package/dist/components/TextEllipsis/TextEllipsis.module.scss.cjs.js +2 -2
- package/dist/components/TextEllipsis/TextEllipsis.module.scss.es.js +3 -3
- package/dist/components/Tiles/Tile.cjs.js.map +1 -1
- package/dist/components/Tiles/Tile.es.js.map +1 -1
- package/dist/components/Tiles/Tile.module.scss.cjs.js +2 -2
- package/dist/components/Tiles/Tile.module.scss.es.js +8 -8
- package/dist/components/Tiles/Tiles.module.scss.cjs.js +2 -2
- package/dist/components/Tiles/Tiles.module.scss.es.js +2 -2
- package/dist/components/Tooltip/Tooltip.cjs.js +1 -1
- package/dist/components/Tooltip/Tooltip.cjs.js.map +1 -1
- package/dist/components/Tooltip/Tooltip.es.js +47 -39
- package/dist/components/Tooltip/Tooltip.es.js.map +1 -1
- package/dist/components/Tooltip/Tooltip.module.scss.cjs.js +2 -2
- package/dist/components/Tooltip/Tooltip.module.scss.es.js +28 -27
- package/dist/components/Tooltip/Tooltip.module.scss.es.js.map +1 -1
- package/dist/components/Typography/Typography.module.scss.cjs.js +2 -2
- package/dist/components/Typography/Typography.module.scss.es.js +13 -13
- package/dist/components/_BaseStyling_/BaseStyling.cjs.js +2 -1
- package/dist/components/_BaseStyling_/BaseStyling.cjs.js.map +1 -1
- package/dist/components/_BaseStyling_/BaseStyling.es.js +3 -3
- package/dist/components/_BaseStyling_/BaseStyling.es.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNav.cjs.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNav.es.js +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNav.es.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNav.module.scss.cjs.js +2 -2
- package/dist/components/admin/layout/LeftNav/LeftNav.module.scss.es.js +5 -5
- package/dist/components/admin/layout/LeftNav/LeftNavItem/ButtonLeftNavItem.cjs.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNavItem/ButtonLeftNavItem.es.js +3 -1
- package/dist/components/admin/layout/LeftNav/LeftNavItem/ButtonLeftNavItem.es.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNavItem/LeftNavItem.module.scss.cjs.js +2 -2
- package/dist/components/admin/layout/LeftNav/LeftNavItem/LeftNavItem.module.scss.es.js +14 -14
- package/dist/components/admin/layout/LeftNav/LeftNavItem/LinkLeftNavItem.cjs.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/LeftNavItem/LinkLeftNavItem.es.js +6 -2
- package/dist/components/admin/layout/LeftNav/LeftNavItem/LinkLeftNavItem.es.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/useRefItems.cjs.js +1 -1
- package/dist/components/admin/layout/LeftNav/useRefItems.cjs.js.map +1 -1
- package/dist/components/admin/layout/LeftNav/useRefItems.es.js +7 -6
- package/dist/components/admin/layout/LeftNav/useRefItems.es.js.map +1 -1
- package/dist/components/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.scss.cjs.js +2 -2
- package/dist/components/admin/layout/MicrofrontendContainer/MicrofrontendContainer.module.scss.es.js +3 -3
- package/dist/components/admin/layout/ProfileMenu/ProfileMenu.module.scss.cjs.js +2 -2
- package/dist/components/admin/layout/ProfileMenu/ProfileMenu.module.scss.es.js +7 -7
- package/dist/components/admin/layout/TopNavBar/TopNavBar.module.scss.cjs.js +2 -2
- package/dist/components/admin/layout/TopNavBar/TopNavBar.module.scss.es.js +13 -13
- package/dist/components/miscellaneous/IdentityProviderButton.cjs.js.map +1 -1
- package/dist/components/miscellaneous/IdentityProviderButton.es.js.map +1 -1
- package/dist/components/miscellaneous/IdentityProviderButton.module.scss.cjs.js +2 -2
- package/dist/components/miscellaneous/IdentityProviderButton.module.scss.es.js +3 -3
- package/dist/components/withReadOnly.cjs.js +1 -1
- package/dist/components/withReadOnly.cjs.js.map +1 -1
- package/dist/components/withReadOnly.es.js +2 -4
- package/dist/components/withReadOnly.es.js.map +1 -1
- package/dist/hooks/useClickOutside.cjs.js +1 -1
- package/dist/hooks/useClickOutside.cjs.js.map +1 -1
- package/dist/hooks/useClickOutside.es.js +1 -1
- package/dist/hooks/useClickOutside.es.js.map +1 -1
- package/dist/hooks/useDebouncedCallback.cjs.js +1 -1
- package/dist/hooks/useDebouncedCallback.cjs.js.map +1 -1
- package/dist/hooks/useDebouncedCallback.es.js +9 -2
- package/dist/hooks/useDebouncedCallback.es.js.map +1 -1
- package/dist/hooks/useGetDomRoot.cjs.js.map +1 -1
- package/dist/hooks/useGetDomRoot.es.js.map +1 -1
- package/dist/hooks/usePosition.cjs.js +1 -1
- package/dist/hooks/usePosition.cjs.js.map +1 -1
- package/dist/hooks/usePosition.es.js +105 -4
- package/dist/hooks/usePosition.es.js.map +1 -1
- package/dist/hooks/useRepeatFocus.cjs.js.map +1 -1
- package/dist/hooks/useRepeatFocus.es.js.map +1 -1
- package/dist/hooks/useScreenSize.cjs.js +1 -1
- package/dist/hooks/useScreenSize.cjs.js.map +1 -1
- package/dist/hooks/useScreenSize.es.js +1 -1
- package/dist/hooks/useScreenSize.es.js.map +1 -1
- package/dist/hooks/useStickyStacking.cjs.js +2 -0
- package/dist/hooks/useStickyStacking.cjs.js.map +1 -0
- package/dist/hooks/useStickyStacking.es.js +208 -0
- package/dist/hooks/useStickyStacking.es.js.map +1 -0
- package/dist/hooks/useUploadFile.cjs.js +1 -1
- package/dist/hooks/useUploadFile.cjs.js.map +1 -1
- package/dist/hooks/useUploadFile.es.js +1 -1
- package/dist/hooks/useUploadFile.es.js.map +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.d.ts +141 -29
- package/dist/index.es.js +4 -0
- package/dist/index.es.js.map +1 -1
- package/dist/node_modules/tabbable/dist/index.esm.cjs.js +1 -1
- package/dist/node_modules/tabbable/dist/index.esm.cjs.js.map +1 -1
- package/dist/node_modules/tabbable/dist/index.esm.es.js +4 -3
- package/dist/node_modules/tabbable/dist/index.esm.es.js.map +1 -1
- package/dist/readyclasses.module.scss.cjs.js +2 -2
- package/dist/readyclasses.module.scss.es.js +5 -5
- package/dist/util/helper.cjs.js +1 -1
- package/dist/util/helper.cjs.js.map +1 -1
- package/dist/util/helper.es.js +33 -16
- package/dist/util/helper.es.js.map +1 -1
- package/package.json +12 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Icon.module.scss.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Icon.module.scss.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react"),t=require("./ActionBar.module.scss.cjs.js");exports.ActionBar=({mode:a="inline",buttons:r,customButtons:s,statusText:n,customStatus:l,className:i,"aria-label":o="Action bar","data-testid":c="action-bar",...u})=>{const d=e.useRef(null),f=e.useRef(null),[m,b]=e.useState(!1),[v,E]=e.useState(0),p=e.useCallback(()=>{if(d.current){const e=d.current.offsetHeight;E(t=>t===e?t:e)}},[]);e.useEffect(()=>{if("sticky"!==a)return void b(!1);p();const e=f.current;if(!e)return;const t=(e=>{if(!e)return null;let t=e.parentElement;for(;t;){const e=getComputedStyle(t);if(/(auto|scroll)/.test(e.overflow+e.overflowY))return t;t=t.parentElement}return null})(e),r=new IntersectionObserver(([e])=>{b(!e.isIntersecting)},{threshold:0,root:t||null,rootMargin:"0px 0px 0px 0px"});return r.observe(e),()=>{r.disconnect()}},[a,p]),e.useEffect(()=>{"docked"===a&&p()},[a,p]),e.useEffect(()=>{if("docked"!==a&&"sticky"!==a)return;const e=()=>p();return window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)},[a,p]);const h=Boolean(r||s),g=Boolean(n||l),y=t.default[a],k="sticky"===a&&m?t.default["is-stuck"]:"",x=[t.default["action-bar"],y,k,i].filter(Boolean).join(" "),w=e.createElement("div",{ref:d,className:x,role:"toolbar","aria-label":o,"data-testid":c,...u},h&&e.createElement("div",{className:t.default["button-area"],"data-testid":`${c}-button-area`},s??r),g&&e.createElement("div",{className:t.default["status-area"],"data-testid":`${c}-status-area`},l??e.createElement("span",{className:t.default["status-text"]},n)));return"docked"===a?e.createElement(e.Fragment,null,e.createElement("div",{className:t.default.placeholder,style:{height:v},"data-testid":`${c}-placeholder`,"aria-hidden":"true"}),w):"sticky"===a?e.createElement(e.Fragment,null,w,e.createElement("div",{ref:f,style:{height:1,marginTop:-1,visibility:"hidden"},"data-testid":`${c}-sentinel`,"aria-hidden":"true"})):w};
|
|
2
|
+
//# sourceMappingURL=ActionBar.cjs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionBar.cjs.js","sources":["../../../../src/components/Layout/ActionBar/ActionBar.tsx"],"sourcesContent":["/*\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { HTMLAttributes, ReactNode, useCallback, useEffect, useRef, useState } from \"react\";\nimport classes from \"./ActionBar.module.scss\";\n\nexport type ActionBarMode = \"inline\" | \"docked\" | \"sticky\";\n\nexport interface ActionBarProps extends HTMLAttributes<HTMLDivElement> {\n mode?: ActionBarMode;\n buttons?: ReactNode;\n customButtons?: ReactNode;\n statusText?: ReactNode;\n customStatus?: ReactNode;\n \"aria-label\"?: string;\n \"data-testid\"?: string;\n}\n\nexport const ActionBar = ({\n mode = \"inline\",\n buttons,\n customButtons,\n statusText,\n customStatus,\n className,\n \"aria-label\": ariaLabel = \"Action bar\",\n \"data-testid\": testId = \"action-bar\",\n ...rest\n}: ActionBarProps) => {\n const barRef = useRef<HTMLDivElement>(null);\n const sentinelRef = useRef<HTMLDivElement>(null);\n const [isStuck, setIsStuck] = useState(false);\n const [barHeight, setBarHeight] = useState(0);\n\n const updateBarHeight = useCallback(() => {\n if (barRef.current) {\n const newHeight = barRef.current.offsetHeight;\n setBarHeight(prev => (prev === newHeight ? prev : newHeight));\n }\n }, []);\n\n useEffect(() => {\n if (mode !== \"sticky\") {\n setIsStuck(false);\n return;\n }\n\n updateBarHeight();\n\n const sentinel = sentinelRef.current;\n if (!sentinel) {\n return;\n }\n\n const findScrollParent = (el: HTMLElement | null): HTMLElement | null => {\n if (!el) {\n return null;\n }\n let parent = el.parentElement;\n while (parent) {\n const style = getComputedStyle(parent);\n if (/(auto|scroll)/.test(style.overflow + style.overflowY)) {\n return parent;\n }\n parent = parent.parentElement;\n }\n return null;\n };\n\n const scrollParent = findScrollParent(sentinel);\n\n const observer = new IntersectionObserver(\n ([entry]) => {\n setIsStuck(!entry.isIntersecting);\n },\n {\n threshold: 0,\n root: scrollParent || null,\n rootMargin: \"0px 0px 0px 0px\"\n }\n );\n\n observer.observe(sentinel);\n\n return () => {\n observer.disconnect();\n };\n }, [mode, updateBarHeight]);\n\n useEffect(() => {\n if (mode === \"docked\") {\n updateBarHeight();\n }\n }, [mode, updateBarHeight]);\n\n useEffect(() => {\n if (mode !== \"docked\" && mode !== \"sticky\") {\n return;\n }\n\n const handleResize = () => updateBarHeight();\n window.addEventListener(\"resize\", handleResize);\n return () => window.removeEventListener(\"resize\", handleResize);\n }, [mode, updateBarHeight]);\n\n const hasButtonArea = Boolean(buttons || customButtons);\n const hasStatusArea = Boolean(statusText || customStatus);\n\n const modeClass = classes[mode];\n const stuckClass = mode === \"sticky\" && isStuck ? classes[\"is-stuck\"] : \"\";\n\n const barClassNames = [classes[\"action-bar\"], modeClass, stuckClass, className]\n .filter(Boolean)\n .join(\" \");\n\n const barContent = (\n <div\n ref={barRef}\n className={barClassNames}\n role=\"toolbar\"\n aria-label={ariaLabel}\n data-testid={testId}\n {...rest}\n >\n {hasButtonArea && (\n <div className={classes[\"button-area\"]} data-testid={`${testId}-button-area`}>\n {customButtons ?? buttons}\n </div>\n )}\n {hasStatusArea && (\n <div className={classes[\"status-area\"]} data-testid={`${testId}-status-area`}>\n {customStatus ?? <span className={classes[\"status-text\"]}>{statusText}</span>}\n </div>\n )}\n </div>\n );\n\n if (mode === \"docked\") {\n return (\n <>\n <div\n className={classes[\"placeholder\"]}\n style={{ height: barHeight }}\n data-testid={`${testId}-placeholder`}\n aria-hidden=\"true\"\n />\n {barContent}\n </>\n );\n }\n\n if (mode === \"sticky\") {\n return (\n <>\n {barContent}\n <div\n ref={sentinelRef}\n style={{ height: 1, marginTop: -1, visibility: \"hidden\" }}\n data-testid={`${testId}-sentinel`}\n aria-hidden=\"true\"\n />\n </>\n );\n }\n\n // Inline mode\n return barContent;\n};\n"],"names":["mode","buttons","customButtons","statusText","customStatus","className","ariaLabel","testId","rest","barRef","useRef","sentinelRef","isStuck","setIsStuck","useState","barHeight","setBarHeight","updateBarHeight","useCallback","current","newHeight","offsetHeight","prev","useEffect","sentinel","scrollParent","el","parent","parentElement","style","getComputedStyle","test","overflow","overflowY","findScrollParent","observer","IntersectionObserver","entry","isIntersecting","threshold","root","rootMargin","observe","disconnect","handleResize","window","addEventListener","removeEventListener","hasButtonArea","Boolean","hasStatusArea","modeClass","classes","stuckClass","barClassNames","filter","join","barContent","React","createElement","ref","role","Fragment","height","marginTop","visibility"],"mappings":"uKA+ByB,EACvBA,OAAO,SACPC,UACAC,gBACAC,aACAC,eACAC,YACA,aAAcC,EAAY,aAC1B,cAAeC,EAAS,gBACrBC,MAEH,MAAMC,EAASC,EAAAA,OAAuB,MAChCC,EAAcD,EAAAA,OAAuB,OACpCE,EAASC,GAAcC,EAAAA,UAAS,IAChCC,EAAWC,GAAgBF,EAAAA,SAAS,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WiD,EACXO,KAAK,UACL,aAAYvD,EACZ,cAAaC,KACTC,GAEHwC,GACCU,EAAAC,cAAC,MAAA,CAAItD,UAAW+C,EAAAA,QAAQ,eAAgB,cAAa,GAAG7C,iBACrDL,GAAiBD,GAGrBiD,GACCQ,EAAAC,cAAC,MAAA,CAAItD,UAAW+C,EAAAA,QAAQ,eAAgB,cAAa,GAAG7C,iBACrDH,mBAAiB,OAAA,CAAKC,UAAW+C,UAAQ,gBAAiBjD,KAMnE,MAAa,WAATH,EAEA0D,EAAAC,cAAAD,EAAAI,SAAA,KACEJ,EAAAC,cAAC,MAAA,CACCtD,UAAW+C,EAAAA,QAAqB,YAChCvB,MAAO,CAAEkC,OAAQhD,GACjB,cAAa,GAAGR,gBAChB,cAAY,SAEbkD,GAKM,WAATzD,kCAGGyD,EACDC,EAAAC,cAAC,MAAA,CACCC,IAAKjD,EACLkB,MAAO,CAAEkC,OAAQ,EAAGC,WAAW,EAAIC,WAAY,UAC/C,cAAa,GAAG1D,aAChB,cAAY,UAObkD"}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import React, { useRef, useState, useCallback, useEffect } from "react";
|
|
2
|
+
import classes from "./ActionBar.module.scss.es.js";
|
|
3
|
+
const ActionBar = ({
|
|
4
|
+
mode = "inline",
|
|
5
|
+
buttons,
|
|
6
|
+
customButtons,
|
|
7
|
+
statusText,
|
|
8
|
+
customStatus,
|
|
9
|
+
className,
|
|
10
|
+
"aria-label": ariaLabel = "Action bar",
|
|
11
|
+
"data-testid": testId = "action-bar",
|
|
12
|
+
...rest
|
|
13
|
+
}) => {
|
|
14
|
+
const barRef = useRef(null);
|
|
15
|
+
const sentinelRef = useRef(null);
|
|
16
|
+
const [isStuck, setIsStuck] = useState(false);
|
|
17
|
+
const [barHeight, setBarHeight] = useState(0);
|
|
18
|
+
const updateBarHeight = useCallback(() => {
|
|
19
|
+
if (barRef.current) {
|
|
20
|
+
const newHeight = barRef.current.offsetHeight;
|
|
21
|
+
setBarHeight((prev) => prev === newHeight ? prev : newHeight);
|
|
22
|
+
}
|
|
23
|
+
}, []);
|
|
24
|
+
useEffect(() => {
|
|
25
|
+
if (mode !== "sticky") {
|
|
26
|
+
setIsStuck(false);
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
updateBarHeight();
|
|
30
|
+
const sentinel = sentinelRef.current;
|
|
31
|
+
if (!sentinel) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
const findScrollParent = (el) => {
|
|
35
|
+
if (!el) {
|
|
36
|
+
return null;
|
|
37
|
+
}
|
|
38
|
+
let parent = el.parentElement;
|
|
39
|
+
while (parent) {
|
|
40
|
+
const style = getComputedStyle(parent);
|
|
41
|
+
if (/(auto|scroll)/.test(style.overflow + style.overflowY)) {
|
|
42
|
+
return parent;
|
|
43
|
+
}
|
|
44
|
+
parent = parent.parentElement;
|
|
45
|
+
}
|
|
46
|
+
return null;
|
|
47
|
+
};
|
|
48
|
+
const scrollParent = findScrollParent(sentinel);
|
|
49
|
+
const observer = new IntersectionObserver(
|
|
50
|
+
([entry]) => {
|
|
51
|
+
setIsStuck(!entry.isIntersecting);
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
threshold: 0,
|
|
55
|
+
root: scrollParent || null,
|
|
56
|
+
rootMargin: "0px 0px 0px 0px"
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
observer.observe(sentinel);
|
|
60
|
+
return () => {
|
|
61
|
+
observer.disconnect();
|
|
62
|
+
};
|
|
63
|
+
}, [mode, updateBarHeight]);
|
|
64
|
+
useEffect(() => {
|
|
65
|
+
if (mode === "docked") {
|
|
66
|
+
updateBarHeight();
|
|
67
|
+
}
|
|
68
|
+
}, [mode, updateBarHeight]);
|
|
69
|
+
useEffect(() => {
|
|
70
|
+
if (mode !== "docked" && mode !== "sticky") {
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
const handleResize = () => updateBarHeight();
|
|
74
|
+
window.addEventListener("resize", handleResize);
|
|
75
|
+
return () => window.removeEventListener("resize", handleResize);
|
|
76
|
+
}, [mode, updateBarHeight]);
|
|
77
|
+
const hasButtonArea = Boolean(buttons || customButtons);
|
|
78
|
+
const hasStatusArea = Boolean(statusText || customStatus);
|
|
79
|
+
const modeClass = classes[mode];
|
|
80
|
+
const stuckClass = mode === "sticky" && isStuck ? classes["is-stuck"] : "";
|
|
81
|
+
const barClassNames = [classes["action-bar"], modeClass, stuckClass, className].filter(Boolean).join(" ");
|
|
82
|
+
const barContent = /* @__PURE__ */ React.createElement(
|
|
83
|
+
"div",
|
|
84
|
+
{
|
|
85
|
+
ref: barRef,
|
|
86
|
+
className: barClassNames,
|
|
87
|
+
role: "toolbar",
|
|
88
|
+
"aria-label": ariaLabel,
|
|
89
|
+
"data-testid": testId,
|
|
90
|
+
...rest
|
|
91
|
+
},
|
|
92
|
+
hasButtonArea && /* @__PURE__ */ React.createElement("div", { className: classes["button-area"], "data-testid": `${testId}-button-area` }, customButtons ?? buttons),
|
|
93
|
+
hasStatusArea && /* @__PURE__ */ React.createElement("div", { className: classes["status-area"], "data-testid": `${testId}-status-area` }, customStatus ?? /* @__PURE__ */ React.createElement("span", { className: classes["status-text"] }, statusText))
|
|
94
|
+
);
|
|
95
|
+
if (mode === "docked") {
|
|
96
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
|
|
97
|
+
"div",
|
|
98
|
+
{
|
|
99
|
+
className: classes["placeholder"],
|
|
100
|
+
style: { height: barHeight },
|
|
101
|
+
"data-testid": `${testId}-placeholder`,
|
|
102
|
+
"aria-hidden": "true"
|
|
103
|
+
}
|
|
104
|
+
), barContent);
|
|
105
|
+
}
|
|
106
|
+
if (mode === "sticky") {
|
|
107
|
+
return /* @__PURE__ */ React.createElement(React.Fragment, null, barContent, /* @__PURE__ */ React.createElement(
|
|
108
|
+
"div",
|
|
109
|
+
{
|
|
110
|
+
ref: sentinelRef,
|
|
111
|
+
style: { height: 1, marginTop: -1, visibility: "hidden" },
|
|
112
|
+
"data-testid": `${testId}-sentinel`,
|
|
113
|
+
"aria-hidden": "true"
|
|
114
|
+
}
|
|
115
|
+
));
|
|
116
|
+
}
|
|
117
|
+
return barContent;
|
|
118
|
+
};
|
|
119
|
+
export {
|
|
120
|
+
ActionBar
|
|
121
|
+
};
|
|
122
|
+
//# sourceMappingURL=ActionBar.es.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionBar.es.js","sources":["../../../../src/components/Layout/ActionBar/ActionBar.tsx"],"sourcesContent":["/*\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { HTMLAttributes, ReactNode, useCallback, useEffect, useRef, useState } from \"react\";\nimport classes from \"./ActionBar.module.scss\";\n\nexport type ActionBarMode = \"inline\" | \"docked\" | \"sticky\";\n\nexport interface ActionBarProps extends HTMLAttributes<HTMLDivElement> {\n mode?: ActionBarMode;\n buttons?: ReactNode;\n customButtons?: ReactNode;\n statusText?: ReactNode;\n customStatus?: ReactNode;\n \"aria-label\"?: string;\n \"data-testid\"?: string;\n}\n\nexport const ActionBar = ({\n mode = \"inline\",\n buttons,\n customButtons,\n statusText,\n customStatus,\n className,\n \"aria-label\": ariaLabel = \"Action bar\",\n \"data-testid\": testId = \"action-bar\",\n ...rest\n}: ActionBarProps) => {\n const barRef = useRef<HTMLDivElement>(null);\n const sentinelRef = useRef<HTMLDivElement>(null);\n const [isStuck, setIsStuck] = useState(false);\n const [barHeight, setBarHeight] = useState(0);\n\n const updateBarHeight = useCallback(() => {\n if (barRef.current) {\n const newHeight = barRef.current.offsetHeight;\n setBarHeight(prev => (prev === newHeight ? prev : newHeight));\n }\n }, []);\n\n useEffect(() => {\n if (mode !== \"sticky\") {\n setIsStuck(false);\n return;\n }\n\n updateBarHeight();\n\n const sentinel = sentinelRef.current;\n if (!sentinel) {\n return;\n }\n\n const findScrollParent = (el: HTMLElement | null): HTMLElement | null => {\n if (!el) {\n return null;\n }\n let parent = el.parentElement;\n while (parent) {\n const style = getComputedStyle(parent);\n if (/(auto|scroll)/.test(style.overflow + style.overflowY)) {\n return parent;\n }\n parent = parent.parentElement;\n }\n return null;\n };\n\n const scrollParent = findScrollParent(sentinel);\n\n const observer = new IntersectionObserver(\n ([entry]) => {\n setIsStuck(!entry.isIntersecting);\n },\n {\n threshold: 0,\n root: scrollParent || null,\n rootMargin: \"0px 0px 0px 0px\"\n }\n );\n\n observer.observe(sentinel);\n\n return () => {\n observer.disconnect();\n };\n }, [mode, updateBarHeight]);\n\n useEffect(() => {\n if (mode === \"docked\") {\n updateBarHeight();\n }\n }, [mode, updateBarHeight]);\n\n useEffect(() => {\n if (mode !== \"docked\" && mode !== \"sticky\") {\n return;\n }\n\n const handleResize = () => updateBarHeight();\n window.addEventListener(\"resize\", handleResize);\n return () => window.removeEventListener(\"resize\", handleResize);\n }, [mode, updateBarHeight]);\n\n const hasButtonArea = Boolean(buttons || customButtons);\n const hasStatusArea = Boolean(statusText || customStatus);\n\n const modeClass = classes[mode];\n const stuckClass = mode === \"sticky\" && isStuck ? classes[\"is-stuck\"] : \"\";\n\n const barClassNames = [classes[\"action-bar\"], modeClass, stuckClass, className]\n .filter(Boolean)\n .join(\" \");\n\n const barContent = (\n <div\n ref={barRef}\n className={barClassNames}\n role=\"toolbar\"\n aria-label={ariaLabel}\n data-testid={testId}\n {...rest}\n >\n {hasButtonArea && (\n <div className={classes[\"button-area\"]} data-testid={`${testId}-button-area`}>\n {customButtons ?? buttons}\n </div>\n )}\n {hasStatusArea && (\n <div className={classes[\"status-area\"]} data-testid={`${testId}-status-area`}>\n {customStatus ?? <span className={classes[\"status-text\"]}>{statusText}</span>}\n </div>\n )}\n </div>\n );\n\n if (mode === \"docked\") {\n return (\n <>\n <div\n className={classes[\"placeholder\"]}\n style={{ height: barHeight }}\n data-testid={`${testId}-placeholder`}\n aria-hidden=\"true\"\n />\n {barContent}\n </>\n );\n }\n\n if (mode === \"sticky\") {\n return (\n <>\n {barContent}\n <div\n ref={sentinelRef}\n style={{ height: 1, marginTop: -1, visibility: \"hidden\" }}\n data-testid={`${testId}-sentinel`}\n aria-hidden=\"true\"\n />\n </>\n );\n }\n\n // Inline mode\n return barContent;\n};\n"],"names":[],"mappings":";;AA+BO,MAAM,YAAY,CAAC;AAAA,EACxB,OAAO;AAAA,EACP;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,cAAc,YAAY;AAAA,EAC1B,eAAe,SAAS;AAAA,EACxB,GAAG;AACL,MAAsB;AACpB,QAAM,SAAS,OAAuB,IAAI;AAC1C,QAAM,cAAc,OAAuB,IAAI;AAC/C,QAAM,CAAC,SAAS,UAAU,IAAI,SAAS,KAAK;AAC5C,QAAM,CAAC,WAAW,YAAY,IAAI,SAAS,CAAC;AAE5C,QAAM,kBAAkB,YAAY,MAAM;AACxC,QAAI,OAAO,SAAS;AAClB,YAAM,YAAY,OAAO,QAAQ;AACjC,mBAAa,CAAA,SAAS,SAAS,YAAY,OAAO,SAAU;AAAA,IAC9D;AAAA,EACF,GAAG,CAAA,CAAE;AAEL,YAAU,MAAM;AACd,QAAI,SAAS,UAAU;AACrB,iBAAW,KAAK;AAChB;AAAA,IACF;AAEA,oBAAA;AAEA,UAAM,WAAW,YAAY;AAC7B,QAAI,CAAC,UAAU;AACb;AAAA,IACF;AAEA,UAAM,mBAAmB,CAAC,OAA+C;AACvE,UAAI,CAAC,IAAI;AACP,eAAO;AAAA,MACT;AACA,UAAI,SAAS,GAAG;AAChB,aAAO,QAAQ;AACb,cAAM,QAAQ,iBAAiB,MAAM;AAC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AA,IAAA;AAAA,IAEH,iBACC,sBAAA,cAAC,OAAA,EAAI,WAAW,QAAQ,aAAa,GAAG,eAAa,GAAG,MAAM,eAAA,GAC3D,iBAAiB,OACpB;AAAA,IAED,iBACC,sBAAA,cAAC,OAAA,EAAI,WAAW,QAAQ,aAAa,GAAG,eAAa,GAAG,MAAM,eAAA,GAC3D,oDAAiB,QAAA,EAAK,WAAW,QAAQ,aAAa,EAAA,GAAI,UAAW,CACxE;AAAA,EAAA;AAKN,MAAI,SAAS,UAAU;AACrB,WACE,sBAAA,cAAA,MAAA,UAAA,MACE,sBAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAW,QAAQ,aAAa;AAAA,QAChC,OAAO,EAAE,QAAQ,UAAA;AAAA,QACjB,eAAa,GAAG,MAAM;AAAA,QACtB,eAAY;AAAA,MAAA;AAAA,IAAA,GAEb,UACH;AAAA,EAEJ;AAEA,MAAI,SAAS,UAAU;AACrB,qEAEK,YACD,sBAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,KAAK;AAAA,QACL,OAAO,EAAE,QAAQ,GAAG,WAAW,IAAI,YAAY,SAAA;AAAA,QAC/C,eAAa,GAAG,MAAM;AAAA,QACtB,eAAY;AAAA,MAAA;AAAA,IAAA,CAEhB;AAAA,EAEJ;AAGA,SAAO;AACT;"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode('/*!\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.ActionBar_action-bar_8eZbI{display:flex;align-items:center;justify-content:space-between;padding:calc(.75 * var(--font-size)) 0;background-color:var(--color-white);width:100%;box-sizing:border-box;min-height:calc(3.5 * var(--font-size));gap:calc(1 * var(--font-size))}.ActionBar_inline_8eZbI{position:relative}.ActionBar_docked_8eZbI{position:fixed;bottom:0;left:0;right:0;padding-top:calc(.75 * var(--font-size));padding-bottom:calc(.75 * var(--font-size));padding-left:var(--action-bar-horizontal-padding, 2rem);padding-right:var(--action-bar-horizontal-padding, 2rem);z-index:10;box-shadow:0 -2px 4px #01053205,0 -4px 12px #0105320a,0 -8px 24px #0105320a}.ActionBar_sticky_8eZbI{position:sticky;bottom:0;z-index:10}.ActionBar_sticky_8eZbI.ActionBar_is-stuck_8eZbI{margin-left:calc(-1 * var(--action-bar-horizontal-padding, 2rem));margin-right:calc(-1 * var(--action-bar-horizontal-padding, 2rem));padding-left:var(--action-bar-horizontal-padding, 2rem);padding-right:var(--action-bar-horizontal-padding, 2rem);width:auto;box-shadow:0 -2px 4px #01053205,0 -4px 12px #0105320a,0 -8px 24px #0105320a}.ActionBar_placeholder_8eZbI{visibility:hidden;pointer-events:none}.ActionBar_button-area_8eZbI{display:flex;align-items:center;gap:calc(.5 * var(--font-size));flex-shrink:0}.ActionBar_status-area_8eZbI{display:flex;align-items:center;justify-content:flex-end;flex:1 1 auto;min-width:0}.ActionBar_status-text_8eZbI{color:var(--color-blue-grey500);font-size:calc(.875 * var(--font-size));line-height:1.4;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}')),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}}();
|
|
2
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t="ActionBar_inline_8eZbI",e="ActionBar_docked_8eZbI",a="ActionBar_sticky_8eZbI",o="ActionBar_placeholder_8eZbI",r={"action-bar":"ActionBar_action-bar_8eZbI",inline:t,docked:e,sticky:a,"is-stuck":"ActionBar_is-stuck_8eZbI",placeholder:o,"button-area":"ActionBar_button-area_8eZbI","status-area":"ActionBar_status-area_8eZbI","status-text":"ActionBar_status-text_8eZbI"};exports.default=r,exports.docked=e,exports.inline=t,exports.placeholder=o,exports.sticky=a;
|
|
3
|
+
//# sourceMappingURL=ActionBar.module.scss.cjs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionBar.module.scss.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode('/*!\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.ActionBar_action-bar_8eZbI{display:flex;align-items:center;justify-content:space-between;padding:calc(.75 * var(--font-size)) 0;background-color:var(--color-white);width:100%;box-sizing:border-box;min-height:calc(3.5 * var(--font-size));gap:calc(1 * var(--font-size))}.ActionBar_inline_8eZbI{position:relative}.ActionBar_docked_8eZbI{position:fixed;bottom:0;left:0;right:0;padding-top:calc(.75 * var(--font-size));padding-bottom:calc(.75 * var(--font-size));padding-left:var(--action-bar-horizontal-padding, 2rem);padding-right:var(--action-bar-horizontal-padding, 2rem);z-index:10;box-shadow:0 -2px 4px #01053205,0 -4px 12px #0105320a,0 -8px 24px #0105320a}.ActionBar_sticky_8eZbI{position:sticky;bottom:0;z-index:10}.ActionBar_sticky_8eZbI.ActionBar_is-stuck_8eZbI{margin-left:calc(-1 * var(--action-bar-horizontal-padding, 2rem));margin-right:calc(-1 * var(--action-bar-horizontal-padding, 2rem));padding-left:var(--action-bar-horizontal-padding, 2rem);padding-right:var(--action-bar-horizontal-padding, 2rem);width:auto;box-shadow:0 -2px 4px #01053205,0 -4px 12px #0105320a,0 -8px 24px #0105320a}.ActionBar_placeholder_8eZbI{visibility:hidden;pointer-events:none}.ActionBar_button-area_8eZbI{display:flex;align-items:center;gap:calc(.5 * var(--font-size));flex-shrink:0}.ActionBar_status-area_8eZbI{display:flex;align-items:center;justify-content:flex-end;flex:1 1 auto;min-width:0}.ActionBar_status-text_8eZbI{color:var(--color-blue-grey500);font-size:calc(.875 * var(--font-size));line-height:1.4;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}')),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}}();
|
|
2
|
+
const inline = "ActionBar_inline_8eZbI";
|
|
3
|
+
const docked = "ActionBar_docked_8eZbI";
|
|
4
|
+
const sticky = "ActionBar_sticky_8eZbI";
|
|
5
|
+
const placeholder = "ActionBar_placeholder_8eZbI";
|
|
6
|
+
const classes = {
|
|
7
|
+
"action-bar": "ActionBar_action-bar_8eZbI",
|
|
8
|
+
inline,
|
|
9
|
+
docked,
|
|
10
|
+
sticky,
|
|
11
|
+
"is-stuck": "ActionBar_is-stuck_8eZbI",
|
|
12
|
+
placeholder,
|
|
13
|
+
"button-area": "ActionBar_button-area_8eZbI",
|
|
14
|
+
"status-area": "ActionBar_status-area_8eZbI",
|
|
15
|
+
"status-text": "ActionBar_status-text_8eZbI"
|
|
16
|
+
};
|
|
17
|
+
export {
|
|
18
|
+
classes as default,
|
|
19
|
+
docked,
|
|
20
|
+
inline,
|
|
21
|
+
placeholder,
|
|
22
|
+
sticky
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=ActionBar.module.scss.es.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionBar.module.scss.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode('/*!\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.
|
|
2
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="
|
|
1
|
+
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode('/*!\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.Card_main_8eZbI{border-radius:calc(.25 * var(--font-size));min-width:calc(18.5 * var(--font-size));overflow:hidden}.Card_header_8eZbI{display:flex;align-items:center;padding:calc(.5 * var(--font-size)) calc(1.5 * var(--font-size));justify-content:space-between;gap:calc(.5 * var(--font-size));background-color:var(--color-primary100)}.Card_header_8eZbI .Card_title-left_8eZbI{flex:1 1 auto;min-width:0;display:flex;flex-direction:column}.Card_header_8eZbI .Card_title-left_8eZbI .Card_title_8eZbI{margin:0;font-weight:500;max-width:100%;display:block}.Card_header_8eZbI .Card_title-left_8eZbI .Card_description_8eZbI{margin:0;max-width:100%;display:block}.Card_header_8eZbI .Card_title-right_8eZbI{flex:0 0 auto;display:flex;align-items:center;height:100%;gap:calc(.5 * var(--font-size));white-space:nowrap}.Card_body_8eZbI{padding:calc(1 * var(--font-size)) calc(1.5 * var(--font-size))}.Card_body_8eZbI.Card_default-body-style_8eZbI{background-color:var(--color-blue-grey50)}.Card_body_8eZbI.Card_white-body-style_8eZbI{background-color:var(--color-white);border:1px solid var(--color-blue-grey100)}.Card_body_8eZbI.Card_white-body-style_8eZbI.Card_without-header_8eZbI{border-radius:calc(.25 * var(--font-size))}.Card_body_8eZbI.Card_white-body-style_8eZbI.Card_with-header_8eZbI{border-top:none;border-bottom-left-radius:calc(.25 * var(--font-size));border-bottom-right-radius:calc(.25 * var(--font-size))}')),document.head.appendChild(e)}}catch(r){console.error("vite-plugin-css-injected-by-js",r)}}();
|
|
2
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="Card_main_8eZbI",t="Card_header_8eZbI",d="Card_title_8eZbI",r="Card_description_8eZbI",i="Card_body_8eZbI",a={main:e,header:t,"title-left":"Card_title-left_8eZbI",title:d,description:r,"title-right":"Card_title-right_8eZbI",body:i,"default-body-style":"Card_default-body-style_8eZbI","white-body-style":"Card_white-body-style_8eZbI","without-header":"Card_without-header_8eZbI","with-header":"Card_with-header_8eZbI"};exports.body=i,exports.default=a,exports.description=r,exports.header=t,exports.main=e,exports.title=d;
|
|
3
3
|
//# sourceMappingURL=Card.module.scss.cjs.js.map
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode('/*!\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.
|
|
2
|
-
const main = "
|
|
3
|
-
const header = "
|
|
4
|
-
const title = "
|
|
5
|
-
const description = "
|
|
6
|
-
const body = "
|
|
1
|
+
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode('/*!\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the "License");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an "AS IS" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */.Card_main_8eZbI{border-radius:calc(.25 * var(--font-size));min-width:calc(18.5 * var(--font-size));overflow:hidden}.Card_header_8eZbI{display:flex;align-items:center;padding:calc(.5 * var(--font-size)) calc(1.5 * var(--font-size));justify-content:space-between;gap:calc(.5 * var(--font-size));background-color:var(--color-primary100)}.Card_header_8eZbI .Card_title-left_8eZbI{flex:1 1 auto;min-width:0;display:flex;flex-direction:column}.Card_header_8eZbI .Card_title-left_8eZbI .Card_title_8eZbI{margin:0;font-weight:500;max-width:100%;display:block}.Card_header_8eZbI .Card_title-left_8eZbI .Card_description_8eZbI{margin:0;max-width:100%;display:block}.Card_header_8eZbI .Card_title-right_8eZbI{flex:0 0 auto;display:flex;align-items:center;height:100%;gap:calc(.5 * var(--font-size));white-space:nowrap}.Card_body_8eZbI{padding:calc(1 * var(--font-size)) calc(1.5 * var(--font-size))}.Card_body_8eZbI.Card_default-body-style_8eZbI{background-color:var(--color-blue-grey50)}.Card_body_8eZbI.Card_white-body-style_8eZbI{background-color:var(--color-white);border:1px solid var(--color-blue-grey100)}.Card_body_8eZbI.Card_white-body-style_8eZbI.Card_without-header_8eZbI{border-radius:calc(.25 * var(--font-size))}.Card_body_8eZbI.Card_white-body-style_8eZbI.Card_with-header_8eZbI{border-top:none;border-bottom-left-radius:calc(.25 * var(--font-size));border-bottom-right-radius:calc(.25 * var(--font-size))}')),document.head.appendChild(e)}}catch(r){console.error("vite-plugin-css-injected-by-js",r)}}();
|
|
2
|
+
const main = "Card_main_8eZbI";
|
|
3
|
+
const header = "Card_header_8eZbI";
|
|
4
|
+
const title = "Card_title_8eZbI";
|
|
5
|
+
const description = "Card_description_8eZbI";
|
|
6
|
+
const body = "Card_body_8eZbI";
|
|
7
7
|
const classes = {
|
|
8
8
|
main,
|
|
9
9
|
header,
|
|
10
|
-
"title-left": "Card_title-
|
|
10
|
+
"title-left": "Card_title-left_8eZbI",
|
|
11
11
|
title,
|
|
12
12
|
description,
|
|
13
|
-
"title-right": "Card_title-
|
|
13
|
+
"title-right": "Card_title-right_8eZbI",
|
|
14
14
|
body,
|
|
15
|
-
"default-body-style": "Card_default-body-
|
|
16
|
-
"white-body-style": "Card_white-body-
|
|
17
|
-
"without-header": "Card_without-
|
|
18
|
-
"with-header": "Card_with-
|
|
15
|
+
"default-body-style": "Card_default-body-style_8eZbI",
|
|
16
|
+
"white-body-style": "Card_white-body-style_8eZbI",
|
|
17
|
+
"without-header": "Card_without-header_8eZbI",
|
|
18
|
+
"with-header": "Card_with-header_8eZbI"
|
|
19
19
|
};
|
|
20
20
|
export {
|
|
21
21
|
body,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react"),a=require("../../Typography/Typography.cjs.js"),t=require("./ContentHeader.module.scss.cjs.js"),l=require("../../Button/IconButton.cjs.js"),r=require("../../Icon/Icon.cjs.js"),n=require("../../Tag/Tag.cjs.js"),c=require("../../TextEllipsis/TextEllipsis.cjs.js"),s=require("../../../hooks/useStickyStacking.cjs.js"),i=({title:i,children:o,buttons:d,collapsed:u,subtitle:m,navigation:p,tags:f,error:E,errorMessage:g,errorTagText:v,sticky:h,...y})=>{const b=e.useRef(null),k=e.useRef(null),N=e.useRef(null),{isStuck:T}=s.useStickyStacking(b,{enabled:!!h,zIndex:12,disableScrollAnchoring:!0}),x=h&&T||!!u;e.useLayoutEffect(()=>{var e,a;p&&(x&&document.activeElement===k.current?null==(e=N.current)||e.focus():x||document.activeElement!==N.current||null==(a=k.current)||a.focus())},[x,p]);const j=e.createElement(n.Tag,{icon:r.Icons.Forbidden,backgroundColor:"var(--color-red100)",color:"var(--color-red900)"},v||"Blocked"),$=()=>f??[],S=e.useMemo(()=>E&&x?[j,...$().filter(e=>"enabled"!==e.props.variant)]:E?$().filter(e=>"enabled"!==e.props.variant):$(),[f,E,x]),I=`${t.default.collapsible} ${x?t.default.collapsed:""}`,q=(a,n,c={})=>e.createElement(l.IconButton,{ref:a,onClick:()=>null==p?void 0:p.navigateFN(-1),className:t.default["back-arrow"],iconSize:c.iconSize,tabIndex:n?0:-1},e.createElement(r.Icon,{icon:r.Icons.ArrowLeft}),c.withText&&e.createElement("span",{className:t.default["back-text"]},(null==p?void 0:p.displayText)?p.displayText:"Back"));return e.createElement("div",{className:`${t.default["header-background-color"]} ${h?t.default.sticky:""} ${h&&T?t.default["sticky-spacing"]:""}`,ref:b},e.createElement("div",{className:`${t.default.header} ${y.className} ${x?t.default["collapsed-header"]:""}`,...y},e.createElement("div",null,p&&e.createElement("div",{className:I},e.createElement("div",{className:`${t.default["collapsible-inner"]} ${t.default["navigation-top"]} ${x?t.default.collapsed:""}`,"aria-hidden":x},q(k,!x,{withText:!0,iconSize:"s"}))),e.createElement(a.Typography,{className:t.default["header-text"],variant:"h1"},p&&e.createElement("span",{className:`${t.default["inline-back"]} ${x?"":t.default.hidden}`,"aria-hidden":!x},q(N,x)),e.createElement(c.TextEllipsis,{"data-testid":"content-header-title"},i),e.createElement("span",{className:t.default["header-tags"]},S.map((a,t)=>e.createElement(e.Fragment,{key:a.key||t},a)))),m&&!E&&e.createElement("div",{className:I},e.createElement("div",{className:t.default["collapsible-inner"],"aria-hidden":x},e.createElement(a.Typography,{className:t.default["header-subtitle"],variant:"h4"},m))),e.createElement("div",{className:I},e.createElement("div",{className:t.default["collapsible-inner"],"aria-hidden":x},e.createElement(a.Typography,{variant:"body",spacing:{margin:0}},E?e.createElement(e.Fragment,null,j,e.createElement("span",{className:t.default["error-text"]},g)):o)))),d&&e.createElement("div",{className:t.default["buttons-wrapper"]},d)))},o=i;exports.ContentHeader=o,exports.ContentHeaderComponent=i;
|
|
2
2
|
//# sourceMappingURL=ContentHeader.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ContentHeader.cjs.js","sources":["../../../../src/components/Layout/ContentHeader/ContentHeader.tsx"],"sourcesContent":["/*\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { HTMLAttributes, ReactElement, useMemo } from \"react\";\nimport { Button, Props as ButtonProps } from \"../../Button/Button\";\nimport { Typography } from \"../../Typography/Typography\";\n\nimport classes from \"./ContentHeader.module.scss\";\nimport { IconButton } from \"../../Button/IconButton\";\nimport { Icon, Icons } from \"../../Icon/Icon\";\nimport { NavigateFunction } from \"react-router-dom\";\nimport { Tag, Props as TagProps } from \"../../Tag/Tag\";\nimport { TextEllipsis } from \"../../TextEllipsis/TextEllipsis\";\n\nexport interface ContentHeaderNavigationProps {\n displayText?: string;\n navigateFN: NavigateFunction;\n}\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n title: string;\n /**\n * @deprecated pass text as children\n */\n subtitle?: string;\n buttons?: ReactElement<ButtonProps, typeof Button> | ReactElement<ButtonProps, typeof Button>[];\n collapsed?: boolean;\n navigation?: ContentHeaderNavigationProps;\n tags?: ReactElement<TagProps, typeof Tag>[];\n error?: boolean;\n errorMessage?: string;\n errorTagText?: string;\n}\n\nexport const ContentHeaderComponent = ({\n title,\n children,\n buttons,\n collapsed,\n subtitle,\n navigation,\n tags,\n error,\n errorMessage,\n errorTagText,\n ...rest\n}: Props) => {\n const errorTag = (\n <Tag icon={Icons.Forbidden} backgroundColor=\"var(--color-red100)\" color=\"var(--color-red900)\">\n {errorTagText || \"Blocked\"}\n </Tag>\n );\n\n const getTags = () => tags ?? [];\n\n const renderTags = useMemo(() => {\n if (error && collapsed) {\n return [errorTag, ...getTags().filter(tag => tag.props.variant !== \"enabled\")];\n } else if (error) {\n return getTags().filter(tag => tag.props.variant !== \"enabled\");\n }\n return getTags();\n }, [tags, error, collapsed]);\n\n return (\n <div className={classes[\"header-background-color\"]}>\n <div\n className={`${classes[\"header\"]} ${rest.className} ${collapsed ? classes[\"collapsed-header\"] : \"\"}`}\n {...rest}\n >\n <div>\n {navigation && !collapsed && (\n <IconButton\n onClick={() => {\n navigation.navigateFN(-1);\n }}\n className={classes[\"back-arrow\"]}\n iconSize=\"s\"\n >\n <Icon icon={Icons.ArrowLeft} />\n <span className={classes[\"back-text\"]}>\n {navigation.displayText ? navigation.displayText : \"Back\"}\n </span>\n </IconButton>\n )}\n <Typography className={classes[\"header-text\"]} variant={\"h1\"}>\n {navigation && collapsed && (\n <IconButton\n onClick={() => {\n navigation.navigateFN(-1);\n }}\n className={classes[\"back-arrow\"]}\n >\n <Icon icon={Icons.ArrowLeft} />\n </IconButton>\n )}\n <TextEllipsis data-testid={\"content-header-title\"}>{title}</TextEllipsis>\n <span className={classes[\"header-tags\"]}>\n {renderTags.map((tag, index) => (\n <React.Fragment key={tag.key || index}>{tag}</React.Fragment>\n ))}\n </span>\n </Typography>\n {subtitle && !error && (\n <Typography\n className={`${classes[\"header-subtitle\"]} ${collapsed ? classes[\"hide-text\"] : \"\"}`}\n variant=\"h4\"\n >\n {subtitle}\n </Typography>\n )}\n <Typography\n className={`${collapsed ? classes[\"hide-text\"] : \"\"}`}\n variant=\"body\"\n spacing={{ margin: 0 }}\n >\n {error ? (\n <>\n {errorTag}\n <span className={classes[\"error-text\"]}>{errorMessage}</span>\n </>\n ) : (\n children\n )}\n </Typography>\n </div>\n {buttons && <div className={classes[\"buttons-wrapper\"]}>{buttons}</div>}\n </div>\n </div>\n );\n};\n\nexport const ContentHeader = ContentHeaderComponent;\n"],"names":["ContentHeaderComponent","title","children","buttons","collapsed","subtitle","navigation","tags","error","errorMessage","errorTagText","rest","errorTag","React","createElement","Tag","icon","Icons","Forbidden","backgroundColor","color","getTags","renderTags","useMemo","filter","tag","props","variant","className","classes","IconButton","onClick","navigateFN","iconSize","Icon","ArrowLeft","displayText","Typography","TextEllipsis","map","index","Fragment","key","spacing","margin","ContentHeader"],"mappings":"+WA+CaA,EAAyB,EACpCC,QACAC,WACAC,UACAC,YACAC,WACAC,aACAC,OACAC,QACAC,eACAC,kBACGC,MAEH,MAAMC,EACJC,EAAAC,cAACC,EAAAA,IAAA,CAAIC,KAAMC,EAAAA,MAAMC,UAAWC,gBAAgB,sBAAsBC,MAAM,uBACrEV,GAAgB,WAIfW,EAAU,IAAMd,GAAQ,GAExBe,EAAaC,EAAAA,QAAQ,IACrBf,GAASJ,EACJ,CAACQ,KAAaS,IAAUG,OAAOC,GAA6B,YAAtBA,EAAIC,MAAMC,UAC9CnB,EACFa,IAAUG,UAAoC,YAAtBC,EAAIC,MAAMC,SAEpCN,IACN,CAACd,EAAMC,EAAOJ,IAEjB,OACES,EAAAC,cAAC,MAAA,CAAIc,UAAWC,EAAAA,QAAQ,4BACtBhB,EAAAC,cAAC,MAAA,CACCc,UAAW,GAAGC,EAAAA,QAAgB,UAAKlB,EAAKiB,aAAaxB,EAAYyB,EAAAA,QAAQ,oBAAsB,QAC3FlB,KAEJG,cAAC,MAAA,KACER,IAAeF,GACdS,EAAAC,cAACg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,"file":"ContentHeader.cjs.js","sources":["../../../../src/components/Layout/ContentHeader/ContentHeader.tsx"],"sourcesContent":["/*\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { HTMLAttributes, ReactElement, useLayoutEffect, useMemo, useRef } from \"react\";\nimport { Button, Props as ButtonProps } from \"../../Button/Button\";\nimport { Typography } from \"../../Typography/Typography\";\n\nimport classes from \"./ContentHeader.module.scss\";\nimport { IconButton } from \"../../Button/IconButton\";\nimport { Icon, Icons } from \"../../Icon/Icon\";\nimport { NavigateFunction } from \"react-router-dom\";\nimport { Tag, Props as TagProps } from \"../../Tag/Tag\";\nimport { TextEllipsis } from \"../../TextEllipsis/TextEllipsis\";\nimport { useStickyStacking } from \"../../../hooks/useStickyStacking\";\n\nconst STICKY_CONTENT_HEADER_Z_INDEX = 12; //Keeps the docked header above form fields(toggle).\n\nexport interface ContentHeaderNavigationProps {\n displayText?: string;\n navigateFN: NavigateFunction;\n}\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n title: string;\n /**\n * @deprecated pass text as children\n */\n subtitle?: string;\n buttons?: ReactElement<ButtonProps, typeof Button> | ReactElement<ButtonProps, typeof Button>[];\n collapsed?: boolean;\n navigation?: ContentHeaderNavigationProps;\n tags?: ReactElement<TagProps, typeof Tag>[];\n error?: boolean;\n errorMessage?: string;\n errorTagText?: string;\n sticky?: boolean;\n}\n\nexport const ContentHeaderComponent = ({\n title,\n children,\n buttons,\n collapsed,\n subtitle,\n navigation,\n tags,\n error,\n errorMessage,\n errorTagText,\n sticky,\n ...rest\n}: Props) => {\n const rootRef = useRef<HTMLDivElement>(null);\n const topBackButtonRef = useRef<HTMLButtonElement>(null);\n const inlineBackButtonRef = useRef<HTMLButtonElement>(null);\n\n const { isStuck } = useStickyStacking(rootRef, {\n enabled: !!sticky,\n zIndex: STICKY_CONTENT_HEADER_Z_INDEX,\n disableScrollAnchoring: true\n });\n const effectiveCollapsed = sticky ? isStuck || !!collapsed : !!collapsed;\n\n useLayoutEffect(() => {\n if (!navigation) {\n return;\n }\n if (effectiveCollapsed && document.activeElement === topBackButtonRef.current) {\n inlineBackButtonRef.current?.focus();\n } else if (!effectiveCollapsed && document.activeElement === inlineBackButtonRef.current) {\n topBackButtonRef.current?.focus();\n }\n }, [effectiveCollapsed, navigation]);\n\n const errorTag = (\n <Tag icon={Icons.Forbidden} backgroundColor=\"var(--color-red100)\" color=\"var(--color-red900)\">\n {errorTagText || \"Blocked\"}\n </Tag>\n );\n\n const getTags = () => tags ?? [];\n\n const renderTags = useMemo(() => {\n if (error && effectiveCollapsed) {\n return [errorTag, ...getTags().filter(tag => tag.props.variant !== \"enabled\")];\n } else if (error) {\n return getTags().filter(tag => tag.props.variant !== \"enabled\");\n }\n return getTags();\n }, [tags, error, effectiveCollapsed]);\n\n const collapsibleClassName = `${classes[\"collapsible\"]} ${\n effectiveCollapsed ? classes[\"collapsed\"] : \"\"\n }`;\n\n const renderBackButton = (\n ref: React.RefObject<HTMLButtonElement | null>,\n isActive: boolean,\n options: { withText?: boolean; iconSize?: \"s\" | \"m\" | \"l\" } = {}\n ) => (\n <IconButton\n ref={ref}\n onClick={() => navigation?.navigateFN(-1)}\n className={classes[\"back-arrow\"]}\n iconSize={options.iconSize}\n tabIndex={isActive ? 0 : -1}\n >\n <Icon icon={Icons.ArrowLeft} />\n {options.withText && (\n <span className={classes[\"back-text\"]}>\n {navigation?.displayText ? navigation.displayText : \"Back\"}\n </span>\n )}\n </IconButton>\n );\n\n return (\n <div\n className={`${classes[\"header-background-color\"]} ${sticky ? classes[\"sticky\"] : \"\"} ${\n sticky && isStuck ? classes[\"sticky-spacing\"] : \"\"\n }`}\n ref={rootRef}\n >\n <div\n className={`${classes[\"header\"]} ${rest.className} ${effectiveCollapsed ? classes[\"collapsed-header\"] : \"\"}`}\n {...rest}\n >\n <div>\n {navigation && (\n <div className={collapsibleClassName}>\n <div\n className={`${classes[\"collapsible-inner\"]} ${classes[\"navigation-top\"]} ${effectiveCollapsed ? classes[\"collapsed\"] : \"\"}`}\n aria-hidden={effectiveCollapsed}\n >\n {renderBackButton(topBackButtonRef, !effectiveCollapsed, {\n withText: true,\n iconSize: \"s\"\n })}\n </div>\n </div>\n )}\n <Typography className={classes[\"header-text\"]} variant={\"h1\"}>\n {navigation && (\n <span\n className={`${classes[\"inline-back\"]} ${effectiveCollapsed ? \"\" : classes[\"hidden\"]}`}\n aria-hidden={!effectiveCollapsed}\n >\n {renderBackButton(inlineBackButtonRef, effectiveCollapsed)}\n </span>\n )}\n <TextEllipsis data-testid={\"content-header-title\"}>{title}</TextEllipsis>\n <span className={classes[\"header-tags\"]}>\n {renderTags.map((tag, index) => (\n <React.Fragment key={tag.key || index}>{tag}</React.Fragment>\n ))}\n </span>\n </Typography>\n {subtitle && !error && (\n <div className={collapsibleClassName}>\n <div className={classes[\"collapsible-inner\"]} aria-hidden={effectiveCollapsed}>\n <Typography className={classes[\"header-subtitle\"]} variant=\"h4\">\n {subtitle}\n </Typography>\n </div>\n </div>\n )}\n <div className={collapsibleClassName}>\n <div className={classes[\"collapsible-inner\"]} aria-hidden={effectiveCollapsed}>\n <Typography variant=\"body\" spacing={{ margin: 0 }}>\n {error ? (\n <>\n {errorTag}\n <span className={classes[\"error-text\"]}>{errorMessage}</span>\n </>\n ) : (\n children\n )}\n </Typography>\n </div>\n </div>\n </div>\n {buttons && <div className={classes[\"buttons-wrapper\"]}>{buttons}</div>}\n </div>\n </div>\n );\n};\n\nexport const ContentHeader = ContentHeaderComponent;\n"],"names":["ContentHeaderComponent","title","children","buttons","collapsed","subtitle","navigation","tags","error","errorMessage","errorTagText","sticky","rest","rootRef","useRef","topBackButtonRef","inlineBackButtonRef","isStuck","useStickyStacking","enabled","zIndex","disableScrollAnchoring","effectiveCollapsed","useLayoutEffect","document","activeElement","current","_a","focus","_b","errorTag","React","createElement","Tag","icon","Icons","Forbidden","backgroundColor","color","getTags","renderTags","useMemo","filter","tag","props","variant","collapsibleClassName","classes","renderBackButton","ref","isActive","options","IconButton","onClick","navigateFN","className","iconSize","tabIndex","Icon","ArrowLeft","withText","displayText","Typography","TextEllipsis","map","index","Fragment","key","spacing","margin","ContentHeader"],"mappings":"oaAmDaA,EAAyB,EACpCC,QACAC,WACAC,UACAC,YACAC,WACAC,aACAC,OACAC,QACAC,eACAC,eACAC,YACGC,MAEH,MAAMC,EAAUC,EAAAA,OAAuB,MACjCC,EAAmBD,EAAAA,OAA0B,MAC7CE,EAAsBF,EAAAA,OAA0B,OAEhDG,QAAEA,GAAYC,EAAAA,kBAAkBL,EAAS,CAC7CM,UAAWR,EACXS,OA3CkC,GA4ClCC,wBAAwB,IAEpBC,EAAqBX,GAASM,KAA2Bb,EAE/DmB,EAAAA,gBAAgB,aACTjB,IAGDgB,GAAsBE,SAASC,gBAAkBV,EAAiBW,QACpE,OAAAC,EAAAX,EAAoBU,UAApBC,EAA6BC,QACnBN,GAAsBE,SAASC,gBAAkBT,EAAoBU,SAC/E,OAAAG,EAAAd,EAAiBW,UAAjBG,EAA0BD,UAE3B,CAACN,EAAoBhB,IAExB,MAAMwB,EACJC,EAAAC,cAACC,EAAAA,IAAA,CAAIC,KAAMC,EAAAA,MAAMC,UAAWC,gBAAgB,sBAAsBC,MAAM,uBACrE5B,GAAgB,WAIf6B,EAAU,IAAMhC,GAAQ,GAExBiC,EAAaC,EAAAA,QAAQ,IACrBjC,GAASc,EACJ,CAACQ,KAAaS,IAAUG,OAAOC,GAA6B,YAAtBA,EAAIC,MAAMC,UAC9CrC,EACF+B,IAAUG,UAAoC,YAAtBC,EAAIC,MAAMC,SAEpCN,IACN,CAA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AA,QAAgB,SAClF,eAAczB,GAEb0B,EAAiBhC,EAAqBM,oBAG1CyC,EAAAA,aAAA,CAAa,cAAa,wBAAyB9D,mBACnD,OAAA,CAAKsD,UAAWR,UAAQ,gBACtBP,EAAWwB,IAAI,CAACrB,EAAKsB,IACpBlC,EAAAC,cAACD,EAAMmC,SAAN,CAAeC,IAAKxB,EAAIwB,KAAOF,GAAQtB,MAI7CtC,IAAaG,mBACX,MAAA,CAAI+C,UAAWT,GACdf,EAAAC,cAAC,MAAA,CAAIuB,UAAWR,EAAAA,QAAQ,qBAAsB,cAAazB,GACzDS,EAAAC,cAAC8B,EAAAA,YAAWP,UAAWR,UAAQ,mBAAoBF,QAAQ,MACxDxC,KAKT0B,EAAAC,cAAC,OAAIuB,UAAWT,mBACb,MAAA,CAAIS,UAAWR,EAAAA,QAAQ,qBAAsB,cAAazB,KACzDU,cAAC8B,EAAAA,YAAWjB,QAAQ,OAAOuB,QAAS,CAAEC,OAAQ,IAC3C7D,kCAEIsB,EACDC,EAAAC,cAAC,QAAKuB,UAAWR,EAAAA,QAAQ,eAAgBtC,IAG3CP,MAMTC,GAAW4B,EAAAC,cAAC,MAAA,CAAIuB,UAAWR,EAAAA,QAAQ,oBAAqB5C,MAMpDmE,EAAgBtE"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import React, { useMemo } from "react";
|
|
1
|
+
import React, { useRef, useLayoutEffect, useMemo } from "react";
|
|
2
2
|
import { Typography } from "../../Typography/Typography.es.js";
|
|
3
3
|
import classes from "./ContentHeader.module.scss.es.js";
|
|
4
4
|
import { IconButton } from "../../Button/IconButton.es.js";
|
|
5
5
|
import { Icons, Icon } from "../../Icon/Icon.es.js";
|
|
6
6
|
import { Tag } from "../../Tag/Tag.es.js";
|
|
7
7
|
import { TextEllipsis } from "../../TextEllipsis/TextEllipsis.es.js";
|
|
8
|
+
import { useStickyStacking } from "../../../hooks/useStickyStacking.es.js";
|
|
9
|
+
const STICKY_CONTENT_HEADER_Z_INDEX = 12;
|
|
8
10
|
const ContentHeaderComponent = ({
|
|
9
11
|
title,
|
|
10
12
|
children,
|
|
@@ -16,62 +18,85 @@ const ContentHeaderComponent = ({
|
|
|
16
18
|
error,
|
|
17
19
|
errorMessage,
|
|
18
20
|
errorTagText,
|
|
21
|
+
sticky,
|
|
19
22
|
...rest
|
|
20
23
|
}) => {
|
|
24
|
+
const rootRef = useRef(null);
|
|
25
|
+
const topBackButtonRef = useRef(null);
|
|
26
|
+
const inlineBackButtonRef = useRef(null);
|
|
27
|
+
const { isStuck } = useStickyStacking(rootRef, {
|
|
28
|
+
enabled: !!sticky,
|
|
29
|
+
zIndex: STICKY_CONTENT_HEADER_Z_INDEX,
|
|
30
|
+
disableScrollAnchoring: true
|
|
31
|
+
});
|
|
32
|
+
const effectiveCollapsed = sticky ? isStuck || !!collapsed : !!collapsed;
|
|
33
|
+
useLayoutEffect(() => {
|
|
34
|
+
var _a, _b;
|
|
35
|
+
if (!navigation) {
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
if (effectiveCollapsed && document.activeElement === topBackButtonRef.current) {
|
|
39
|
+
(_a = inlineBackButtonRef.current) == null ? void 0 : _a.focus();
|
|
40
|
+
} else if (!effectiveCollapsed && document.activeElement === inlineBackButtonRef.current) {
|
|
41
|
+
(_b = topBackButtonRef.current) == null ? void 0 : _b.focus();
|
|
42
|
+
}
|
|
43
|
+
}, [effectiveCollapsed, navigation]);
|
|
21
44
|
const errorTag = /* @__PURE__ */ React.createElement(Tag, { icon: Icons.Forbidden, backgroundColor: "var(--color-red100)", color: "var(--color-red900)" }, errorTagText || "Blocked");
|
|
22
45
|
const getTags = () => tags ?? [];
|
|
23
46
|
const renderTags = useMemo(() => {
|
|
24
|
-
if (error &&
|
|
47
|
+
if (error && effectiveCollapsed) {
|
|
25
48
|
return [errorTag, ...getTags().filter((tag) => tag.props.variant !== "enabled")];
|
|
26
49
|
} else if (error) {
|
|
27
50
|
return getTags().filter((tag) => tag.props.variant !== "enabled");
|
|
28
51
|
}
|
|
29
52
|
return getTags();
|
|
30
|
-
}, [tags, error,
|
|
31
|
-
|
|
53
|
+
}, [tags, error, effectiveCollapsed]);
|
|
54
|
+
const collapsibleClassName = `${classes["collapsible"]} ${effectiveCollapsed ? classes["collapsed"] : ""}`;
|
|
55
|
+
const renderBackButton = (ref, isActive, options = {}) => /* @__PURE__ */ React.createElement(
|
|
56
|
+
IconButton,
|
|
57
|
+
{
|
|
58
|
+
ref,
|
|
59
|
+
onClick: () => navigation == null ? void 0 : navigation.navigateFN(-1),
|
|
60
|
+
className: classes["back-arrow"],
|
|
61
|
+
iconSize: options.iconSize,
|
|
62
|
+
tabIndex: isActive ? 0 : -1
|
|
63
|
+
},
|
|
64
|
+
/* @__PURE__ */ React.createElement(Icon, { icon: Icons.ArrowLeft }),
|
|
65
|
+
options.withText && /* @__PURE__ */ React.createElement("span", { className: classes["back-text"] }, (navigation == null ? void 0 : navigation.displayText) ? navigation.displayText : "Back")
|
|
66
|
+
);
|
|
67
|
+
return /* @__PURE__ */ React.createElement(
|
|
32
68
|
"div",
|
|
33
69
|
{
|
|
34
|
-
className: `${classes["header"]} ${
|
|
35
|
-
|
|
70
|
+
className: `${classes["header-background-color"]} ${sticky ? classes["sticky"] : ""} ${sticky && isStuck ? classes["sticky-spacing"] : ""}`,
|
|
71
|
+
ref: rootRef
|
|
36
72
|
},
|
|
37
|
-
/* @__PURE__ */ React.createElement(
|
|
38
|
-
|
|
73
|
+
/* @__PURE__ */ React.createElement(
|
|
74
|
+
"div",
|
|
39
75
|
{
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
},
|
|
43
|
-
className: classes["back-arrow"],
|
|
44
|
-
iconSize: "s"
|
|
76
|
+
className: `${classes["header"]} ${rest.className} ${effectiveCollapsed ? classes["collapsed-header"] : ""}`,
|
|
77
|
+
...rest
|
|
45
78
|
},
|
|
46
|
-
/* @__PURE__ */ React.createElement(
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
onClick: () => {
|
|
52
|
-
navigation.navigateFN(-1);
|
|
79
|
+
/* @__PURE__ */ React.createElement("div", null, navigation && /* @__PURE__ */ React.createElement("div", { className: collapsibleClassName }, /* @__PURE__ */ React.createElement(
|
|
80
|
+
"div",
|
|
81
|
+
{
|
|
82
|
+
className: `${classes["collapsible-inner"]} ${classes["navigation-top"]} ${effectiveCollapsed ? classes["collapsed"] : ""}`,
|
|
83
|
+
"aria-hidden": effectiveCollapsed
|
|
53
84
|
},
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
Typography,
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
Typography,
|
|
66
|
-
{
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
spacing: { margin: 0 }
|
|
70
|
-
},
|
|
71
|
-
error ? /* @__PURE__ */ React.createElement(React.Fragment, null, errorTag, /* @__PURE__ */ React.createElement("span", { className: classes["error-text"] }, errorMessage)) : children
|
|
72
|
-
)),
|
|
73
|
-
buttons && /* @__PURE__ */ React.createElement("div", { className: classes["buttons-wrapper"] }, buttons)
|
|
74
|
-
));
|
|
85
|
+
renderBackButton(topBackButtonRef, !effectiveCollapsed, {
|
|
86
|
+
withText: true,
|
|
87
|
+
iconSize: "s"
|
|
88
|
+
})
|
|
89
|
+
)), /* @__PURE__ */ React.createElement(Typography, { className: classes["header-text"], variant: "h1" }, navigation && /* @__PURE__ */ React.createElement(
|
|
90
|
+
"span",
|
|
91
|
+
{
|
|
92
|
+
className: `${classes["inline-back"]} ${effectiveCollapsed ? "" : classes["hidden"]}`,
|
|
93
|
+
"aria-hidden": !effectiveCollapsed
|
|
94
|
+
},
|
|
95
|
+
renderBackButton(inlineBackButtonRef, effectiveCollapsed)
|
|
96
|
+
), /* @__PURE__ */ React.createElement(TextEllipsis, { "data-testid": "content-header-title" }, title), /* @__PURE__ */ React.createElement("span", { className: classes["header-tags"] }, renderTags.map((tag, index) => /* @__PURE__ */ React.createElement(React.Fragment, { key: tag.key || index }, tag)))), subtitle && !error && /* @__PURE__ */ React.createElement("div", { className: collapsibleClassName }, /* @__PURE__ */ React.createElement("div", { className: classes["collapsible-inner"], "aria-hidden": effectiveCollapsed }, /* @__PURE__ */ React.createElement(Typography, { className: classes["header-subtitle"], variant: "h4" }, subtitle))), /* @__PURE__ */ React.createElement("div", { className: collapsibleClassName }, /* @__PURE__ */ React.createElement("div", { className: classes["collapsible-inner"], "aria-hidden": effectiveCollapsed }, /* @__PURE__ */ React.createElement(Typography, { variant: "body", spacing: { margin: 0 } }, error ? /* @__PURE__ */ React.createElement(React.Fragment, null, errorTag, /* @__PURE__ */ React.createElement("span", { className: classes["error-text"] }, errorMessage)) : children)))),
|
|
97
|
+
buttons && /* @__PURE__ */ React.createElement("div", { className: classes["buttons-wrapper"] }, buttons)
|
|
98
|
+
)
|
|
99
|
+
);
|
|
75
100
|
};
|
|
76
101
|
const ContentHeader = ContentHeaderComponent;
|
|
77
102
|
export {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ContentHeader.es.js","sources":["../../../../src/components/Layout/ContentHeader/ContentHeader.tsx"],"sourcesContent":["/*\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { HTMLAttributes, ReactElement, useMemo } from \"react\";\nimport { Button, Props as ButtonProps } from \"../../Button/Button\";\nimport { Typography } from \"../../Typography/Typography\";\n\nimport classes from \"./ContentHeader.module.scss\";\nimport { IconButton } from \"../../Button/IconButton\";\nimport { Icon, Icons } from \"../../Icon/Icon\";\nimport { NavigateFunction } from \"react-router-dom\";\nimport { Tag, Props as TagProps } from \"../../Tag/Tag\";\nimport { TextEllipsis } from \"../../TextEllipsis/TextEllipsis\";\n\nexport interface ContentHeaderNavigationProps {\n displayText?: string;\n navigateFN: NavigateFunction;\n}\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n title: string;\n /**\n * @deprecated pass text as children\n */\n subtitle?: string;\n buttons?: ReactElement<ButtonProps, typeof Button> | ReactElement<ButtonProps, typeof Button>[];\n collapsed?: boolean;\n navigation?: ContentHeaderNavigationProps;\n tags?: ReactElement<TagProps, typeof Tag>[];\n error?: boolean;\n errorMessage?: string;\n errorTagText?: string;\n}\n\nexport const ContentHeaderComponent = ({\n title,\n children,\n buttons,\n collapsed,\n subtitle,\n navigation,\n tags,\n error,\n errorMessage,\n errorTagText,\n ...rest\n}: Props) => {\n const errorTag = (\n <Tag icon={Icons.Forbidden} backgroundColor=\"var(--color-red100)\" color=\"var(--color-red900)\">\n {errorTagText || \"Blocked\"}\n </Tag>\n );\n\n const getTags = () => tags ?? [];\n\n const renderTags = useMemo(() => {\n if (error && collapsed) {\n return [errorTag, ...getTags().filter(tag => tag.props.variant !== \"enabled\")];\n } else if (error) {\n return getTags().filter(tag => tag.props.variant !== \"enabled\");\n }\n return getTags();\n }, [tags, error, collapsed]);\n\n return (\n <div className={classes[\"header-background-color\"]}>\n <div\n className={`${classes[\"header\"]} ${rest.className} ${collapsed ? classes[\"collapsed-header\"] : \"\"}`}\n {...rest}\n >\n <div>\n {navigation && !collapsed && (\n <IconButton\n onClick={() => {\n navigation.navigateFN(-1);\n }}\n className={classes[\"back-arrow\"]}\n iconSize=\"s\"\n >\n <Icon icon={Icons.ArrowLeft} />\n <span className={classes[\"back-text\"]}>\n {navigation.displayText ? navigation.displayText : \"Back\"}\n </span>\n </IconButton>\n )}\n <Typography className={classes[\"header-text\"]} variant={\"h1\"}>\n {navigation && collapsed && (\n <IconButton\n onClick={() => {\n navigation.navigateFN(-1);\n }}\n className={classes[\"back-arrow\"]}\n >\n <Icon icon={Icons.ArrowLeft} />\n </IconButton>\n )}\n <TextEllipsis data-testid={\"content-header-title\"}>{title}</TextEllipsis>\n <span className={classes[\"header-tags\"]}>\n {renderTags.map((tag, index) => (\n <React.Fragment key={tag.key || index}>{tag}</React.Fragment>\n ))}\n </span>\n </Typography>\n {subtitle && !error && (\n <Typography\n className={`${classes[\"header-subtitle\"]} ${collapsed ? classes[\"hide-text\"] : \"\"}`}\n variant=\"h4\"\n >\n {subtitle}\n </Typography>\n )}\n <Typography\n className={`${collapsed ? classes[\"hide-text\"] : \"\"}`}\n variant=\"body\"\n spacing={{ margin: 0 }}\n >\n {error ? (\n <>\n {errorTag}\n <span className={classes[\"error-text\"]}>{errorMessage}</span>\n </>\n ) : (\n children\n )}\n </Typography>\n </div>\n {buttons && <div className={classes[\"buttons-wrapper\"]}>{buttons}</div>}\n </div>\n </div>\n );\n};\n\nexport const ContentHeader = ContentHeaderComponent;\n"],"names":[],"mappings":";;;;;;;AA+CO,MAAM,yBAAyB,CAAC;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAa;AACX,QAAM,WACJ,sBAAA,cAAC,KAAA,EAAI,MAAM,MAAM,WAAW,iBAAgB,uBAAsB,OAAM,sBAAA,GACrE,gBAAgB,SACnB;AAGF,QAAM,UAAU,MAAM,QAAQ,CAAA;AAE9B,QAAM,aAAa,QAAQ,MAAM;AAC/B,QAAI,SAAS,WAAW;AACtB,aAAO,CAAC,UAAU,GAAG,QAAA,EAAU,OAAO,CAAA,QAAO,IAAI,MAAM,YAAY,SAAS,CAAC;AAAA,IAC/E,WAAW,OAAO;AAChB,aAAO,UAAU,OAAO,SAAO,IAAI,MAAM,YAAY,SAAS;AAAA,IAChE;AACA,WAAO,QAAA;AAAA,E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,GAAG,QAAQ,iBAAiB,CAAC,IAAI,YAAY,QAAQ,WAAW,IAAI,EAAE;AAAA,QACjF,SAAQ;AAAA,MAAA;AAAA,MAEP;AAAA,IAAA,GAGL,sBAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAW,GAAG,YAAY,QAAQ,WAAW,IAAI,EAAE;AAAA,QACnD,SAAQ;AAAA,QACR,SAAS,EAAE,QAAQ,EAAA;AAAA,MAAE;AAAA,MAEpB,QACC,sBAAA,cAAA,MAAA,UAAA,MACG,UACD,sBAAA,cAAC,QAAA,EAAK,WAAW,QAAQ,YAAY,EAAA,GAAI,YAAa,CACxD,IAEA;AAAA,IAAA,CAGN;AAAA,IACC,WAAW,sBAAA,cAAC,OAAA,EAAI,WAAW,QAAQ,iBAAiB,KAAI,OAAQ;AAAA,EAAA,CAErE;AAEJ;AAEO,MAAM,gBAAgB;"}
|
|
1
|
+
{"version":3,"file":"ContentHeader.es.js","sources":["../../../../src/components/Layout/ContentHeader/ContentHeader.tsx"],"sourcesContent":["/*\n * Copyright 2022 OneWelcome B.V.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { HTMLAttributes, ReactElement, useLayoutEffect, useMemo, useRef } from \"react\";\nimport { Button, Props as ButtonProps } from \"../../Button/Button\";\nimport { Typography } from \"../../Typography/Typography\";\n\nimport classes from \"./ContentHeader.module.scss\";\nimport { IconButton } from \"../../Button/IconButton\";\nimport { Icon, Icons } from \"../../Icon/Icon\";\nimport { NavigateFunction } from \"react-router-dom\";\nimport { Tag, Props as TagProps } from \"../../Tag/Tag\";\nimport { TextEllipsis } from \"../../TextEllipsis/TextEllipsis\";\nimport { useStickyStacking } from \"../../../hooks/useStickyStacking\";\n\nconst STICKY_CONTENT_HEADER_Z_INDEX = 12; //Keeps the docked header above form fields(toggle).\n\nexport interface ContentHeaderNavigationProps {\n displayText?: string;\n navigateFN: NavigateFunction;\n}\n\nexport interface Props extends HTMLAttributes<HTMLDivElement> {\n title: string;\n /**\n * @deprecated pass text as children\n */\n subtitle?: string;\n buttons?: ReactElement<ButtonProps, typeof Button> | ReactElement<ButtonProps, typeof Button>[];\n collapsed?: boolean;\n navigation?: ContentHeaderNavigationProps;\n tags?: ReactElement<TagProps, typeof Tag>[];\n error?: boolean;\n errorMessage?: string;\n errorTagText?: string;\n sticky?: boolean;\n}\n\nexport const ContentHeaderComponent = ({\n title,\n children,\n buttons,\n collapsed,\n subtitle,\n navigation,\n tags,\n error,\n errorMessage,\n errorTagText,\n sticky,\n ...rest\n}: Props) => {\n const rootRef = useRef<HTMLDivElement>(null);\n const topBackButtonRef = useRef<HTMLButtonElement>(null);\n const inlineBackButtonRef = useRef<HTMLButtonElement>(null);\n\n const { isStuck } = useStickyStacking(rootRef, {\n enabled: !!sticky,\n zIndex: STICKY_CONTENT_HEADER_Z_INDEX,\n disableScrollAnchoring: true\n });\n const effectiveCollapsed = sticky ? isStuck || !!collapsed : !!collapsed;\n\n useLayoutEffect(() => {\n if (!navigation) {\n return;\n }\n if (effectiveCollapsed && document.activeElement === topBackButtonRef.current) {\n inlineBackButtonRef.current?.focus();\n } else if (!effectiveCollapsed && document.activeElement === inlineBackButtonRef.current) {\n topBackButtonRef.current?.focus();\n }\n }, [effectiveCollapsed, navigation]);\n\n const errorTag = (\n <Tag icon={Icons.Forbidden} backgroundColor=\"var(--color-red100)\" color=\"var(--color-red900)\">\n {errorTagText || \"Blocked\"}\n </Tag>\n );\n\n const getTags = () => tags ?? [];\n\n const renderTags = useMemo(() => {\n if (error && effectiveCollapsed) {\n return [errorTag, ...getTags().filter(tag => tag.props.variant !== \"enabled\")];\n } else if (error) {\n return getTags().filter(tag => tag.props.variant !== \"enabled\");\n }\n return getTags();\n }, [tags, error, effectiveCollapsed]);\n\n const collapsibleClassName = `${classes[\"collapsible\"]} ${\n effectiveCollapsed ? classes[\"collapsed\"] : \"\"\n }`;\n\n const renderBackButton = (\n ref: React.RefObject<HTMLButtonElement | null>,\n isActive: boolean,\n options: { withText?: boolean; iconSize?: \"s\" | \"m\" | \"l\" } = {}\n ) => (\n <IconButton\n ref={ref}\n onClick={() => navigation?.navigateFN(-1)}\n className={classes[\"back-arrow\"]}\n iconSize={options.iconSize}\n tabIndex={isActive ? 0 : -1}\n >\n <Icon icon={Icons.ArrowLeft} />\n {options.withText && (\n <span className={classes[\"back-text\"]}>\n {navigation?.displayText ? navigation.displayText : \"Back\"}\n </span>\n )}\n </IconButton>\n );\n\n return (\n <div\n className={`${classes[\"header-background-color\"]} ${sticky ? classes[\"sticky\"] : \"\"} ${\n sticky && isStuck ? classes[\"sticky-spacing\"] : \"\"\n }`}\n ref={rootRef}\n >\n <div\n className={`${classes[\"header\"]} ${rest.className} ${effectiveCollapsed ? classes[\"collapsed-header\"] : \"\"}`}\n {...rest}\n >\n <div>\n {navigation && (\n <div className={collapsibleClassName}>\n <div\n className={`${classes[\"collapsible-inner\"]} ${classes[\"navigation-top\"]} ${effectiveCollapsed ? classes[\"collapsed\"] : \"\"}`}\n aria-hidden={effectiveCollapsed}\n >\n {renderBackButton(topBackButtonRef, !effectiveCollapsed, {\n withText: true,\n iconSize: \"s\"\n })}\n </div>\n </div>\n )}\n <Typography className={classes[\"header-text\"]} variant={\"h1\"}>\n {navigation && (\n <span\n className={`${classes[\"inline-back\"]} ${effectiveCollapsed ? \"\" : classes[\"hidden\"]}`}\n aria-hidden={!effectiveCollapsed}\n >\n {renderBackButton(inlineBackButtonRef, effectiveCollapsed)}\n </span>\n )}\n <TextEllipsis data-testid={\"content-header-title\"}>{title}</TextEllipsis>\n <span className={classes[\"header-tags\"]}>\n {renderTags.map((tag, index) => (\n <React.Fragment key={tag.key || index}>{tag}</React.Fragment>\n ))}\n </span>\n </Typography>\n {subtitle && !error && (\n <div className={collapsibleClassName}>\n <div className={classes[\"collapsible-inner\"]} aria-hidden={effectiveCollapsed}>\n <Typography className={classes[\"header-subtitle\"]} variant=\"h4\">\n {subtitle}\n </Typography>\n </div>\n </div>\n )}\n <div className={collapsibleClassName}>\n <div className={classes[\"collapsible-inner\"]} aria-hidden={effectiveCollapsed}>\n <Typography variant=\"body\" spacing={{ margin: 0 }}>\n {error ? (\n <>\n {errorTag}\n <span className={classes[\"error-text\"]}>{errorMessage}</span>\n </>\n ) : (\n children\n )}\n </Typography>\n </div>\n </div>\n </div>\n {buttons && <div className={classes[\"buttons-wrapper\"]}>{buttons}</div>}\n </div>\n </div>\n );\n};\n\nexport const ContentHeader = ContentHeaderComponent;\n"],"names":[],"mappings":";;;;;;;;AA4BA,MAAM,gCAAgC;AAuB/B,MAAM,yBAAyB,CAAC;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAa;AACX,QAAM,UAAU,OAAuB,IAAI;AAC3C,QAAM,mBAAmB,OAA0B,IAAI;AACvD,QAAM,sBAAsB,OAA0B,IAAI;AAE1D,QAAM,EAAE,QAAA,IAAY,kBAAkB,SAAS;AAAA,IAC7C,SAAS,CAAC,CAAC;AAAA,IACX,QAAQ;AAAA,IACR,wBAAwB;AAAA,EAAA,CACzB;AACD,QAAM,qBAAqB,SAAS,WAAW,CAAC,CAAC,YAAY,CAAC,CAAC;AAE/D,kBAAgB,MAAM;;AACpB,QAAI,CAAC,YAAY;AACf;AAAA,IACF;AACA,QAAI,sBAAsB,SAAS,kBAAkB,iBAAiB,SAAS;AAC7E,gCAAoB,YAApB,mBAA6B;AAAA,IAC/B,WAAW,CAAC,sBAAsB,SAAS,kBAAkB,oBAAoB,SAAS;A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,sBAAA,cAAC,SAAI,WAAW,qBAAA,uCACb,OAAA,EAAI,WAAW,QAAQ,mBAAmB,GAAG,eAAa,sBACzD,sBAAA,cAAC,cAAW,SAAQ,QAAO,SAAS,EAAE,QAAQ,OAC3C,kEAEI,UACD,sBAAA,cAAC,UAAK,WAAW,QAAQ,YAAY,EAAA,GAAI,YAAa,CACxD,IAEA,QAEJ,CACF,CACF,CACF;AAAA,MACC,WAAW,sBAAA,cAAC,OAAA,EAAI,WAAW,QAAQ,iBAAiB,KAAI,OAAQ;AAAA,IAAA;AAAA,EACnE;AAGN;AAEO,MAAM,gBAAgB;"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode(".
|
|
2
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="
|
|
1
|
+
!function(){"use strict";try{if("undefined"!=typeof document){var e=document.createElement("style");e.appendChild(document.createTextNode(".ContentHeader_header_8eZbI{display:flex;align-items:flex-end;justify-content:space-between;gap:2rem;padding:2rem;z-index:1;transition:.5s;max-width:105rem}.ContentHeader_header_8eZbI.ContentHeader_collapsed-header_8eZbI{padding:1rem 2rem;transition:.5s}.ContentHeader_header_8eZbI.ContentHeader_collapsed-header_8eZbI .ContentHeader_buttons-wrapper_8eZbI{margin-bottom:.25rem}.ContentHeader_header-background-color_8eZbI{background-color:var(--color-blue-grey25)}.ContentHeader_header_8eZbI button.ContentHeader_back-arrow_8eZbI{width:auto;height:1rem;display:block;gap:.5rem}.ContentHeader_sticky_8eZbI{border-bottom:0 solid var(--color-white);transition:border-bottom-width .5s}.ContentHeader_sticky_8eZbI .ContentHeader_header_8eZbI,.ContentHeader_sticky_8eZbI .ContentHeader_header_8eZbI.ContentHeader_collapsed-header_8eZbI{transition:.5s}.ContentHeader_sticky-spacing_8eZbI{border-bottom-width:.5rem}.ContentHeader_collapsible_8eZbI{display:grid;grid-template-rows:1fr;transition:grid-template-rows .5s}.ContentHeader_collapsible_8eZbI.ContentHeader_collapsed_8eZbI{grid-template-rows:0fr}.ContentHeader_collapsible-inner_8eZbI{overflow:hidden;min-height:0}.ContentHeader_collapsible-inner_8eZbI.ContentHeader_navigation-top_8eZbI:not(.ContentHeader_collapsed_8eZbI){padding:.25rem;margin:-.25rem -.25rem .25rem}.ContentHeader_header-text_8eZbI{margin:0;font-weight:500;color:var(--color-blue-grey900);line-height:1.25;display:flex;align-items:center;max-width:65vw}@media screen and (max-width:900px){.ContentHeader_header-text_8eZbI{max-width:unset}.ContentHeader_header-text_8eZbI div{text-wrap:wrap}}.ContentHeader_header-text_8eZbI div{vertical-align:middle;align-self:center}.ContentHeader_header-text_8eZbI button.ContentHeader_back-arrow_8eZbI{margin-right:.5rem;width:2.5rem;height:2.5rem}.ContentHeader_header-tags_8eZbI{display:flex;margin-left:1rem;gap:.5rem}.ContentHeader_header-subtitle_8eZbI{color:var(--color-blue-grey400);font-weight:500}.ContentHeader_back-text_8eZbI{font-size:.875rem;font-weight:400;margin-left:.5rem}.ContentHeader_error-text_8eZbI{color:var(--color-red500);vertical-align:middle;margin-left:.5rem}.ContentHeader_navigation-top_8eZbI{margin-bottom:.5rem;transition:margin-bottom .5s,padding-bottom .5s}.ContentHeader_navigation-top_8eZbI.ContentHeader_collapsed_8eZbI{margin-bottom:0}.ContentHeader_inline-back_8eZbI{display:flex;overflow:hidden;max-width:4rem;transition:max-width .5s,opacity .5s;opacity:1}.ContentHeader_inline-back_8eZbI:not(.ContentHeader_hidden_8eZbI){padding:.25rem;margin:-.25rem}.ContentHeader_inline-back_8eZbI.ContentHeader_hidden_8eZbI{max-width:0;opacity:0}.ContentHeader_buttons-wrapper_8eZbI{display:flex;justify-content:flex-end;flex-shrink:0;gap:1rem;transition:margin-bottom .5s}")),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}}();
|
|
2
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="ContentHeader_header_8eZbI",t="ContentHeader_sticky_8eZbI",a="ContentHeader_collapsible_8eZbI",r="ContentHeader_collapsed_8eZbI",n="ContentHeader_hidden_8eZbI",o={header:e,"collapsed-header":"ContentHeader_collapsed-header_8eZbI","buttons-wrapper":"ContentHeader_buttons-wrapper_8eZbI","header-background-color":"ContentHeader_header-background-color_8eZbI","back-arrow":"ContentHeader_back-arrow_8eZbI",sticky:t,"sticky-spacing":"ContentHeader_sticky-spacing_8eZbI",collapsible:a,collapsed:r,"collapsible-inner":"ContentHeader_collapsible-inner_8eZbI","navigation-top":"ContentHeader_navigation-top_8eZbI","header-text":"ContentHeader_header-text_8eZbI","header-tags":"ContentHeader_header-tags_8eZbI","header-subtitle":"ContentHeader_header-subtitle_8eZbI","back-text":"ContentHeader_back-text_8eZbI","error-text":"ContentHeader_error-text_8eZbI","inline-back":"ContentHeader_inline-back_8eZbI",hidden:n};exports.collapsed=r,exports.collapsible=a,exports.default=o,exports.header=e,exports.hidden=n,exports.sticky=t;
|
|
3
3
|
//# sourceMappingURL=ContentHeader.module.scss.cjs.js.map
|