@geotab/zenith 3.16.0-beta.1 → 3.16.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -10
- package/dist/absolute/absolute.js +1 -1
- package/dist/advancedGroupsFilter/advancedGroupsFilter.js +3 -3
- package/dist/advancedGroupsFilter/advancedGroupsFilterForm.js +2 -2
- package/dist/advancedGroupsFilter/advancedGroupsFilterFormSection.js +7 -7
- package/dist/advancedGroupsFilter/advancedGroupsFilterSectionTooltip.js +1 -1
- package/dist/alertRaw/alertRaw.js +1 -1
- package/dist/banner/bannerMultipLine.js +1 -1
- package/dist/banner/bannerSingleLine.js +1 -1
- package/dist/banner/utils/useSummaryBannerProp.js +1 -1
- package/dist/betaPill/betaPill.js +4 -4
- package/dist/bookmark/bookmark.js +2 -2
- package/dist/bulkEditControl/bulkEditControl.js +5 -5
- package/dist/calendar/calendar.js +30 -30
- package/dist/calendar/calendarUtils.js +6 -6
- package/dist/card/card.js +1 -1
- package/dist/chart/accessibleChart/accessibleChartNarrative.js +13 -13
- package/dist/chart/accessibleChart/accessibleChartTable.js +5 -5
- package/dist/chart/accessibleChart/generatePieNarrative.js +6 -6
- package/dist/chart/barChart.js +1 -1
- package/dist/chart/chart.js +1 -1
- package/dist/chart/chartAxis/chartAxis.js +2 -2
- package/dist/chart/lineChart.js +1 -1
- package/dist/chart/pieChart.js +1 -1
- package/dist/chart/plugins/linePlugin/getInterpolatedValue.d.ts +2 -2
- package/dist/chart/plugins/linePlugin/getInterpolatedValue.js +3 -2
- package/dist/chart/plugins/linePlugin/linePlugin.js +2 -1
- package/dist/chart/utils/getFormattedLabel.js +5 -1
- package/dist/checkbox/checkbox.d.ts +2 -1
- package/dist/checkbox/checkbox.js +2 -2
- package/dist/checkboxListWithAction/checkboxListWithAction.js +5 -4
- package/dist/chip/chip.js +1 -1
- package/dist/columnsSelector/columnsSelector.js +2 -2
- package/dist/columnsSelector/columnsTab/columnsTab.js +1 -1
- package/dist/columnsSelector/columnsTabGroup/columnsTabGroup.js +1 -1
- package/dist/commonHelpers/hooks/useTrapFocus.d.ts +0 -9
- package/dist/commonHelpers/hooks/useTrapFocus.js +14 -66
- package/dist/controlledPopup/controlledPopup.d.ts +1 -1
- package/dist/controlledPopup/controlledPopup.js +17 -3
- package/dist/dataFeed/feedExpandControl/feedExpandControl.js +2 -2
- package/dist/dataGrid/columns/checkboxColumn/checkboxCell.d.ts +2 -1
- package/dist/dataGrid/columns/checkboxColumn/checkboxCell.js +1 -1
- package/dist/dataGrid/columns/checkboxColumn/checkboxColumnWrapper.d.ts +4 -2
- package/dist/dataGrid/columns/checkboxColumn/checkboxColumnWrapper.js +10 -1
- package/dist/dataGrid/columns/checkboxColumn/checkboxHeaderCell.js +1 -1
- package/dist/dataGrid/dataGrid.js +1 -1
- package/dist/dataGrid/emptySearchList/emptySearchList.js +1 -1
- package/dist/dataGrid/entitiesListActions/actions/columnsListButton.js +1 -1
- package/dist/dataGrid/entitiesListActions/actions/fullscreenButton.js +2 -2
- package/dist/dataGrid/row/row.js +3 -2
- package/dist/dataGrid/withFlexibleColumns/components/columnSettings.js +2 -2
- package/dist/dataGrid/withFlexibleColumns/components/columnSettingsSidePanel.js +1 -1
- package/dist/dataGrid/withFlexibleColumns/withFlexibleColumns.js +1 -1
- package/dist/dataGrid/withSelectableRows/components/bulkActions/bulkActions.js +5 -5
- package/dist/dataGrid/withSelectableRows/withSelectableRows.js +77 -16
- package/dist/dataGrid/withSortableColumns/columns/sortableColumnWrapper.js +2 -2
- package/dist/dateInputInner/dateInputInner.js +7 -7
- package/dist/dateInputInner/dateInputInnerControlBlock.js +2 -2
- package/dist/dateInputRaw/dateInputRaw.js +3 -3
- package/dist/dateInputRaw/utils/getLabel.js +2 -2
- package/dist/dateRangeInner/dateRangeInner.js +1 -1
- package/dist/dateRangeRaw/dateRangeRaw.js +10 -10
- package/dist/dateRangeRaw/utils/dateRangeUtils.js +17 -17
- package/dist/dateSelectionWrapper/dateSelectionWrapper.js +4 -4
- package/dist/dialog/dialogContent.js +1 -1
- package/dist/dropdown/dropdownTrigger.d.ts +1 -1
- package/dist/dropdownRaw/dropdownList.js +9 -9
- package/dist/dropdownRaw/dropdownPopup.js +3 -3
- package/dist/dropdownRaw/dropdownRaw.js +249 -3
- package/dist/dropdownRaw/dropdownSearchableTrigger.d.ts +2 -1
- package/dist/dropdownRaw/dropdownSearchableTrigger.js +8 -6
- package/dist/dropdownRaw/dropdownTrigger.d.ts +2 -1
- package/dist/dropdownRaw/dropdownTrigger.js +2 -2
- package/dist/dropdownRaw/types.d.ts +7 -0
- package/dist/favoriteButton/favoriteButton.js +1 -1
- package/dist/fileUpload/components/dropZoneContent.js +4 -4
- package/dist/fileUpload/components/templateDownloadSection.js +1 -1
- package/dist/fileUpload/components/uploadedFilesSection.js +2 -2
- package/dist/fileUpload/fileUpload.js +6 -6
- package/dist/filters/components/filtersContainer.js +3 -3
- package/dist/filters/components/filtersEmptyState.js +2 -2
- package/dist/filters/components/filtersSaveModal.js +5 -5
- package/dist/filters/components/filtersSavedChipComponent.js +11 -11
- package/dist/filters/components/filtersSearchItemData.js +1 -1
- package/dist/filters/components/filtersSearchList.js +9 -9
- package/dist/filters/components/filtersSelect.js +1 -1
- package/dist/filters/components/filtersSelectListItem.js +2 -2
- package/dist/filters/components/filtersSidePanel.js +8 -8
- package/dist/filters/filters.js +4 -3
- package/dist/filtersBar/components/filtersBarPeriodPicker/getRangeOption.js +18 -18
- package/dist/filtersBar/components/resetComponentButton.js +1 -1
- package/dist/filtersBar/filtersBarActions/filtersBarActions.js +4 -4
- package/dist/filtersBar/filtersBarSidePanel/components/filtersBarSidePanelRange/filtersBarSidePanelRange.js +2 -2
- package/dist/filtersBar/filtersBarSidePanel/filtersBarSidePanel.js +5 -5
- package/dist/filtersBar/filtersContainer/filtersContainer.js +2 -2
- package/dist/formField/hooks/useError.js +3 -3
- package/dist/formGroup/components/reviewListToggle/reviewListToggle.js +2 -2
- package/dist/formGroup/hooks/useToggle.js +1 -1
- package/dist/formLayout/hooks/useError.js +3 -3
- package/dist/formLayout/hooks/useFormButtons.js +3 -3
- package/dist/formSection/hooks/useError.js +3 -3
- package/dist/formStepper/components/formStep.js +1 -1
- package/dist/formStepper/formStepper.js +2 -2
- package/dist/formStepperButtons/formStepperButtons.js +4 -4
- package/dist/groupsFilterRaw/groupsFilterAdjustmentState.js +4 -4
- package/dist/groupsFilterRaw/groupsFilterBox.js +3 -3
- package/dist/groupsFilterRaw/groupsFilterCommon.js +2 -2
- package/dist/groupsFilterRaw/groupsFilterCurrentlySelectedState.js +5 -5
- package/dist/groupsFilterRaw/groupsFilterHelper.js +2 -2
- package/dist/groupsFilterRaw/groupsFilterInitialState.js +8 -8
- package/dist/groupsFilterRaw/groupsFilterMenu.js +3 -3
- package/dist/groupsFilterRaw/groupsFilterRaw.js +8 -8
- package/dist/groupsFilterRaw/groupsFilterTrigger.js +2 -2
- package/dist/groupsFilterRaw/groupsHelper.js +22 -22
- package/dist/header/components/collapsedItemsControl/collapsedItemsControl.js +1 -1
- package/dist/header/components/mobileFilterControl/mobileFilterControl.js +1 -1
- package/dist/header/components/mobileSearchControl/mobileSearchControl.js +3 -3
- package/dist/header/headerBack.js +1 -1
- package/dist/index.css +90 -84
- package/dist/index.d.ts +3 -0
- package/dist/index.js +8 -3
- package/dist/lineChart/lineChart.js +1 -1
- package/dist/lineChartMini/lineChartMini.js +1 -1
- package/dist/list/itemData/itemDataInternal.js +2 -2
- package/dist/list/listItem/listItem.js +2 -2
- package/dist/menu/components/menuErrorItem.js +2 -2
- package/dist/mobileSheet/mobileSheet.js +2 -2
- package/dist/modal/modal.js +1 -1
- package/dist/nav/navFooter/navEditFooter/navEditFooter.js +2 -2
- package/dist/nav/navFooter/navFooter.js +1 -1
- package/dist/nav/navFooter/navFooterAction/navFooterAction.js +1 -1
- package/dist/nav/navHeader/navHeader.js +2 -2
- package/dist/nav/navHeader/navHeaderSearch/navHeaderSearch.js +2 -2
- package/dist/nav/navMobileBar/navMobileBar.js +1 -1
- package/dist/notification/notification.js +1 -1
- package/dist/pagination/paginationArrow.js +2 -2
- package/dist/pagination/paginationText/paginationText.js +1 -1
- package/dist/pill/components/pillNonActionable/pillNonActionable.js +1 -1
- package/dist/pillBox/components/pillBoxItem.js +1 -1
- package/dist/pillBox/pillBox.js +3 -3
- package/dist/pillExpandable/pillExpandable.js +1 -1
- package/dist/pillExpandable/pillExpandableAlignments.js +65 -48
- package/dist/progressIndicator/progressIndicator.d.ts +4 -4
- package/dist/progressIndicator/progressIndicator.js +4 -4
- package/dist/rangeRaw/rangeRaw.js +7 -7
- package/dist/rangeRaw/utils/rangeHelper.js +7 -7
- package/dist/searchInputRaw/searchInputRaw.js +2 -2
- package/dist/selectList/selectList.js +2 -2
- package/dist/skeleton/skeleton.js +1 -1
- package/dist/sortControl/sortControl.js +5 -5
- package/dist/stepperRaw/stepperRaw.js +2 -2
- package/dist/summary/summary.js +2 -2
- package/dist/summaryTile/summaryTile.js +1 -1
- package/dist/table/actions/actionsMenu.js +2 -2
- package/dist/table/detailPanel/detailPanel.js +1 -1
- package/dist/table/detailPanel/detailPanelHeader.js +2 -2
- package/dist/table/flexible/columnSettings.js +2 -2
- package/dist/table/flexible/columnsPopup.js +1 -1
- package/dist/table/nested/useNestedRows.js +2 -2
- package/dist/table/selectable/interfaces.d.ts +9 -13
- package/dist/table/selectable/selectableHeader.js +5 -5
- package/dist/table/selectable/useDragSelection.d.ts +10 -0
- package/dist/table/selectable/useDragSelection.js +139 -0
- package/dist/table/selectable/useSelectableRows.d.ts +2 -2
- package/dist/table/selectable/useSelectableRows.js +61 -51
- package/dist/table/selectable/utils/calculateSelectionState.js +0 -35
- package/dist/table/selectable/utils/getDragSelectionRows.d.ts +15 -0
- package/dist/table/selectable/utils/getDragSelectionRows.js +28 -0
- package/dist/table/selectable/utils/getRangeIds.d.ts +2 -0
- package/dist/table/selectable/utils/getRangeIds.js +21 -0
- package/dist/table/selectable/utils/isRowChecked.js +1 -12
- package/dist/table/sortable/mobileSortControl.js +3 -3
- package/dist/table/sortable/sortableHeader.js +2 -2
- package/dist/table/table.d.ts +4 -0
- package/dist/table/table.js +11 -7
- package/dist/tabs/tabs.js +2 -2
- package/dist/tag/tag.d.ts +3 -2
- package/dist/tag/tag.js +3 -2
- package/dist/timePickerRaw/timePickerRaw.js +7 -7
- package/dist/toastRaw/toastRaw.js +1 -1
- package/dist/toggleButtonRaw/toggleButtonRaw.js +2 -2
- package/dist/tooltip/tooltip.js +5 -2
- package/dist/utils/formatDate.js +37 -37
- package/dist/utils/localization/flipAlignment.js +5 -1
- package/dist/utils/localization/getSupportedLanguage.d.ts +1 -1
- package/dist/utils/localization/getSupportedLanguage.js +8 -2
- package/dist/utils/localization/getTextDirection.js +1 -1
- package/dist/utils/localization/languageContext.d.ts +1 -1
- package/dist/utils/localization/translations/{ar.json → ar-001.json} +54 -53
- package/dist/utils/localization/translationsDictionary.js +1 -1
- package/dist/utils/localization/useRTLAlignment.d.ts +6 -0
- package/dist/utils/localization/useRTLAlignment.js +6 -0
- package/esm/absolute/absolute.js +1 -1
- package/esm/advancedGroupsFilter/advancedGroupsFilter.js +3 -3
- package/esm/advancedGroupsFilter/advancedGroupsFilterForm.js +2 -2
- package/esm/advancedGroupsFilter/advancedGroupsFilterFormSection.js +7 -7
- package/esm/advancedGroupsFilter/advancedGroupsFilterSectionTooltip.js +1 -1
- package/esm/alertRaw/alertRaw.js +1 -1
- package/esm/banner/bannerMultipLine.js +1 -1
- package/esm/banner/bannerSingleLine.js +1 -1
- package/esm/banner/utils/useSummaryBannerProp.js +1 -1
- package/esm/betaPill/betaPill.js +4 -4
- package/esm/bookmark/bookmark.js +2 -2
- package/esm/bulkEditControl/bulkEditControl.js +5 -5
- package/esm/calendar/calendar.js +30 -30
- package/esm/calendar/calendarUtils.js +6 -6
- package/esm/card/card.js +1 -1
- package/esm/chart/accessibleChart/accessibleChartNarrative.js +13 -13
- package/esm/chart/accessibleChart/accessibleChartTable.js +5 -5
- package/esm/chart/accessibleChart/generatePieNarrative.js +6 -6
- package/esm/chart/barChart.js +1 -1
- package/esm/chart/chart.js +1 -1
- package/esm/chart/chartAxis/chartAxis.js +2 -2
- package/esm/chart/lineChart.js +1 -1
- package/esm/chart/pieChart.js +1 -1
- package/esm/chart/plugins/linePlugin/getInterpolatedValue.d.ts +2 -2
- package/esm/chart/plugins/linePlugin/getInterpolatedValue.js +3 -2
- package/esm/chart/plugins/linePlugin/linePlugin.js +2 -1
- package/esm/chart/utils/getFormattedLabel.js +5 -1
- package/esm/checkbox/checkbox.d.ts +2 -1
- package/esm/checkbox/checkbox.js +2 -2
- package/esm/checkboxListWithAction/checkboxListWithAction.js +5 -4
- package/esm/chip/chip.js +1 -1
- package/esm/columnsSelector/columnsSelector.js +2 -2
- package/esm/columnsSelector/columnsTab/columnsTab.js +1 -1
- package/esm/columnsSelector/columnsTabGroup/columnsTabGroup.js +1 -1
- package/esm/commonHelpers/hooks/useTrapFocus.d.ts +0 -9
- package/esm/commonHelpers/hooks/useTrapFocus.js +15 -67
- package/esm/controlledPopup/controlledPopup.d.ts +1 -1
- package/esm/controlledPopup/controlledPopup.js +17 -3
- package/esm/dataFeed/feedExpandControl/feedExpandControl.js +2 -2
- package/esm/dataGrid/columns/checkboxColumn/checkboxCell.d.ts +2 -1
- package/esm/dataGrid/columns/checkboxColumn/checkboxCell.js +1 -1
- package/esm/dataGrid/columns/checkboxColumn/checkboxColumnWrapper.d.ts +4 -2
- package/esm/dataGrid/columns/checkboxColumn/checkboxColumnWrapper.js +10 -1
- package/esm/dataGrid/columns/checkboxColumn/checkboxHeaderCell.js +1 -1
- package/esm/dataGrid/dataGrid.js +1 -1
- package/esm/dataGrid/emptySearchList/emptySearchList.js +1 -1
- package/esm/dataGrid/entitiesListActions/actions/columnsListButton.js +1 -1
- package/esm/dataGrid/entitiesListActions/actions/fullscreenButton.js +2 -2
- package/esm/dataGrid/row/row.js +3 -2
- package/esm/dataGrid/withFlexibleColumns/components/columnSettings.js +2 -2
- package/esm/dataGrid/withFlexibleColumns/components/columnSettingsSidePanel.js +1 -1
- package/esm/dataGrid/withFlexibleColumns/withFlexibleColumns.js +1 -1
- package/esm/dataGrid/withSelectableRows/components/bulkActions/bulkActions.js +5 -5
- package/esm/dataGrid/withSelectableRows/withSelectableRows.js +77 -16
- package/esm/dataGrid/withSortableColumns/columns/sortableColumnWrapper.js +2 -2
- package/esm/dateInputInner/dateInputInner.js +7 -7
- package/esm/dateInputInner/dateInputInnerControlBlock.js +2 -2
- package/esm/dateInputRaw/dateInputRaw.js +3 -3
- package/esm/dateInputRaw/utils/getLabel.js +2 -2
- package/esm/dateRangeInner/dateRangeInner.js +1 -1
- package/esm/dateRangeRaw/dateRangeRaw.js +10 -10
- package/esm/dateRangeRaw/utils/dateRangeUtils.js +17 -17
- package/esm/dateSelectionWrapper/dateSelectionWrapper.js +4 -4
- package/esm/dialog/dialogContent.js +1 -1
- package/esm/dropdown/dropdownTrigger.d.ts +1 -1
- package/esm/dropdownRaw/dropdownList.js +9 -9
- package/esm/dropdownRaw/dropdownPopup.js +3 -3
- package/esm/dropdownRaw/dropdownRaw.js +249 -3
- package/esm/dropdownRaw/dropdownSearchableTrigger.d.ts +2 -1
- package/esm/dropdownRaw/dropdownSearchableTrigger.js +8 -6
- package/esm/dropdownRaw/dropdownTrigger.d.ts +2 -1
- package/esm/dropdownRaw/dropdownTrigger.js +2 -2
- package/esm/dropdownRaw/types.d.ts +7 -0
- package/esm/favoriteButton/favoriteButton.js +1 -1
- package/esm/fileUpload/components/dropZoneContent.js +4 -4
- package/esm/fileUpload/components/templateDownloadSection.js +1 -1
- package/esm/fileUpload/components/uploadedFilesSection.js +2 -2
- package/esm/fileUpload/fileUpload.js +6 -6
- package/esm/filters/components/filtersContainer.js +3 -3
- package/esm/filters/components/filtersEmptyState.js +2 -2
- package/esm/filters/components/filtersSaveModal.js +5 -5
- package/esm/filters/components/filtersSavedChipComponent.js +11 -11
- package/esm/filters/components/filtersSearchItemData.js +1 -1
- package/esm/filters/components/filtersSearchList.js +9 -9
- package/esm/filters/components/filtersSelect.js +1 -1
- package/esm/filters/components/filtersSelectListItem.js +2 -2
- package/esm/filters/components/filtersSidePanel.js +8 -8
- package/esm/filters/filters.js +4 -3
- package/esm/filtersBar/components/filtersBarPeriodPicker/getRangeOption.js +18 -18
- package/esm/filtersBar/components/resetComponentButton.js +1 -1
- package/esm/filtersBar/filtersBarActions/filtersBarActions.js +4 -4
- package/esm/filtersBar/filtersBarSidePanel/components/filtersBarSidePanelRange/filtersBarSidePanelRange.js +2 -2
- package/esm/filtersBar/filtersBarSidePanel/filtersBarSidePanel.js +5 -5
- package/esm/filtersBar/filtersContainer/filtersContainer.js +2 -2
- package/esm/formField/hooks/useError.js +3 -3
- package/esm/formGroup/components/reviewListToggle/reviewListToggle.js +2 -2
- package/esm/formGroup/hooks/useToggle.js +1 -1
- package/esm/formLayout/hooks/useError.js +3 -3
- package/esm/formLayout/hooks/useFormButtons.js +3 -3
- package/esm/formSection/hooks/useError.js +3 -3
- package/esm/formStepper/components/formStep.js +1 -1
- package/esm/formStepper/formStepper.js +2 -2
- package/esm/formStepperButtons/formStepperButtons.js +4 -4
- package/esm/groupsFilterRaw/groupsFilterAdjustmentState.js +4 -4
- package/esm/groupsFilterRaw/groupsFilterBox.js +3 -3
- package/esm/groupsFilterRaw/groupsFilterCommon.js +2 -2
- package/esm/groupsFilterRaw/groupsFilterCurrentlySelectedState.js +5 -5
- package/esm/groupsFilterRaw/groupsFilterHelper.js +2 -2
- package/esm/groupsFilterRaw/groupsFilterInitialState.js +8 -8
- package/esm/groupsFilterRaw/groupsFilterMenu.js +3 -3
- package/esm/groupsFilterRaw/groupsFilterRaw.js +8 -8
- package/esm/groupsFilterRaw/groupsFilterTrigger.js +2 -2
- package/esm/groupsFilterRaw/groupsHelper.js +22 -22
- package/esm/header/components/collapsedItemsControl/collapsedItemsControl.js +1 -1
- package/esm/header/components/mobileFilterControl/mobileFilterControl.js +1 -1
- package/esm/header/components/mobileSearchControl/mobileSearchControl.js +3 -3
- package/esm/header/headerBack.js +1 -1
- package/esm/index.d.ts +3 -0
- package/esm/index.js +2 -0
- package/esm/lineChart/lineChart.js +1 -1
- package/esm/lineChartMini/lineChartMini.js +1 -1
- package/esm/list/itemData/itemDataInternal.js +2 -2
- package/esm/list/listItem/listItem.js +2 -2
- package/esm/menu/components/menuErrorItem.js +2 -2
- package/esm/mobileSheet/mobileSheet.js +2 -2
- package/esm/modal/modal.js +1 -1
- package/esm/nav/navFooter/navEditFooter/navEditFooter.js +2 -2
- package/esm/nav/navFooter/navFooter.js +1 -1
- package/esm/nav/navFooter/navFooterAction/navFooterAction.js +1 -1
- package/esm/nav/navHeader/navHeader.js +2 -2
- package/esm/nav/navHeader/navHeaderSearch/navHeaderSearch.js +2 -2
- package/esm/nav/navMobileBar/navMobileBar.js +1 -1
- package/esm/notification/notification.js +1 -1
- package/esm/pagination/paginationArrow.js +2 -2
- package/esm/pagination/paginationText/paginationText.js +1 -1
- package/esm/pill/components/pillNonActionable/pillNonActionable.js +1 -1
- package/esm/pillBox/components/pillBoxItem.js +1 -1
- package/esm/pillBox/pillBox.js +3 -3
- package/esm/pillExpandable/pillExpandable.js +1 -1
- package/esm/pillExpandable/pillExpandableAlignments.js +65 -48
- package/esm/progressIndicator/progressIndicator.d.ts +4 -4
- package/esm/progressIndicator/progressIndicator.js +4 -4
- package/esm/rangeRaw/rangeRaw.js +7 -7
- package/esm/rangeRaw/utils/rangeHelper.js +7 -7
- package/esm/searchInputRaw/searchInputRaw.js +2 -2
- package/esm/selectList/selectList.js +2 -2
- package/esm/skeleton/skeleton.js +1 -1
- package/esm/sortControl/sortControl.js +5 -5
- package/esm/stepperRaw/stepperRaw.js +2 -2
- package/esm/summary/summary.js +2 -2
- package/esm/summaryTile/summaryTile.js +1 -1
- package/esm/table/actions/actionsMenu.js +2 -2
- package/esm/table/detailPanel/detailPanel.js +1 -1
- package/esm/table/detailPanel/detailPanelHeader.js +2 -2
- package/esm/table/flexible/columnSettings.js +2 -2
- package/esm/table/flexible/columnsPopup.js +1 -1
- package/esm/table/nested/useNestedRows.js +2 -2
- package/esm/table/selectable/interfaces.d.ts +9 -13
- package/esm/table/selectable/selectableHeader.js +5 -5
- package/esm/table/selectable/useDragSelection.d.ts +10 -0
- package/esm/table/selectable/useDragSelection.js +135 -0
- package/esm/table/selectable/useSelectableRows.d.ts +2 -2
- package/esm/table/selectable/useSelectableRows.js +61 -51
- package/esm/table/selectable/utils/calculateSelectionState.js +0 -35
- package/esm/table/selectable/utils/getDragSelectionRows.d.ts +15 -0
- package/esm/table/selectable/utils/getDragSelectionRows.js +24 -0
- package/esm/table/selectable/utils/getRangeIds.d.ts +2 -0
- package/esm/table/selectable/utils/getRangeIds.js +17 -0
- package/esm/table/selectable/utils/isRowChecked.js +1 -12
- package/esm/table/sortable/mobileSortControl.js +3 -3
- package/esm/table/sortable/sortableHeader.js +2 -2
- package/esm/table/table.d.ts +4 -0
- package/esm/table/table.js +10 -6
- package/esm/tabs/tabs.js +2 -2
- package/esm/tag/tag.d.ts +3 -2
- package/esm/tag/tag.js +3 -2
- package/esm/timePickerRaw/timePickerRaw.js +7 -7
- package/esm/toastRaw/toastRaw.js +1 -1
- package/esm/toggleButtonRaw/toggleButtonRaw.js +2 -2
- package/esm/tooltip/tooltip.js +5 -2
- package/esm/utils/formatDate.js +37 -37
- package/esm/utils/localization/flipAlignment.js +5 -1
- package/esm/utils/localization/getSupportedLanguage.d.ts +1 -1
- package/esm/utils/localization/getSupportedLanguage.js +8 -2
- package/esm/utils/localization/getTextDirection.js +1 -1
- package/esm/utils/localization/languageContext.d.ts +1 -1
- package/esm/utils/localization/translations/{ar.json → ar-001.json} +54 -53
- package/esm/utils/localization/translationsDictionary.js +1 -1
- package/esm/utils/localization/useRTLAlignment.d.ts +6 -0
- package/esm/utils/localization/useRTLAlignment.js +6 -0
- package/package.json +1 -1
|
@@ -29,7 +29,7 @@ injectString("tr", "Y-axis", "Y ekseni");
|
|
|
29
29
|
injectString("zh-Hans", "Y-axis", "Y \u8F74");
|
|
30
30
|
injectString("zh-TW", "Y-axis", "Y \u8EF8");
|
|
31
31
|
injectString("ro-RO", "Y-axis", "Axa Y");
|
|
32
|
-
injectString("ar", "Y-axis", "\u0627\u0644\u0645\u062D\u0648\u0631 \u0627\u0644\u0635\u0627\u062F\u064A");
|
|
32
|
+
injectString("ar-001", "Y-axis", "\u0627\u0644\u0645\u062D\u0648\u0631 \u0627\u0644\u0635\u0627\u062F\u064A");
|
|
33
33
|
injectString("lt-LT", "Y-axis", "Y a\u0161is");
|
|
34
34
|
injectString("lv-LV", "Y-axis", "Y ass");
|
|
35
35
|
injectString("ka-GE", "Y-axis", "Y-\u10E6\u10D4\u10E0\u10EB\u10D8");
|
|
@@ -62,7 +62,7 @@ injectString("tr", "X-axis", "X ekseni");
|
|
|
62
62
|
injectString("zh-Hans", "X-axis", "X \u8F74");
|
|
63
63
|
injectString("zh-TW", "X-axis", "X \u8EF8");
|
|
64
64
|
injectString("ro-RO", "X-axis", "Axa X");
|
|
65
|
-
injectString("ar", "X-axis", "\u0627\u0644\u0645\u062D\u0648\u0631 \u0627\u0644\u0633\u064A\u0646\u064A");
|
|
65
|
+
injectString("ar-001", "X-axis", "\u0627\u0644\u0645\u062D\u0648\u0631 \u0627\u0644\u0633\u064A\u0646\u064A");
|
|
66
66
|
injectString("lt-LT", "X-axis", "X a\u0161is");
|
|
67
67
|
injectString("lv-LV", "X-axis", "X ass");
|
|
68
68
|
injectString("ka-GE", "X-axis", "X-\u10E6\u10D4\u10E0\u10EB\u10D8");
|
package/esm/chart/lineChart.js
CHANGED
|
@@ -63,7 +63,7 @@ injectString("tr", "Line chart", "\xC7izgi grafik");
|
|
|
63
63
|
injectString("zh-Hans", "Line chart", "\u6298\u7EBF\u56FE");
|
|
64
64
|
injectString("zh-TW", "Line chart", "\u6298\u7DDA\u5716");
|
|
65
65
|
injectString("ro-RO", "Line chart", "Grafic liniar");
|
|
66
|
-
injectString("ar", "Line chart", "\u0645\u062E\u0637\u0637 \u062E\u0637\u064A");
|
|
66
|
+
injectString("ar-001", "Line chart", "\u0645\u062E\u0637\u0637 \u062E\u0637\u064A");
|
|
67
67
|
injectString("lt-LT", "Line chart", "Linijin\u0117 diagrama");
|
|
68
68
|
injectString("lv-LV", "Line chart", "L\u012Bniju diagramma");
|
|
69
69
|
injectString("ka-GE", "Line chart", "\u10EE\u10D0\u10D6\u10DD\u10D5\u10D0\u10DC\u10D8 \u10E1\u10E5\u10D4\u10DB\u10D0");
|
package/esm/chart/pieChart.js
CHANGED
|
@@ -56,7 +56,7 @@ injectString("tr", "Pie chart", "Pasta grafik");
|
|
|
56
56
|
injectString("zh-Hans", "Pie chart", "\u997C\u56FE");
|
|
57
57
|
injectString("zh-TW", "Pie chart", "\u5713\u5F62\u5716");
|
|
58
58
|
injectString("ro-RO", "Pie chart", "Diagram\u0103 circular\u0103");
|
|
59
|
-
injectString("ar", "Pie chart", "\u0645\u062E\u0637\u0637 \u062F\u0627\u0626\u0631\u064A");
|
|
59
|
+
injectString("ar-001", "Pie chart", "\u0645\u062E\u0637\u0637 \u062F\u0627\u0626\u0631\u064A");
|
|
60
60
|
injectString("lt-LT", "Pie chart", "Skritulin\u0117 diagrama");
|
|
61
61
|
injectString("lv-LV", "Pie chart", "Sektoru diagramma");
|
|
62
62
|
injectString("ka-GE", "Pie chart", "\u10EC\u10E0\u10D8\u10E3\u10DA\u10D8 \u10E1\u10E5\u10D4\u10DB\u10D0");
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { Scale } from "chart.js";
|
|
1
|
+
import { Scale, type ChartOptions } from "chart.js";
|
|
2
2
|
import { ILineChartData } from "../../lineChart/interfaces";
|
|
3
|
-
export declare function getInterpolatedValue(xScale: Scale, data: ILineChartData, datasetIndex: number, xPixel: number): number | null;
|
|
3
|
+
export declare function getInterpolatedValue(xScale: Scale, data: ILineChartData, datasetIndex: number, xPixel: number, parsing?: ChartOptions<"line">["parsing"]): number | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export function getInterpolatedValue(xScale, data, datasetIndex, xPixel) {
|
|
1
|
+
export function getInterpolatedValue(xScale, data, datasetIndex, xPixel, parsing) {
|
|
2
2
|
const dataset = data.datasets[datasetIndex];
|
|
3
3
|
const dataPoints = dataset.data;
|
|
4
4
|
if (dataPoints.length < 2) {
|
|
@@ -15,7 +15,8 @@ export function getInterpolatedValue(xScale, data, datasetIndex, xPixel) {
|
|
|
15
15
|
if (y === null) {
|
|
16
16
|
continue;
|
|
17
17
|
}
|
|
18
|
-
const
|
|
18
|
+
const parsedX = parsing === false ? x : xScale.parse(x, i);
|
|
19
|
+
const pointXPixel = xScale.getPixelForValue(parsedX);
|
|
19
20
|
if (pointXPixel <= xPixel && pointXPixel > lowerXPixel) {
|
|
20
21
|
lowerPoint = y;
|
|
21
22
|
lowerXPixel = pointXPixel;
|
|
@@ -57,6 +57,7 @@ export const LinePlugin = (containerId, options, isDark) => ({
|
|
|
57
57
|
let lowestValueY = Infinity;
|
|
58
58
|
const items = datasets
|
|
59
59
|
.map((dataset, dsIndex) => {
|
|
60
|
+
var _a;
|
|
60
61
|
if (!chart.isDatasetVisible(dsIndex)) {
|
|
61
62
|
return undefined;
|
|
62
63
|
}
|
|
@@ -64,7 +65,7 @@ export const LinePlugin = (containerId, options, isDark) => ({
|
|
|
64
65
|
return undefined;
|
|
65
66
|
}
|
|
66
67
|
const xScale = chart.scales.x;
|
|
67
|
-
const value = getInterpolatedValue(xScale, chart.data, dsIndex, x);
|
|
68
|
+
const value = getInterpolatedValue(xScale, chart.data, dsIndex, x, (_a = dataset.parsing) !== null && _a !== void 0 ? _a : chart.options.parsing);
|
|
68
69
|
const yAxisID = dataset.yAxisID || "y";
|
|
69
70
|
const yScale = chart.scales[yAxisID];
|
|
70
71
|
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
|
|
@@ -3,14 +3,18 @@ export function getFormattedLabel(value, dateFormatter, options) {
|
|
|
3
3
|
var _a, _b, _c;
|
|
4
4
|
const scaleType = (_b = (_a = options === null || options === void 0 ? void 0 : options.scales) === null || _a === void 0 ? void 0 : _a.x) === null || _b === void 0 ? void 0 : _b.type;
|
|
5
5
|
let format;
|
|
6
|
+
let parser;
|
|
6
7
|
if (((_c = options === null || options === void 0 ? void 0 : options.scales) === null || _c === void 0 ? void 0 : _c.x) && scaleType) {
|
|
7
8
|
const scaleFormat = options.scales.x[scaleType];
|
|
8
9
|
if ((scaleFormat === null || scaleFormat === void 0 ? void 0 : scaleFormat.unit) && scaleFormat.displayFormats && scaleFormat.displayFormats[scaleFormat.unit]) {
|
|
9
10
|
format = scaleFormat.displayFormats[scaleFormat.unit];
|
|
10
11
|
}
|
|
12
|
+
if (options.parsing !== false && scaleFormat && "parser" in scaleFormat && typeof scaleFormat.parser === "function") {
|
|
13
|
+
parser = scaleFormat.parser;
|
|
14
|
+
}
|
|
11
15
|
}
|
|
12
16
|
if (value instanceof Date || (typeof value === "string" && isDateString(value))) {
|
|
13
|
-
return dateFormatter(value, format);
|
|
17
|
+
return dateFormatter(parser ? new Date(parser(value)) : value, format);
|
|
14
18
|
}
|
|
15
19
|
return String(value);
|
|
16
20
|
}
|
|
@@ -8,6 +8,7 @@ export interface ICheckbox extends IZenComponentProps {
|
|
|
8
8
|
checked?: boolean;
|
|
9
9
|
indeterminate?: boolean;
|
|
10
10
|
title?: string;
|
|
11
|
+
ariaLabel?: string;
|
|
11
12
|
disabled?: boolean;
|
|
12
13
|
fullWidth?: boolean;
|
|
13
14
|
reverse?: boolean;
|
|
@@ -16,4 +17,4 @@ export interface ICheckbox extends IZenComponentProps {
|
|
|
16
17
|
tabIndex?: number;
|
|
17
18
|
describedBy?: string;
|
|
18
19
|
}
|
|
19
|
-
export declare const Checkbox: ({ reverse, fullWidth, id, checked, indeterminate, title, className, children, disabled, wrapped, describedBy, ...rest }: ICheckbox) => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export declare const Checkbox: ({ reverse, fullWidth, id, checked, indeterminate, title, ariaLabel, className, children, disabled, wrapped, describedBy, ...rest }: ICheckbox) => import("react/jsx-runtime").JSX.Element;
|
package/esm/checkbox/checkbox.js
CHANGED
|
@@ -20,14 +20,14 @@ import { CheckboxIconCheckmark } from "./checkboxIconCheckmark";
|
|
|
20
20
|
import { CheckboxIconMinus } from "./checkboxIconMinus";
|
|
21
21
|
import { useMobile } from "../commonHelpers/hooks/useMobile";
|
|
22
22
|
export const Checkbox = (_a) => {
|
|
23
|
-
var { reverse, fullWidth, id, checked, indeterminate, title, className = "", children, disabled, wrapped, describedBy } = _a, rest = __rest(_a, ["reverse", "fullWidth", "id", "checked", "indeterminate", "title", "className", "children", "disabled", "wrapped", "describedBy"]);
|
|
23
|
+
var { reverse, fullWidth, id, checked, indeterminate, title, ariaLabel, className = "", children, disabled, wrapped, describedBy } = _a, rest = __rest(_a, ["reverse", "fullWidth", "id", "checked", "indeterminate", "title", "ariaLabel", "className", "children", "disabled", "wrapped", "describedBy"]);
|
|
24
24
|
const state = getCheckboxState(checked, indeterminate);
|
|
25
25
|
const generatedId = React.useId();
|
|
26
26
|
const intId = id || generatedId;
|
|
27
27
|
const driveClasses = useDriveClassName("zen-checkbox");
|
|
28
28
|
const isMobile = useMobile();
|
|
29
29
|
const checkboxIconClasses = useMemo(() => classNames(["zen-checkbox__icon", disabled ? "zen-checkbox__icon--disabled" : ""]), [disabled]);
|
|
30
|
-
const checkbox = (_jsx(TriStateCheckbox, Object.assign({ className: "zen-checkbox__input", id: intId, checked: checked, indeterminate: indeterminate, disabled: disabled, "aria-label": title, "aria-describedby": describedBy }, rest)));
|
|
30
|
+
const checkbox = (_jsx(TriStateCheckbox, Object.assign({ className: "zen-checkbox__input", id: intId, checked: checked, indeterminate: indeterminate, disabled: disabled, "aria-label": ariaLabel || title, "aria-describedby": describedBy }, rest)));
|
|
31
31
|
const iconAndLabel = (_jsxs(_Fragment, { children: [_jsx("div", { className: "zen-checkbox__box", "aria-hidden": true, children: state === CheckboxState.Indeterminate ? (_jsx(CheckboxIconMinus, { className: checkboxIconClasses, size: driveClasses ? "bigger" : "medium" })) : state === CheckboxState.On ? (_jsx(CheckboxIconCheckmark, { className: checkboxIconClasses, size: driveClasses ? "bigger" : "medium" })) : null }), children ? (_jsx("div", { className: classNames(["zen-checkbox__label-text", fullWidth ? "zen-checkbox__label-text--full-width" : ""]), children: children })) : null] }));
|
|
32
32
|
if (wrapped) {
|
|
33
33
|
return (_jsxs("label", { className: classNames(["zen-checkbox", driveClasses || "", className]), title: title, children: [checkbox, _jsx("div", { className: classNames(["zen-checkbox__label", reverse ? "zen-checkbox__label--reverse" : ""]), children: iconAndLabel })] }));
|
|
@@ -34,7 +34,7 @@ injectString("tr", "Number of selected child groups - {count}", "Se\xE7ilen alt
|
|
|
34
34
|
injectString("zh-Hans", "Number of selected child groups - {count}", "\u9009\u4E2D\u7684\u5B50\u7EC4\u6570\u91CF - {count}");
|
|
35
35
|
injectString("zh-TW", "Number of selected child groups - {count}", "\u6240\u9078\u5B50\u7FA4\u7D44\u7684\u6578\u76EE - {count}");
|
|
36
36
|
injectString("ro-RO", "Number of selected child groups - {count}", "Num\u0103r de grupuri derivate selectate \u2013 {count}");
|
|
37
|
-
injectString("ar", "Number of selected child groups - {count}", "\u0639\u062F\u062F \u0627\u0644\u0645\u062C\u0645\u0648\u0639\u0627\u062A \u0627\u0644\u062A\u0627\u0628\u0639\u0629 \u0627\u0644\u0645\u062D\u062F\u062F\u0629 - {count}");
|
|
37
|
+
injectString("ar-001", "Number of selected child groups - {count}", "\u0639\u062F\u062F \u0627\u0644\u0645\u062C\u0645\u0648\u0639\u0627\u062A \u0627\u0644\u062A\u0627\u0628\u0639\u0629 \u0627\u0644\u0645\u062D\u062F\u062F\u0629 - {count}");
|
|
38
38
|
injectString("lt-LT", "Number of selected child groups - {count}", "Pasirinkt\u0173 pogrupi\u0173 skai\u010Dius - {count}");
|
|
39
39
|
injectString("lv-LV", "Number of selected child groups - {count}", "Atlas\u012Bto apak\u0161grupu skaits - {count}");
|
|
40
40
|
injectString("ka-GE", "Number of selected child groups - {count}", "\u10D0\u10E0\u10E9\u10D4\u10E3\u10DA\u10D8 \u10E5\u10D5\u10D4\u10EF\u10D2\u10E3\u10E4\u10D4\u10D1\u10D8\u10E1 \u10E0\u10D0\u10DD\u10D3\u10D4\u10DC\u10DD\u10D1\u10D0 - {count}");
|
|
@@ -67,7 +67,7 @@ injectString("tr", "View {groupName} children", "{groupName} alt \xF6\u011Feleri
|
|
|
67
67
|
injectString("zh-Hans", "View {groupName} children", "\u67E5\u770B {groupName} \u5B50\u7EC4");
|
|
68
68
|
injectString("zh-TW", "View {groupName} children", "\u6AA2\u8996\u300C{groupName}\u300D\u5B50\u7FA4\u7D44");
|
|
69
69
|
injectString("ro-RO", "View {groupName} children", "Vede\u021Bi derivatele {groupName}");
|
|
70
|
-
injectString("ar", "View {groupName} children", "\u0639\u0631\u0636 \u062A\u0648\u0627\u0628\u0639 {groupName}");
|
|
70
|
+
injectString("ar-001", "View {groupName} children", "\u0639\u0631\u0636 \u062A\u0648\u0627\u0628\u0639 {groupName}");
|
|
71
71
|
injectString("lt-LT", "View {groupName} children", "Per\u017Ei\u016Br\u0117ti {groupName} pogrupius");
|
|
72
72
|
injectString("lv-LV", "View {groupName} children", "Skat\u012Bt {groupName} apak\u0161grupas");
|
|
73
73
|
injectString("ka-GE", "View {groupName} children", "{groupName} \u10E5\u10D5\u10D4\u10EF\u10D2\u10E3\u10E4\u10D4\u10D1\u10D8\u10E1 \u10DC\u10D0\u10EE\u10D5\u10D0");
|
|
@@ -100,7 +100,7 @@ injectString("tr", "Toggle {groupName} filter", "{groupName} filtresini de\u011F
|
|
|
100
100
|
injectString("zh-Hans", "Toggle {groupName} filter", "\u5207\u6362 {groupName} \u7B5B\u9009\u5668");
|
|
101
101
|
injectString("zh-TW", "Toggle {groupName} filter", "\u5207\u63DB\u300C{groupName}\u300D\u7BE9\u9078\u689D\u4EF6");
|
|
102
102
|
injectString("ro-RO", "Toggle {groupName} filter", "Activa\u021Bi filtrul {groupName}");
|
|
103
|
-
injectString("ar", "Toggle {groupName} filter", "\u062A\u0628\u062F\u064A\u0644 \u0639\u0627\u0645\u0644 \u062A\u0635\u0641\u064A\u0629 {groupName}");
|
|
103
|
+
injectString("ar-001", "Toggle {groupName} filter", "\u062A\u0628\u062F\u064A\u0644 \u0639\u0627\u0645\u0644 \u062A\u0635\u0641\u064A\u0629 {groupName}");
|
|
104
104
|
injectString("lt-LT", "Toggle {groupName} filter", "\u012Ejungti / i\u0161jungti {groupName} filtr\u0105");
|
|
105
105
|
injectString("lv-LV", "Toggle {groupName} filter", "Iesl\u0113gt/izsl\u0113gt {groupName} filtru");
|
|
106
106
|
injectString("ka-GE", "Toggle {groupName} filter", "{groupName} \u10E4\u10D8\u10DA\u10E2\u10E0\u10D8\u10E1 \u10D2\u10D0\u10D3\u10D0\u10E0\u10D7\u10D5\u10D0");
|
|
@@ -133,7 +133,7 @@ injectString("tr", "Has additional actions. Use right arrow to access button, le
|
|
|
133
133
|
injectString("zh-Hans", "Has additional actions. Use right arrow to access button, left arrow to return.", "Has additional actions. Use right arrow to access button, left arrow to return.");
|
|
134
134
|
injectString("zh-TW", "Has additional actions. Use right arrow to access button, left arrow to return.", "Has additional actions. Use right arrow to access button, left arrow to return.");
|
|
135
135
|
injectString("ro-RO", "Has additional actions. Use right arrow to access button, left arrow to return.", "Has additional actions. Use right arrow to access button, left arrow to return.");
|
|
136
|
-
injectString("ar", "Has additional actions. Use right arrow to access button, left arrow to return.", "\u064A\u062D\u062A\u0648\u064A \u0639\u0644\u0649 \u0625\u062C\u0631\u0627\u0621\u0627\u062A \u0625\u0636\u0627\u0641\u064A\u0629. \u0627\u0633\u062A\u062E\u062F\u0645 \u0627\u0644\u0633\u0647\u0645 \u0627\u0644\u0623\u064A\u0645\u0646 \u0644\u0644\u0648\u0635\u0648\u0644 \u0625\u0644\u0649 \u0627\u0644\u0632\u0631\u060C \u0648\u0627\u0644\u0633\u0647\u0645 \u0627\u0644\u0623\u064A\u0633\u0631 \u0644\u0644\u0639\u0648\u062F\u0629.");
|
|
136
|
+
injectString("ar-001", "Has additional actions. Use right arrow to access button, left arrow to return.", "\u064A\u062D\u062A\u0648\u064A \u0639\u0644\u0649 \u0625\u062C\u0631\u0627\u0621\u0627\u062A \u0625\u0636\u0627\u0641\u064A\u0629. \u0627\u0633\u062A\u062E\u062F\u0645 \u0627\u0644\u0633\u0647\u0645 \u0627\u0644\u0623\u064A\u0645\u0646 \u0644\u0644\u0648\u0635\u0648\u0644 \u0625\u0644\u0649 \u0627\u0644\u0632\u0631\u060C \u0648\u0627\u0644\u0633\u0647\u0645 \u0627\u0644\u0623\u064A\u0633\u0631 \u0644\u0644\u0639\u0648\u062F\u0629.");
|
|
137
137
|
injectString("lt-LT", "Has additional actions. Use right arrow to access button, left arrow to return.", "Yra papildom\u0173 veiksm\u0173. De\u0161iniojo rodykl\u0117s klavi\u0161o paspauskite mygtuk\u0105, kairiojo - gr\u012F\u017Ekite.");
|
|
138
138
|
injectString("lv-LV", "Has additional actions. Use right arrow to access button, left arrow to return.", "Ir papildu darb\u012Bbas. Lab\u0101 bulti\u0146a - piek\u013C\u016Bt pogai, kreis\u0101 bulti\u0146a - atgriezties.");
|
|
139
139
|
injectString("ka-GE", "Has additional actions. Use right arrow to access button, left arrow to return.", "\u10D3\u10D0\u10DB\u10D0\u10E2\u10D4\u10D1\u10D8\u10D7\u10D8 \u10DB\u10DD\u10E5\u10DB\u10D4\u10D3\u10D4\u10D1\u10D4\u10D1\u10D8 \u10D0\u10E0\u10E1\u10D4\u10D1\u10DD\u10D1\u10E1. \u10DB\u10D0\u10E0\u10EF\u10D5\u10D4\u10DC\u10D0 \u10D8\u10E1\u10E0\u10D8\u10D7 \u10EC\u10D5\u10D3\u10DD\u10DB\u10D8\u10E1\u10D7\u10D5\u10D8\u10E1, \u10DB\u10D0\u10E0\u10EA\u10EE\u10D4\u10DC\u10D8\u10D7 \u10D3\u10D0\u10E1\u10D0\u10D1\u10E0\u10E3\u10DC\u10D4\u10D1\u10DA\u10D0\u10D3.");
|
|
@@ -445,6 +445,7 @@ export const CheckboxListWithAction = ({
|
|
|
445
445
|
checked: opt.checked,
|
|
446
446
|
disabled: opt.blocked,
|
|
447
447
|
title: translate("Toggle {groupName} filter").replace("{groupName}", titleForRender),
|
|
448
|
+
ariaLabel: titleForRender,
|
|
448
449
|
describedBy: opt.isWithAction ? navigationInstructionsId : undefined,
|
|
449
450
|
"data-indeterminate": opt.partialChecked,
|
|
450
451
|
tabIndex: getTabIndex(ind, "checkbox", opt.blocked),
|
package/esm/chip/chip.js
CHANGED
|
@@ -38,7 +38,7 @@ injectString("tr", "Clear selection", "Se\xE7imi temizle");
|
|
|
38
38
|
injectString("zh-Hans", "Clear selection", "\u6E05\u9664\u9009\u62E9");
|
|
39
39
|
injectString("zh-TW", "Clear selection", "\u6E05\u9664\u9078\u53D6\u9805\u76EE");
|
|
40
40
|
injectString("ro-RO", "Clear selection", "\u0218terge\u021Bi selec\u021Bia");
|
|
41
|
-
injectString("ar", "Clear selection", "\u0645\u0633\u062D \u0627\u0644\u062A\u062D\u062F\u064A\u062F");
|
|
41
|
+
injectString("ar-001", "Clear selection", "\u0645\u0633\u062D \u0627\u0644\u062A\u062D\u062F\u064A\u062F");
|
|
42
42
|
injectString("lt-LT", "Clear selection", "I\u0161valyti pasirinkim\u0105");
|
|
43
43
|
injectString("lv-LV", "Clear selection", "Not\u012Br\u012Bt atlasi");
|
|
44
44
|
injectString("ka-GE", "Clear selection", "\u10DB\u10DD\u10DC\u10D8\u10E8\u10D5\u10DC\u10D8\u10E1 \u10D2\u10D0\u10E1\u10E3\u10E4\u10D7\u10D0\u10D5\u10D4\u10D1\u10D0");
|
|
@@ -38,7 +38,7 @@ injectString("tr", "Column Settings", "S\xFCtun Ayarlar\u0131");
|
|
|
38
38
|
injectString("zh-Hans", "Column Settings", "\u5217\u8BBE\u7F6E");
|
|
39
39
|
injectString("zh-TW", "Column Settings", "\u6B04\u8A2D\u5B9A");
|
|
40
40
|
injectString("ro-RO", "Column Settings", "Set\u0103ri coloane");
|
|
41
|
-
injectString("ar", "Column Settings", "\u0625\u0639\u062F\u0627\u062F\u0627\u062A \u0627\u0644\u0639\u0645\u0648\u062F");
|
|
41
|
+
injectString("ar-001", "Column Settings", "\u0625\u0639\u062F\u0627\u062F\u0627\u062A \u0627\u0644\u0639\u0645\u0648\u062F");
|
|
42
42
|
injectString("lt-LT", "Column Settings", "Stulpelio nustatymai");
|
|
43
43
|
injectString("lv-LV", "Column Settings", "Kolonnas iestat\u012Bjumi");
|
|
44
44
|
injectString("ka-GE", "Column Settings", "\u10E1\u10D5\u10D4\u10E2\u10D8\u10E1 \u10DE\u10D0\u10E0\u10D0\u10DB\u10D4\u10E2\u10E0\u10D4\u10D1\u10D8");
|
|
@@ -71,7 +71,7 @@ injectString("tr", "Reset to default", "Varsay\u0131lana s\u0131f\u0131rla");
|
|
|
71
71
|
injectString("zh-Hans", "Reset to default", "\u91CD\u7F6E\u4E3A\u9ED8\u8BA4\u503C");
|
|
72
72
|
injectString("zh-TW", "Reset to default", "\u91CD\u8A2D\u70BA\u9810\u8A2D\u503C");
|
|
73
73
|
injectString("ro-RO", "Reset to default", "Reseta\u021Bi la implicit");
|
|
74
|
-
injectString("ar", "Reset to default", "\u0625\u0639\u0627\u062F\u0629 \u0627\u0644\u062A\u0639\u064A\u064A\u0646 \u0625\u0644\u0649 \u0627\u0644\u0627\u0641\u062A\u0631\u0627\u0636\u064A");
|
|
74
|
+
injectString("ar-001", "Reset to default", "\u0625\u0639\u0627\u062F\u0629 \u0627\u0644\u062A\u0639\u064A\u064A\u0646 \u0625\u0644\u0649 \u0627\u0644\u0627\u0641\u062A\u0631\u0627\u0636\u064A");
|
|
75
75
|
injectString("lt-LT", "Reset to default", "Atkurti numatyt\u0105j\u0105 reik\u0161m\u0119");
|
|
76
76
|
injectString("lv-LV", "Reset to default", "Atjaunot noklus\u0113jumu");
|
|
77
77
|
injectString("ka-GE", "Reset to default", "\u10DC\u10D0\u10D2\u10E3\u10DA\u10D8\u10E1\u10EE\u10DB\u10D4\u10D5\u10D6\u10D4 \u10D2\u10D0\u10D3\u10D0\u10E7\u10D4\u10DC\u10D4\u10D1\u10D0");
|
|
@@ -29,7 +29,7 @@ injectString("tr", "Columns", "S\xFCtunlar");
|
|
|
29
29
|
injectString("zh-Hans", "Columns", "\u5217");
|
|
30
30
|
injectString("zh-TW", "Columns", "\u6B04");
|
|
31
31
|
injectString("ro-RO", "Columns", "Coloane");
|
|
32
|
-
injectString("ar", "Columns", "\u0627\u0644\u0623\u0639\u0645\u062F\u0629");
|
|
32
|
+
injectString("ar-001", "Columns", "\u0627\u0644\u0623\u0639\u0645\u062F\u0629");
|
|
33
33
|
injectString("lt-LT", "Columns", "Stulpeliai");
|
|
34
34
|
injectString("lv-LV", "Columns", "Kolonnas");
|
|
35
35
|
injectString("ka-GE", "Columns", "\u10E1\u10D5\u10D4\u10E2\u10D4\u10D1\u10D8");
|
|
@@ -30,7 +30,7 @@ injectString("tr", "Additional Properties", "Ek \xD6zellikler");
|
|
|
30
30
|
injectString("zh-Hans", "Additional Properties", "\u5176\u4ED6\u5C5E\u6027");
|
|
31
31
|
injectString("zh-TW", "Additional Properties", "\u5176\u4ED6\u5C6C\u6027");
|
|
32
32
|
injectString("ro-RO", "Additional Properties", "Propriet\u0103\u021Bi suplimentare");
|
|
33
|
-
injectString("ar", "Additional Properties", "\u062E\u0635\u0627\u0626\u0635 \u0625\u0636\u0627\u0641\u064A\u0629");
|
|
33
|
+
injectString("ar-001", "Additional Properties", "\u062E\u0635\u0627\u0626\u0635 \u0625\u0636\u0627\u0641\u064A\u0629");
|
|
34
34
|
injectString("lt-LT", "Additional Properties", "Papildomos savyb\u0117s");
|
|
35
35
|
injectString("lv-LV", "Additional Properties", "Papildu rekviz\u012Bti");
|
|
36
36
|
injectString("ka-GE", "Additional Properties", "\u10D3\u10D0\u10DB\u10D0\u10E2\u10D4\u10D1\u10D8\u10D7\u10D8 \u10D7\u10D5\u10D8\u10E1\u10D4\u10D1\u10D4\u10D1\u10D8");
|
|
@@ -1,13 +1,4 @@
|
|
|
1
1
|
import { RefObject } from "react";
|
|
2
2
|
type TElementToBool = (element: HTMLElement) => boolean;
|
|
3
|
-
/**
|
|
4
|
-
* Traps keyboard (Tab) focus within `containerRef` (and optionally its `triggerRef`).
|
|
5
|
-
*
|
|
6
|
-
* Nested-popup contract: for correct nested-popup behaviour, a focused element that triggers an
|
|
7
|
-
* open child popup must expose a `data-popup-id` attribute whose value is the `id` of the child
|
|
8
|
-
* popup element rendered in the DOM. When present, focus is deferred to that child popup's trap.
|
|
9
|
-
* This contract is fulfilled automatically by `ControlledPopup`; callers using `useTrapFocus`
|
|
10
|
-
* directly must set `data-popup-id` themselves or nested popups will silently lose focus handling.
|
|
11
|
-
*/
|
|
12
3
|
export declare const useTrapFocus: (containerRef: RefObject<HTMLElement | null>, triggerRef: RefObject<HTMLElement | null> | undefined, subscriptionTrigger: unknown, condition?: (t: unknown) => boolean, isElementVisible?: TElementToBool) => void;
|
|
13
4
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useCallback
|
|
1
|
+
import { useCallback } from "react";
|
|
2
2
|
import { isElementInsideContainer } from "../../dialog/dialogHelpers";
|
|
3
3
|
import { FOCUSABLE_SELECTOR } from "../../utils/focusableSelector";
|
|
4
4
|
import { useKeydown } from "./useKeydown";
|
|
@@ -6,38 +6,18 @@ import { isChildOf } from "../../utils/isChildOf";
|
|
|
6
6
|
import { isElementHidden } from "../../utils/isElementHidden";
|
|
7
7
|
import { zen } from "../../utils/zen";
|
|
8
8
|
const findFirstVisible = (elems, isElementVisible) => elems.find(elem => isElementVisible(elem));
|
|
9
|
-
/**
|
|
10
|
-
* Traps keyboard (Tab) focus within `containerRef` (and optionally its `triggerRef`).
|
|
11
|
-
*
|
|
12
|
-
* Nested-popup contract: for correct nested-popup behaviour, a focused element that triggers an
|
|
13
|
-
* open child popup must expose a `data-popup-id` attribute whose value is the `id` of the child
|
|
14
|
-
* popup element rendered in the DOM. When present, focus is deferred to that child popup's trap.
|
|
15
|
-
* This contract is fulfilled automatically by `ControlledPopup`; callers using `useTrapFocus`
|
|
16
|
-
* directly must set `data-popup-id` themselves or nested popups will silently lose focus handling.
|
|
17
|
-
*/
|
|
18
9
|
export const useTrapFocus = (containerRef, triggerRef, subscriptionTrigger, condition, isElementVisible) => {
|
|
19
10
|
/* eslint-disable complexity */
|
|
20
11
|
const handleKeyDown = useCallback(e => {
|
|
21
|
-
var _a, _b, _c, _d, _e, _f
|
|
12
|
+
var _a, _b, _c, _d, _e, _f;
|
|
22
13
|
/* eslint-enable complexity */
|
|
23
14
|
const getChildCondition = () => {
|
|
24
|
-
var _a, _b
|
|
25
|
-
const targetEl = e.target;
|
|
26
|
-
// If the target is a trigger for an open child popup, defer to that popup's
|
|
27
|
-
// focus trap. Key on data-popup-id + DOM presence so this works even when
|
|
28
|
-
// preventAttributesAutoSet suppresses aria-expanded.
|
|
29
|
-
const dataPopupId = targetEl.getAttribute("data-popup-id");
|
|
30
|
-
if (dataPopupId &&
|
|
31
|
-
((_a = zen.document) === null || _a === void 0 ? void 0 : _a.getElementById(dataPopupId)) &&
|
|
32
|
-
isChildOf(targetEl, containerRef.current) &&
|
|
33
|
-
targetEl !== (triggerRef === null || triggerRef === void 0 ? void 0 : triggerRef.current)) {
|
|
34
|
-
return true;
|
|
35
|
-
}
|
|
15
|
+
var _a, _b;
|
|
36
16
|
return triggerRef
|
|
37
|
-
? !isChildOf(
|
|
38
|
-
|
|
39
|
-
!isChildOf(
|
|
40
|
-
: !isChildOf(
|
|
17
|
+
? !isChildOf(e.target, containerRef.current) &&
|
|
18
|
+
e.target !== ((_a = zen.document) === null || _a === void 0 ? void 0 : _a.body) &&
|
|
19
|
+
!isChildOf(e.target, triggerRef.current)
|
|
20
|
+
: !isChildOf(e.target, containerRef.current) && e.target !== ((_b = zen.document) === null || _b === void 0 ? void 0 : _b.body);
|
|
41
21
|
};
|
|
42
22
|
if (!containerRef.current || getChildCondition()) {
|
|
43
23
|
return;
|
|
@@ -47,14 +27,9 @@ export const useTrapFocus = (containerRef, triggerRef, subscriptionTrigger, cond
|
|
|
47
27
|
: !isElementInsideContainer(target, containerEl.current) &&
|
|
48
28
|
!isElementInsideContainer(target, triggerEl.current);
|
|
49
29
|
const isTargetOutside = e.target ? checkIsElementOutside(e.target, containerRef, triggerRef) : undefined;
|
|
50
|
-
const
|
|
51
|
-
const triggerSelf = (triggerElement === null || triggerElement === void 0 ? void 0 : triggerElement.matches(FOCUSABLE_SELECTOR)) ? [triggerElement] : [];
|
|
52
|
-
const triggerChildren = Array.from((_b = triggerElement === null || triggerElement === void 0 ? void 0 : triggerElement.querySelectorAll(FOCUSABLE_SELECTOR)) !== null && _b !== void 0 ? _b : []);
|
|
53
|
-
// querySelectorAll only returns descendants (never the element itself), so triggerSelf
|
|
54
|
-
// and triggerChildren are disjoint by definition and need no deduplication.
|
|
55
|
-
const triggerSelectors = [...triggerSelf, ...triggerChildren];
|
|
30
|
+
const triggerSelectors = ((_a = triggerRef === null || triggerRef === void 0 ? void 0 : triggerRef.current) === null || _a === void 0 ? void 0 : _a.querySelectorAll(FOCUSABLE_SELECTOR)) || [];
|
|
56
31
|
const containerSelectors = containerRef.current.querySelectorAll(FOCUSABLE_SELECTOR);
|
|
57
|
-
const focusable = triggerRef ? [...triggerSelectors, ...Array.from(containerSelectors)] : [...Array.from(containerSelectors)];
|
|
32
|
+
const focusable = triggerRef ? [...Array.from(triggerSelectors), ...Array.from(containerSelectors)] : [...Array.from(containerSelectors)];
|
|
58
33
|
if (!focusable.length) {
|
|
59
34
|
return;
|
|
60
35
|
}
|
|
@@ -71,58 +46,31 @@ export const useTrapFocus = (containerRef, triggerRef, subscriptionTrigger, cond
|
|
|
71
46
|
return;
|
|
72
47
|
}
|
|
73
48
|
if (e.shiftKey) {
|
|
74
|
-
if (((
|
|
49
|
+
if (((_b = zen.document) === null || _b === void 0 ? void 0 : _b.activeElement) === first) {
|
|
75
50
|
e.preventDefault();
|
|
76
51
|
last === null || last === void 0 ? void 0 : last.focus();
|
|
77
52
|
return;
|
|
78
53
|
}
|
|
79
|
-
if (firstContainerFocusable && ((
|
|
54
|
+
if (firstContainerFocusable && ((_c = zen.document) === null || _c === void 0 ? void 0 : _c.activeElement) === firstContainerFocusable) {
|
|
80
55
|
e.preventDefault();
|
|
81
56
|
lastTriggerFocusable === null || lastTriggerFocusable === void 0 ? void 0 : lastTriggerFocusable.focus();
|
|
82
57
|
}
|
|
83
58
|
return;
|
|
84
59
|
}
|
|
85
|
-
if (((
|
|
60
|
+
if (((_d = zen.document) === null || _d === void 0 ? void 0 : _d.activeElement) === last) {
|
|
86
61
|
e.preventDefault();
|
|
87
62
|
first === null || first === void 0 ? void 0 : first.focus();
|
|
88
63
|
return;
|
|
89
64
|
}
|
|
90
|
-
if (lastTriggerFocusable && ((
|
|
65
|
+
if (lastTriggerFocusable && ((_e = zen.document) === null || _e === void 0 ? void 0 : _e.activeElement) === lastTriggerFocusable) {
|
|
91
66
|
e.preventDefault();
|
|
92
67
|
firstContainerFocusable === null || firstContainerFocusable === void 0 ? void 0 : firstContainerFocusable.focus();
|
|
93
68
|
}
|
|
94
|
-
else if (isLastChildOfFirst && first && isChildOf((
|
|
69
|
+
else if (isLastChildOfFirst && first && isChildOf((_f = zen.document) === null || _f === void 0 ? void 0 : _f.activeElement, first)) {
|
|
95
70
|
e.preventDefault();
|
|
96
71
|
}
|
|
97
72
|
return;
|
|
98
73
|
}
|
|
99
|
-
},
|
|
100
|
-
// condition is consumed by useKeydown below, not read by handleKeyDown directly; its absence from deps is intentional.
|
|
101
|
-
[containerRef, triggerRef, isElementVisible]);
|
|
74
|
+
}, [containerRef, triggerRef, isElementVisible]);
|
|
102
75
|
useKeydown(handleKeyDown, subscriptionTrigger, condition);
|
|
103
|
-
// When withTrigger mode closes (condition goes false), restore focus to the trigger
|
|
104
|
-
// if focus landed on body (which happens when the popup's focused element is unmounted).
|
|
105
|
-
// This restoration is intentionally scoped to the "focused element unmounted → body" case;
|
|
106
|
-
// the general close case (e.g. click-outside, item selection) is handled separately by the
|
|
107
|
-
// returnFocusToTrigger effect in absolute.tsx. Both are idempotent, so overlap is harmless.
|
|
108
|
-
// Initialized to false because popups mount closed; the guard below reconciles the first
|
|
109
|
-
// active/inactive edge, so a popup that mounts already open still resolves correctly.
|
|
110
|
-
const isActiveRef = useRef(false);
|
|
111
|
-
useEffect(() => {
|
|
112
|
-
var _a, _b;
|
|
113
|
-
const isActive = condition ? condition(subscriptionTrigger) : !!subscriptionTrigger;
|
|
114
|
-
// Guard: short-circuit when the raw open/close state is unchanged to avoid spurious
|
|
115
|
-
// focus restoration if an unstable condition reference re-fires this effect.
|
|
116
|
-
if (!!subscriptionTrigger === isActiveRef.current) {
|
|
117
|
-
isActiveRef.current = isActive;
|
|
118
|
-
return;
|
|
119
|
-
}
|
|
120
|
-
if (!isActive && isActiveRef.current && (triggerRef === null || triggerRef === void 0 ? void 0 : triggerRef.current)) {
|
|
121
|
-
const active = (_a = zen.document) === null || _a === void 0 ? void 0 : _a.activeElement;
|
|
122
|
-
if (!active || active === ((_b = zen.document) === null || _b === void 0 ? void 0 : _b.body)) {
|
|
123
|
-
triggerRef.current.focus();
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
isActiveRef.current = isActive;
|
|
127
|
-
}, [condition, subscriptionTrigger, triggerRef]);
|
|
128
76
|
};
|
|
@@ -10,7 +10,7 @@ import { IAlignment } from "../utils/positioningUtils/alignments";
|
|
|
10
10
|
export type TAlignment = "top" | "top-left" | "top-right" | "left" | "left-top" | "left-bottom" | "right" | "right-top" | "right-bottom" | "bottom" | "bottom-left" | "bottom-right";
|
|
11
11
|
export interface IControlledPopup extends IZenComponentProps {
|
|
12
12
|
triggerRef: RefObject<HTMLElement | null>;
|
|
13
|
-
/** Alignment of the popup relative to its trigger. Defaults to `"bottom-start"
|
|
13
|
+
/** Alignment of the popup relative to its trigger. Defaults to `"bottom-start"` (resolves to `"bottom-left"` in LTR and `"bottom-right"` in RTL). Accepts both logical and physical `TAlignment` values. */
|
|
14
14
|
alignment?: TAlignmentAbsolute;
|
|
15
15
|
id?: string;
|
|
16
16
|
className?: string;
|
|
@@ -3,12 +3,26 @@ import { useEffect, useId } from "react";
|
|
|
3
3
|
import { Absolute } from "../absolute/absolute";
|
|
4
4
|
import { classNames } from "../commonHelpers/classNames/classNames";
|
|
5
5
|
import { useClientReady } from "../commonHelpers/hooks/useClientReady";
|
|
6
|
-
import {
|
|
6
|
+
import { useDirection } from "../utils/localization/useDirection";
|
|
7
|
+
import { flipAlignment } from "../utils/localization/flipAlignment";
|
|
7
8
|
export const ControlledPopup = ({ isOpen, id, paddingX, paddingY, triggerRef, className, children, alignment, inline, onOpenChange, useTrapFocusWithTrigger, shouldHoldScroll, ariaLabel, ariaLabelledby, recalculateOnScroll, closeOnScroll, preventAttributesAutoSet, focusOnOpen, alignmentsFn, role = "dialog" }) => {
|
|
8
9
|
const autoId = useId();
|
|
9
10
|
const popupId = id || autoId;
|
|
10
11
|
const isClientReady = useClientReady();
|
|
11
|
-
const
|
|
12
|
+
const direction = useDirection();
|
|
13
|
+
// ControlledPopup's sole alignment responsibility: flip deprecated physical values in RTL
|
|
14
|
+
// for backward compatibility with consumers that haven't migrated to logical TAlignment values.
|
|
15
|
+
// In RTL, flipAlignment is called: it flips physical values (e.g. "bottom-left" → "bottom-right")
|
|
16
|
+
// and is a no-op for logical values (e.g. "bottom-start" → "bottom-start"), so logical values
|
|
17
|
+
// pass through to Absolute unchanged. In LTR, flipAlignment is not called at all.
|
|
18
|
+
// Absolute/calculatePosition handles logical → physical resolution internally in both directions.
|
|
19
|
+
//
|
|
20
|
+
// Asymmetry note: passing a physical value (e.g. "bottom-left") directly to <Absolute> in RTL
|
|
21
|
+
// renders on the physical left (no flip). The same prop via ControlledPopup renders on the
|
|
22
|
+
// physical right (pre-flipped here). This is intentional — consumers migrating from
|
|
23
|
+
// ControlledPopup to Absolute directly must switch to logical values to retain RTL behavior.
|
|
24
|
+
const effectiveAlignment = alignment !== null && alignment !== void 0 ? alignment : "bottom-start";
|
|
25
|
+
const flippedAlignment = direction === "rtl" ? flipAlignment(effectiveAlignment) : effectiveAlignment;
|
|
12
26
|
useEffect(() => {
|
|
13
27
|
if (!triggerRef.current || !isClientReady) {
|
|
14
28
|
return;
|
|
@@ -23,5 +37,5 @@ export const ControlledPopup = ({ isOpen, id, paddingX, paddingY, triggerRef, cl
|
|
|
23
37
|
triggerRef.current.setAttribute("aria-expanded", isOpen ? "true" : "false");
|
|
24
38
|
triggerRef.current.setAttribute("aria-controls", popupId);
|
|
25
39
|
}, [triggerRef, isOpen, popupId, preventAttributesAutoSet, isClientReady]);
|
|
26
|
-
return (_jsx(Absolute, Object.assign({ triggerRef: triggerRef, alignment:
|
|
40
|
+
return (_jsx(Absolute, Object.assign({ triggerRef: triggerRef, alignment: flippedAlignment, id: popupId, isOpen: isOpen, className: classNames(["zen-popup", className ? className : ""]), paddingX: paddingX, paddingY: paddingY, inline: inline, onOpenChange: onOpenChange, useTrapFocusWithTrigger: useTrapFocusWithTrigger, shouldHoldScroll: shouldHoldScroll }, (role !== false && typeof role === "string" ? { role } : {}), (role !== false && ariaLabel ? { ariaLabel } : {}), (role !== false && ariaLabelledby ? { ariaLabelledby } : {}), { recalculateOnScroll: recalculateOnScroll, closeOnScroll: closeOnScroll, focusOnOpen: focusOnOpen, alignmentsFn: alignmentsFn, children: children })));
|
|
27
41
|
};
|
|
@@ -33,7 +33,7 @@ injectString("tr", "Collapse feed", "Ak\u0131\u015F\u0131 daralt");
|
|
|
33
33
|
injectString("zh-Hans", "Collapse feed", "\u6298\u53E0\u52A8\u6001");
|
|
34
34
|
injectString("zh-TW", "Collapse feed", "\u647A\u758A\u52D5\u614B");
|
|
35
35
|
injectString("ro-RO", "Collapse feed", "Restr\xE2nge\u021Bi feedul");
|
|
36
|
-
injectString("ar", "Collapse feed", "\u0637\u064A
|
|
36
|
+
injectString("ar-001", "Collapse feed", "\u0637\u064A \u0627\u0644\u0645\u0648\u062C\u0632");
|
|
37
37
|
injectString("lt-LT", "Collapse feed", "Sutraukti sraut\u0105");
|
|
38
38
|
injectString("lv-LV", "Collapse feed", "Sak\u013Caut pl\u016Bsmu");
|
|
39
39
|
injectString("ka-GE", "Collapse feed", "\u10E4\u10D8\u10D3\u10D8\u10E1 \u10E9\u10D0\u10D9\u10D4\u10EA\u10D5\u10D0");
|
|
@@ -66,7 +66,7 @@ injectString("tr", "Expand feed", "Ak\u0131\u015F\u0131 geni\u015Flet");
|
|
|
66
66
|
injectString("zh-Hans", "Expand feed", "\u5C55\u5F00\u52A8\u6001");
|
|
67
67
|
injectString("zh-TW", "Expand feed", "\u5C55\u958B\u52D5\u614B");
|
|
68
68
|
injectString("ro-RO", "Expand feed", "Extinde\u021Bi feedul");
|
|
69
|
-
injectString("ar", "Expand feed", "\u062A\u0648\u0633\u064A\u0639 \u0627\u0644\
|
|
69
|
+
injectString("ar-001", "Expand feed", "\u062A\u0648\u0633\u064A\u0639 \u0627\u0644\u0645\u0648\u062C\u0632");
|
|
70
70
|
injectString("lt-LT", "Expand feed", "I\u0161pl\u0117sti sraut\u0105");
|
|
71
71
|
injectString("lv-LV", "Expand feed", "Izv\u0113rst pl\u016Bsmu");
|
|
72
72
|
injectString("ka-GE", "Expand feed", "\u10E4\u10D8\u10D3\u10D8\u10E1 \u10D2\u10D0\u10E8\u10DA\u10D0");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { FC, PropsWithChildren, ReactElement } from "react";
|
|
1
|
+
import { FC, MouseEvent as ReactMouseEvent, PropsWithChildren, ReactElement } from "react";
|
|
2
2
|
import { IZenIdComponentProps } from "../../../commonHelpers/zenComponent";
|
|
3
3
|
import "./checkboxColumn.less";
|
|
4
4
|
interface ICheckboxCellProps extends IZenIdComponentProps {
|
|
@@ -8,6 +8,7 @@ interface ICheckboxCellProps extends IZenIdComponentProps {
|
|
|
8
8
|
disabled?: boolean;
|
|
9
9
|
children?: ReactElement<typeof CheckboxCell.Content>;
|
|
10
10
|
onChange?: (id: string, checked: boolean) => void;
|
|
11
|
+
onMouseDown?: (id: string, checked: boolean, e: ReactMouseEvent) => void;
|
|
11
12
|
}
|
|
12
13
|
interface ICheckboxCell extends FC<ICheckboxCellProps> {
|
|
13
14
|
Content: FC<PropsWithChildren>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Checkbox } from "../../../checkbox/checkbox";
|
|
3
3
|
import { classNames } from "../../../commonHelpers/classNames/classNames";
|
|
4
|
-
export const CheckboxCell = ({ id, checked, indeterminate, label, disabled, className, onChange, children }) => (_jsxs("div", { className: classNames(["zen-checkbox-column", className || ""]), children: [_jsx(Checkbox, { className: "zen-checkbox-column__checkbox", checked: checked, indeterminate: indeterminate, disabled: disabled, title: label, onChange: e => onChange && onChange(id, e.target.checked), wrapped: true }), children] }));
|
|
4
|
+
export const CheckboxCell = ({ id, checked, indeterminate, label, disabled, className, onChange, onMouseDown, children }) => (_jsxs("div", { className: classNames(["zen-checkbox-column", className || ""]), onMouseDown: onMouseDown ? e => onMouseDown(id, checked, e) : undefined, children: [_jsx(Checkbox, { className: "zen-checkbox-column__checkbox", checked: checked, indeterminate: indeterminate, disabled: disabled, title: label, onChange: e => onChange && onChange(id, e.target.checked), wrapped: true }), children] }));
|
|
5
5
|
CheckboxCell.Content = function content({ children }) {
|
|
6
6
|
return _jsx("div", { className: "zen-checkbox-column__content", children: children });
|
|
7
7
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactNode, RefObject } from "react";
|
|
1
|
+
import { MouseEvent as ReactMouseEvent, ReactNode, RefObject } from "react";
|
|
2
2
|
import { IListColumnWrapper } from "../../listColumn";
|
|
3
3
|
import "./checkboxColumn.less";
|
|
4
4
|
import { SimpleEventHandler } from "../../../commonHelpers/simpleEventHandler";
|
|
@@ -17,7 +17,8 @@ export interface ICheckboxColumnWrapper<T extends object> extends IListColumnWra
|
|
|
17
17
|
attach(event: "toggle", handler: (state: [Event, HTMLButtonElement]) => void): this;
|
|
18
18
|
attach(event: "change", handler: (state: [string, boolean]) => void): this;
|
|
19
19
|
attach(event: "change-all", handler: (state: [boolean]) => void): this;
|
|
20
|
-
|
|
20
|
+
attach(event: "mousedown", handler: (state: [string, boolean, ReactMouseEvent]) => void): this;
|
|
21
|
+
detach(event: "change" | "toggle" | "change-all" | "mousedown", handler?: (state: unknown) => void): this;
|
|
21
22
|
}
|
|
22
23
|
export declare enum SelectionState {
|
|
23
24
|
All = 0,
|
|
@@ -34,6 +35,7 @@ export declare class CheckboxColumnWrapper<T extends IEntityWithId> extends Simp
|
|
|
34
35
|
private state;
|
|
35
36
|
private readonly actionsClickHandler;
|
|
36
37
|
private readonly changeHandler;
|
|
38
|
+
private readonly mouseDownHandler;
|
|
37
39
|
private readonly changeHandlerAll;
|
|
38
40
|
constructor(selections: Set<string>, options: ICheckboxColumnOptions<T>, menuTriggerRef: RefObject<HTMLButtonElement | null>);
|
|
39
41
|
get selectionState(): SelectionState;
|
|
@@ -64,6 +64,15 @@ export class CheckboxColumnWrapper extends SimpleEventHandler {
|
|
|
64
64
|
this.fire("change", [id, checked]);
|
|
65
65
|
}
|
|
66
66
|
});
|
|
67
|
+
// Only fired for enabled checkboxes, so a disabled row can never become a drag anchor.
|
|
68
|
+
Object.defineProperty(this, "mouseDownHandler", {
|
|
69
|
+
enumerable: true,
|
|
70
|
+
configurable: true,
|
|
71
|
+
writable: true,
|
|
72
|
+
value: (id, checked, e) => {
|
|
73
|
+
this.fire("mousedown", [id, checked, e]);
|
|
74
|
+
}
|
|
75
|
+
});
|
|
67
76
|
Object.defineProperty(this, "changeHandlerAll", {
|
|
68
77
|
enumerable: true,
|
|
69
78
|
configurable: true,
|
|
@@ -89,7 +98,7 @@ export class CheckboxColumnWrapper extends SimpleEventHandler {
|
|
|
89
98
|
}
|
|
90
99
|
const allowed = this.condition(entity);
|
|
91
100
|
const isDisable = this.disabled ? this.disabled(entity) : this.state === SelectionState.All;
|
|
92
|
-
const cell = (_jsx(CheckboxCell, { id: entity.id, className: allowed ? "" : "zen-checkbox-column--no-checkbox", checked: this.state === SelectionState.All || this.selections.has(entity.id), indeterminate: false, disabled: isDisable, label: this.options.createTitle(entity), onChange: this.changeHandler, children: _jsx(CheckboxCell.Content, { children: value }) }));
|
|
101
|
+
const cell = (_jsx(CheckboxCell, { id: entity.id, className: allowed ? "" : "zen-checkbox-column--no-checkbox", checked: this.state === SelectionState.All || this.selections.has(entity.id), indeterminate: false, disabled: isDisable, label: this.options.createTitle(entity), onChange: this.changeHandler, onMouseDown: isDisable ? undefined : this.mouseDownHandler, children: _jsx(CheckboxCell.Content, { children: value }) }));
|
|
93
102
|
return cell;
|
|
94
103
|
}
|
|
95
104
|
renderHeader(title) {
|
|
@@ -32,7 +32,7 @@ injectString("tr", "Multiple row selection menu", "\xC7oklu s\u0131ra se\xE7imi
|
|
|
32
32
|
injectString("zh-Hans", "Multiple row selection menu", "\u591A\u884C\u9009\u62E9\u83DC\u5355");
|
|
33
33
|
injectString("zh-TW", "Multiple row selection menu", "\u591A\u5217\u9078\u64C7\u9078\u55AE");
|
|
34
34
|
injectString("ro-RO", "Multiple row selection menu", "Meniu de selectare cu mai multe r\xE2nduri");
|
|
35
|
-
injectString("ar", "Multiple row selection menu", "\u0642\u0627\u0626\u0645\u0629 \u0627\u062E\u062A\u064A\u0627\u0631 \u0635\u0641\u0648\u0641 \u0645\u062A\u0639\u062F\u062F\u0629");
|
|
35
|
+
injectString("ar-001", "Multiple row selection menu", "\u0642\u0627\u0626\u0645\u0629 \u0627\u062E\u062A\u064A\u0627\u0631 \u0635\u0641\u0648\u0641 \u0645\u062A\u0639\u062F\u062F\u0629");
|
|
36
36
|
injectString("lt-LT", "Multiple row selection menu", "Keli\u0173 eilu\u010Di\u0173 pasirinkimo meniu");
|
|
37
37
|
injectString("lv-LV", "Multiple row selection menu", "Vair\u0101ku rindu atlases izv\u0113lne");
|
|
38
38
|
injectString("ka-GE", "Multiple row selection menu", "\u10DB\u10E0\u10D0\u10D5\u10D0\u10DA\u10D8 \u10DB\u10EC\u10D9\u10E0\u10D8\u10D5\u10D8\u10E1 \u10D0\u10E0\u10E9\u10D4\u10D5\u10D8\u10E1 \u10DB\u10D4\u10DC\u10D8\u10E3");
|
package/esm/dataGrid/dataGrid.js
CHANGED
|
@@ -37,7 +37,7 @@ injectString("tr", "Action", "Eylem");
|
|
|
37
37
|
injectString("zh-Hans", "Action", "\u64CD\u4F5C");
|
|
38
38
|
injectString("zh-TW", "Action", "\u52D5\u4F5C");
|
|
39
39
|
injectString("ro-RO", "Action", "M\u0103sur\u0103");
|
|
40
|
-
injectString("ar", "Action", "\u0625\u062C\u0631\u0627\u0621");
|
|
40
|
+
injectString("ar-001", "Action", "\u0625\u062C\u0631\u0627\u0621");
|
|
41
41
|
injectString("lt-LT", "Action", "Veiksmas");
|
|
42
42
|
injectString("lv-LV", "Action", "Darb\u012Bba");
|
|
43
43
|
injectString("ka-GE", "Action", "\u10DB\u10DD\u10E5\u10DB\u10D4\u10D3\u10D4\u10D1\u10D0");
|
|
@@ -36,7 +36,7 @@ injectString("tr", "Try adjusting your search or filter.", "Araman\u0131z\u0131
|
|
|
36
36
|
injectString("zh-Hans", "Try adjusting your search or filter.", "\u5C1D\u8BD5\u8C03\u6574\u60A8\u7684\u641C\u7D22\u6216\u7B5B\u9009\u6761\u4EF6\u3002");
|
|
37
37
|
injectString("zh-TW", "Try adjusting your search or filter.", "\u8ACB\u5617\u8A66\u8ABF\u6574\u60A8\u7684\u641C\u5C0B\u6216\u7BE9\u9078\u689D\u4EF6\u3002");
|
|
38
38
|
injectString("ro-RO", "Try adjusting your search or filter.", "\xCEncerca\u021Bi s\u0103 ajusta\u021Bi c\u0103utarea sau filtrul.");
|
|
39
|
-
injectString("ar", "Try adjusting your search or filter.", "\u062D\u0627\u0648\u0644 \u062A\u0639\u062F\u064A\u0644 \u0627\u0644\u0628\u062D\u062B \u0623\u0648 \u0639\u0627\u0645\u0644 \u0627\u0644\u062A\u0635\u0641\u064A\u0629.");
|
|
39
|
+
injectString("ar-001", "Try adjusting your search or filter.", "\u062D\u0627\u0648\u0644 \u062A\u0639\u062F\u064A\u0644 \u0627\u0644\u0628\u062D\u062B \u0623\u0648 \u0639\u0627\u0645\u0644 \u0627\u0644\u062A\u0635\u0641\u064A\u0629.");
|
|
40
40
|
injectString("lt-LT", "Try adjusting your search or filter.", "Pabandykite koreguoti paie\u0161k\u0105 arba filtr\u0105.");
|
|
41
41
|
injectString("lv-LV", "Try adjusting your search or filter.", "M\u0113\u0123iniet piel\u0101got mekl\u0113\u0161anu vai filtru.");
|
|
42
42
|
injectString("ka-GE", "Try adjusting your search or filter.", "\u10E1\u10EA\u10D0\u10D3\u10D4\u10D7 \u10EB\u10D8\u10D4\u10D1\u10D8\u10E1 \u10D0\u10DC \u10E4\u10D8\u10DA\u10E2\u10E0\u10D8\u10E1 \u10DB\u10DD\u10E0\u10D2\u10D4\u10D1\u10D0.");
|
|
@@ -31,7 +31,7 @@ injectString("tr", "Column Settings", "S\xFCtun Ayarlar\u0131");
|
|
|
31
31
|
injectString("zh-Hans", "Column Settings", "\u5217\u8BBE\u7F6E");
|
|
32
32
|
injectString("zh-TW", "Column Settings", "\u6B04\u8A2D\u5B9A");
|
|
33
33
|
injectString("ro-RO", "Column Settings", "Set\u0103ri coloane");
|
|
34
|
-
injectString("ar", "Column Settings", "\u0625\u0639\u062F\u0627\u062F\u0627\u062A \u0627\u0644\u0639\u0645\u0648\u062F");
|
|
34
|
+
injectString("ar-001", "Column Settings", "\u0625\u0639\u062F\u0627\u062F\u0627\u062A \u0627\u0644\u0639\u0645\u0648\u062F");
|
|
35
35
|
injectString("lt-LT", "Column Settings", "Stulpelio nustatymai");
|
|
36
36
|
injectString("lv-LV", "Column Settings", "Kolonnas iestat\u012Bjumi");
|
|
37
37
|
injectString("ka-GE", "Column Settings", "\u10E1\u10D5\u10D4\u10E2\u10D8\u10E1 \u10DE\u10D0\u10E0\u10D0\u10DB\u10D4\u10E2\u10E0\u10D4\u10D1\u10D8");
|