@geotab/zenith 3.1.1-beta.6 → 3.2.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +20 -0
- package/dist/advancedGroupsFilter/advancedGroupsFilter.js +136 -30
- package/dist/advancedGroupsFilter/advancedGroupsFilterForm.js +139 -34
- package/dist/advancedGroupsFilter/advancedGroupsFilterFormSection.js +352 -87
- package/dist/advancedGroupsFilter/advancedGroupsFilterSectionTooltip.d.ts +0 -1
- package/dist/advancedGroupsFilter/advancedGroupsFilterSectionTooltip.js +83 -9
- package/dist/alertRaw/alertRaw.js +175 -54
- package/dist/banner/bannerMultipLine.js +131 -23
- package/dist/banner/bannerSingleLine.js +110 -16
- package/dist/betaPill/betaPill.js +111 -20
- package/dist/bookmark/bookmark.js +95 -28
- package/dist/bulkEditControl/bulkEditControl.js +167 -34
- package/dist/calendar/calendar.js +943 -273
- package/dist/calendar/calendarUtils.js +157 -85
- package/dist/card/card.js +268 -123
- package/dist/chart/accessibleChart/accessibleChartNarrative.js +648 -555
- package/dist/chart/accessibleChart/accessibleChartTable.js +245 -86
- package/dist/chart/chart.js +36 -21
- package/dist/chart/chartAxis/chartAxis.js +85 -7
- package/dist/checkboxListWithAction/checkboxListWithAction.js +224 -69
- package/dist/chip/chip.js +195 -91
- package/dist/columnsSelector/columnsSelector.js +97 -12
- package/dist/columnsSelector/columnsTab/columnsTab.js +59 -15
- package/dist/columnsSelector/columnsTabGroup/columnsTabGroup.js +81 -34
- package/dist/comboboxSelected/comboboxSelected.js +1 -3
- package/dist/dataFeed/feedExpandControl/feedExpandControl.js +25 -10
- package/dist/dataGrid/columns/checkboxColumn/checkboxHeaderCell.js +92 -11
- package/dist/dataGrid/dataGrid.js +227 -117
- package/dist/dataGrid/emptySearchList/emptySearchList.js +56 -9
- package/dist/dataGrid/entitiesListActions/actions/columnsListButton.js +51 -7
- package/dist/dataGrid/entitiesListActions/actions/fullscreenButton.js +64 -18
- package/dist/dataGrid/withFlexibleColumns/components/columnSettings.js +84 -10
- package/dist/dataGrid/withFlexibleColumns/components/columnSettingsSidePanel.js +48 -16
- package/dist/dataGrid/withSelectableRows/components/bulkActions/bulkActions.js +223 -32
- package/dist/dataGrid/withSelectableRows/withSelectableRows.js +286 -213
- package/dist/dataGrid/withSortableColumns/columns/sortableColumnWrapper.js +178 -95
- package/dist/dateInputInner/dateInputInner.js +791 -476
- package/dist/dateInputInner/dateInputInnerControlBlock.js +125 -22
- package/dist/dateInputRaw/dateInputRaw.js +315 -104
- package/dist/dateInputRaw/utils/getLabel.js +38 -7
- package/dist/dateRangeInner/dateRangeInner.js +173 -59
- package/dist/dateRangeRaw/dateRangeRaw.js +601 -239
- package/dist/dateRangeRaw/utils/dateRangeUtils.js +629 -241
- package/dist/dateSelectionWrapper/dateSelectionWrapper.js +152 -14
- package/dist/dialog/dialogContent.js +123 -40
- package/dist/dropdownRaw/dropdownHelper.d.ts +2 -2
- package/dist/dropdownRaw/dropdownHelper.js +9 -9
- package/dist/dropdownRaw/dropdownList.js +447 -78
- package/dist/dropdownRaw/dropdownPopup.js +218 -20
- package/dist/dropdownRaw/dropdownRaw.js +866 -506
- package/dist/dropdownRaw/dropdownSearchableTrigger.js +223 -46
- package/dist/dropdownRaw/stateReducer/stateAction.d.ts +5 -1
- package/dist/dropdownRaw/stateReducer/stateActionType.d.ts +2 -1
- package/dist/dropdownRaw/stateReducer/stateActionType.js +1 -0
- package/dist/dropdownRaw/stateReducer/stateReducer.d.ts +6 -1
- package/dist/dropdownRaw/stateReducer/stateReducer.js +24 -12
- package/dist/dropdownRaw/stateReducer/stateReducerHelper.d.ts +2 -0
- package/dist/dropdownRaw/stateReducer/stateReducerHelper.js +20 -1
- package/dist/dropdownRaw/stateReducer/stateReducerTestData.d.ts +39 -0
- package/dist/dropdownRaw/stateReducer/stateReducerTestData.js +74 -0
- package/dist/dropdownRaw/types.d.ts +1 -0
- package/dist/favoriteButton/favoriteButton.js +59 -10
- package/dist/filters/components/filtersContainer.js +151 -64
- package/dist/filters/components/filtersEmptySelectedList.js +30 -4
- package/dist/filters/components/filtersSaveModal.js +140 -42
- package/dist/filters/components/filtersSavedChipComponent.js +318 -108
- package/dist/filters/components/filtersSearchItemData.js +127 -47
- package/dist/filters/components/filtersSearchList.js +381 -179
- package/dist/filters/components/filtersSelect.js +128 -61
- package/dist/filters/components/filtersSelectListItem.js +125 -13
- package/dist/filters/components/filtersSidePanel.js +510 -178
- package/dist/filters/components/filtersSidePanelDropdown.js +2 -2
- package/dist/filters/filters.js +445 -268
- package/dist/filtersBar/components/filtersBarPeriodPicker/getRangeOption.js +729 -272
- package/dist/filtersBar/components/resetComponentButton.js +45 -5
- package/dist/filtersBar/filtersBarActions/filtersBarActions.js +126 -15
- package/dist/filtersBar/filtersBarSidePanel/components/filtersBarSidePanelRadioGroup/filtersBarSidePanelRadioGroup.js +2 -2
- package/dist/filtersBar/filtersBarSidePanel/components/filtersBarSidePanelRange/filtersBarSidePanelRange.js +155 -49
- package/dist/filtersBar/filtersBarSidePanel/filtersBarSidePanel.js +360 -104
- package/dist/filtersBar/filtersContainer/filtersContainer.js +204 -134
- package/dist/formField/components/formFieldWithLabel.d.ts +2 -1
- package/dist/formField/components/formFieldWithLabel.js +3 -2
- package/dist/formField/components/formFieldWithoutLabel.d.ts +2 -1
- package/dist/formField/components/formFieldWithoutLabel.js +3 -3
- package/dist/formField/components/trailingComponent.d.ts +8 -0
- package/dist/formField/components/trailingComponent.js +11 -0
- package/dist/formField/formField.js +26 -11
- package/dist/formField/hooks/useError.js +100 -36
- package/dist/formGroup/components/reviewListToggle/reviewListToggle.js +72 -7
- package/dist/formGroup/hooks/useToggle.js +37 -11
- package/dist/formGroup/utils/getControls.js +8 -7
- package/dist/formLayout/hooks/useError.js +55 -15
- package/dist/formLayout/hooks/useFormButtons.js +128 -27
- package/dist/formSection/components/formSectionModal.js +1 -1
- package/dist/formSection/formSection.js +1 -1
- package/dist/formSection/hooks/useError.js +70 -22
- package/dist/formStepper/components/formStep.js +65 -10
- package/dist/formStepper/formStepper.js +129 -33
- package/dist/formStepperButtons/formStepperButtons.js +184 -38
- package/dist/groupsFilter/groupsHelper.d.ts +1 -1
- package/dist/groupsFilterRaw/groupsFilterAdjustmentState.js +162 -17
- package/dist/groupsFilterRaw/groupsFilterBox.js +137 -32
- package/dist/groupsFilterRaw/groupsFilterCommon.js +75 -8
- package/dist/groupsFilterRaw/groupsFilterCurrentlySelectedState.js +184 -25
- package/dist/groupsFilterRaw/groupsFilterHelper.d.ts +2 -1
- package/dist/groupsFilterRaw/groupsFilterHelper.js +284 -168
- package/dist/groupsFilterRaw/groupsFilterInitialState.js +266 -18
- package/dist/groupsFilterRaw/groupsFilterMenu.js +124 -9
- package/dist/groupsFilterRaw/groupsFilterRaw.d.ts +1 -0
- package/dist/groupsFilterRaw/groupsFilterRaw.js +816 -308
- package/dist/groupsFilterRaw/groupsFilterTestData.d.ts +155 -2
- package/dist/groupsFilterRaw/groupsFilterTestData.js +153 -58
- package/dist/groupsFilterRaw/groupsFilterTrigger.js +139 -35
- package/dist/groupsFilterRaw/groupsHelper.js +739 -208
- package/dist/groupsFilterRaw/stateReducer/stateReducerHelper.js +3 -1
- package/dist/groupsFilterRaw/types.d.ts +1 -0
- package/dist/header/components/collapsedItemsControl/collapsedItemsControl.js +107 -52
- package/dist/header/components/mobileFilterControl/mobileFilterControl.js +62 -9
- package/dist/header/components/mobileSearchControl/mobileSearchControl.js +119 -14
- package/dist/header/headerBack.js +64 -20
- package/dist/index.css +116 -74
- package/dist/index.d.ts +1 -0
- package/dist/index.js +4 -1
- package/dist/list/itemData/itemDataInternal.js +216 -51
- package/dist/list/listItem/listItem.js +168 -55
- package/dist/menu/components/menuErrorItem.js +33 -5
- package/dist/mobileSheet/mobileSheet.js +195 -69
- package/dist/modal/modal.js +300 -142
- package/dist/nav/nav.js +1 -1
- package/dist/nav/navFooter/navFooter.js +82 -39
- package/dist/nav/navFooter/navFooterAction/navFooterAction.js +52 -13
- package/dist/nav/navHeader/navHeader.js +86 -36
- package/dist/nav/navHeader/navHeaderSearch/navHeaderSearch.js +88 -29
- package/dist/nav/navItem/navItem.d.ts +3 -3
- package/dist/nav/navItem/navItem.js +35 -33
- package/dist/nav/navMobileBar/navMobileBar.js +67 -21
- package/dist/notification/notification.js +124 -21
- package/dist/pagination/paginationArrow.js +81 -11
- package/dist/pagination/paginationText/paginationText.js +45 -11
- package/dist/pill/components/pillNonActionable/pillNonActionable.js +93 -24
- package/dist/pillBox/components/pillBoxItem.js +52 -9
- package/dist/pillBox/pillBox.js +121 -20
- package/dist/pillExpandable/pillExpandable.js +333 -139
- package/dist/rangeRaw/rangeRaw.js +486 -141
- package/dist/rangeRaw/utils/rangeHelper.js +209 -39
- package/dist/searchInputRaw/searchInputRaw.js +180 -65
- package/dist/skeleton/skeleton.js +51 -6
- package/dist/sortControl/sortControl.js +152 -42
- package/dist/stepperRaw/stepperRaw.js +116 -42
- package/dist/summary/summary.js +94 -8
- package/dist/table/actions/actionsMenu.js +171 -78
- package/dist/table/flexible/columnSettings.js +80 -10
- package/dist/table/flexible/columnsList.js +110 -43
- package/dist/table/flexible/columnsPopup.js +77 -20
- package/dist/table/nested/useNestedRows.js +167 -77
- package/dist/table/selectable/selectableHeader.js +180 -41
- package/dist/table/selectable/useSelectableRows.js +270 -191
- package/dist/table/sortable/sortableHeader.js +153 -75
- package/dist/tabs/tabs.js +227 -118
- package/dist/timePickerRaw/timePickerRaw.js +278 -58
- package/dist/toastRaw/toastRaw.js +138 -32
- package/dist/toggleButton/toggleButton.d.ts +0 -1
- package/dist/toggleButtonRaw/toggleButtonRaw.d.ts +1 -0
- package/dist/toggleButtonRaw/toggleButtonRaw.js +146 -40
- package/dist/utils/formatDate.js +1001 -117
- package/{esm/utils/localization/translations/cs-json.js → dist/utils/localization/translations/cs.json} +11 -12
- package/{esm/utils/localization/translations/da-DK-json.js → dist/utils/localization/translations/da-DK.json} +31 -23
- package/{esm/utils/localization/translations/de-json.js → dist/utils/localization/translations/de.json} +12 -13
- package/dist/utils/localization/translations/en.json +308 -0
- package/{esm/utils/localization/translations/es-json.js → dist/utils/localization/translations/es.json} +11 -12
- package/{esm/utils/localization/translations/fi-FI-json.js → dist/utils/localization/translations/fi-FI.json} +31 -23
- package/{esm/utils/localization/translations/fr-FR-json.js → dist/utils/localization/translations/fr-FR.json} +12 -12
- package/{esm/utils/localization/translations/fr-json.js → dist/utils/localization/translations/fr.json} +11 -12
- package/{esm/utils/localization/translations/hu-HU-json.js → dist/utils/localization/translations/hu-HU.json} +31 -23
- package/{esm/utils/localization/translations/id-json.js → dist/utils/localization/translations/id.json} +11 -13
- package/{esm/utils/localization/translations/it-json.js → dist/utils/localization/translations/it.json} +11 -12
- package/{esm/utils/localization/translations/ja-json.js → dist/utils/localization/translations/ja.json} +11 -12
- package/{esm/utils/localization/translations/ko-KR-json.js → dist/utils/localization/translations/ko-KR.json} +24 -23
- package/{esm/utils/localization/translations/ms-json.js → dist/utils/localization/translations/ms.json} +11 -12
- package/{esm/utils/localization/translations/nb-NO-json.js → dist/utils/localization/translations/nb-NO.json} +31 -23
- package/{esm/utils/localization/translations/nl-json.js → dist/utils/localization/translations/nl.json} +11 -12
- package/{esm/utils/localization/translations/pl-json.js → dist/utils/localization/translations/pl.json} +11 -12
- package/{esm/utils/localization/translations/pt-BR-json.js → dist/utils/localization/translations/pt-BR.json} +11 -12
- package/{esm/utils/localization/translations/sk-SK-json.js → dist/utils/localization/translations/sk-SK.json} +31 -23
- package/{esm/utils/localization/translations/sv-json.js → dist/utils/localization/translations/sv.json} +11 -12
- package/{esm/utils/localization/translations/th-json.js → dist/utils/localization/translations/th.json} +11 -12
- package/{esm/utils/localization/translations/tr-json.js → dist/utils/localization/translations/tr.json} +11 -12
- package/{esm/utils/localization/translations/zh-Hans-json.js → dist/utils/localization/translations/zh-Hans.json} +11 -12
- package/{esm/utils/localization/translations/zh-TW-json.js → dist/utils/localization/translations/zh-TW.json} +11 -23
- package/dist/utils/localization/translationsDictionary.d.ts +2 -0
- package/dist/utils/localization/translationsDictionary.js +63 -0
- package/dist/utils/localization/useLanguage.js +2 -74
- package/esm/advancedGroupsFilter/advancedGroupsFilter.js +130 -29
- package/esm/advancedGroupsFilter/advancedGroupsFilterForm.js +133 -33
- package/esm/advancedGroupsFilter/advancedGroupsFilterFormSection.js +317 -65
- package/esm/advancedGroupsFilter/advancedGroupsFilterSectionTooltip.d.ts +0 -1
- package/esm/advancedGroupsFilter/advancedGroupsFilterSectionTooltip.js +77 -8
- package/esm/alertRaw/alertRaw.js +165 -51
- package/esm/banner/bannerMultipLine.js +121 -20
- package/esm/banner/bannerSingleLine.js +100 -13
- package/esm/betaPill/betaPill.js +105 -19
- package/esm/bookmark/bookmark.js +89 -27
- package/esm/bulkEditControl/bulkEditControl.js +161 -33
- package/esm/calendar/calendar.js +937 -272
- package/esm/calendar/calendarUtils.js +151 -84
- package/esm/card/card.js +233 -101
- package/esm/chart/accessibleChart/accessibleChartNarrative.js +642 -554
- package/esm/chart/accessibleChart/accessibleChartTable.js +239 -85
- package/esm/chart/chart.js +30 -20
- package/esm/chart/chartAxis/chartAxis.js +79 -6
- package/esm/checkboxListWithAction/checkboxListWithAction.js +218 -68
- package/esm/chip/chip.js +189 -90
- package/esm/columnsSelector/columnsSelector.js +91 -11
- package/esm/columnsSelector/columnsTab/columnsTab.js +53 -14
- package/esm/columnsSelector/columnsTabGroup/columnsTabGroup.js +75 -33
- package/esm/comboboxSelected/comboboxSelected.js +1 -3
- package/esm/dataFeed/feedExpandControl/feedExpandControl.js +21 -9
- package/esm/dataGrid/columns/checkboxColumn/checkboxHeaderCell.js +86 -10
- package/esm/dataGrid/dataGrid.js +221 -116
- package/esm/dataGrid/emptySearchList/emptySearchList.js +50 -8
- package/esm/dataGrid/entitiesListActions/actions/columnsListButton.js +45 -6
- package/esm/dataGrid/entitiesListActions/actions/fullscreenButton.js +58 -17
- package/esm/dataGrid/withFlexibleColumns/components/columnSettings.js +78 -9
- package/esm/dataGrid/withFlexibleColumns/components/columnSettingsSidePanel.js +44 -15
- package/esm/dataGrid/withSelectableRows/components/bulkActions/bulkActions.js +217 -31
- package/esm/dataGrid/withSelectableRows/withSelectableRows.js +280 -212
- package/esm/dataGrid/withSortableColumns/columns/sortableColumnWrapper.js +172 -94
- package/esm/dateInputInner/dateInputInner.js +785 -475
- package/esm/dateInputInner/dateInputInnerControlBlock.js +119 -21
- package/esm/dateInputRaw/dateInputRaw.js +309 -103
- package/esm/dateInputRaw/utils/getLabel.js +32 -6
- package/esm/dateRangeInner/dateRangeInner.js +167 -58
- package/esm/dateRangeRaw/dateRangeRaw.js +595 -238
- package/esm/dateRangeRaw/utils/dateRangeUtils.js +622 -239
- package/esm/dateSelectionWrapper/dateSelectionWrapper.js +146 -13
- package/esm/dialog/dialogContent.js +117 -39
- package/esm/dropdownRaw/dropdownHelper.d.ts +2 -2
- package/esm/dropdownRaw/dropdownHelper.js +10 -10
- package/esm/dropdownRaw/dropdownList.js +412 -56
- package/esm/dropdownRaw/dropdownPopup.js +212 -19
- package/esm/dropdownRaw/dropdownRaw.js +862 -507
- package/esm/dropdownRaw/dropdownSearchableTrigger.js +217 -45
- package/esm/dropdownRaw/stateReducer/stateAction.d.ts +5 -1
- package/esm/dropdownRaw/stateReducer/stateActionType.d.ts +2 -1
- package/esm/dropdownRaw/stateReducer/stateActionType.js +1 -0
- package/esm/dropdownRaw/stateReducer/stateReducer.d.ts +6 -1
- package/esm/dropdownRaw/stateReducer/stateReducer.js +24 -12
- package/esm/dropdownRaw/stateReducer/stateReducerHelper.d.ts +2 -0
- package/esm/dropdownRaw/stateReducer/stateReducerHelper.js +18 -0
- package/esm/dropdownRaw/stateReducer/stateReducerTestData.d.ts +39 -0
- package/esm/dropdownRaw/stateReducer/stateReducerTestData.js +71 -0
- package/esm/dropdownRaw/types.d.ts +1 -0
- package/esm/favoriteButton/favoriteButton.js +53 -9
- package/esm/filters/components/filtersContainer.js +141 -61
- package/esm/filters/components/filtersEmptySelectedList.js +24 -3
- package/esm/filters/components/filtersSaveModal.js +134 -41
- package/esm/filters/components/filtersSavedChipComponent.js +312 -107
- package/esm/filters/components/filtersSearchItemData.js +121 -46
- package/esm/filters/components/filtersSearchList.js +375 -178
- package/esm/filters/components/filtersSelect.js +122 -60
- package/esm/filters/components/filtersSelectListItem.js +119 -12
- package/esm/filters/components/filtersSidePanel.js +504 -177
- package/esm/filters/components/filtersSidePanelDropdown.js +2 -2
- package/esm/filters/filters.js +435 -265
- package/esm/filtersBar/components/filtersBarPeriodPicker/getRangeOption.js +722 -270
- package/esm/filtersBar/components/resetComponentButton.js +39 -4
- package/esm/filtersBar/filtersBarActions/filtersBarActions.js +120 -14
- package/esm/filtersBar/filtersBarSidePanel/components/filtersBarSidePanelRadioGroup/filtersBarSidePanelRadioGroup.js +2 -2
- package/esm/filtersBar/filtersBarSidePanel/components/filtersBarSidePanelRange/filtersBarSidePanelRange.js +149 -48
- package/esm/filtersBar/filtersBarSidePanel/filtersBarSidePanel.js +354 -103
- package/esm/filtersBar/filtersContainer/filtersContainer.js +198 -133
- package/esm/formField/components/formFieldWithLabel.d.ts +2 -1
- package/esm/formField/components/formFieldWithLabel.js +3 -2
- package/esm/formField/components/formFieldWithoutLabel.d.ts +2 -1
- package/esm/formField/components/formFieldWithoutLabel.js +3 -3
- package/esm/formField/components/trailingComponent.d.ts +8 -0
- package/esm/formField/components/trailingComponent.js +7 -0
- package/esm/formField/formField.js +27 -12
- package/esm/formField/hooks/useError.js +94 -35
- package/esm/formGroup/components/reviewListToggle/reviewListToggle.js +66 -6
- package/esm/formGroup/hooks/useToggle.js +31 -10
- package/esm/formGroup/utils/getControls.js +8 -7
- package/esm/formLayout/hooks/useError.js +49 -14
- package/esm/formLayout/hooks/useFormButtons.js +122 -26
- package/esm/formSection/components/formSectionModal.js +1 -1
- package/esm/formSection/formSection.js +1 -1
- package/esm/formSection/hooks/useError.js +64 -21
- package/esm/formStepper/components/formStep.js +59 -9
- package/esm/formStepper/formStepper.js +123 -32
- package/esm/formStepperButtons/formStepperButtons.js +178 -37
- package/esm/groupsFilter/groupsHelper.d.ts +1 -1
- package/esm/groupsFilterRaw/groupsFilterAdjustmentState.js +152 -14
- package/esm/groupsFilterRaw/groupsFilterBox.js +131 -31
- package/esm/groupsFilterRaw/groupsFilterCommon.js +69 -7
- package/esm/groupsFilterRaw/groupsFilterCurrentlySelectedState.js +178 -24
- package/esm/groupsFilterRaw/groupsFilterHelper.d.ts +2 -1
- package/esm/groupsFilterRaw/groupsFilterHelper.js +279 -168
- package/esm/groupsFilterRaw/groupsFilterInitialState.js +260 -17
- package/esm/groupsFilterRaw/groupsFilterMenu.js +118 -8
- package/esm/groupsFilterRaw/groupsFilterRaw.d.ts +1 -0
- package/esm/groupsFilterRaw/groupsFilterRaw.js +811 -308
- package/esm/groupsFilterRaw/groupsFilterTestData.d.ts +155 -2
- package/esm/groupsFilterRaw/groupsFilterTestData.js +152 -57
- package/esm/groupsFilterRaw/groupsFilterTrigger.js +133 -34
- package/esm/groupsFilterRaw/groupsHelper.js +733 -207
- package/esm/groupsFilterRaw/stateReducer/stateReducerHelper.js +3 -1
- package/esm/groupsFilterRaw/types.d.ts +1 -0
- package/esm/header/components/collapsedItemsControl/collapsedItemsControl.js +101 -51
- package/esm/header/components/mobileFilterControl/mobileFilterControl.js +56 -8
- package/esm/header/components/mobileSearchControl/mobileSearchControl.js +113 -13
- package/esm/header/headerBack.js +58 -19
- package/esm/index.d.ts +1 -0
- package/esm/index.js +1 -0
- package/esm/list/itemData/itemDataInternal.js +210 -50
- package/esm/list/listItem/listItem.js +162 -54
- package/esm/menu/components/menuErrorItem.js +27 -4
- package/esm/mobileSheet/mobileSheet.js +189 -68
- package/esm/modal/modal.js +265 -120
- package/esm/nav/nav.js +1 -1
- package/esm/nav/navFooter/navFooter.js +76 -38
- package/esm/nav/navFooter/navFooterAction/navFooterAction.js +46 -12
- package/esm/nav/navHeader/navHeader.js +80 -35
- package/esm/nav/navHeader/navHeaderSearch/navHeaderSearch.js +82 -28
- package/esm/nav/navItem/navItem.d.ts +3 -3
- package/esm/nav/navItem/navItem.js +35 -33
- package/esm/nav/navMobileBar/navMobileBar.js +61 -20
- package/esm/notification/notification.js +114 -18
- package/esm/pagination/paginationArrow.js +75 -10
- package/esm/pagination/paginationText/paginationText.js +39 -10
- package/esm/pill/components/pillNonActionable/pillNonActionable.js +87 -23
- package/esm/pillBox/components/pillBoxItem.js +46 -8
- package/esm/pillBox/pillBox.js +115 -19
- package/esm/pillExpandable/pillExpandable.js +327 -138
- package/esm/rangeRaw/rangeRaw.js +480 -140
- package/esm/rangeRaw/utils/rangeHelper.js +203 -38
- package/esm/searchInputRaw/searchInputRaw.js +145 -43
- package/esm/skeleton/skeleton.js +45 -5
- package/esm/sortControl/sortControl.js +146 -41
- package/esm/stepperRaw/stepperRaw.js +112 -41
- package/esm/storybookHelpers/dataGridWithDifferentCellOptions/components/EntitiesListAction.js +178 -19
- package/esm/summary/summary.js +88 -7
- package/esm/table/actions/actionsMenu.js +165 -77
- package/esm/table/flexible/columnSettings.js +74 -9
- package/esm/table/flexible/columnsList.js +104 -42
- package/esm/table/flexible/columnsPopup.js +71 -19
- package/esm/table/nested/useNestedRows.js +161 -76
- package/esm/table/selectable/selectableHeader.js +174 -40
- package/esm/table/selectable/useSelectableRows.js +264 -190
- package/esm/table/sortable/sortableHeader.js +147 -74
- package/esm/tabs/tabs.js +221 -117
- package/esm/timePickerRaw/timePickerRaw.js +272 -57
- package/esm/toastRaw/toastRaw.js +132 -31
- package/esm/toggleButton/toggleButton.d.ts +0 -1
- package/esm/toggleButtonRaw/toggleButtonRaw.d.ts +1 -0
- package/esm/toggleButtonRaw/toggleButtonRaw.js +111 -18
- package/esm/utils/formatDate.js +995 -116
- package/{dist/utils/localization/translations/cs-json.js → esm/utils/localization/translations/cs.json} +11 -15
- package/{dist/utils/localization/translations/da-DK-json.js → esm/utils/localization/translations/da-DK.json} +31 -26
- package/{dist/utils/localization/translations/de-json.js → esm/utils/localization/translations/de.json} +12 -16
- package/esm/utils/localization/translations/en.json +308 -0
- package/{dist/utils/localization/translations/es-json.js → esm/utils/localization/translations/es.json} +11 -15
- package/{dist/utils/localization/translations/fi-FI-json.js → esm/utils/localization/translations/fi-FI.json} +31 -26
- package/{dist/utils/localization/translations/fr-FR-json.js → esm/utils/localization/translations/fr-FR.json} +12 -15
- package/{dist/utils/localization/translations/fr-json.js → esm/utils/localization/translations/fr.json} +11 -15
- package/{dist/utils/localization/translations/hu-HU-json.js → esm/utils/localization/translations/hu-HU.json} +31 -26
- package/{dist/utils/localization/translations/id-json.js → esm/utils/localization/translations/id.json} +11 -16
- package/{dist/utils/localization/translations/it-json.js → esm/utils/localization/translations/it.json} +11 -15
- package/{dist/utils/localization/translations/ja-json.js → esm/utils/localization/translations/ja.json} +11 -15
- package/{dist/utils/localization/translations/ko-KR-json.js → esm/utils/localization/translations/ko-KR.json} +24 -26
- package/{dist/utils/localization/translations/ms-json.js → esm/utils/localization/translations/ms.json} +11 -15
- package/{dist/utils/localization/translations/nb-NO-json.js → esm/utils/localization/translations/nb-NO.json} +31 -26
- package/{dist/utils/localization/translations/nl-json.js → esm/utils/localization/translations/nl.json} +11 -15
- package/{dist/utils/localization/translations/pl-json.js → esm/utils/localization/translations/pl.json} +11 -15
- package/{dist/utils/localization/translations/pt-BR-json.js → esm/utils/localization/translations/pt-BR.json} +11 -15
- package/{dist/utils/localization/translations/sk-SK-json.js → esm/utils/localization/translations/sk-SK.json} +31 -26
- package/{dist/utils/localization/translations/sv-json.js → esm/utils/localization/translations/sv.json} +11 -15
- package/{dist/utils/localization/translations/th-json.js → esm/utils/localization/translations/th.json} +11 -15
- package/{dist/utils/localization/translations/tr-json.js → esm/utils/localization/translations/tr.json} +11 -15
- package/{dist/utils/localization/translations/zh-Hans-json.js → esm/utils/localization/translations/zh-Hans.json} +11 -15
- package/{dist/utils/localization/translations/zh-TW-json.js → esm/utils/localization/translations/zh-TW.json} +11 -26
- package/esm/utils/localization/translationsDictionary.d.ts +2 -0
- package/esm/utils/localization/translationsDictionary.js +59 -0
- package/esm/utils/localization/useLanguage.js +1 -50
- package/package.json +19 -12
- package/dist/utils/localization/translations/cs-json.d.ts +0 -251
- package/dist/utils/localization/translations/da-DK-json.d.ts +0 -252
- package/dist/utils/localization/translations/de-json.d.ts +0 -251
- package/dist/utils/localization/translations/en-json.d.ts +0 -314
- package/dist/utils/localization/translations/en-json.js +0 -317
- package/dist/utils/localization/translations/es-json.d.ts +0 -251
- package/dist/utils/localization/translations/fi-FI-json.d.ts +0 -252
- package/dist/utils/localization/translations/fr-FR-json.d.ts +0 -250
- package/dist/utils/localization/translations/fr-json.d.ts +0 -251
- package/dist/utils/localization/translations/hu-HU-json.d.ts +0 -252
- package/dist/utils/localization/translations/id-json.d.ts +0 -252
- package/dist/utils/localization/translations/it-json.d.ts +0 -251
- package/dist/utils/localization/translations/ja-json.d.ts +0 -251
- package/dist/utils/localization/translations/ko-KR-json.d.ts +0 -258
- package/dist/utils/localization/translations/ms-json.d.ts +0 -251
- package/dist/utils/localization/translations/nb-NO-json.d.ts +0 -252
- package/dist/utils/localization/translations/nl-json.d.ts +0 -251
- package/dist/utils/localization/translations/pl-json.d.ts +0 -251
- package/dist/utils/localization/translations/pt-BR-json.d.ts +0 -251
- package/dist/utils/localization/translations/sk-SK-json.d.ts +0 -251
- package/dist/utils/localization/translations/sv-json.d.ts +0 -251
- package/dist/utils/localization/translations/th-json.d.ts +0 -251
- package/dist/utils/localization/translations/tr-json.d.ts +0 -251
- package/dist/utils/localization/translations/zh-Hans-json.d.ts +0 -251
- package/dist/utils/localization/translations/zh-TW-json.d.ts +0 -271
- package/esm/utils/localization/translations/cs-json.d.ts +0 -251
- package/esm/utils/localization/translations/da-DK-json.d.ts +0 -252
- package/esm/utils/localization/translations/de-json.d.ts +0 -251
- package/esm/utils/localization/translations/en-json.d.ts +0 -314
- package/esm/utils/localization/translations/en-json.js +0 -314
- package/esm/utils/localization/translations/es-json.d.ts +0 -251
- package/esm/utils/localization/translations/fi-FI-json.d.ts +0 -252
- package/esm/utils/localization/translations/fr-FR-json.d.ts +0 -250
- package/esm/utils/localization/translations/fr-json.d.ts +0 -251
- package/esm/utils/localization/translations/hu-HU-json.d.ts +0 -252
- package/esm/utils/localization/translations/id-json.d.ts +0 -252
- package/esm/utils/localization/translations/it-json.d.ts +0 -251
- package/esm/utils/localization/translations/ja-json.d.ts +0 -251
- package/esm/utils/localization/translations/ko-KR-json.d.ts +0 -258
- package/esm/utils/localization/translations/ms-json.d.ts +0 -251
- package/esm/utils/localization/translations/nb-NO-json.d.ts +0 -252
- package/esm/utils/localization/translations/nl-json.d.ts +0 -251
- package/esm/utils/localization/translations/pl-json.d.ts +0 -251
- package/esm/utils/localization/translations/pt-BR-json.d.ts +0 -251
- package/esm/utils/localization/translations/sk-SK-json.d.ts +0 -251
- package/esm/utils/localization/translations/sv-json.d.ts +0 -251
- package/esm/utils/localization/translations/th-json.d.ts +0 -251
- package/esm/utils/localization/translations/tr-json.d.ts +0 -251
- package/esm/utils/localization/translations/zh-Hans-json.d.ts +0 -251
- package/esm/utils/localization/translations/zh-TW-json.d.ts +0 -271
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
const {
|
|
4
|
+
injectString
|
|
5
|
+
} = require("../../utils/localization/translationsDictionary");
|
|
6
|
+
Object.defineProperty(exports, "__esModule", {
|
|
7
|
+
value: true
|
|
8
|
+
});
|
|
3
9
|
exports.useError = void 0;
|
|
4
10
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
11
|
const react_1 = require("react");
|
|
@@ -7,43 +13,101 @@ const useFormField_1 = require("../../commonHelpers/hooks/useFormField");
|
|
|
7
13
|
const useLanguage_1 = require("../../utils/localization/useLanguage");
|
|
8
14
|
const formFieldBanner_1 = require("../components/formFieldBanner");
|
|
9
15
|
const loading_1 = require("../../commonHelpers/loading");
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
16
|
+
injectString("cs", "Reload", "Na\u010D\xEDst znovu");
|
|
17
|
+
injectString("da-DK", "Reload", "Genindl\xE6s");
|
|
18
|
+
injectString("de", "Reload", "Neu laden");
|
|
19
|
+
injectString("en", "Reload", "Reload");
|
|
20
|
+
injectString("es", "Reload", "Volver a cargar");
|
|
21
|
+
injectString("fi-FI", "Reload", "Ladata uudelleen");
|
|
22
|
+
injectString("fr", "Reload", "Recharger");
|
|
23
|
+
injectString("fr-FR", "Reload", "Actualiser");
|
|
24
|
+
injectString("hu-HU", "Reload", "\xDAjrat\xF6lt\xE9s");
|
|
25
|
+
injectString("id", "Reload", "Muat ulang");
|
|
26
|
+
injectString("it", "Reload", "Ricarica");
|
|
27
|
+
injectString("ja", "Reload", "\u518D\u8AAD\u8FBC");
|
|
28
|
+
injectString("ko-KR", "Reload", "\uB2E4\uC2DC \uBD88\uB7EC\uC624\uAE30");
|
|
29
|
+
injectString("ms", "Reload", "Muatkan semula");
|
|
30
|
+
injectString("nb-NO", "Reload", "Last inn p\xE5 nytt");
|
|
31
|
+
injectString("nl", "Reload", "Herladen");
|
|
32
|
+
injectString("pl", "Reload", "Od\u015Bwie\u017C");
|
|
33
|
+
injectString("pt-BR", "Reload", "Recarregar");
|
|
34
|
+
injectString("sk-SK", "Reload", "Obnovi\u0165");
|
|
35
|
+
injectString("sv", "Reload", "Ladda igen");
|
|
36
|
+
injectString("th", "Reload", "\u0E42\u0E2B\u0E25\u0E14\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07");
|
|
37
|
+
injectString("tr", "Reload", "Yeniden y\xFCkle");
|
|
38
|
+
injectString("zh-Hans", "Reload", "\u91CD\u65B0\u52A0\u8F7D");
|
|
39
|
+
injectString("zh-TW", "Reload", "\u91CD\u65B0\u8F09\u5165");
|
|
40
|
+
injectString("en", "Failed to load {0}", "Failed to load {0}");
|
|
41
|
+
injectString("cs", "This field is required.", "Toto pole je povinn\xE9.");
|
|
42
|
+
injectString("da-DK", "This field is required.", "Dette felt er p\xE5kr\xE6vet.");
|
|
43
|
+
injectString("de", "This field is required.", "Dieses Feld ist erforderlich.");
|
|
44
|
+
injectString("en", "This field is required.", "This field is required.");
|
|
45
|
+
injectString("es", "This field is required.", "Este campo es obligatorio.");
|
|
46
|
+
injectString("fi-FI", "This field is required.", "T\xE4m\xE4 kentt\xE4 on pakollinen.");
|
|
47
|
+
injectString("fr", "This field is required.", "Ce champ est obligatoire.");
|
|
48
|
+
injectString("fr-FR", "This field is required.", "Ce champ est requis.");
|
|
49
|
+
injectString("hu-HU", "This field is required.", "Ez a mez\u0151 k\xF6telez\u0151.");
|
|
50
|
+
injectString("id", "This field is required.", "Bidang ini harus diisi.");
|
|
51
|
+
injectString("it", "This field is required.", "Questo campo \xE8 obbligatorio.");
|
|
52
|
+
injectString("ja", "This field is required.", "\u3053\u306E\u30D5\u30A3\u30FC\u30EB\u30C9\u306F\u5FC5\u9808\u3067\u3059\u3002");
|
|
53
|
+
injectString("ko-KR", "This field is required.", "\uC774 \uD544\uB4DC\uB294 \uD544\uC218\uC785\uB2C8\uB2E4.");
|
|
54
|
+
injectString("ms", "This field is required.", "Medan ini diperlukan.");
|
|
55
|
+
injectString("nb-NO", "This field is required.", "Dette feltet er p\xE5krevd.");
|
|
56
|
+
injectString("nl", "This field is required.", "Dit veld is verplicht.");
|
|
57
|
+
injectString("pl", "This field is required.", "To pole jest wymagane.");
|
|
58
|
+
injectString("pt-BR", "This field is required.", "Este campo \xE9 obrigat\xF3rio.");
|
|
59
|
+
injectString("sk-SK", "This field is required.", "Toto pole je povinn\xE9.");
|
|
60
|
+
injectString("sv", "This field is required.", "Det h\xE4r f\xE4ltet \xE4r obligatoriskt.");
|
|
61
|
+
injectString("th", "This field is required.", "\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E2A\u0E48\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E43\u0E19\u0E1F\u0E34\u0E25\u0E14\u0E4C\u0E19\u0E35\u0E49");
|
|
62
|
+
injectString("tr", "This field is required.", "Bu alan zorunludur.");
|
|
63
|
+
injectString("zh-Hans", "This field is required.", "\u8BE5\u5B57\u6BB5\u4E3A\u5FC5\u586B\u9879\u3002");
|
|
64
|
+
injectString("zh-TW", "This field is required.", "\u6B64\u6B04\u4F4D\u70BA\u5FC5\u586B\u3002");
|
|
65
|
+
const useError = props => {
|
|
66
|
+
var _a, _b, _c, _d;
|
|
67
|
+
const errorId = (0, react_1.useId)();
|
|
68
|
+
const {
|
|
69
|
+
fieldState
|
|
70
|
+
} = (0, useFormField_1.useFormField)(props.controller);
|
|
71
|
+
const {
|
|
72
|
+
translate
|
|
73
|
+
} = (0, useLanguage_1.useLanguage)();
|
|
74
|
+
if ((0, loading_1.hasErrorProps)(props)) {
|
|
75
|
+
const action = props.retry ? {
|
|
76
|
+
text: translate("Reload"),
|
|
77
|
+
onClick: props.retry
|
|
78
|
+
} : undefined;
|
|
79
|
+
return {
|
|
80
|
+
id: errorId,
|
|
81
|
+
errorBanner: (0, jsx_runtime_1.jsx)(formFieldBanner_1.FormFieldBanner, {
|
|
82
|
+
multiline: false,
|
|
83
|
+
action: action,
|
|
84
|
+
type: "error",
|
|
85
|
+
children: translate("Failed to load {0}").replace("{0}", props.bannerLabel || "")
|
|
86
|
+
})
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
if (!props.error && !((_a = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _a === void 0 ? void 0 : _a.message) || props.isReadOnly) {
|
|
90
|
+
if (props.isReadOnly) {
|
|
91
|
+
return {
|
|
92
|
+
id: "",
|
|
93
|
+
error: null
|
|
94
|
+
};
|
|
24
95
|
}
|
|
25
|
-
if ((
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
if (!((_b = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _b === void 0 ? void 0 : _b.message) && ((_c = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _c === void 0 ? void 0 : _c.type) === "required") {
|
|
33
|
-
return {
|
|
34
|
-
id: errorId,
|
|
35
|
-
error: translate("This field is required.")
|
|
36
|
-
};
|
|
37
|
-
}
|
|
38
|
-
return {
|
|
39
|
-
id: "",
|
|
40
|
-
error: null
|
|
41
|
-
};
|
|
96
|
+
if (!((_b = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _b === void 0 ? void 0 : _b.message) && ((_c = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _c === void 0 ? void 0 : _c.type) === "required") {
|
|
97
|
+
return {
|
|
98
|
+
id: errorId,
|
|
99
|
+
error: translate("This field is required.")
|
|
100
|
+
};
|
|
42
101
|
}
|
|
43
|
-
const error = ((_d = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _d === void 0 ? void 0 : _d.message) || props.error;
|
|
44
102
|
return {
|
|
45
|
-
|
|
46
|
-
|
|
103
|
+
id: "",
|
|
104
|
+
error: null
|
|
47
105
|
};
|
|
106
|
+
}
|
|
107
|
+
const error = ((_d = fieldState === null || fieldState === void 0 ? void 0 : fieldState.error) === null || _d === void 0 ? void 0 : _d.message) || props.error;
|
|
108
|
+
return {
|
|
109
|
+
id: error ? errorId : "",
|
|
110
|
+
error
|
|
111
|
+
};
|
|
48
112
|
};
|
|
49
|
-
exports.useError = useError;
|
|
113
|
+
exports.useError = useError;
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
const {
|
|
4
|
+
injectString
|
|
5
|
+
} = require("../../../utils/localization/translationsDictionary");
|
|
6
|
+
Object.defineProperty(exports, "__esModule", {
|
|
7
|
+
value: true
|
|
8
|
+
});
|
|
3
9
|
exports.ReviewListToggle = void 0;
|
|
4
10
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
11
|
const classNames_1 = require("../../../commonHelpers/classNames/classNames");
|
|
@@ -7,10 +13,69 @@ const iconCheckRadio_1 = require("../../../icons/iconCheckRadio");
|
|
|
7
13
|
const iconCloseCircle_1 = require("../../../icons/iconCloseCircle");
|
|
8
14
|
const pill_1 = require("../../../pill/pill");
|
|
9
15
|
const useLanguage_1 = require("../../../utils/localization/useLanguage");
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
16
|
+
injectString("cs", "On", "Zapnout");
|
|
17
|
+
injectString("da-DK", "On", "P\xE5");
|
|
18
|
+
injectString("de", "On", "Ein");
|
|
19
|
+
injectString("en", "On", "On");
|
|
20
|
+
injectString("es", "On", "Activar");
|
|
21
|
+
injectString("fi-FI", "On", "P\xE4\xE4lle");
|
|
22
|
+
injectString("fr", "On", "Activ\xE9");
|
|
23
|
+
injectString("fr-FR", "On", "On");
|
|
24
|
+
injectString("hu-HU", "On", "Bekapcsolva");
|
|
25
|
+
injectString("id", "On", "Aktif");
|
|
26
|
+
injectString("it", "On", "On");
|
|
27
|
+
injectString("ja", "On", "\u30AA\u30F3");
|
|
28
|
+
injectString("ko-KR", "On", "~\uC5D0");
|
|
29
|
+
injectString("ms", "On", "Hidup");
|
|
30
|
+
injectString("nb-NO", "On", "P\xE5");
|
|
31
|
+
injectString("nl", "On", "Aan");
|
|
32
|
+
injectString("pl", "On", "W\u0142.");
|
|
33
|
+
injectString("pt-BR", "On", "Ativado");
|
|
34
|
+
injectString("sk-SK", "On", "Zapnut\xE9");
|
|
35
|
+
injectString("sv", "On", "P\xE5");
|
|
36
|
+
injectString("th", "On", "\u0E40\u0E1B\u0E34\u0E14");
|
|
37
|
+
injectString("tr", "On", "A\xE7\u0131k");
|
|
38
|
+
injectString("zh-Hans", "On", "\u5F00\u542F");
|
|
39
|
+
injectString("zh-TW", "On", "\u958B\u555F");
|
|
40
|
+
injectString("cs", "Off", "Vypnout");
|
|
41
|
+
injectString("da-DK", "Off", "Slukket");
|
|
42
|
+
injectString("de", "Off", "Aus");
|
|
43
|
+
injectString("en", "Off", "Off");
|
|
44
|
+
injectString("es", "Off", "Desactivar");
|
|
45
|
+
injectString("fi-FI", "Off", "Pois");
|
|
46
|
+
injectString("fr", "Off", "D\xE9sactiv\xE9");
|
|
47
|
+
injectString("fr-FR", "Off", "Off");
|
|
48
|
+
injectString("hu-HU", "Off", "Kikapcsolva");
|
|
49
|
+
injectString("id", "Off", "Nonaktif");
|
|
50
|
+
injectString("it", "Off", "Off");
|
|
51
|
+
injectString("ja", "Off", "\u30AA\u30D5");
|
|
52
|
+
injectString("ko-KR", "Off", "\uB044\uB2E4");
|
|
53
|
+
injectString("ms", "Off", "Mati");
|
|
54
|
+
injectString("nb-NO", "Off", "Av");
|
|
55
|
+
injectString("nl", "Off", "Uit");
|
|
56
|
+
injectString("pl", "Off", "Wy\u0142.");
|
|
57
|
+
injectString("pt-BR", "Off", "Desativado");
|
|
58
|
+
injectString("sk-SK", "Off", "Vypnut\xE9");
|
|
59
|
+
injectString("sv", "Off", "Av");
|
|
60
|
+
injectString("th", "Off", "\u0E1B\u0E34\u0E14");
|
|
61
|
+
injectString("tr", "Off", "Kapal\u0131");
|
|
62
|
+
injectString("zh-Hans", "Off", "\u5173\u95ED");
|
|
63
|
+
injectString("zh-TW", "Off", "\u95DC\u9589");
|
|
64
|
+
const ReviewListToggle = ({
|
|
65
|
+
value,
|
|
66
|
+
className = ""
|
|
67
|
+
}) => {
|
|
68
|
+
const {
|
|
69
|
+
translate
|
|
70
|
+
} = (0, useLanguage_1.useLanguage)();
|
|
71
|
+
const label = value ? translate("On") : translate("Off");
|
|
72
|
+
const icon = value ? iconCheckRadio_1.IconCheckRadio : iconCloseCircle_1.IconCloseCircle;
|
|
73
|
+
return (0, jsx_runtime_1.jsxs)("div", {
|
|
74
|
+
className: (0, classNames_1.classNames)([className, "zen-review-list-toggle"]),
|
|
75
|
+
children: [label, (0, jsx_runtime_1.jsx)(pill_1.Pill, {
|
|
76
|
+
type: "info",
|
|
77
|
+
icon: icon
|
|
78
|
+
})]
|
|
79
|
+
});
|
|
15
80
|
};
|
|
16
|
-
exports.ReviewListToggle = ReviewListToggle;
|
|
81
|
+
exports.ReviewListToggle = ReviewListToggle;
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
const {
|
|
4
|
+
injectString
|
|
5
|
+
} = require("../../utils/localization/translationsDictionary");
|
|
6
|
+
Object.defineProperty(exports, "__esModule", {
|
|
7
|
+
value: true
|
|
8
|
+
});
|
|
3
9
|
exports.useToggle = void 0;
|
|
4
10
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
11
|
const react_1 = require("react");
|
|
@@ -12,14 +18,34 @@ const useLanguage_1 = require("../../utils/localization/useLanguage");
|
|
|
12
18
|
const classNames_1 = require("../../commonHelpers/classNames/classNames");
|
|
13
19
|
const getListClasses_1 = require("../utils/getListClasses");
|
|
14
20
|
const useColumns_1 = require("../../formLayout/hooks/useColumns");
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
21
|
+
injectString("en", "Sub-options are not active.", "Sub-options are not active.");
|
|
22
|
+
const useToggle = result => {
|
|
23
|
+
const {
|
|
24
|
+
controller,
|
|
25
|
+
toggle,
|
|
26
|
+
onToggleChange
|
|
27
|
+
} = (0, react_1.useContext)(formGroupProvider_1.FormGroupContext);
|
|
28
|
+
const {
|
|
29
|
+
value = false
|
|
30
|
+
} = (0, useFormFieldValues_1.useFormFieldValues)(controller, {
|
|
31
|
+
value: toggle,
|
|
32
|
+
onChange: onToggleChange
|
|
33
|
+
});
|
|
34
|
+
const hasToggle = controller !== undefined || toggle !== undefined && onToggleChange !== undefined;
|
|
35
|
+
const mode = (0, useMode_1.useMode)();
|
|
36
|
+
const columns = (0, useColumns_1.useColumns)();
|
|
37
|
+
const {
|
|
38
|
+
translate
|
|
39
|
+
} = (0, useLanguage_1.useLanguage)();
|
|
40
|
+
// TODO: accessibility: do we need id here?
|
|
41
|
+
return (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, {
|
|
42
|
+
children: [(0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, {
|
|
43
|
+
children: [hasToggle && (0, jsx_runtime_1.jsx)(listToggle_1.ListToggle, {}), hasToggle && !value && mode === "review" ? (0, jsx_runtime_1.jsx)(reviewTextControl_1.ReviewTextControl, {
|
|
44
|
+
secondary: true,
|
|
45
|
+
className: (0, classNames_1.classNames)([(0, getListClasses_1.getListClasses)("left", columns, true)]),
|
|
46
|
+
value: translate("Sub-options are not active.")
|
|
47
|
+
}) : null, hasToggle && value ? result : value === undefined ? result : null]
|
|
48
|
+
}), !hasToggle && result]
|
|
49
|
+
});
|
|
24
50
|
};
|
|
25
|
-
exports.useToggle = useToggle;
|
|
51
|
+
exports.useToggle = useToggle;
|
|
@@ -7,19 +7,20 @@ const getControls = (elements) => {
|
|
|
7
7
|
let control1;
|
|
8
8
|
let control2;
|
|
9
9
|
if ((_a = elements.control1) === null || _a === void 0 ? void 0 : _a.value) {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
const element = elements.control1.value;
|
|
11
|
+
const isDOMElement = typeof element.type === "string";
|
|
12
|
+
control1 = (0, react_1.cloneElement)(element, Object.assign({ className: `zen-form-control ${elements.control1.className || ""}` }, (isDOMElement ? {} : {
|
|
13
13
|
isReadOnly: !!elements.control1.isReadOnly,
|
|
14
14
|
bannerLabel: (_b = elements.label1) === null || _b === void 0 ? void 0 : _b.value
|
|
15
|
-
});
|
|
15
|
+
})));
|
|
16
16
|
}
|
|
17
17
|
if ((_c = elements.control2) === null || _c === void 0 ? void 0 : _c.value) {
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
const element = elements.control2.value;
|
|
19
|
+
const isDOMElement = typeof element.type === "string";
|
|
20
|
+
control2 = (0, react_1.cloneElement)(element, Object.assign({ className: `zen-form-control ${elements.control2.className || ""}` }, (isDOMElement ? {} : {
|
|
20
21
|
isReadOnly: !!elements.control2.isReadOnly,
|
|
21
22
|
bannerLabel: (_d = elements.label2) === null || _d === void 0 ? void 0 : _d.value
|
|
22
|
-
});
|
|
23
|
+
})));
|
|
23
24
|
}
|
|
24
25
|
return { control1, control2 };
|
|
25
26
|
};
|
|
@@ -1,24 +1,64 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
const {
|
|
4
|
+
injectString
|
|
5
|
+
} = require("../../utils/localization/translationsDictionary");
|
|
6
|
+
Object.defineProperty(exports, "__esModule", {
|
|
7
|
+
value: true
|
|
8
|
+
});
|
|
3
9
|
exports.useError = void 0;
|
|
4
10
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
11
|
const banner_1 = require("../../banner/banner");
|
|
6
12
|
const loading_1 = require("../../commonHelpers/loading");
|
|
7
13
|
const useLanguage_1 = require("../../utils/localization/useLanguage");
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
14
|
+
injectString("cs", "Reload", "Na\u010D\xEDst znovu");
|
|
15
|
+
injectString("da-DK", "Reload", "Genindl\xE6s");
|
|
16
|
+
injectString("de", "Reload", "Neu laden");
|
|
17
|
+
injectString("en", "Reload", "Reload");
|
|
18
|
+
injectString("es", "Reload", "Volver a cargar");
|
|
19
|
+
injectString("fi-FI", "Reload", "Ladata uudelleen");
|
|
20
|
+
injectString("fr", "Reload", "Recharger");
|
|
21
|
+
injectString("fr-FR", "Reload", "Actualiser");
|
|
22
|
+
injectString("hu-HU", "Reload", "\xDAjrat\xF6lt\xE9s");
|
|
23
|
+
injectString("id", "Reload", "Muat ulang");
|
|
24
|
+
injectString("it", "Reload", "Ricarica");
|
|
25
|
+
injectString("ja", "Reload", "\u518D\u8AAD\u8FBC");
|
|
26
|
+
injectString("ko-KR", "Reload", "\uB2E4\uC2DC \uBD88\uB7EC\uC624\uAE30");
|
|
27
|
+
injectString("ms", "Reload", "Muatkan semula");
|
|
28
|
+
injectString("nb-NO", "Reload", "Last inn p\xE5 nytt");
|
|
29
|
+
injectString("nl", "Reload", "Herladen");
|
|
30
|
+
injectString("pl", "Reload", "Od\u015Bwie\u017C");
|
|
31
|
+
injectString("pt-BR", "Reload", "Recarregar");
|
|
32
|
+
injectString("sk-SK", "Reload", "Obnovi\u0165");
|
|
33
|
+
injectString("sv", "Reload", "Ladda igen");
|
|
34
|
+
injectString("th", "Reload", "\u0E42\u0E2B\u0E25\u0E14\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07");
|
|
35
|
+
injectString("tr", "Reload", "Yeniden y\xFCkle");
|
|
36
|
+
injectString("zh-Hans", "Reload", "\u91CD\u65B0\u52A0\u8F7D");
|
|
37
|
+
injectString("zh-TW", "Reload", "\u91CD\u65B0\u8F09\u5165");
|
|
38
|
+
injectString("en", "Failed to load page", "Failed to load page");
|
|
39
|
+
injectString("en", "Please refresh the page and try again. If the issue persists, contact Support.", "Please refresh the page and try again. If the issue persists, contact Support.");
|
|
40
|
+
const useError = props => {
|
|
41
|
+
const {
|
|
42
|
+
translate
|
|
43
|
+
} = (0, useLanguage_1.useLanguage)();
|
|
44
|
+
if (!(0, loading_1.hasErrorProps)(props)) {
|
|
19
45
|
return {
|
|
20
|
-
|
|
21
|
-
error: (0, jsx_runtime_1.jsx)(banner_1.Banner, { size: "XL", header: translate("Failed to load page"), action: action, type: "error", children: translate("Please refresh the page and try again. If the issue persists, contact Support.") })
|
|
46
|
+
error: null
|
|
22
47
|
};
|
|
48
|
+
}
|
|
49
|
+
const action = props.retry ? {
|
|
50
|
+
text: translate("Reload"),
|
|
51
|
+
onClick: props.retry
|
|
52
|
+
} : undefined;
|
|
53
|
+
return {
|
|
54
|
+
// TODO: add translations
|
|
55
|
+
error: (0, jsx_runtime_1.jsx)(banner_1.Banner, {
|
|
56
|
+
size: "XL",
|
|
57
|
+
header: translate("Failed to load page"),
|
|
58
|
+
action: action,
|
|
59
|
+
type: "error",
|
|
60
|
+
children: translate("Please refresh the page and try again. If the issue persists, contact Support.")
|
|
61
|
+
})
|
|
62
|
+
};
|
|
23
63
|
};
|
|
24
|
-
exports.useError = useError;
|
|
64
|
+
exports.useError = useError;
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
const {
|
|
4
|
+
injectString
|
|
5
|
+
} = require("../../utils/localization/translationsDictionary");
|
|
6
|
+
Object.defineProperty(exports, "__esModule", {
|
|
7
|
+
value: true
|
|
8
|
+
});
|
|
3
9
|
exports.useFormButtons = void 0;
|
|
4
10
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
11
|
const react_1 = require("react");
|
|
@@ -9,31 +15,126 @@ const buttonType_1 = require("../../button/buttonType");
|
|
|
9
15
|
const iconDisk_1 = require("../../icons/iconDisk");
|
|
10
16
|
const iconClose_1 = require("../../icons/iconClose");
|
|
11
17
|
const useLanguage_1 = require("../../utils/localization/useLanguage");
|
|
18
|
+
injectString("cs", "Save", "Ulo\u017Eit");
|
|
19
|
+
injectString("da-DK", "Save", "Spare");
|
|
20
|
+
injectString("de", "Save", "Speichern");
|
|
21
|
+
injectString("en", "Save", "Save");
|
|
22
|
+
injectString("es", "Save", "Guardar");
|
|
23
|
+
injectString("fi-FI", "Save", "S\xE4\xE4st\xE4\xE4");
|
|
24
|
+
injectString("fr", "Save", "Enregistrer");
|
|
25
|
+
injectString("fr-FR", "Save", "Enregistrer");
|
|
26
|
+
injectString("hu-HU", "Save", "Ment\xE9s");
|
|
27
|
+
injectString("id", "Save", "Simpan");
|
|
28
|
+
injectString("it", "Save", "Salvare");
|
|
29
|
+
injectString("ja", "Save", "\u4FDD\u5B58");
|
|
30
|
+
injectString("ko-KR", "Save", "\uC800\uC7A5");
|
|
31
|
+
injectString("ms", "Save", "Simpan");
|
|
32
|
+
injectString("nb-NO", "Save", "Lagre");
|
|
33
|
+
injectString("nl", "Save", "Opslaan");
|
|
34
|
+
injectString("pl", "Save", "Zapisz");
|
|
35
|
+
injectString("pt-BR", "Save", "Salvar");
|
|
36
|
+
injectString("sk-SK", "Save", "Ulo\u017Ei\u0165");
|
|
37
|
+
injectString("sv", "Save", "Spara");
|
|
38
|
+
injectString("th", "Save", "\u0E1A\u0E31\u0E19\u0E17\u0E36\u0E01");
|
|
39
|
+
injectString("tr", "Save", "Kaydet");
|
|
40
|
+
injectString("zh-Hans", "Save", "\u4FDD\u5B58");
|
|
41
|
+
injectString("zh-TW", "Save", "\u5132\u5B58");
|
|
42
|
+
injectString("cs", "Edit", "Upravit");
|
|
43
|
+
injectString("da-DK", "Edit", "Rediger");
|
|
44
|
+
injectString("de", "Edit", "Bearbeiten");
|
|
45
|
+
injectString("en", "Edit", "Edit");
|
|
46
|
+
injectString("es", "Edit", "Editar");
|
|
47
|
+
injectString("fi-FI", "Edit", "Muokkaa");
|
|
48
|
+
injectString("fr", "Edit", "Modifier");
|
|
49
|
+
injectString("fr-FR", "Edit", "Modifier");
|
|
50
|
+
injectString("hu-HU", "Edit", "Szerkeszd meg.");
|
|
51
|
+
injectString("id", "Edit", "Edit");
|
|
52
|
+
injectString("it", "Edit", "Modifica");
|
|
53
|
+
injectString("ja", "Edit", "\u7DE8\u96C6");
|
|
54
|
+
injectString("ko-KR", "Edit", "\uD3B8\uC9D1");
|
|
55
|
+
injectString("ms", "Edit", "Edit");
|
|
56
|
+
injectString("nb-NO", "Edit", "Rediger");
|
|
57
|
+
injectString("nl", "Edit", "Bewerken");
|
|
58
|
+
injectString("pl", "Edit", "Edytuj");
|
|
59
|
+
injectString("pt-BR", "Edit", "Editar");
|
|
60
|
+
injectString("sk-SK", "Edit", "Uprav.");
|
|
61
|
+
injectString("sv", "Edit", "Redigera");
|
|
62
|
+
injectString("th", "Edit", "\u0E41\u0E01\u0E49\u0E44\u0E02");
|
|
63
|
+
injectString("tr", "Edit", "D\xFCzenle");
|
|
64
|
+
injectString("zh-Hans", "Edit", "\u7F16\u8F91");
|
|
65
|
+
injectString("zh-TW", "Edit", "\u7DE8\u8F2F");
|
|
66
|
+
injectString("cs", "Cancel", "Zru\u0161it");
|
|
67
|
+
injectString("da-DK", "Cancel", "Annuller");
|
|
68
|
+
injectString("de", "Cancel", "Abbrechen");
|
|
69
|
+
injectString("en", "Cancel", "Cancel");
|
|
70
|
+
injectString("es", "Cancel", "Cancelar");
|
|
71
|
+
injectString("fi-FI", "Cancel", "Peruuta");
|
|
72
|
+
injectString("fr", "Cancel", "Annuler");
|
|
73
|
+
injectString("fr-FR", "Cancel", "Annuler");
|
|
74
|
+
injectString("hu-HU", "Cancel", "M\xE9gse");
|
|
75
|
+
injectString("id", "Cancel", "Batalkan");
|
|
76
|
+
injectString("it", "Cancel", "Annullare");
|
|
77
|
+
injectString("ja", "Cancel", "\u30AD\u30E3\u30F3\u30BB\u30EB");
|
|
78
|
+
injectString("ko-KR", "Cancel", "\uCDE8\uC18C");
|
|
79
|
+
injectString("ms", "Cancel", "Batal");
|
|
80
|
+
injectString("nb-NO", "Cancel", "Avbryt");
|
|
81
|
+
injectString("nl", "Cancel", "Annuleren");
|
|
82
|
+
injectString("pl", "Cancel", "Anuluj");
|
|
83
|
+
injectString("pt-BR", "Cancel", "Cancelar");
|
|
84
|
+
injectString("sk-SK", "Cancel", "Zru\u0161.");
|
|
85
|
+
injectString("sv", "Cancel", "Avbryt");
|
|
86
|
+
injectString("th", "Cancel", "\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01");
|
|
87
|
+
injectString("tr", "Cancel", "\u0130ptal");
|
|
88
|
+
injectString("zh-Hans", "Cancel", "\u53D6\u6D88");
|
|
89
|
+
injectString("zh-TW", "Cancel", "\u53D6\u6D88");
|
|
12
90
|
const useFormButtons = (props = {}) => {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
91
|
+
const {
|
|
92
|
+
onSave,
|
|
93
|
+
onEdit,
|
|
94
|
+
onCancel
|
|
95
|
+
} = props;
|
|
96
|
+
const [mode, setMode] = (0, react_1.useState)(props.mode || "review");
|
|
97
|
+
const isReview = mode === "review";
|
|
98
|
+
const {
|
|
99
|
+
translate
|
|
100
|
+
} = (0, useLanguage_1.useLanguage)();
|
|
101
|
+
const saveButton = (0, react_1.useMemo)(() => (0, jsx_runtime_1.jsx)(header_1.Header.Button, {
|
|
102
|
+
important: true,
|
|
103
|
+
icon: iconDisk_1.IconDisk,
|
|
104
|
+
title: translate("Save"),
|
|
105
|
+
onClick: (...args) => {
|
|
106
|
+
onSave === null || onSave === void 0 ? void 0 : onSave(...args);
|
|
107
|
+
setMode("review");
|
|
108
|
+
},
|
|
109
|
+
id: "form-save",
|
|
110
|
+
type: buttonType_1.ButtonType.Primary
|
|
111
|
+
}, "form-save"), [onSave, translate]);
|
|
112
|
+
const editButton = (0, react_1.useMemo)(() => (0, jsx_runtime_1.jsx)(header_1.Header.Button, {
|
|
113
|
+
important: true,
|
|
114
|
+
icon: iconEdit_1.IconEdit,
|
|
115
|
+
title: translate("Edit"),
|
|
116
|
+
onClick: () => {
|
|
117
|
+
onEdit === null || onEdit === void 0 ? void 0 : onEdit();
|
|
118
|
+
setMode("edit");
|
|
119
|
+
},
|
|
120
|
+
id: "form-edit",
|
|
121
|
+
type: buttonType_1.ButtonType.Primary
|
|
122
|
+
}, "form-edit"), [onEdit, translate]);
|
|
123
|
+
const cancelButton = (0, react_1.useMemo)(() => (0, jsx_runtime_1.jsx)(header_1.Header.Button, {
|
|
124
|
+
important: true,
|
|
125
|
+
icon: iconClose_1.IconClose,
|
|
126
|
+
title: translate("Cancel"),
|
|
127
|
+
onClick: () => {
|
|
128
|
+
setMode("review");
|
|
129
|
+
onCancel === null || onCancel === void 0 ? void 0 : onCancel();
|
|
130
|
+
},
|
|
131
|
+
id: "form-cancel",
|
|
132
|
+
type: buttonType_1.ButtonType.Secondary
|
|
133
|
+
}, "form-cancel"), [onCancel, translate]);
|
|
134
|
+
const buttons = (0, react_1.useMemo)(() => [!isReview ? saveButton : null, !isReview ? cancelButton : null, isReview ? editButton : null].filter(el => !!el), [cancelButton, editButton, isReview, saveButton]);
|
|
135
|
+
return {
|
|
136
|
+
mode,
|
|
137
|
+
buttons
|
|
138
|
+
};
|
|
38
139
|
};
|
|
39
|
-
exports.useFormButtons = useFormButtons;
|
|
140
|
+
exports.useFormButtons = useFormButtons;
|
|
@@ -5,5 +5,5 @@ const jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
5
5
|
const modal_1 = require("../../modal/modal");
|
|
6
6
|
const formSectionDefault_1 = require("./formSectionDefault");
|
|
7
7
|
// TODO: readonly mode?
|
|
8
|
-
const FormSectionModal = (props) => (0, jsx_runtime_1.jsxs)(modal_1.Modal, { className: "zen-form-section-modal", isOpen: props.isOpen, onClose: props.onClose, title: props.title, children: [(0, jsx_runtime_1.jsx)(formSectionDefault_1.FormSectionDefault, { type: "modal", labelAlign: props.labelAlign, className: props.className, children: props.children }), (0, jsx_runtime_1.jsx)(modal_1.Modal.SecondaryButton, { onClick: props.onCancel, children: "Cancel" }), (0, jsx_runtime_1.jsx)(modal_1.Modal.PrimaryButton, { onClick: props.onConfirm, children: "Confirm" })] });
|
|
8
|
+
const FormSectionModal = (props) => (0, jsx_runtime_1.jsxs)(modal_1.Modal, { className: "zen-form-section-modal", isOpen: props.isOpen, onClose: props.onClose, title: props.title, children: [(0, jsx_runtime_1.jsx)(formSectionDefault_1.FormSectionDefault, { type: "modal", mode: props.mode, labelAlign: props.labelAlign, className: props.className, children: props.children }), (0, jsx_runtime_1.jsx)(modal_1.Modal.SecondaryButton, { onClick: props.onCancel, children: "Cancel" }), (0, jsx_runtime_1.jsx)(modal_1.Modal.PrimaryButton, { onClick: props.onConfirm, children: "Confirm" })] });
|
|
9
9
|
exports.FormSectionModal = FormSectionModal;
|
|
@@ -38,7 +38,7 @@ const FormSection = (props) => {
|
|
|
38
38
|
return (0, jsx_runtime_1.jsx)(formSectionCard_1.FormSectionCard, Object.assign({ mode: mode, labelAlign: labelAlign, className: className }, cardProps, { children: props.children }));
|
|
39
39
|
}
|
|
40
40
|
if ((0, isModalSection_1.isModalSection)(props)) {
|
|
41
|
-
return (0, jsx_runtime_1.jsx)(formSectionModal_1.FormSectionModal, { type: "modal", isOpen: props.isOpen, onClose: props.onClose, title: props.title, labelAlign: labelAlign, className: props.className, onConfirm: props.onConfirm, onCancel: props.onCancel, children: props.children });
|
|
41
|
+
return (0, jsx_runtime_1.jsx)(formSectionModal_1.FormSectionModal, { type: "modal", isOpen: props.isOpen, onClose: props.onClose, title: props.title, labelAlign: labelAlign, className: props.className, onConfirm: props.onConfirm, onCancel: props.onCancel, mode: mode, children: props.children });
|
|
42
42
|
}
|
|
43
43
|
return (0, jsx_runtime_1.jsx)(formSectionDefault_1.FormSectionDefault, { mode: mode, title: props.title, labelAlign: labelAlign, className: props.className, children: props.children });
|
|
44
44
|
};
|