@talxis/base-controls 0.0.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 +41 -0
- package/dist/components/DatasetControl/DatasetControl.d.ts +3 -0
- package/dist/components/DatasetControl/DatasetControl.js +72 -0
- package/dist/components/DatasetControl/DatasetControl.js.map +1 -0
- package/dist/components/DatasetControl/Paging/DatasetPaging.d.ts +3 -0
- package/dist/components/DatasetControl/Paging/DatasetPaging.js +69 -0
- package/dist/components/DatasetControl/Paging/DatasetPaging.js.map +1 -0
- package/dist/components/DatasetControl/Paging/Paging.d.ts +26 -0
- package/dist/components/DatasetControl/Paging/Paging.js +80 -0
- package/dist/components/DatasetControl/Paging/Paging.js.map +1 -0
- package/dist/components/DatasetControl/Paging/index.d.ts +3 -0
- package/dist/components/DatasetControl/Paging/index.js +3 -0
- package/dist/components/DatasetControl/Paging/index.js.map +1 -0
- package/dist/components/DatasetControl/Paging/interfaces.d.ts +16 -0
- package/dist/components/DatasetControl/Paging/styles.d.ts +35 -0
- package/dist/components/DatasetControl/Paging/styles.js +41 -0
- package/dist/components/DatasetControl/Paging/styles.js.map +1 -0
- package/dist/components/DatasetControl/Paging/translations.d.ts +38 -0
- package/dist/components/DatasetControl/Paging/translations.js +14 -0
- package/dist/components/DatasetControl/Paging/translations.js.map +1 -0
- package/dist/components/DatasetControl/QuickFind/QuickFind.d.ts +13 -0
- package/dist/components/DatasetControl/QuickFind/QuickFind.js +59 -0
- package/dist/components/DatasetControl/QuickFind/QuickFind.js.map +1 -0
- package/dist/components/DatasetControl/QuickFind/styles.d.ts +8 -0
- package/dist/components/DatasetControl/QuickFind/styles.js +15 -0
- package/dist/components/DatasetControl/QuickFind/styles.js.map +1 -0
- package/dist/components/DatasetControl/index.d.ts +3 -0
- package/dist/components/DatasetControl/index.js +4 -0
- package/dist/components/DatasetControl/index.js.map +1 -0
- package/dist/components/DatasetControl/interfaces.d.ts +32 -0
- package/dist/components/DatasetControl/styles.d.ts +18 -0
- package/dist/components/DatasetControl/styles.js +29 -0
- package/dist/components/DatasetControl/styles.js.map +1 -0
- package/dist/components/DatasetControl/translations.d.ts +18 -0
- package/dist/components/DatasetControl/translations.js +9 -0
- package/dist/components/DatasetControl/translations.js.map +1 -0
- package/dist/components/DateTime/DateTime.d.ts +3 -0
- package/dist/components/DateTime/DateTime.js +149 -0
- package/dist/components/DateTime/DateTime.js.map +1 -0
- package/dist/components/DateTime/components/Calendar.d.ts +17 -0
- package/dist/components/DateTime/components/Calendar.js +63 -0
- package/dist/components/DateTime/components/Calendar.js.map +1 -0
- package/dist/components/DateTime/hooks/useDateTime.d.ts +32 -0
- package/dist/components/DateTime/hooks/useDateTime.js +150 -0
- package/dist/components/DateTime/hooks/useDateTime.js.map +1 -0
- package/dist/components/DateTime/index.d.ts +3 -0
- package/dist/components/DateTime/index.js +3 -0
- package/dist/components/DateTime/index.js.map +1 -0
- package/dist/components/DateTime/interfaces.d.ts +23 -0
- package/dist/components/DateTime/styles.d.ts +31 -0
- package/dist/components/DateTime/styles.js +37 -0
- package/dist/components/DateTime/styles.js.map +1 -0
- package/dist/components/DateTime/translations.d.ts +19 -0
- package/dist/components/DateTime/translations.js +23 -0
- package/dist/components/DateTime/translations.js.map +1 -0
- package/dist/components/Decimal/Decimal.d.ts +3 -0
- package/dist/components/Decimal/Decimal.js +204 -0
- package/dist/components/Decimal/Decimal.js.map +1 -0
- package/dist/components/Decimal/components/ArrowButtons.d.ts +10 -0
- package/dist/components/Decimal/components/ArrowButtons.js +38 -0
- package/dist/components/Decimal/components/ArrowButtons.js.map +1 -0
- package/dist/components/Decimal/components/styles.d.ts +20 -0
- package/dist/components/Decimal/components/styles.js +26 -0
- package/dist/components/Decimal/components/styles.js.map +1 -0
- package/dist/components/Decimal/index.d.ts +2 -0
- package/dist/components/Decimal/index.js +2 -0
- package/dist/components/Decimal/index.js.map +1 -0
- package/dist/components/Decimal/interfaces.d.ts +13 -0
- package/dist/components/Duration/Duration.d.ts +3 -0
- package/dist/components/Duration/Duration.js +155 -0
- package/dist/components/Duration/Duration.js.map +1 -0
- package/dist/components/Duration/durationOptions.d.ts +2 -0
- package/dist/components/Duration/durationOptions.js +27 -0
- package/dist/components/Duration/durationOptions.js.map +1 -0
- package/dist/components/Duration/index.d.ts +2 -0
- package/dist/components/Duration/index.js +2 -0
- package/dist/components/Duration/index.js.map +1 -0
- package/dist/components/Duration/interfaces.d.ts +13 -0
- package/dist/components/Duration/translations.d.ts +26 -0
- package/dist/components/Duration/translations.js +31 -0
- package/dist/components/Duration/translations.js.map +1 -0
- package/dist/components/Grid/Grid.d.ts +3 -0
- package/dist/components/Grid/Grid.js +37 -0
- package/dist/components/Grid/Grid.js.map +1 -0
- package/dist/components/Grid/GridContext.d.ts +3 -0
- package/dist/components/Grid/GridContext.js +6 -0
- package/dist/components/Grid/GridContext.js.map +1 -0
- package/dist/components/Grid/aggregation/Aggregation.d.ts +18 -0
- package/dist/components/Grid/aggregation/Aggregation.js +129 -0
- package/dist/components/Grid/aggregation/Aggregation.js.map +1 -0
- package/dist/components/Grid/constants.d.ts +1 -0
- package/dist/components/Grid/constants.js +4 -0
- package/dist/components/Grid/constants.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/AgGrid.d.ts +5 -0
- package/dist/components/Grid/core/components/AgGrid/AgGrid.js +203 -0
- package/dist/components/Grid/core/components/AgGrid/AgGrid.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/components/EmptyRecordsOverlay/EmptyRecords.d.ts +2 -0
- package/dist/components/Grid/core/components/AgGrid/components/EmptyRecordsOverlay/EmptyRecords.js +12 -0
- package/dist/components/Grid/core/components/AgGrid/components/EmptyRecordsOverlay/EmptyRecords.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/components/EmptyRecordsOverlay/styles.d.ts +18 -0
- package/dist/components/Grid/core/components/AgGrid/components/EmptyRecordsOverlay/styles.js +23 -0
- package/dist/components/Grid/core/components/AgGrid/components/EmptyRecordsOverlay/styles.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/components/LoadingOverlay/LoadingOverlay.d.ts +2 -0
- package/dist/components/Grid/core/components/AgGrid/components/LoadingOverlay/LoadingOverlay.js +10 -0
- package/dist/components/Grid/core/components/AgGrid/components/LoadingOverlay/LoadingOverlay.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/context.d.ts +3 -0
- package/dist/components/Grid/core/components/AgGrid/context.js +6 -0
- package/dist/components/Grid/core/components/AgGrid/context.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/model/AgGrid.d.ts +52 -0
- package/dist/components/Grid/core/components/AgGrid/model/AgGrid.js +343 -0
- package/dist/components/Grid/core/components/AgGrid/model/AgGrid.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/model/Comparator.d.ts +9 -0
- package/dist/components/Grid/core/components/AgGrid/model/Comparator.js +86 -0
- package/dist/components/Grid/core/components/AgGrid/model/Comparator.js.map +1 -0
- package/dist/components/Grid/core/components/AgGrid/styles.d.ts +72 -0
- package/dist/components/Grid/core/components/AgGrid/styles.js +78 -0
- package/dist/components/Grid/core/components/AgGrid/styles.js.map +1 -0
- package/dist/components/Grid/core/components/Cell/Cell.d.ts +13 -0
- package/dist/components/Grid/core/components/Cell/Cell.js +158 -0
- package/dist/components/Grid/core/components/Cell/Cell.js.map +1 -0
- package/dist/components/Grid/core/components/Cell/CellContent/CellContent.d.ts +8 -0
- package/dist/components/Grid/core/components/Cell/CellContent/CellContent.js +230 -0
- package/dist/components/Grid/core/components/Cell/CellContent/CellContent.js.map +1 -0
- package/dist/components/Grid/core/components/Cell/CellContent/styles.d.ts +33 -0
- package/dist/components/Grid/core/components/Cell/CellContent/styles.js +39 -0
- package/dist/components/Grid/core/components/Cell/CellContent/styles.js.map +1 -0
- package/dist/components/Grid/core/components/Cell/Notifications/Notifications.d.ts +12 -0
- package/dist/components/Grid/core/components/Cell/Notifications/Notifications.js +112 -0
- package/dist/components/Grid/core/components/Cell/Notifications/Notifications.js.map +1 -0
- package/dist/components/Grid/core/components/Cell/Notifications/styles.d.ts +39 -0
- package/dist/components/Grid/core/components/Cell/Notifications/styles.js +46 -0
- package/dist/components/Grid/core/components/Cell/Notifications/styles.js.map +1 -0
- package/dist/components/Grid/core/components/Cell/styles.d.ts +40 -0
- package/dist/components/Grid/core/components/Cell/styles.js +59 -0
- package/dist/components/Grid/core/components/Cell/styles.js.map +1 -0
- package/dist/components/Grid/core/components/ColumnHeader/ColumnHeader.d.ts +6 -0
- package/dist/components/Grid/core/components/ColumnHeader/ColumnHeader.js +61 -0
- package/dist/components/Grid/core/components/ColumnHeader/ColumnHeader.js.map +1 -0
- package/dist/components/Grid/core/components/ColumnHeader/components/GlobalCheckbox/GlobalCheckbox.d.ts +2 -0
- package/dist/components/Grid/core/components/ColumnHeader/components/GlobalCheckbox/GlobalCheckbox.js +50 -0
- package/dist/components/Grid/core/components/ColumnHeader/components/GlobalCheckbox/GlobalCheckbox.js.map +1 -0
- package/dist/components/Grid/core/components/ColumnHeader/components/GlobalCheckbox/styles.d.ts +14 -0
- package/dist/components/Grid/core/components/ColumnHeader/components/GlobalCheckbox/styles.js +20 -0
- package/dist/components/Grid/core/components/ColumnHeader/components/GlobalCheckbox/styles.js.map +1 -0
- package/dist/components/Grid/core/components/ColumnHeader/styles.d.ts +42 -0
- package/dist/components/Grid/core/components/ColumnHeader/styles.js +48 -0
- package/dist/components/Grid/core/components/ColumnHeader/styles.js.map +1 -0
- package/dist/components/Grid/core/components/Dialog/Constants.d.ts +2 -0
- package/dist/components/Grid/core/components/Dialog/Constants.js +9 -0
- package/dist/components/Grid/core/components/Dialog/Constants.js.map +1 -0
- package/dist/components/Grid/core/components/Dialog/Styles.d.ts +2 -0
- package/dist/components/Grid/core/components/Dialog/Styles.js +61 -0
- package/dist/components/Grid/core/components/Dialog/Styles.js.map +1 -0
- package/dist/components/Grid/core/components/Dialog/index.d.ts +4 -0
- package/dist/components/Grid/core/components/Dialog/index.js +16 -0
- package/dist/components/Grid/core/components/Dialog/index.js.map +1 -0
- package/dist/components/Grid/core/components/Dialog/interfaces/index.d.ts +6 -0
- package/dist/components/Grid/core/components/Dialog/interfaces/index.js +2 -0
- package/dist/components/Grid/core/components/Dialog/interfaces/index.js.map +1 -0
- package/dist/components/Grid/core/components/Save/Save.d.ts +2 -0
- package/dist/components/Grid/core/components/Save/Save.js +59 -0
- package/dist/components/Grid/core/components/Save/Save.js.map +1 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/ChangeEditor.d.ts +7 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/ChangeEditor.js +73 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/ChangeEditor.js.map +1 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/components/ChangeGrid/ChangeGrid.d.ts +11 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/components/ChangeGrid/ChangeGrid.js +231 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/components/ChangeGrid/ChangeGrid.js.map +1 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/components/ChangeGrid/styles.d.ts +39 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/components/ChangeGrid/styles.js +45 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/components/ChangeGrid/styles.js.map +1 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/styles.d.ts +31 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/styles.js +37 -0
- package/dist/components/Grid/core/components/Save/components/ChangeEditor/styles.js.map +1 -0
- package/dist/components/Grid/core/components/Save/styles.d.ts +35 -0
- package/dist/components/Grid/core/components/Save/styles.js +42 -0
- package/dist/components/Grid/core/components/Save/styles.js.map +1 -0
- package/dist/components/Grid/core/controllers/useGridController.d.ts +7 -0
- package/dist/components/Grid/core/controllers/useGridController.js +29 -0
- package/dist/components/Grid/core/controllers/useGridController.js.map +1 -0
- package/dist/components/Grid/core/enums/ConditionOperator.d.ts +48 -0
- package/dist/components/Grid/core/enums/ConditionOperator.js +52 -0
- package/dist/components/Grid/core/enums/ConditionOperator.js.map +1 -0
- package/dist/components/Grid/core/enums/DataType.d.ts +25 -0
- package/dist/components/Grid/core/enums/DataType.js +30 -0
- package/dist/components/Grid/core/enums/DataType.js.map +1 -0
- package/dist/components/Grid/core/hooks/useGridInstance.d.ts +2 -0
- package/dist/components/Grid/core/hooks/useGridInstance.js +9 -0
- package/dist/components/Grid/core/hooks/useGridInstance.js.map +1 -0
- package/dist/components/Grid/core/hooks/useRefreshCallback.d.ts +2 -0
- package/dist/components/Grid/core/hooks/useRefreshCallback.js +20 -0
- package/dist/components/Grid/core/hooks/useRefreshCallback.js.map +1 -0
- package/dist/components/Grid/core/interfaces/IGridColumn.d.ts +13 -0
- package/dist/components/Grid/core/interfaces/IGridContext.d.ts +4 -0
- package/dist/components/Grid/core/model/Grid.d.ts +81 -0
- package/dist/components/Grid/core/model/Grid.js +513 -0
- package/dist/components/Grid/core/model/Grid.js.map +1 -0
- package/dist/components/Grid/core/model/GridDependency.d.ts +13 -0
- package/dist/components/Grid/core/model/GridDependency.js +28 -0
- package/dist/components/Grid/core/model/GridDependency.js.map +1 -0
- package/dist/components/Grid/core/services/KeyListener.d.ts +12 -0
- package/dist/components/Grid/core/services/KeyListener.js +31 -0
- package/dist/components/Grid/core/services/KeyListener.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/FilterCallout.d.ts +8 -0
- package/dist/components/Grid/filtering/components/FilterCallout/FilterCallout.js +59 -0
- package/dist/components/Grid/filtering/components/FilterCallout/FilterCallout.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionOperator/ConditionOperator.d.ts +7 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionOperator/ConditionOperator.js +56 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionOperator/ConditionOperator.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/ConditionValue.d.ts +7 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/ConditionValue.js +73 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/ConditionValue.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/ConditionValueBetween.d.ts +7 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/ConditionValueBetween.js +90 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/ConditionValueBetween.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/model/ConditionComponentValue.d.ts +48 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/model/ConditionComponentValue.js +146 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/ConditionValue/model/ConditionComponentValue.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/Component.d.ts +11 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/Component.js +53 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/Component.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/controller/useComponentController.d.ts +9 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/controller/useComponentController.js +31 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/controller/useComponentController.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/model/Component.d.ts +10 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/model/Component.js +294 -0
- package/dist/components/Grid/filtering/components/FilterCallout/components/LegacyControlRendering/model/Component.js.map +1 -0
- package/dist/components/Grid/filtering/components/FilterCallout/styles.d.ts +35 -0
- package/dist/components/Grid/filtering/components/FilterCallout/styles.js +40 -0
- package/dist/components/Grid/filtering/components/FilterCallout/styles.js.map +1 -0
- package/dist/components/Grid/filtering/constants.d.ts +5 -0
- package/dist/components/Grid/filtering/constants.js +53 -0
- package/dist/components/Grid/filtering/constants.js.map +1 -0
- package/dist/components/Grid/filtering/controller/useColumnFilterConditionController.d.ts +21 -0
- package/dist/components/Grid/filtering/controller/useColumnFilterConditionController.js +44 -0
- package/dist/components/Grid/filtering/controller/useColumnFilterConditionController.js.map +1 -0
- package/dist/components/Grid/filtering/model/Condition.d.ts +49 -0
- package/dist/components/Grid/filtering/model/Condition.js +347 -0
- package/dist/components/Grid/filtering/model/Condition.js.map +1 -0
- package/dist/components/Grid/filtering/model/Filtering.d.ts +11 -0
- package/dist/components/Grid/filtering/model/Filtering.js +78 -0
- package/dist/components/Grid/filtering/model/Filtering.js.map +1 -0
- package/dist/components/Grid/filtering/utils/FilteringUtilts.d.ts +34 -0
- package/dist/components/Grid/filtering/utils/FilteringUtilts.js +195 -0
- package/dist/components/Grid/filtering/utils/FilteringUtilts.js.map +1 -0
- package/dist/components/Grid/index.d.ts +2 -0
- package/dist/components/Grid/index.js +2 -0
- package/dist/components/Grid/index.js.map +1 -0
- package/dist/components/Grid/interfaces.d.ts +36 -0
- package/dist/components/Grid/selection/model/Selection.d.ts +12 -0
- package/dist/components/Grid/selection/model/Selection.js +54 -0
- package/dist/components/Grid/selection/model/Selection.js.map +1 -0
- package/dist/components/Grid/sorting/Sorting.d.ts +10 -0
- package/dist/components/Grid/sorting/Sorting.js +31 -0
- package/dist/components/Grid/sorting/Sorting.js.map +1 -0
- package/dist/components/Grid/sorting/components/SortingContextualMenu/SortingContextualMenu.d.ts +8 -0
- package/dist/components/Grid/sorting/components/SortingContextualMenu/SortingContextualMenu.js +157 -0
- package/dist/components/Grid/sorting/components/SortingContextualMenu/SortingContextualMenu.js.map +1 -0
- package/dist/components/Grid/sorting/components/SortingContextualMenu/styles.d.ts +9 -0
- package/dist/components/Grid/sorting/components/SortingContextualMenu/styles.js +15 -0
- package/dist/components/Grid/sorting/components/SortingContextualMenu/styles.js.map +1 -0
- package/dist/components/Grid/sorting/controllers/useColumnSortingController.d.ts +9 -0
- package/dist/components/Grid/sorting/controllers/useColumnSortingController.js +22 -0
- package/dist/components/Grid/sorting/controllers/useColumnSortingController.js.map +1 -0
- package/dist/components/Grid/translations.d.ts +366 -0
- package/dist/components/Grid/translations.js +99 -0
- package/dist/components/Grid/translations.js.map +1 -0
- package/dist/components/GridCellRenderer/DefaultContentRenderer/DefaultContentRenderer.d.ts +2 -0
- package/dist/components/GridCellRenderer/DefaultContentRenderer/DefaultContentRenderer.js +11 -0
- package/dist/components/GridCellRenderer/DefaultContentRenderer/DefaultContentRenderer.js.map +1 -0
- package/dist/components/GridCellRenderer/DefaultContentRenderer/index.d.ts +1 -0
- package/dist/components/GridCellRenderer/DefaultContentRenderer/index.js +2 -0
- package/dist/components/GridCellRenderer/DefaultContentRenderer/index.js.map +1 -0
- package/dist/components/GridCellRenderer/GridCellRenderer.d.ts +3 -0
- package/dist/components/GridCellRenderer/GridCellRenderer.js +293 -0
- package/dist/components/GridCellRenderer/GridCellRenderer.js.map +1 -0
- package/dist/components/GridCellRenderer/OptionSet/OptionSet.d.ts +5 -0
- package/dist/components/GridCellRenderer/OptionSet/OptionSet.js +75 -0
- package/dist/components/GridCellRenderer/OptionSet/OptionSet.js.map +1 -0
- package/dist/components/GridCellRenderer/OptionSet/index.d.ts +1 -0
- package/dist/components/GridCellRenderer/OptionSet/index.js +2 -0
- package/dist/components/GridCellRenderer/OptionSet/index.js.map +1 -0
- package/dist/components/GridCellRenderer/OptionSet/styles.d.ts +20 -0
- package/dist/components/GridCellRenderer/OptionSet/styles.js +29 -0
- package/dist/components/GridCellRenderer/OptionSet/styles.js.map +1 -0
- package/dist/components/GridCellRenderer/RecordCommands/Icon.d.ts +7 -0
- package/dist/components/GridCellRenderer/RecordCommands/Icon.js +32 -0
- package/dist/components/GridCellRenderer/RecordCommands/Icon.js.map +1 -0
- package/dist/components/GridCellRenderer/RecordCommands/RecordCommands.d.ts +13 -0
- package/dist/components/GridCellRenderer/RecordCommands/RecordCommands.js +103 -0
- package/dist/components/GridCellRenderer/RecordCommands/RecordCommands.js.map +1 -0
- package/dist/components/GridCellRenderer/RecordCommands/styles.d.ts +13 -0
- package/dist/components/GridCellRenderer/RecordCommands/styles.js +32 -0
- package/dist/components/GridCellRenderer/RecordCommands/styles.js.map +1 -0
- package/dist/components/GridCellRenderer/index.d.ts +2 -0
- package/dist/components/GridCellRenderer/index.js +2 -0
- package/dist/components/GridCellRenderer/index.js.map +1 -0
- package/dist/components/GridCellRenderer/interfaces.d.ts +66 -0
- package/dist/components/GridCellRenderer/styles.d.ts +85 -0
- package/dist/components/GridCellRenderer/styles.js +119 -0
- package/dist/components/GridCellRenderer/styles.js.map +1 -0
- package/dist/components/GridCellRenderer/translations.d.ts +30 -0
- package/dist/components/GridCellRenderer/translations.js +35 -0
- package/dist/components/GridCellRenderer/translations.js.map +1 -0
- package/dist/components/GridCellRenderer/useComponentProps.d.ts +6 -0
- package/dist/components/GridCellRenderer/useComponentProps.js +10 -0
- package/dist/components/GridCellRenderer/useComponentProps.js.map +1 -0
- package/dist/components/Lookup/Lookup.d.ts +3 -0
- package/dist/components/Lookup/Lookup.js +222 -0
- package/dist/components/Lookup/Lookup.js.map +1 -0
- package/dist/components/Lookup/components/RecordCreator.d.ts +10 -0
- package/dist/components/Lookup/components/RecordCreator.js +37 -0
- package/dist/components/Lookup/components/RecordCreator.js.map +1 -0
- package/dist/components/Lookup/components/TargetSelector.d.ts +9 -0
- package/dist/components/Lookup/components/TargetSelector.js +19 -0
- package/dist/components/Lookup/components/TargetSelector.js.map +1 -0
- package/dist/components/Lookup/hooks/useFetchXml.d.ts +6 -0
- package/dist/components/Lookup/hooks/useFetchXml.js +52 -0
- package/dist/components/Lookup/hooks/useFetchXml.js.map +1 -0
- package/dist/components/Lookup/hooks/useLoadedEntities.d.ts +6 -0
- package/dist/components/Lookup/hooks/useLoadedEntities.js +20 -0
- package/dist/components/Lookup/hooks/useLoadedEntities.js.map +1 -0
- package/dist/components/Lookup/hooks/useLookup.d.ts +43 -0
- package/dist/components/Lookup/hooks/useLookup.js +120 -0
- package/dist/components/Lookup/hooks/useLookup.js.map +1 -0
- package/dist/components/Lookup/index.d.ts +3 -0
- package/dist/components/Lookup/index.js +3 -0
- package/dist/components/Lookup/index.js.map +1 -0
- package/dist/components/Lookup/interfaces.d.ts +75 -0
- package/dist/components/Lookup/styles.d.ts +95 -0
- package/dist/components/Lookup/styles.js +112 -0
- package/dist/components/Lookup/styles.js.map +1 -0
- package/dist/components/Lookup/translations.d.ts +30 -0
- package/dist/components/Lookup/translations.js +33 -0
- package/dist/components/Lookup/translations.js.map +1 -0
- package/dist/components/MultiSelectOptionSet/ColofulOptions/ColorfulOptions.d.ts +8 -0
- package/dist/components/MultiSelectOptionSet/ColofulOptions/ColorfulOptions.js +42 -0
- package/dist/components/MultiSelectOptionSet/ColofulOptions/ColorfulOptions.js.map +1 -0
- package/dist/components/MultiSelectOptionSet/ColofulOptions/styles.d.ts +17 -0
- package/dist/components/MultiSelectOptionSet/ColofulOptions/styles.js +24 -0
- package/dist/components/MultiSelectOptionSet/ColofulOptions/styles.js.map +1 -0
- package/dist/components/MultiSelectOptionSet/MultiSelectOptionSet.d.ts +3 -0
- package/dist/components/MultiSelectOptionSet/MultiSelectOptionSet.js +132 -0
- package/dist/components/MultiSelectOptionSet/MultiSelectOptionSet.js.map +1 -0
- package/dist/components/MultiSelectOptionSet/index.d.ts +2 -0
- package/dist/components/MultiSelectOptionSet/index.js +2 -0
- package/dist/components/MultiSelectOptionSet/index.js.map +1 -0
- package/dist/components/MultiSelectOptionSet/interfaces.d.ts +13 -0
- package/dist/components/MultiSelectOptionSet/styles.d.ts +31 -0
- package/dist/components/MultiSelectOptionSet/styles.js +42 -0
- package/dist/components/MultiSelectOptionSet/styles.js.map +1 -0
- package/dist/components/NestedControlRenderer/NestedControl.d.ts +86 -0
- package/dist/components/NestedControlRenderer/NestedControl.js +456 -0
- package/dist/components/NestedControlRenderer/NestedControl.js.map +1 -0
- package/dist/components/NestedControlRenderer/NestedControlError.d.ts +4 -0
- package/dist/components/NestedControlRenderer/NestedControlError.js +13 -0
- package/dist/components/NestedControlRenderer/NestedControlError.js.map +1 -0
- package/dist/components/NestedControlRenderer/NestedControlRenderer.d.ts +3 -0
- package/dist/components/NestedControlRenderer/NestedControlRenderer.js +194 -0
- package/dist/components/NestedControlRenderer/NestedControlRenderer.js.map +1 -0
- package/dist/components/NestedControlRenderer/index.d.ts +1 -0
- package/dist/components/NestedControlRenderer/index.js +2 -0
- package/dist/components/NestedControlRenderer/index.js.map +1 -0
- package/dist/components/NestedControlRenderer/interfaces.d.ts +122 -0
- package/dist/components/NestedControlRenderer/manifest/Control.d.ts +16 -0
- package/dist/components/NestedControlRenderer/manifest/Control.js +40 -0
- package/dist/components/NestedControlRenderer/manifest/Control.js.map +1 -0
- package/dist/components/NestedControlRenderer/manifest/Manifest.d.ts +5 -0
- package/dist/components/NestedControlRenderer/manifest/Manifest.js +12 -0
- package/dist/components/NestedControlRenderer/manifest/Manifest.js.map +1 -0
- package/dist/components/NestedControlRenderer/manifest/TypeGroup.d.ts +6 -0
- package/dist/components/NestedControlRenderer/manifest/TypeGroup.js +13 -0
- package/dist/components/NestedControlRenderer/manifest/TypeGroup.js.map +1 -0
- package/dist/components/NestedControlRenderer/manifest/index.d.ts +1 -0
- package/dist/components/NestedControlRenderer/manifest/index.js +2 -0
- package/dist/components/NestedControlRenderer/manifest/index.js.map +1 -0
- package/dist/components/NestedControlRenderer/manifest/property/Property.d.ts +16 -0
- package/dist/components/NestedControlRenderer/manifest/property/Property.js +34 -0
- package/dist/components/NestedControlRenderer/manifest/property/Property.js.map +1 -0
- package/dist/components/NestedControlRenderer/manifest/property/Value.d.ts +8 -0
- package/dist/components/NestedControlRenderer/manifest/property/Value.js +12 -0
- package/dist/components/NestedControlRenderer/manifest/property/Value.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/DateProperty.d.ts +5 -0
- package/dist/components/NestedControlRenderer/properties/DateProperty.js +20 -0
- package/dist/components/NestedControlRenderer/properties/DateProperty.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/FileProperty.d.ts +5 -0
- package/dist/components/NestedControlRenderer/properties/FileProperty.js +14 -0
- package/dist/components/NestedControlRenderer/properties/FileProperty.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/LookupProperty.d.ts +6 -0
- package/dist/components/NestedControlRenderer/properties/LookupProperty.js +35 -0
- package/dist/components/NestedControlRenderer/properties/LookupProperty.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/NumberProperty.d.ts +5 -0
- package/dist/components/NestedControlRenderer/properties/NumberProperty.js +15 -0
- package/dist/components/NestedControlRenderer/properties/NumberProperty.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/OptionSetProperty.d.ts +5 -0
- package/dist/components/NestedControlRenderer/properties/OptionSetProperty.js +18 -0
- package/dist/components/NestedControlRenderer/properties/OptionSetProperty.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/Property.d.ts +17 -0
- package/dist/components/NestedControlRenderer/properties/Property.js +46 -0
- package/dist/components/NestedControlRenderer/properties/Property.js.map +1 -0
- package/dist/components/NestedControlRenderer/properties/TextProperty.d.ts +5 -0
- package/dist/components/NestedControlRenderer/properties/TextProperty.js +15 -0
- package/dist/components/NestedControlRenderer/properties/TextProperty.js.map +1 -0
- package/dist/components/NestedControlRenderer/styles.d.ts +14 -0
- package/dist/components/NestedControlRenderer/styles.js +21 -0
- package/dist/components/NestedControlRenderer/styles.js.map +1 -0
- package/dist/components/NestedControlRenderer/translations.d.ts +14 -0
- package/dist/components/NestedControlRenderer/translations.js +19 -0
- package/dist/components/NestedControlRenderer/translations.js.map +1 -0
- package/dist/components/OptionSet/OptionSet.d.ts +3 -0
- package/dist/components/OptionSet/OptionSet.js +80 -0
- package/dist/components/OptionSet/OptionSet.js.map +1 -0
- package/dist/components/OptionSet/index.d.ts +2 -0
- package/dist/components/OptionSet/index.js +2 -0
- package/dist/components/OptionSet/index.js.map +1 -0
- package/dist/components/OptionSet/interfaces.d.ts +13 -0
- package/dist/components/OptionSet/shared.d.ts +5 -0
- package/dist/components/OptionSet/shared.js +19 -0
- package/dist/components/OptionSet/shared.js.map +1 -0
- package/dist/components/OptionSet/styles.d.ts +11 -0
- package/dist/components/OptionSet/styles.js +18 -0
- package/dist/components/OptionSet/styles.js.map +1 -0
- package/dist/components/OptionSet/useComboBoxTheme.d.ts +3 -0
- package/dist/components/OptionSet/useComboBoxTheme.js +61 -0
- package/dist/components/OptionSet/useComboBoxTheme.js.map +1 -0
- package/dist/components/TextField/TextField.d.ts +3 -0
- package/dist/components/TextField/TextField.js +120 -0
- package/dist/components/TextField/TextField.js.map +1 -0
- package/dist/components/TextField/index.d.ts +2 -0
- package/dist/components/TextField/index.js +2 -0
- package/dist/components/TextField/index.js.map +1 -0
- package/dist/components/TextField/interfaces.d.ts +14 -0
- package/dist/components/TwoOptions/TwoOptions.d.ts +3 -0
- package/dist/components/TwoOptions/TwoOptions.js +55 -0
- package/dist/components/TwoOptions/TwoOptions.js.map +1 -0
- package/dist/components/TwoOptions/index.d.ts +2 -0
- package/dist/components/TwoOptions/index.js +2 -0
- package/dist/components/TwoOptions/index.js.map +1 -0
- package/dist/components/TwoOptions/interfaces.d.ts +13 -0
- package/dist/components/index.d.ts +13 -0
- package/dist/components/index.js +17 -0
- package/dist/components/index.js.map +1 -0
- package/dist/constants.d.ts +15 -0
- package/dist/constants.js +35 -0
- package/dist/constants.js.map +1 -0
- package/dist/hooks/index.d.ts +7 -0
- package/dist/hooks/index.js +8 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/hooks/useControl.d.ts +17 -0
- package/dist/hooks/useControl.js +67 -0
- package/dist/hooks/useControl.js.map +1 -0
- package/dist/hooks/useControlLabels.d.ts +14 -0
- package/dist/hooks/useControlLabels.js +47 -0
- package/dist/hooks/useControlLabels.js.map +1 -0
- package/dist/hooks/useControlSizing.d.ts +5 -0
- package/dist/hooks/useControlSizing.js +15 -0
- package/dist/hooks/useControlSizing.js.map +1 -0
- package/dist/hooks/useFocusIn.d.ts +1 -0
- package/dist/hooks/useFocusIn.js +33 -0
- package/dist/hooks/useFocusIn.js.map +1 -0
- package/dist/hooks/useInputBasedControl.d.ts +37 -0
- package/dist/hooks/useInputBasedControl.js +36 -0
- package/dist/hooks/useInputBasedControl.js.map +1 -0
- package/dist/hooks/useMouseOver.d.ts +1 -0
- package/dist/hooks/useMouseOver.js +23 -0
- package/dist/hooks/useMouseOver.js.map +1 -0
- package/dist/hooks/usePrevious.d.ts +1 -0
- package/dist/index.d.ts +1504 -0
- package/dist/index.js +30 -0
- package/dist/index.js.map +1 -0
- package/dist/interfaces/context.d.ts +27 -0
- package/dist/interfaces/index.d.ts +9 -0
- package/dist/interfaces/index.js +2 -0
- package/dist/interfaces/index.js.map +1 -0
- package/dist/interfaces/parameters.d.ts +25 -0
- package/dist/interfaces/property.d.ts +67 -0
- package/dist/utils/BaseControls.d.ts +16 -0
- package/dist/utils/BaseControls.js +82 -0
- package/dist/utils/BaseControls.js.map +1 -0
- package/dist/utils/dataset/adapters/DatasetAdapter.d.ts +59 -0
- package/dist/utils/dataset/adapters/DatasetAdapter.js +229 -0
- package/dist/utils/dataset/adapters/DatasetAdapter.js.map +1 -0
- package/dist/utils/dataset/adapters/VirtualDatasetAdapter.d.ts +48 -0
- package/dist/utils/dataset/adapters/VirtualDatasetAdapter.js +169 -0
- package/dist/utils/dataset/adapters/VirtualDatasetAdapter.js.map +1 -0
- package/dist/utils/dataset/adapters/index.d.ts +2 -0
- package/dist/utils/dataset/adapters/index.js +3 -0
- package/dist/utils/dataset/adapters/index.js.map +1 -0
- package/dist/utils/dataset/index.d.ts +1 -0
- package/dist/utils/dataset/index.js +3 -0
- package/dist/utils/dataset/index.js.map +1 -0
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/index.js +8 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/theme/ControlTheme.d.ts +21 -0
- package/dist/utils/theme/ControlTheme.js +39 -0
- package/dist/utils/theme/ControlTheme.js.map +1 -0
- package/dist/utils/theme/components/ThemeWrapper.d.ts +9 -0
- package/dist/utils/theme/components/ThemeWrapper.js +11 -0
- package/dist/utils/theme/components/ThemeWrapper.js.map +1 -0
- package/dist/utils/theme/components/index.d.ts +1 -0
- package/dist/utils/theme/components/index.js +2 -0
- package/dist/utils/theme/components/index.js.map +1 -0
- package/dist/utils/theme/hooks/index.d.ts +2 -0
- package/dist/utils/theme/hooks/index.js +3 -0
- package/dist/utils/theme/hooks/index.js.map +1 -0
- package/dist/utils/theme/hooks/useControlTheme.d.ts +3 -0
- package/dist/utils/theme/hooks/useControlTheme.js +12 -0
- package/dist/utils/theme/hooks/useControlTheme.js.map +1 -0
- package/dist/utils/theme/hooks/useControlThemeGenerator.d.ts +14 -0
- package/dist/utils/theme/hooks/useControlThemeGenerator.js +11 -0
- package/dist/utils/theme/hooks/useControlThemeGenerator.js.map +1 -0
- package/dist/utils/theme/index.d.ts +3 -0
- package/dist/utils/theme/index.js +5 -0
- package/dist/utils/theme/index.js.map +1 -0
- package/package.json +94 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { IDatePickerProps } from "@talxis/react-components";
|
|
2
|
+
import { IDateTimeProperty, IStringProperty, ITwoOptionsProperty } from "../../interfaces";
|
|
3
|
+
import { IControl, IOutputs, ITranslations } from "../../interfaces/context";
|
|
4
|
+
import { IInputParameters } from "../../interfaces/parameters";
|
|
5
|
+
import { getDefaultDateTimeTranslations } from "./translations";
|
|
6
|
+
export interface IDateTime extends IControl<IDateTimeParameters, IDateTimeOutputs, Partial<ITranslations<ReturnType<typeof getDefaultDateTimeTranslations>>>, IDatePickerProps> {
|
|
7
|
+
}
|
|
8
|
+
export interface IDateTimeParameters extends IInputParameters {
|
|
9
|
+
value: IDateTimeProperty;
|
|
10
|
+
EnableMonthPicker?: ITwoOptionsProperty;
|
|
11
|
+
EnableDayPicker?: ITwoOptionsProperty;
|
|
12
|
+
/**
|
|
13
|
+
* JSON array of dates that should not be selectable, example: ['2019-01-10', '2019-01-11']
|
|
14
|
+
*/
|
|
15
|
+
RestrictedDates?: IStringProperty;
|
|
16
|
+
/**
|
|
17
|
+
* JSON array of week days that should not be selectable (0 = Sunday,...6 = Saturday), example: [0,2,3]
|
|
18
|
+
*/
|
|
19
|
+
RestrictedDaysOfWeek?: IStringProperty;
|
|
20
|
+
}
|
|
21
|
+
export interface IDateTimeOutputs extends IOutputs {
|
|
22
|
+
value?: Date;
|
|
23
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { ITheme } from "@fluentui/react";
|
|
2
|
+
export declare const getDateTimeStyles: (theme: ITheme) => import("@fluentui/react").IProcessedStyleSet<{
|
|
3
|
+
datePicker: {
|
|
4
|
+
'[class^="statusMessage"]': {
|
|
5
|
+
display: string;
|
|
6
|
+
};
|
|
7
|
+
};
|
|
8
|
+
calendarCallout: {
|
|
9
|
+
'[class*="TALXIS__timepicker__root"]': {
|
|
10
|
+
padding: number;
|
|
11
|
+
label: {
|
|
12
|
+
paddingTop: number;
|
|
13
|
+
};
|
|
14
|
+
i: {
|
|
15
|
+
fontSize: number;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
hr: {
|
|
19
|
+
margin: number;
|
|
20
|
+
border: string;
|
|
21
|
+
height: number;
|
|
22
|
+
backgroundColor: string;
|
|
23
|
+
};
|
|
24
|
+
'[class^="monthAndYear"], [class*="weekDayLabelCell"]': {
|
|
25
|
+
animationDuration: string;
|
|
26
|
+
};
|
|
27
|
+
'.ms-DatePicker': {
|
|
28
|
+
animationDuration: string;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
}>;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { mergeStyleSets } from '@fluentui/react';
|
|
2
|
+
|
|
3
|
+
const getDateTimeStyles = (theme) => {
|
|
4
|
+
return mergeStyleSets({
|
|
5
|
+
datePicker: {
|
|
6
|
+
'[class^="statusMessage"]': {
|
|
7
|
+
display: 'none'
|
|
8
|
+
}
|
|
9
|
+
},
|
|
10
|
+
calendarCallout: {
|
|
11
|
+
'[class*="TALXIS__timepicker__root"]': {
|
|
12
|
+
padding: 12,
|
|
13
|
+
'label': {
|
|
14
|
+
paddingTop: 0
|
|
15
|
+
},
|
|
16
|
+
'i': {
|
|
17
|
+
fontSize: 16
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
'hr': {
|
|
21
|
+
margin: 0,
|
|
22
|
+
border: 'none',
|
|
23
|
+
height: 1,
|
|
24
|
+
backgroundColor: theme.semanticColors.menuDivider
|
|
25
|
+
},
|
|
26
|
+
'[class^="monthAndYear"], [class*="weekDayLabelCell"]': {
|
|
27
|
+
animationDuration: '0s'
|
|
28
|
+
},
|
|
29
|
+
'.ms-DatePicker': {
|
|
30
|
+
animationDuration: '0s'
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export { getDateTimeStyles };
|
|
37
|
+
//# sourceMappingURL=styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.js","sources":["../../../src/components/DateTime/styles.ts"],"sourcesContent":["import { ITheme, mergeStyleSets } from \"@fluentui/react\";\n\nexport const getDateTimeStyles = (theme: ITheme) => {\n return mergeStyleSets({\n datePicker: {\n '[class^=\"statusMessage\"]': {\n display: 'none'\n }\n },\n calendarCallout: {\n '[class*=\"TALXIS__timepicker__root\"]': {\n padding: 12,\n 'label': {\n paddingTop: 0\n },\n 'i': {\n fontSize: 16\n }\n },\n 'hr': {\n margin: 0,\n border: 'none',\n height: 1,\n backgroundColor: theme.semanticColors.menuDivider\n },\n '[class^=\"monthAndYear\"], [class*=\"weekDayLabelCell\"]': {\n animationDuration: '0s'\n },\n '.ms-DatePicker': {\n animationDuration: '0s'\n }\n }\n });\n};"],"names":[],"mappings":";;AAEa,MAAA,iBAAiB,GAAG,CAAC,KAAa,KAAI;AAC/C,IAAA,OAAO,cAAc,CAAC;AAClB,QAAA,UAAU,EAAE;AACR,YAAA,0BAA0B,EAAE;AACxB,gBAAA,OAAO,EAAE,MAAM;AAClB,aAAA;AACJ,SAAA;AACD,QAAA,eAAe,EAAE;AACb,YAAA,qCAAqC,EAAE;AACnC,gBAAA,OAAO,EAAE,EAAE;AACX,gBAAA,OAAO,EAAE;AACL,oBAAA,UAAU,EAAE,CAAC;AAChB,iBAAA;AACD,gBAAA,GAAG,EAAE;AACD,oBAAA,QAAQ,EAAE,EAAE;AACf,iBAAA;AACJ,aAAA;AACD,YAAA,IAAI,EAAE;AACF,gBAAA,MAAM,EAAE,CAAC;AACT,gBAAA,MAAM,EAAE,MAAM;AACd,gBAAA,MAAM,EAAE,CAAC;AACT,gBAAA,eAAe,EAAE,KAAK,CAAC,cAAc,CAAC,WAAW;AACpD,aAAA;AACD,YAAA,sDAAsD,EAAE;AACpD,gBAAA,iBAAiB,EAAE,IAAI;AAC1B,aAAA;AACD,YAAA,gBAAgB,EAAE;AACd,gBAAA,iBAAiB,EAAE,IAAI;AAC1B,aAAA;AACJ,SAAA;AACJ,KAAA,CAAC,CAAC;AACP;;;;"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/// <reference types="@types/powerapps-component-framework" />
|
|
2
|
+
export declare const getDefaultDateTimeTranslations: (dateFormattingInfo: ComponentFramework.UserSettingApi.DateFormattingInfo) => {
|
|
3
|
+
time: {
|
|
4
|
+
1029: string;
|
|
5
|
+
1033: string;
|
|
6
|
+
};
|
|
7
|
+
goToToday: {
|
|
8
|
+
1029: string;
|
|
9
|
+
1033: string;
|
|
10
|
+
};
|
|
11
|
+
invalidTimeInput: {
|
|
12
|
+
1029: string;
|
|
13
|
+
1033: string;
|
|
14
|
+
};
|
|
15
|
+
days: string[];
|
|
16
|
+
months: string[];
|
|
17
|
+
shortDays: string[];
|
|
18
|
+
shortMonths: string[];
|
|
19
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
const getDefaultDateTimeTranslations = (dateFormattingInfo) => {
|
|
2
|
+
return {
|
|
3
|
+
time: {
|
|
4
|
+
1029: 'Čas',
|
|
5
|
+
1033: 'Time'
|
|
6
|
+
},
|
|
7
|
+
goToToday: {
|
|
8
|
+
1029: 'Přejít na dnešek',
|
|
9
|
+
1033: 'Go to today'
|
|
10
|
+
},
|
|
11
|
+
invalidTimeInput: {
|
|
12
|
+
1029: 'Neplatný časový formát.',
|
|
13
|
+
1033: 'Invalid time format.'
|
|
14
|
+
},
|
|
15
|
+
days: dateFormattingInfo.dayNames,
|
|
16
|
+
months: dateFormattingInfo.monthNames,
|
|
17
|
+
shortDays: dateFormattingInfo.shortestDayNames,
|
|
18
|
+
shortMonths: dateFormattingInfo.abbreviatedMonthNames,
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
export { getDefaultDateTimeTranslations };
|
|
23
|
+
//# sourceMappingURL=translations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"translations.js","sources":["../../../src/components/DateTime/translations.ts"],"sourcesContent":["export const getDefaultDateTimeTranslations = (dateFormattingInfo: ComponentFramework.UserSettingApi.DateFormattingInfo) => {\n return {\n time: {\n 1029: 'Čas',\n 1033: 'Time'\n },\n goToToday: {\n 1029: 'Přejít na dnešek',\n 1033: 'Go to today'\n },\n invalidTimeInput: {\n 1029: 'Neplatný časový formát.',\n 1033: 'Invalid time format.'\n },\n days: dateFormattingInfo.dayNames,\n months: dateFormattingInfo.monthNames,\n shortDays: dateFormattingInfo.shortestDayNames,\n shortMonths: dateFormattingInfo.abbreviatedMonthNames,\n }\n};"],"names":[],"mappings":"AAAa,MAAA,8BAA8B,GAAG,CAAC,kBAAwE,KAAI;IACvH,OAAO;AACH,QAAA,IAAI,EAAE;AACF,YAAA,IAAI,EAAE,KAAK;AACX,YAAA,IAAI,EAAE,MAAM;AACf,SAAA;AACD,QAAA,SAAS,EAAE;AACP,YAAA,IAAI,EAAE,kBAAkB;AACxB,YAAA,IAAI,EAAE,aAAa;AACtB,SAAA;AACD,QAAA,gBAAgB,EAAE;AACd,YAAA,IAAI,EAAE,yBAAyB;AAC/B,YAAA,IAAI,EAAE,sBAAsB;AAC/B,SAAA;QACD,IAAI,EAAE,kBAAkB,CAAC,QAAQ;QACjC,MAAM,EAAE,kBAAkB,CAAC,UAAU;QACrC,SAAS,EAAE,kBAAkB,CAAC,gBAAgB;QAC9C,WAAW,EAAE,kBAAkB,CAAC,qBAAqB;KACxD,CAAA;AACL;;;;"}
|
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { TextField } from '@talxis/react-components';
|
|
3
|
+
import { useInputBasedControl } from '../../hooks/useInputBasedControl.js';
|
|
4
|
+
import { useRef, useMemo, useEffect } from 'react';
|
|
5
|
+
import numeral from 'numeral';
|
|
6
|
+
import { CURRENCY_POSITIVE_PATTERN, CURRENCY_NEGATIVE_PATTERN, NUMBER_NEGATIVE_PATTERN } from '../../constants.js';
|
|
7
|
+
import { ThemeProvider } from '@fluentui/react';
|
|
8
|
+
import { ArrowButtons } from './components/ArrowButtons.js';
|
|
9
|
+
import { Numeral } from '@talxis/client-libraries';
|
|
10
|
+
|
|
11
|
+
const Decimal = (props) => {
|
|
12
|
+
const arrowButtonsRef = useRef(null);
|
|
13
|
+
const context = props.context;
|
|
14
|
+
const parameters = props.parameters;
|
|
15
|
+
const boundValue = parameters.value;
|
|
16
|
+
const numberFormatting = context.userSettings.numberFormattingInfo;
|
|
17
|
+
const onOverrideComponentProps = props.onOverrideComponentProps ?? ((props) => props);
|
|
18
|
+
const formatter = (value) => {
|
|
19
|
+
if (typeof value === 'number') {
|
|
20
|
+
if (props.parameters.value.type === 'Decimal') {
|
|
21
|
+
return context.formatting.formatDecimal(value, boundValue.attributes?.Precision);
|
|
22
|
+
}
|
|
23
|
+
if (props.parameters.value.type === 'Currency') {
|
|
24
|
+
//the layer above has information about the symbol, so we can use the formatted string
|
|
25
|
+
if (props.parameters.value.formatted) {
|
|
26
|
+
return props.parameters.value.formatted;
|
|
27
|
+
}
|
|
28
|
+
return context.formatting.formatCurrency(value, boundValue.attributes?.Precision);
|
|
29
|
+
}
|
|
30
|
+
return context.formatting.formatInteger(value);
|
|
31
|
+
}
|
|
32
|
+
return value;
|
|
33
|
+
};
|
|
34
|
+
const createNumberPattern = (pattern, numberPattern) => {
|
|
35
|
+
return new RegExp(`^${escapeRegExp(pattern).replace('n', numberPattern)}$`.replace(/\s/g, ''));
|
|
36
|
+
};
|
|
37
|
+
const createCurrencyPattern = (pattern, numberPattern) => {
|
|
38
|
+
const escapedPattern = escapeRegExp(pattern);
|
|
39
|
+
const escapedCurrencySymbolPattern = `(${escapeRegExp(numberFormatting.currencySymbol)})?`;
|
|
40
|
+
const finalPattern = escapedPattern.replace('\\$', escapedCurrencySymbolPattern).replace('n', numberPattern);
|
|
41
|
+
return new RegExp(`^${finalPattern.replace(/\s/g, '')}$`);
|
|
42
|
+
};
|
|
43
|
+
const escapeRegExp = (string) => {
|
|
44
|
+
return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
45
|
+
};
|
|
46
|
+
const extractNumericPart = (value) => {
|
|
47
|
+
// Currency control just sends the string up and lets the framework decide whether the value is correct
|
|
48
|
+
// It only tries to parse the number based on the current user format
|
|
49
|
+
// This means that the value will also pass if the user inputs his own currency even though
|
|
50
|
+
// the currency is different on the field
|
|
51
|
+
if (typeof value === 'number') {
|
|
52
|
+
return value;
|
|
53
|
+
}
|
|
54
|
+
//TODO: investigate why this is needed
|
|
55
|
+
if (value === initialFormattedValue) {
|
|
56
|
+
return initialValue;
|
|
57
|
+
}
|
|
58
|
+
const str = value?.replace(/\s/g, '');
|
|
59
|
+
Numeral.decimal(numberFormatting);
|
|
60
|
+
let positivePattern;
|
|
61
|
+
let negativePattern;
|
|
62
|
+
switch (props.parameters.value.type) {
|
|
63
|
+
case 'Whole.None': {
|
|
64
|
+
const numberPattern = `\\d{1,}(${numberFormatting.numberGroupSeparator}\\d{1,})*`;
|
|
65
|
+
positivePattern = createNumberPattern('n', numberPattern);
|
|
66
|
+
negativePattern = createNumberPattern(NUMBER_NEGATIVE_PATTERN[numberFormatting.numberNegativePattern], numberPattern);
|
|
67
|
+
break;
|
|
68
|
+
}
|
|
69
|
+
case 'Decimal': {
|
|
70
|
+
const numberPattern = `\\d{1,}(${numberFormatting.numberGroupSeparator}\\d{1,})*(\\${numberFormatting.numberDecimalSeparator}\\d+)?`;
|
|
71
|
+
positivePattern = createNumberPattern('n', numberPattern);
|
|
72
|
+
negativePattern = createNumberPattern(NUMBER_NEGATIVE_PATTERN[numberFormatting.numberNegativePattern], numberPattern);
|
|
73
|
+
break;
|
|
74
|
+
}
|
|
75
|
+
case 'Currency': {
|
|
76
|
+
Numeral.currency(numberFormatting);
|
|
77
|
+
const numberPattern = `\\d{1,}(${numberFormatting.currencyGroupSeparator}\\d{1,})*(\\${numberFormatting.currencyDecimalSeparator}\\d+)?`;
|
|
78
|
+
positivePattern = createCurrencyPattern(CURRENCY_POSITIVE_PATTERN[numberFormatting.currencyPositivePattern], numberPattern);
|
|
79
|
+
negativePattern = createCurrencyPattern(CURRENCY_NEGATIVE_PATTERN[numberFormatting.currencyNegativePattern], numberPattern);
|
|
80
|
+
break;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
if (positivePattern.test(str)) {
|
|
84
|
+
return numeral(str).value() ?? undefined;
|
|
85
|
+
}
|
|
86
|
+
if (negativePattern.test(str)) {
|
|
87
|
+
const value = numeral(str).value();
|
|
88
|
+
if (value > 0) {
|
|
89
|
+
return value * -1;
|
|
90
|
+
}
|
|
91
|
+
return value;
|
|
92
|
+
}
|
|
93
|
+
return value;
|
|
94
|
+
};
|
|
95
|
+
const { value, sizing, theme, setValue, onNotifyOutputChanged } = useInputBasedControl('Decimal', props, {
|
|
96
|
+
formatter: formatter,
|
|
97
|
+
valueExtractor: extractNumericPart
|
|
98
|
+
});
|
|
99
|
+
const initialFormattedValue = useMemo(() => value, []);
|
|
100
|
+
const initialValue = useMemo(() => boundValue.raw, []);
|
|
101
|
+
const getSuffixItems = () => {
|
|
102
|
+
if (context.mode.isControlDisabled || !parameters.EnableSpinButton?.raw) {
|
|
103
|
+
return undefined;
|
|
104
|
+
}
|
|
105
|
+
return [
|
|
106
|
+
{
|
|
107
|
+
key: 'arrows',
|
|
108
|
+
onRender: () => jsx(ArrowButtons, { ref: arrowButtonsRef, onDecrement: () => makeStep('decrement'), onIncrement: () => makeStep('increment') })
|
|
109
|
+
}
|
|
110
|
+
];
|
|
111
|
+
};
|
|
112
|
+
const makeStep = (type) => {
|
|
113
|
+
const value = boundValue.raw ?? 0;
|
|
114
|
+
if (typeof value !== 'number') {
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
const precision = Math.pow(10, boundValue.attributes?.Precision ?? 0);
|
|
118
|
+
const adjustment = type === 'increment' ? 1 : -1;
|
|
119
|
+
const newValue = parseFloat(((value) + adjustment / precision).toFixed(boundValue.attributes?.Precision ?? 0));
|
|
120
|
+
onNotifyOutputChanged({ value: newValue });
|
|
121
|
+
};
|
|
122
|
+
const onKeyDown = (e) => {
|
|
123
|
+
if (context.mode.isControlDisabled) {
|
|
124
|
+
return;
|
|
125
|
+
}
|
|
126
|
+
switch (e.key) {
|
|
127
|
+
case 'ArrowDown': {
|
|
128
|
+
e.preventDefault();
|
|
129
|
+
makeStep('decrement');
|
|
130
|
+
arrowButtonsRef.current?.setActiveBtn('down');
|
|
131
|
+
break;
|
|
132
|
+
}
|
|
133
|
+
case 'ArrowUp': {
|
|
134
|
+
e.preventDefault();
|
|
135
|
+
makeStep('increment');
|
|
136
|
+
arrowButtonsRef.current?.setActiveBtn('up');
|
|
137
|
+
break;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
};
|
|
141
|
+
const getInputMode = () => {
|
|
142
|
+
switch (props.parameters.value.type) {
|
|
143
|
+
case 'Whole.None': {
|
|
144
|
+
return 'numeric';
|
|
145
|
+
}
|
|
146
|
+
case 'Decimal':
|
|
147
|
+
case 'Currency': {
|
|
148
|
+
return 'decimal';
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
};
|
|
152
|
+
useEffect(() => {
|
|
153
|
+
if (boundValue.type === 'Currency') {
|
|
154
|
+
setValue(boundValue.formatted);
|
|
155
|
+
}
|
|
156
|
+
}, [boundValue.formatted]);
|
|
157
|
+
const componentProps = onOverrideComponentProps({
|
|
158
|
+
hideErrorMessage: !parameters.ShowErrorMessage?.raw,
|
|
159
|
+
readOnly: context.mode.isControlDisabled,
|
|
160
|
+
inputMode: useMemo(() => getInputMode(), [props.parameters.value.type]),
|
|
161
|
+
suffixItems: getSuffixItems(),
|
|
162
|
+
autoFocus: parameters.AutoFocus?.raw,
|
|
163
|
+
errorMessage: boundValue.errorMessage,
|
|
164
|
+
styles: {
|
|
165
|
+
fieldGroup: {
|
|
166
|
+
height: sizing.height,
|
|
167
|
+
width: sizing.width
|
|
168
|
+
}
|
|
169
|
+
},
|
|
170
|
+
deleteButtonProps: parameters.EnableDeleteButton?.raw === true
|
|
171
|
+
? {
|
|
172
|
+
key: "delete",
|
|
173
|
+
showOnlyOnHover: true,
|
|
174
|
+
iconProps: {
|
|
175
|
+
iconName: "Cancel",
|
|
176
|
+
},
|
|
177
|
+
onClick: () => setValue(undefined),
|
|
178
|
+
}
|
|
179
|
+
: undefined,
|
|
180
|
+
clickToCopyProps: parameters.EnableCopyButton?.raw === true
|
|
181
|
+
? {
|
|
182
|
+
key: "copy",
|
|
183
|
+
showOnlyOnHover: true,
|
|
184
|
+
iconProps: {
|
|
185
|
+
iconName: "Copy",
|
|
186
|
+
},
|
|
187
|
+
}
|
|
188
|
+
: undefined,
|
|
189
|
+
value: value ?? "",
|
|
190
|
+
onBlur: (event) => {
|
|
191
|
+
onNotifyOutputChanged({
|
|
192
|
+
value: extractNumericPart(event.target.value)
|
|
193
|
+
});
|
|
194
|
+
},
|
|
195
|
+
onChange: (e, value) => {
|
|
196
|
+
setValue(value);
|
|
197
|
+
},
|
|
198
|
+
onKeyDown: onKeyDown,
|
|
199
|
+
});
|
|
200
|
+
return (jsx(ThemeProvider, { theme: theme, applyTo: "none", children: jsx(TextField, { ...componentProps }) }));
|
|
201
|
+
};
|
|
202
|
+
|
|
203
|
+
export { Decimal };
|
|
204
|
+
//# sourceMappingURL=Decimal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Decimal.js","sources":["../../../src/components/Decimal/Decimal.tsx"],"sourcesContent":["import { TextField } from \"@talxis/react-components\";\nimport { useInputBasedControl } from \"../../hooks/useInputBasedControl\";\nimport { IDecimal, IDecimalOutputs, IDecimalParameters } from \"./interfaces\";\nimport React, { useEffect, useMemo, useRef } from \"react\";\nimport numeral from \"numeral\";\nimport { CURRENCY_NEGATIVE_PATTERN, CURRENCY_POSITIVE_PATTERN, NUMBER_NEGATIVE_PATTERN } from \"../../constants\";\nimport { ICommandBarItemProps, ThemeProvider } from \"@fluentui/react\";\nimport { ArrowButtons, IArrowButtons } from \"./components/ArrowButtons\";\nimport { Numeral } from \"@talxis/client-libraries\";\n\nexport const Decimal = (props: IDecimal) => {\n const arrowButtonsRef = useRef<IArrowButtons>(null);\n const context = props.context;\n const parameters = props.parameters;\n const boundValue = parameters.value;\n const numberFormatting = context.userSettings.numberFormattingInfo;\n const onOverrideComponentProps = props.onOverrideComponentProps ?? ((props) => props);\n\n const formatter = (value: string | number | null): string | undefined | null => {\n if (typeof value === 'number') {\n if (props.parameters.value.type === 'Decimal') {\n return context.formatting.formatDecimal(value, boundValue.attributes?.Precision);\n }\n if (props.parameters.value.type === 'Currency') {\n //the layer above has information about the symbol, so we can use the formatted string\n if (props.parameters.value.formatted) {\n return props.parameters.value.formatted;\n }\n return context.formatting.formatCurrency(value, boundValue.attributes?.Precision);\n }\n return context.formatting.formatInteger(value);\n }\n return value;\n };\n\n const createNumberPattern = (pattern: string, numberPattern: string) => {\n return new RegExp(`^${escapeRegExp(pattern).replace('n', numberPattern)}$`.replace(/\\s/g, ''));\n };\n\n const createCurrencyPattern = (pattern: string, numberPattern: string) => {\n const escapedPattern = escapeRegExp(pattern);\n const escapedCurrencySymbolPattern = `(${escapeRegExp(numberFormatting.currencySymbol)})?`;\n const finalPattern = escapedPattern.replace('\\\\$', escapedCurrencySymbolPattern).replace('n', numberPattern);\n return new RegExp(`^${finalPattern.replace(/\\s/g, '')}$`);\n };\n\n const escapeRegExp = (string: string) => {\n return string.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\$&');\n };\n\n const extractNumericPart = (value: any): number | undefined => {\n // Currency control just sends the string up and lets the framework decide whether the value is correct\n // It only tries to parse the number based on the current user format\n // This means that the value will also pass if the user inputs his own currency even though\n // the currency is different on the field\n if (typeof value === 'number') {\n return value\n }\n //TODO: investigate why this is needed\n if(value === initialFormattedValue) {\n return initialValue as number;\n }\n const str = value?.replace(/\\s/g, '');\n Numeral.decimal(numberFormatting);\n let positivePattern: any;\n let negativePattern: any;\n\n switch (props.parameters.value.type) {\n case 'Whole.None': {\n const numberPattern = `\\\\d{1,}(${numberFormatting.numberGroupSeparator}\\\\d{1,})*`;\n positivePattern = createNumberPattern('n', numberPattern);\n negativePattern = createNumberPattern(NUMBER_NEGATIVE_PATTERN[numberFormatting.numberNegativePattern], numberPattern);\n break;\n }\n case 'Decimal': {\n const numberPattern = `\\\\d{1,}(${numberFormatting.numberGroupSeparator}\\\\d{1,})*(\\\\${numberFormatting.numberDecimalSeparator}\\\\d+)?`;\n positivePattern = createNumberPattern('n', numberPattern);\n negativePattern = createNumberPattern(NUMBER_NEGATIVE_PATTERN[numberFormatting.numberNegativePattern], numberPattern);\n break;\n }\n case 'Currency': {\n Numeral.currency(numberFormatting);\n const numberPattern = `\\\\d{1,}(${numberFormatting.currencyGroupSeparator}\\\\d{1,})*(\\\\${numberFormatting.currencyDecimalSeparator}\\\\d+)?`;\n positivePattern = createCurrencyPattern(CURRENCY_POSITIVE_PATTERN[numberFormatting.currencyPositivePattern], numberPattern);\n negativePattern = createCurrencyPattern(CURRENCY_NEGATIVE_PATTERN[numberFormatting.currencyNegativePattern], numberPattern);\n break;\n }\n }\n if (positivePattern.test(str)) {\n return numeral(str).value() ?? undefined;\n }\n if (negativePattern.test(str)) {\n const value = numeral(str).value()!;\n if (value > 0) {\n return value * -1;\n }\n return value;\n }\n return value;\n };\n\n const { value, sizing, theme, setValue, onNotifyOutputChanged } = useInputBasedControl<string | undefined, IDecimalParameters, IDecimalOutputs, any>('Decimal', props, {\n formatter: formatter,\n valueExtractor: extractNumericPart\n });\n const initialFormattedValue = useMemo(() => value, []);\n const initialValue = useMemo(() => boundValue.raw, []);\n\n const getSuffixItems = (): ICommandBarItemProps[] | undefined => {\n if (context.mode.isControlDisabled || !parameters.EnableSpinButton?.raw) {\n return undefined;\n }\n return [\n {\n key: 'arrows',\n onRender: () => <ArrowButtons\n ref={arrowButtonsRef}\n onDecrement={() => makeStep('decrement')}\n onIncrement={() => makeStep('increment')} />\n }\n ]\n }\n\n const makeStep = (type: 'increment' | 'decrement') => {\n const value = boundValue.raw ?? 0;\n if (typeof value !== 'number') {\n return;\n }\n const precision = Math.pow(10, boundValue.attributes?.Precision ?? 0);\n const adjustment = type === 'increment' ? 1 : -1;\n const newValue = parseFloat(((value) + adjustment / precision).toFixed(boundValue.attributes?.Precision ?? 0));\n onNotifyOutputChanged({ value: newValue });\n\n }\n\n const onKeyDown = (e: React.KeyboardEvent<HTMLInputElement | HTMLTextAreaElement>) => {\n if (context.mode.isControlDisabled) {\n return;\n }\n switch (e.key) {\n case 'ArrowDown': {\n e.preventDefault();\n makeStep('decrement');\n arrowButtonsRef.current?.setActiveBtn('down');\n break;\n }\n case 'ArrowUp': {\n e.preventDefault();\n makeStep('increment');\n arrowButtonsRef.current?.setActiveBtn('up');\n break;\n }\n }\n }\n\n const getInputMode = () => {\n switch (props.parameters.value.type) {\n case 'Whole.None': {\n return 'numeric';\n }\n case 'Decimal':\n case 'Currency': {\n return 'decimal';\n }\n }\n }\n useEffect(() => {\n if (boundValue.type === 'Currency') {\n setValue(boundValue.formatted);\n }\n }, [boundValue.formatted]);\n\n const componentProps = onOverrideComponentProps({\n hideErrorMessage: !parameters.ShowErrorMessage?.raw,\n readOnly: context.mode.isControlDisabled,\n inputMode: useMemo(() => getInputMode(), [props.parameters.value.type]),\n suffixItems: getSuffixItems(),\n autoFocus: parameters.AutoFocus?.raw,\n errorMessage: boundValue.errorMessage,\n styles: {\n fieldGroup: {\n height: sizing.height,\n width: sizing.width\n }\n },\n deleteButtonProps: parameters.EnableDeleteButton?.raw === true\n ? {\n key: \"delete\",\n showOnlyOnHover: true,\n iconProps: {\n iconName: \"Cancel\",\n },\n onClick: () => setValue(undefined),\n }\n : undefined,\n clickToCopyProps: parameters.EnableCopyButton?.raw === true\n ? {\n key: \"copy\",\n showOnlyOnHover: true,\n iconProps: {\n iconName: \"Copy\",\n },\n }\n : undefined,\n value: value ?? \"\",\n onBlur: (event) => {\n onNotifyOutputChanged({\n value: extractNumericPart(event.target.value)\n });\n },\n onChange: (e, value) => {\n setValue(value);\n },\n onKeyDown: onKeyDown,\n });\n return (\n <ThemeProvider theme={theme} applyTo=\"none\">\n <TextField {...componentProps} />\n </ThemeProvider>\n );\n};\n"],"names":["_jsx"],"mappings":";;;;;;;;;;AAUa,MAAA,OAAO,GAAG,CAAC,KAAe,KAAI;AACvC,IAAA,MAAM,eAAe,GAAG,MAAM,CAAgB,IAAI,CAAC,CAAC;AACpD,IAAA,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC;AAC9B,IAAA,MAAM,UAAU,GAAG,KAAK,CAAC,UAAU,CAAC;AACpC,IAAA,MAAM,UAAU,GAAG,UAAU,CAAC,KAAK,CAAC;AACpC,IAAA,MAAM,gBAAgB,GAAG,OAAO,CAAC,YAAY,CAAC,oBAAoB,CAAC;AACnE,IAAA,MAAM,wBAAwB,GAAG,KAAK,CAAC,wBAAwB,K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M;AACnB,iBAAA;AACJ,aAAA;AACD,cAAE,SAAS;QACf,KAAK,EAAE,KAAK,IAAI,EAAE;AAClB,QAAA,MAAM,EAAE,CAAC,KAAK,KAAI;AACd,YAAA,qBAAqB,CAAC;gBAClB,KAAK,EAAE,kBAAkB,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;AAChD,aAAA,CAAC,CAAC;SACN;AACD,QAAA,QAAQ,EAAE,CAAC,CAAC,EAAE,KAAK,KAAI;YACnB,QAAQ,CAAC,KAAK,CAAC,CAAC;SACnB;AACD,QAAA,SAAS,EAAE,SAAS;AACvB,KAAA,CAAC,CAAC;AACH,IAAA,QACIA,GAAC,CAAA,aAAa,IAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAC,MAAM,EAAA,QAAA,EACvCA,IAAC,SAAS,EAAA,EAAA,GAAK,cAAc,EAAI,CAAA,EAAA,CACrB,EAClB;AACN;;;;"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface IArrowButtonsProps {
|
|
3
|
+
onIncrement: () => void;
|
|
4
|
+
onDecrement: () => void;
|
|
5
|
+
}
|
|
6
|
+
export interface IArrowButtons {
|
|
7
|
+
setActiveBtn: (direction: 'up' | 'down') => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const ArrowButtons: React.ForwardRefExoticComponent<IArrowButtonsProps & React.RefAttributes<IArrowButtons>>;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { useTheme, IconButton } from '@fluentui/react';
|
|
3
|
+
import { forwardRef, useMemo, useState, useEffect, useImperativeHandle } from 'react';
|
|
4
|
+
import { getArrowButtonStyles } from './styles.js';
|
|
5
|
+
|
|
6
|
+
const ArrowButtons = forwardRef((props, ref) => {
|
|
7
|
+
const theme = useTheme();
|
|
8
|
+
const styles = useMemo(() => getArrowButtonStyles(theme), []);
|
|
9
|
+
const [activeBtn, setActiveBtn] = useState(undefined);
|
|
10
|
+
const getIconButtonClassNames = (type) => {
|
|
11
|
+
let classNames = `${styles.iconButton}`;
|
|
12
|
+
if (activeBtn === type) {
|
|
13
|
+
classNames += ` ${styles.iconButtonActive}`;
|
|
14
|
+
}
|
|
15
|
+
return classNames;
|
|
16
|
+
};
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
if (!activeBtn) {
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
setTimeout(() => {
|
|
22
|
+
setActiveBtn(undefined);
|
|
23
|
+
}, 100);
|
|
24
|
+
}, [activeBtn]);
|
|
25
|
+
useImperativeHandle(ref, () => {
|
|
26
|
+
return {
|
|
27
|
+
setActiveBtn: setActiveBtn
|
|
28
|
+
};
|
|
29
|
+
});
|
|
30
|
+
return jsxs("div", { className: styles.root, children: [jsx(IconButton, { onClick: props.onIncrement, className: getIconButtonClassNames('up'), iconProps: {
|
|
31
|
+
iconName: 'ChevronUpSmall'
|
|
32
|
+
} }), jsx(IconButton, { onClick: props.onDecrement, className: getIconButtonClassNames('down'), iconProps: {
|
|
33
|
+
iconName: 'ChevronDownSmall'
|
|
34
|
+
} })] });
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
export { ArrowButtons };
|
|
38
|
+
//# sourceMappingURL=ArrowButtons.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ArrowButtons.js","sources":["../../../../src/components/Decimal/components/ArrowButtons.tsx"],"sourcesContent":["import { IconButton, useTheme } from \"@fluentui/react\"\nimport { forwardRef, useEffect, useImperativeHandle, useMemo, useState } from \"react\"\nimport { getArrowButtonStyles } from \"./styles\";\nimport React from 'react';\n\ninterface IArrowButtonsProps {\n onIncrement: () => void;\n onDecrement: () => void;\n}\n\nexport interface IArrowButtons {\n setActiveBtn: (direction: 'up' | 'down') => void;\n}\n\nexport const ArrowButtons = forwardRef<IArrowButtons, IArrowButtonsProps>((props, ref) => {\n const theme = useTheme();\n const styles = useMemo(() => getArrowButtonStyles(theme), []);\n const [activeBtn, setActiveBtn] = useState<'up' | 'down' | undefined>(undefined);\n\n const getIconButtonClassNames = (type: 'up' | 'down') => {\n let classNames = `${styles.iconButton}`;\n if(activeBtn === type) {\n classNames += ` ${styles.iconButtonActive}`\n }\n return classNames;\n }\n useEffect(() => {\n if(!activeBtn) {\n return;\n }\n setTimeout(() => {\n setActiveBtn(undefined);\n }, 100)\n }, [activeBtn]);\n\n useImperativeHandle(ref, () => {\n return {\n setActiveBtn: setActiveBtn\n }\n });\n \n return <div className={styles.root}>\n <IconButton onClick={props.onIncrement} className={getIconButtonClassNames('up')} iconProps={{\n iconName: 'ChevronUpSmall'\n }} />\n <IconButton onClick={props.onDecrement} className={getIconButtonClassNames('down')} iconProps={{\n iconName: 'ChevronDownSmall'\n }} />\n </div>\n});"],"names":["_jsxs","_jsx"],"mappings":";;;;;AAca,MAAA,YAAY,GAAG,UAAU,CAAoC,CAAC,KAAK,EAAE,GAAG,KAAI;AACrF,IAAA,MAAM,KAAK,GAAG,QAAQ,EAAE,CAAC;AACzB,IAAA,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,oBAAoB,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,CAAC;IAC9D,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC,GAAG,QAAQ,CAA4B,SAAS,CAAC,CAAC;AAEjF,IAAA,MAAM,uBAAuB,GAAG,CAAC,IAAmB,KAAI;AACpD,QAAA,IAAI,UAAU,GAAG,CAAA,EAAG,MAAM,CAAC,UAAU,EAAE,CAAC;QACxC,IAAG,SAAS,KAAK,IAAI,EAAE;AACnB,YAAA,UAAU,IAAI,CAAI,CAAA,EAAA,MAAM,CAAC,gBAAgB,EAAE,CAAA;AAC9C,SAAA;AACD,QAAA,OAAO,UAAU,CAAC;AACtB,KAAC,CAAA;IACD,SAAS,CAAC,MAAK;QACX,IAAG,CAAC,SAAS,EAAE;YACX,OAAO;AACV,SAAA;QACD,UAAU,CAAC,MAAK;YACZ,YAAY,CAAC,SAAS,CAAC,CAAC;SAC3B,EAAE,GAAG,CAAC,CAAA;AACX,KAAC,EAAE,CAAC,SAAS,CAAC,CAAC,CAAC;AAEhB,IAAA,mBAAmB,CAAC,GAAG,EAAE,MAAK;QAC1B,OAAO;AACH,YAAA,YAAY,EAAE,YAAY;SAC7B,CAAA;AACL,KAAC,CAAC,CAAC;IAEH,OAAOA,IAAA,CAAA,KAAA,EAAA,EAAK,SAAS,EAAE,MAAM,CAAC,IAAI,EAC9B,QAAA,EAAA,CAAAC,GAAA,CAAC,UAAU,EAAA,EAAC,OAAO,EAAE,KAAK,CAAC,WAAW,EAAE,SAAS,EAAE,uBAAuB,CAAC,IAAI,CAAC,EAAE,SAAS,EAAE;AACzF,oBAAA,QAAQ,EAAE,gBAAgB;AAC7B,iBAAA,EAAA,CAAI,EACHA,GAAC,CAAA,UAAU,IAAC,OAAO,EAAE,KAAK,CAAC,WAAW,EAAE,SAAS,EAAE,uBAAuB,CAAC,MAAM,CAAC,EAAE,SAAS,EAAE;AAC7F,oBAAA,QAAQ,EAAE,kBAAkB;AAC/B,iBAAA,EAAA,CAAI,IACH,CAAA;AACV,CAAC;;;;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ITheme } from "@fluentui/react";
|
|
2
|
+
export declare const getArrowButtonStyles: (theme: ITheme) => import("@fluentui/react").IProcessedStyleSet<{
|
|
3
|
+
root: {
|
|
4
|
+
display: string;
|
|
5
|
+
flexDirection: string;
|
|
6
|
+
};
|
|
7
|
+
iconButton: {
|
|
8
|
+
borderRadius: number;
|
|
9
|
+
height: string;
|
|
10
|
+
i: {
|
|
11
|
+
fontSize: number;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
iconButtonActive: {
|
|
15
|
+
backgroundColor: string;
|
|
16
|
+
i: {
|
|
17
|
+
color: string;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
}>;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { mergeStyleSets } from '@fluentui/react';
|
|
2
|
+
|
|
3
|
+
const getArrowButtonStyles = (theme) => {
|
|
4
|
+
return mergeStyleSets({
|
|
5
|
+
root: {
|
|
6
|
+
display: 'flex',
|
|
7
|
+
flexDirection: 'column',
|
|
8
|
+
},
|
|
9
|
+
iconButton: {
|
|
10
|
+
borderRadius: 0,
|
|
11
|
+
height: '50%',
|
|
12
|
+
'i': {
|
|
13
|
+
fontSize: 8,
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
iconButtonActive: {
|
|
17
|
+
backgroundColor: theme.semanticColors.buttonBackgroundPressed,
|
|
18
|
+
'i': {
|
|
19
|
+
color: theme.semanticColors.inputIconHovered
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
export { getArrowButtonStyles };
|
|
26
|
+
//# sourceMappingURL=styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.js","sources":["../../../../src/components/Decimal/components/styles.ts"],"sourcesContent":["import { ITheme, mergeStyleSets } from \"@fluentui/react\"\n\nexport const getArrowButtonStyles = (theme: ITheme) => {\n return mergeStyleSets({\n root: {\n display: 'flex',\n flexDirection: 'column',\n },\n iconButton: {\n borderRadius: 0,\n height: '50%',\n 'i': {\n fontSize: 8,\n }\n },\n iconButtonActive: {\n backgroundColor: theme.semanticColors.buttonBackgroundPressed,\n 'i': {\n color: theme.semanticColors.inputIconHovered\n }\n }\n })\n}"],"names":[],"mappings":";;AAEa,MAAA,oBAAoB,GAAG,CAAC,KAAa,KAAI;AAClD,IAAA,OAAO,cAAc,CAAC;AAClB,QAAA,IAAI,EAAE;AACF,YAAA,OAAO,EAAE,MAAM;AACf,YAAA,aAAa,EAAE,QAAQ;AAC1B,SAAA;AACD,QAAA,UAAU,EAAE;AACR,YAAA,YAAY,EAAE,CAAC;AACf,YAAA,MAAM,EAAE,KAAK;AACb,YAAA,GAAG,EAAE;AACD,gBAAA,QAAQ,EAAE,CAAC;AACd,aAAA;AACJ,SAAA;AACD,QAAA,gBAAgB,EAAE;AACd,YAAA,eAAe,EAAE,KAAK,CAAC,cAAc,CAAC,uBAAuB;AAC7D,YAAA,GAAG,EAAE;AACD,gBAAA,KAAK,EAAE,KAAK,CAAC,cAAc,CAAC,gBAAgB;AAC/C,aAAA;AACJ,SAAA;AACJ,KAAA,CAAC,CAAA;AACN;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IDecimalNumberProperty, ITwoOptionsProperty } from "../../interfaces";
|
|
2
|
+
import { IInputParameters } from "../../interfaces/parameters";
|
|
3
|
+
import { IControl, IOutputs } from "../../interfaces/context";
|
|
4
|
+
import { ITextFieldProps } from "@talxis/react-components";
|
|
5
|
+
export interface IDecimal extends IControl<IDecimalParameters, IDecimalOutputs, any, ITextFieldProps> {
|
|
6
|
+
}
|
|
7
|
+
export interface IDecimalParameters extends IInputParameters {
|
|
8
|
+
value: IDecimalNumberProperty;
|
|
9
|
+
EnableSpinButton?: Omit<ITwoOptionsProperty, 'attributes'>;
|
|
10
|
+
}
|
|
11
|
+
export interface IDecimalOutputs extends IOutputs {
|
|
12
|
+
value?: number;
|
|
13
|
+
}
|