@zohodesk/library-platform 1.0.0-exp.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/.eslintrc.js +31 -0
- package/.prettierignore +1 -0
- package/.prettierrc +12 -0
- package/README.md +21 -0
- package/arch-rules/README.md +23 -0
- package/arch-rules/index.js +16 -0
- package/arch-rules/rules-config/IndependentFolder.js +13 -0
- package/arch-rules/rules-config/NoOuterLayerUsedInnerLayer.js +60 -0
- package/arch-rules/rules-config/RuleConfig.js +13 -0
- package/examples/desk-app/mockapi/apiMappings.js +5 -0
- package/examples/desk-app/mockapi/fileResponseStrategy.js +9 -0
- package/examples/desk-app/mockapi/getAbsoluteFilePath.js +6 -0
- package/examples/desk-app/mockapi/getFilePath.js +11 -0
- package/examples/desk-app/mockapi/index.js +14 -0
- package/examples/desk-app/mockapi/initialSetup.js +21 -0
- package/examples/desk-app/mockapi/jsonResponseStrategy.js +6 -0
- package/examples/desk-app/mockapi/list/support-email-address/apis.js +27 -0
- package/examples/desk-app/mockapi/list/support-email-address/availableFields.json +94 -0
- package/examples/desk-app/mockapi/list/support-email-address/selectedFields.json +3 -0
- package/examples/desk-app/mockapi/responseMapper.js +13 -0
- package/examples/desk-app/package.json +37 -0
- package/examples/desk-app/react-cli.config.js +18 -0
- package/examples/desk-app/src/AppContainer.js +102 -0
- package/examples/desk-app/src/DeleteRecordIcon.js +39 -0
- package/examples/desk-app/src/actions/CustomDeleteAction.js +19 -0
- package/examples/desk-app/src/actions/DeleteAction.js +20 -0
- package/examples/desk-app/src/actions/EditAction.js +19 -0
- package/examples/desk-app/src/actions/GoSignalAction.js +18 -0
- package/examples/desk-app/src/actions/RowActions.js +7 -0
- package/examples/desk-app/src/actions/StopSignalAction.js +19 -0
- package/examples/desk-app/src/actions/WaitSignalAction.js +18 -0
- package/examples/desk-app/src/apiHeaders.js +12 -0
- package/examples/desk-app/src/common/UIProvider.js +153 -0
- package/examples/desk-app/src/common/docstyle.module.css +40 -0
- package/examples/desk-app/src/hooks/useDepartments.js +18 -0
- package/examples/desk-app/src/hooks/useModules.js +38 -0
- package/examples/desk-app/src/hooks/useViews.js +64 -0
- package/examples/desk-app/src/index.html +11 -0
- package/examples/desk-app/src/index.js +24 -0
- package/examples/desk-app/src/module/ModuleListContainer.js +52 -0
- package/examples/desk-app/src/module/TableConnected.js +25 -0
- package/examples/desk-app/src/non-module/support-email-address/SupportEmailAddress.js +58 -0
- package/examples/desk-app/src/non-module/support-email-address/constants.js +1 -0
- package/examples/desk-app/src/non-module/support-email-address/data-broker/http-template/getAvailableFields.js +22 -0
- package/examples/desk-app/src/non-module/support-email-address/data-broker/http-template/getRecords.js +64 -0
- package/examples/desk-app/src/non-module/support-email-address/data-broker/http-template/getSelectedFields.js +27 -0
- package/examples/desk-app/src/non-module/support-email-address/data-broker/index.js +13 -0
- package/examples/desk-app/src/non-module/support-email-address/empty-state/EmptyStateView.js +15 -0
- package/examples/desk-app/src/non-module/support-email-address/empty-state/SupportEmailAddressEmptyState.js +13 -0
- package/examples/desk-app/src/style.module.css +38 -0
- package/examples/library/package.json +52 -0
- package/examples/library/public/favicon.ico +0 -0
- package/examples/library/react-cli.config.js +13 -0
- package/examples/library/src/common/AppContainer.js +62 -0
- package/examples/library/src/common/AppContainer.module.css +50 -0
- package/examples/library/src/common/Pages.js +28 -0
- package/examples/library/src/common/UIProvider.js +155 -0
- package/examples/library/src/common/docstyle.module.css +40 -0
- package/examples/library/src/index.html +17 -0
- package/examples/library/src/index.js +11 -0
- package/examples/library/src/table-list/AllFieldsList.js +20 -0
- package/examples/library/src/table-list/EmptyList.js +20 -0
- package/examples/library/src/table-list/FlexibleList.js +21 -0
- package/examples/library/src/table-list/InitialLoadingList.js +22 -0
- package/examples/library/src/table-list/ItemsInitialLoadingList.js +20 -0
- package/examples/library/src/table-list/ListWithoutActions.js +20 -0
- package/examples/library/src/table-list/MassSelectionList.js +24 -0
- package/examples/library/src/table-list/MoreLoadingList.js +20 -0
- package/examples/library/src/table-list/ResizerList.js +40 -0
- package/examples/library/src/table-list/SimpleList.js +20 -0
- package/examples/library/src/table-list/SortableList.js +20 -0
- package/examples/library/src/table-list/data/all_fields.js +192 -0
- package/examples/library/src/table-list/data/all_fields_without_actions.js +109 -0
- package/examples/library/src/table-list/data/all_sortable_fields.js +142 -0
- package/examples/library/src/table-list/data/empty_data.js +47 -0
- package/examples/library/src/table-list/data/resizer_data.js +62 -0
- package/examples/library/src/table-list/data/simple_data.js +63 -0
- package/jsconfig.json +13 -0
- package/lint.config.js +29 -0
- package/old-tsconfig.json +23 -0
- package/package.json +67 -0
- package/post_publish.js +13 -0
- package/prettify.js +90 -0
- package/react-cli.config.js +15 -0
- package/src/bc/list-selection/ActionHandlers.ts +10 -0
- package/src/bc/list-selection/Actions.ts +45 -0
- package/src/bc/list-selection/Constants.ts +3 -0
- package/src/bc/list-selection/Properties.ts +17 -0
- package/src/bc/local-storage/ActionHandlers.ts +7 -0
- package/src/bc/local-storage/Constants.ts +1 -0
- package/src/bc/local-storage/Properties.ts +10 -0
- package/src/bc/sort-by/ActionHandlers.ts +8 -0
- package/src/bc/sort-by/Constants.ts +2 -0
- package/src/bc/sort-by/Properties.ts +22 -0
- package/src/bc/sort-by/SortOrderEnum.ts +7 -0
- package/src/bc/table-column-resizer/ActionHandlers.ts +12 -0
- package/src/bc/table-column-resizer/Constants.ts +9 -0
- package/src/bc/table-column-resizer/Properties.ts +18 -0
- package/src/bc/zfield/ActionHandlers.ts +13 -0
- package/src/bc/zfield/Actions.ts +36 -0
- package/src/bc/zfield/Constants.ts +6 -0
- package/src/bc/zfield/Properties.ts +5 -0
- package/src/bc/zhttp/ActionHandlers.ts +6 -0
- package/src/bc/zhttp/Actions.ts +88 -0
- package/src/bc/zhttp/Constants.ts +6 -0
- package/src/bc/zhttp/Properties.ts +1 -0
- package/src/bc/zlist/Actions.ts +6 -0
- package/src/bc/zlist/Constants.ts +4 -0
- package/src/bc/zlist/EventHandlers.ts +6 -0
- package/src/bc/zlist/Properties.ts +55 -0
- package/src/bc/zrecord/Actions.ts +149 -0
- package/src/bc/zrecord/Constants.ts +13 -0
- package/src/bc/zrecord/EventHandlers.ts +14 -0
- package/src/bc/zrecord/Properties.ts +1 -0
- package/src/bc/zrecord/Symbols.ts +4 -0
- package/src/cc/action-icon/Constants.ts +5 -0
- package/src/cc/action-icon/Model.ts +20 -0
- package/src/cc/action-icon/Properties.ts +31 -0
- package/src/cc/action-icon/index.ts +3 -0
- package/src/cc/action-location/Constants.ts +7 -0
- package/src/cc/action-location/Properties.ts +10 -0
- package/src/cc/architecture/IController.ts +5 -0
- package/src/cc/architecture/IUseCase.ts +4 -0
- package/src/cc/architecture/LifeCycleActionEnum.ts +7 -0
- package/src/cc/avatar/ActionHandlers.ts +1 -0
- package/src/cc/avatar/Actions.ts +7 -0
- package/src/cc/avatar/Constants.ts +5 -0
- package/src/cc/avatar/Data.ts +17 -0
- package/src/cc/avatar/Model.ts +16 -0
- package/src/cc/avatar/Properties.ts +50 -0
- package/src/cc/avatar/index.ts +5 -0
- package/src/cc/checkbox/ActionHandlers.ts +1 -0
- package/src/cc/checkbox/Actions.ts +7 -0
- package/src/cc/checkbox/Constants.ts +5 -0
- package/src/cc/checkbox/Data.ts +9 -0
- package/src/cc/checkbox/Model.ts +16 -0
- package/src/cc/checkbox/Properties.ts +44 -0
- package/src/cc/checkbox/index.ts +5 -0
- package/src/cc/component/Action.ts +3 -0
- package/src/cc/component/ActionHandlers.ts +6 -0
- package/src/cc/component/Behaviour.ts +14 -0
- package/src/cc/component/DeclarativeAction.ts +14 -0
- package/src/cc/component/Event.ts +10 -0
- package/src/cc/component/EventHandlers.ts +12 -0
- package/src/cc/component/Helpers.ts +9 -0
- package/src/cc/component/LifeCycleAction.ts +20 -0
- package/src/cc/component/Payload.ts +13 -0
- package/src/cc/component/Styles.ts +13 -0
- package/src/cc/component/View.ts +8 -0
- package/src/cc/component/component.ts +29 -0
- package/src/cc/component/properties/AppendToActionPayloadProperty.ts +44 -0
- package/src/cc/component/properties/Property.ts +11 -0
- package/src/cc/component/properties/Schema.ts +4 -0
- package/src/cc/component/properties/appendToActionPayload.ts +37 -0
- package/src/cc/component/properties/index.ts +8 -0
- package/src/cc/component/setInitialState.ts +2 -0
- package/src/cc/component/transferState.ts +2 -0
- package/src/cc/email/ActionHandlers.ts +1 -0
- package/src/cc/email/Actions.ts +7 -0
- package/src/cc/email/Constants.ts +5 -0
- package/src/cc/email/Data.ts +5 -0
- package/src/cc/email/Model.ts +6 -0
- package/src/cc/email/Properties.ts +10 -0
- package/src/cc/email/index.ts +5 -0
- package/src/cc/empty-state/Properties.ts +1 -0
- package/src/cc/fields/boolean/Events.ts +6 -0
- package/src/cc/fields/boolean/Model.ts +13 -0
- package/src/cc/fields/boolean/Properties.ts +14 -0
- package/src/cc/fields/currency/Events.ts +6 -0
- package/src/cc/fields/currency/Model.ts +13 -0
- package/src/cc/fields/currency/Properties.ts +13 -0
- package/src/cc/fields/date/Events.ts +6 -0
- package/src/cc/fields/date/Model.ts +13 -0
- package/src/cc/fields/date/Properties.ts +13 -0
- package/src/cc/fields/datetime/Events.ts +6 -0
- package/src/cc/fields/datetime/Model.ts +13 -0
- package/src/cc/fields/datetime/Properties.ts +13 -0
- package/src/cc/fields/decimal/Events.ts +6 -0
- package/src/cc/fields/decimal/Model.ts +13 -0
- package/src/cc/fields/decimal/Properties.ts +13 -0
- package/src/cc/fields/email/Events.ts +6 -0
- package/src/cc/fields/email/Model.ts +13 -0
- package/src/cc/fields/email/Properties.ts +13 -0
- package/src/cc/fields/field/Constants.ts +6 -0
- package/src/cc/fields/field/Events.ts +41 -0
- package/src/cc/fields/field/Properties.ts +29 -0
- package/src/cc/fields/lookup/Events.ts +6 -0
- package/src/cc/fields/lookup/Model.ts +13 -0
- package/src/cc/fields/lookup/Properties.ts +13 -0
- package/src/cc/fields/multi-line/Events.ts +6 -0
- package/src/cc/fields/multi-line/Model.ts +13 -0
- package/src/cc/fields/multi-line/Properties.ts +42 -0
- package/src/cc/fields/multi-select/Events.ts +6 -0
- package/src/cc/fields/multi-select/Model.ts +17 -0
- package/src/cc/fields/multi-select/Properties.ts +42 -0
- package/src/cc/fields/number/Events.ts +6 -0
- package/src/cc/fields/number/Model.ts +13 -0
- package/src/cc/fields/number/Properties.ts +13 -0
- package/src/cc/fields/percent/Events.ts +6 -0
- package/src/cc/fields/percent/Model.ts +13 -0
- package/src/cc/fields/percent/Properties.ts +13 -0
- package/src/cc/fields/phone/Events.ts +6 -0
- package/src/cc/fields/phone/Model.ts +13 -0
- package/src/cc/fields/phone/Properties.ts +13 -0
- package/src/cc/fields/pick-list/Events.ts +6 -0
- package/src/cc/fields/pick-list/Model.ts +17 -0
- package/src/cc/fields/pick-list/Properties.ts +42 -0
- package/src/cc/fields/text/Events.ts +6 -0
- package/src/cc/fields/text/Model.ts +13 -0
- package/src/cc/fields/text/Properties.ts +12 -0
- package/src/cc/fields/url/Events.ts +6 -0
- package/src/cc/fields/url/Model.ts +13 -0
- package/src/cc/fields/url/Properties.ts +14 -0
- package/src/cc/highlighted-value/ActionHandlers.ts +1 -0
- package/src/cc/highlighted-value/Actions.ts +7 -0
- package/src/cc/highlighted-value/Constants.ts +5 -0
- package/src/cc/highlighted-value/Data.ts +15 -0
- package/src/cc/highlighted-value/Model.ts +8 -0
- package/src/cc/highlighted-value/Properties.ts +34 -0
- package/src/cc/highlighted-value/index.ts +5 -0
- package/src/cc/index.ts +10 -0
- package/src/cc/link/ActionHandlers.ts +1 -0
- package/src/cc/link/Actions.ts +7 -0
- package/src/cc/link/Constants.ts +5 -0
- package/src/cc/link/Data.ts +13 -0
- package/src/cc/link/Model.ts +9 -0
- package/src/cc/link/Properties.ts +41 -0
- package/src/cc/link/index.ts +5 -0
- package/src/cc/switch/ActionHandlers.ts +1 -0
- package/src/cc/switch/Actions.ts +20 -0
- package/src/cc/switch/Constants.ts +5 -0
- package/src/cc/switch/Data.ts +13 -0
- package/src/cc/switch/Model.ts +9 -0
- package/src/cc/switch/Properties.ts +41 -0
- package/src/cc/switch/index.ts +5 -0
- package/src/cc/table-connected/Properties.ts +82 -0
- package/src/cc/table-list/ActionHandlers.ts +6 -0
- package/src/cc/table-list/Actions.ts +19 -0
- package/src/cc/table-list/Constants.ts +11 -0
- package/src/cc/table-list/Data.ts +17 -0
- package/src/cc/table-list/Events.ts +69 -0
- package/src/cc/table-list/Properties.ts +430 -0
- package/src/cc/table-list/behaviour-properties/ResizerConfig.ts +18 -0
- package/src/cc/table-list/behaviour-properties/SelectionConfig.ts +17 -0
- package/src/cc/table-list/behaviour-properties/SortByConfig.ts +15 -0
- package/src/cc/table-list/behaviour-properties/index.ts +3 -0
- package/src/cc/table-list/data-types/Column.ts +7 -0
- package/src/cc/table-list/data-types/Data.ts +9 -0
- package/src/cc/table-list/data-types/Header.ts +32 -0
- package/src/cc/table-list/data-types/ResizerConfig.ts +7 -0
- package/src/cc/table-list/data-types/Row.ts +10 -0
- package/src/cc/table-list/data-types/RowSelection.ts +7 -0
- package/src/cc/table-list/data-types/SelectionConfig.ts +7 -0
- package/src/cc/table-list/data-types/fields/AvatarField.ts +7 -0
- package/src/cc/table-list/data-types/fields/CheckboxField.ts +7 -0
- package/src/cc/table-list/data-types/fields/EmailField.ts +7 -0
- package/src/cc/table-list/data-types/fields/HighlightedValueField.ts +7 -0
- package/src/cc/table-list/data-types/fields/LinkField.ts +7 -0
- package/src/cc/table-list/data-types/fields/SwitchField.ts +7 -0
- package/src/cc/table-list/data-types/fields/TagsField.ts +7 -0
- package/src/cc/table-list/data-types/fields/TextField.ts +7 -0
- package/src/cc/table-list/data-types/fields/index.ts +8 -0
- package/src/cc/table-list/index.ts +5 -0
- package/src/cc/table-list/model/HeaderModel.ts +15 -0
- package/src/cc/table-list/model/RowModel.ts +13 -0
- package/src/cc/table-list/model/TableModel.ts +28 -0
- package/src/cc/table-list/model/index.ts +9 -0
- package/src/cc/table-list/row/Constants.ts +7 -0
- package/src/cc/table-list/row/Properties.ts +104 -0
- package/src/cc/tags/ActionHandlers.ts +1 -0
- package/src/cc/tags/Actions.ts +7 -0
- package/src/cc/tags/Constants.ts +5 -0
- package/src/cc/tags/Data.ts +23 -0
- package/src/cc/tags/Properties.ts +69 -0
- package/src/cc/tags/index.ts +5 -0
- package/src/cc/tags/model/TagModel.ts +14 -0
- package/src/cc/tags/model/TagsDataModel.ts +10 -0
- package/src/cc/tags/model/index.ts +7 -0
- package/src/cc/text/ActionHandlers.ts +1 -0
- package/src/cc/text/Actions.ts +7 -0
- package/src/cc/text/Constants.ts +5 -0
- package/src/cc/text/Data.ts +14 -0
- package/src/cc/text/Model.ts +8 -0
- package/src/cc/text/Properties.ts +32 -0
- package/src/cc/text/index.ts +5 -0
- package/src/desk-frameworks/index.ts +1 -0
- package/src/desk-frameworks/table-connected/frameworks/EventHandlersFactory.ts +30 -0
- package/src/desk-frameworks/table-connected/frameworks/ListSdkFactory.ts +32 -0
- package/src/desk-frameworks/table-connected/frameworks/TableConnected.ts +5 -0
- package/src/desk-frameworks/table-connected/frameworks/TableConnectedFactory.ts +31 -0
- package/src/desk-frameworks/table-connected/frameworks/TableConnectedView.tsx +23 -0
- package/src/library/behaviours/list-selection/adapters/controllers/AbstractController.ts +11 -0
- package/src/library/behaviours/list-selection/adapters/controllers/AllSelectionController.ts +13 -0
- package/src/library/behaviours/list-selection/adapters/controllers/DestructController.ts +14 -0
- package/src/library/behaviours/list-selection/adapters/controllers/InitializeController.ts +14 -0
- package/src/library/behaviours/list-selection/adapters/controllers/RangeSelectionController.ts +14 -0
- package/src/library/behaviours/list-selection/adapters/controllers/SelectionController.ts +14 -0
- package/src/library/behaviours/list-selection/adapters/controllers/UpdateController.ts +14 -0
- package/src/library/behaviours/list-selection/adapters/gateways/Repository.ts +23 -0
- package/src/library/behaviours/list-selection/adapters/gateways/Service.ts +25 -0
- package/src/library/behaviours/list-selection/adapters/presenters/Presenter.ts +24 -0
- package/src/library/behaviours/list-selection/entities/ListItemSelection.ts +95 -0
- package/src/library/behaviours/list-selection/entities/interfaces/IListItemSelection.ts +10 -0
- package/src/library/behaviours/list-selection/entities/interfaces/ListSelectionModel.ts +6 -0
- package/src/library/behaviours/list-selection/frameworks/ActionHandlerFactory.ts +39 -0
- package/src/library/behaviours/list-selection/frameworks/ListItemSelectionBehaviourFactory.ts +25 -0
- package/src/library/behaviours/list-selection/usecases/interactors/AbstractUseCase.ts +17 -0
- package/src/library/behaviours/list-selection/usecases/interactors/AllItemSelection.ts +14 -0
- package/src/library/behaviours/list-selection/usecases/interactors/Destruct.ts +8 -0
- package/src/library/behaviours/list-selection/usecases/interactors/Initialize.ts +13 -0
- package/src/library/behaviours/list-selection/usecases/interactors/ItemsSelection.ts +16 -0
- package/src/library/behaviours/list-selection/usecases/interactors/RangeSelection.ts +15 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/UseCase.ts +5 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/UseCaseDependencies.ts +9 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/gateways/IRepository.ts +8 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/gateways/IService.ts +15 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/input/AllSelectionInputModel.ts +3 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/input/DestructInputModel.ts +3 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/input/InitializeInputModel.ts +5 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/input/RangeSelectionInputModel.ts +5 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/input/SelectionInputModel.ts +5 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/output/BehaviourStateModel.ts +6 -0
- package/src/library/behaviours/list-selection/usecases/interfaces/output/IPresenter.ts +8 -0
- package/src/library/behaviours/local-storage/adapters/controllers/handlers/Mount.ts +0 -0
- package/src/library/behaviours/local-storage/adapters/controllers/handlers/SetData.ts +0 -0
- package/src/library/behaviours/local-storage/adapters/controllers/handlers/UnMount.ts +0 -0
- package/src/library/behaviours/local-storage/entities/Storage.ts +16 -0
- package/src/library/behaviours/local-storage/entities/interfaces/ILocalStorage.ts +6 -0
- package/src/library/behaviours/local-storage/entities/interfaces/IStorage.ts +6 -0
- package/src/library/behaviours/local-storage/usecases/interactors/AbstractUseCase.ts +8 -0
- package/src/library/behaviours/local-storage/usecases/interactors/DeleteData.ts +13 -0
- package/src/library/behaviours/local-storage/usecases/interactors/GetData.ts +13 -0
- package/src/library/behaviours/local-storage/usecases/interactors/SetData.ts +13 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/InputDependencies.ts +8 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/UseCase.ts +4 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/gateways/IRepository.ts +7 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/input/DeleteDataInput.ts +4 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/input/GetDataInput.ts +4 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/input/SetDataInput.ts +5 -0
- package/src/library/behaviours/local-storage/usecases/interfaces/output/IPresenter.ts +4 -0
- package/src/library/behaviours/mouse-resizable/adapters/controllers/handlers/MountHandler.ts +7 -0
- package/src/library/behaviours/mouse-resizable/adapters/controllers/handlers/StartResize.ts +11 -0
- package/src/library/behaviours/mouse-resizable/adapters/controllers/handlers/UnMountHandler.ts +0 -0
- package/src/library/behaviours/mouse-resizable/frameworks/MouseResizableFactory.ts +28 -0
- package/src/library/behaviours/sort-by/adapters/controllers/AbstractController.ts +11 -0
- package/src/library/behaviours/sort-by/adapters/controllers/Initialize.ts +11 -0
- package/src/library/behaviours/sort-by/adapters/controllers/SortBy.ts +14 -0
- package/src/library/behaviours/sort-by/adapters/gateway/Repository.ts +16 -0
- package/src/library/behaviours/sort-by/adapters/gateway/Service.ts +15 -0
- package/src/library/behaviours/sort-by/adapters/presenter/Presenter.ts +23 -0
- package/src/library/behaviours/sort-by/entities/SortBy.ts +38 -0
- package/src/library/behaviours/sort-by/entities/interfaces/ISortBy.ts +8 -0
- package/src/library/behaviours/sort-by/frameworks/ui/ActionsHandlerFactory.ts +21 -0
- package/src/library/behaviours/sort-by/frameworks/ui/DemoBehaviour.ts +19 -0
- package/src/library/behaviours/sort-by/frameworks/ui/SortByBehaviourFactory.ts +19 -0
- package/src/library/behaviours/sort-by/usecases/interactors/AbstractUseCase.ts +17 -0
- package/src/library/behaviours/sort-by/usecases/interactors/SortBy.ts +22 -0
- package/src/library/behaviours/sort-by/usecases/interfaces/UseCaseDependencies.ts +10 -0
- package/src/library/behaviours/sort-by/usecases/interfaces/gateways/IRepository.ts +8 -0
- package/src/library/behaviours/sort-by/usecases/interfaces/gateways/IService.ts +8 -0
- package/src/library/behaviours/sort-by/usecases/interfaces/input/SortByInputModel.ts +6 -0
- package/src/library/behaviours/sort-by/usecases/interfaces/output/IPresenter.ts +6 -0
- package/src/library/behaviours/sort-by/usecases/interfaces/output/SortByOutputModel.ts +9 -0
- package/src/library/behaviours/table-column-resizer/adapters/controllers/handlers/HandleDragStart.ts +0 -0
- package/src/library/custom-component/adapters/controllers/Controller.ts +24 -0
- package/src/library/custom-component/adapters/controllers/interface/IController.ts +20 -0
- package/src/library/custom-component/adapters/gateways/event-manager/EventManager.ts +67 -0
- package/src/library/custom-component/adapters/gateways/repository/Repository.ts +17 -0
- package/src/library/custom-component/adapters/gateways/service/Service.ts +29 -0
- package/src/library/custom-component/adapters/gateways/validator/jsonValidator.ts +9 -0
- package/src/library/custom-component/adapters/presenters/Presenter.ts +22 -0
- package/src/library/custom-component/entities/Behaviour.ts +40 -0
- package/src/library/custom-component/entities/Component.ts +170 -0
- package/src/library/custom-component/entities/EventHandler.ts +13 -0
- package/src/library/custom-component/entities/EventHandlers.ts +9 -0
- package/src/library/custom-component/entities/Events.ts +18 -0
- package/src/library/custom-component/entities/LifeCycleAction.ts +31 -0
- package/src/library/custom-component/entities/Payload.ts +17 -0
- package/src/library/custom-component/entities/Properties.ts +120 -0
- package/src/library/custom-component/entities/Property.ts +42 -0
- package/src/library/custom-component/entities/Schema.ts +10 -0
- package/src/library/custom-component/entities/State.ts +15 -0
- package/src/library/custom-component/entities/Style.ts +25 -0
- package/src/library/custom-component/entities/__tests__/Action.spec.ts +22 -0
- package/src/library/custom-component/entities/__tests__/ActionHandlers.spec.ts +19 -0
- package/src/library/custom-component/entities/__tests__/Behaviour.spec.ts +56 -0
- package/src/library/custom-component/entities/__tests__/Component.spec.ts +105 -0
- package/src/library/custom-component/entities/defaultAppendToActionPayload.ts +10 -0
- package/src/library/custom-component/entities/interfaces/IBehaviour.ts +11 -0
- package/src/library/custom-component/entities/interfaces/IComponent.ts +37 -0
- package/src/library/custom-component/entities/interfaces/IEvent.ts +7 -0
- package/src/library/custom-component/entities/interfaces/IEventHandler.ts +5 -0
- package/src/library/custom-component/entities/interfaces/IEventHandlerHelpers.ts +7 -0
- package/src/library/custom-component/entities/interfaces/IEventHandlers.ts +4 -0
- package/src/library/custom-component/entities/interfaces/IEventWrapper.ts +5 -0
- package/src/library/custom-component/entities/interfaces/ILifeCycleAction.ts +19 -0
- package/src/library/custom-component/entities/interfaces/IPayload.ts +5 -0
- package/src/library/custom-component/entities/interfaces/IProperties.ts +12 -0
- package/src/library/custom-component/entities/interfaces/IProperty.ts +9 -0
- package/src/library/custom-component/entities/interfaces/ISchema.ts +4 -0
- package/src/library/custom-component/entities/interfaces/IState.ts +5 -0
- package/src/library/custom-component/entities/interfaces/IStyle.ts +8 -0
- package/src/library/custom-component/entities/interfaces/IUpdateHelper.ts +0 -0
- package/src/library/custom-component/entities/interfaces/IValidator.ts +8 -0
- package/src/library/custom-component/frameworks/json-schema-validator/validator.ts +5 -0
- package/src/library/custom-component/frameworks/object-path-immutable/ImmutableHelper.ts +3 -0
- package/src/library/custom-component/frameworks/ui/Compare.ts +41 -0
- package/src/library/custom-component/frameworks/ui/ComponentRegistry.ts +26 -0
- package/src/library/custom-component/frameworks/ui/createCustomComponent.tsx +97 -0
- package/src/library/custom-component/frameworks/ui/dependencyFactory.ts +25 -0
- package/src/library/custom-component/index.ts +1 -0
- package/src/library/custom-component/usecases/entities-factory/BehavioursFactory.ts +37 -0
- package/src/library/custom-component/usecases/entities-factory/ComponentFactory.ts +42 -0
- package/src/library/custom-component/usecases/entities-factory/EventHandlersFactory.ts +10 -0
- package/src/library/custom-component/usecases/entities-factory/PropertiesFactory.ts +13 -0
- package/src/library/custom-component/usecases/interactors/AbstractUseCase.ts +8 -0
- package/src/library/custom-component/usecases/interactors/DispatchUseCase.ts +18 -0
- package/src/library/custom-component/usecases/interactors/InitializeUseCase.ts +23 -0
- package/src/library/custom-component/usecases/interactors/MountUseCase.ts +18 -0
- package/src/library/custom-component/usecases/interactors/UnmountUseCase.ts +18 -0
- package/src/library/custom-component/usecases/interactors/UpdatePropertyUseCase.ts +24 -0
- package/src/library/custom-component/usecases/interactors/UpdateStateUseCase.ts +13 -0
- package/src/library/custom-component/usecases/interfaces/InputDependencies.ts +13 -0
- package/src/library/custom-component/usecases/interfaces/OutputDependencies.ts +5 -0
- package/src/library/custom-component/usecases/interfaces/UseCase.ts +4 -0
- package/src/library/custom-component/usecases/interfaces/gateways/IEventManager.ts +12 -0
- package/src/library/custom-component/usecases/interfaces/gateways/IJSONValidator.ts +8 -0
- package/src/library/custom-component/usecases/interfaces/gateways/IRepository.ts +9 -0
- package/src/library/custom-component/usecases/interfaces/gateways/IService.ts +15 -0
- package/src/library/custom-component/usecases/interfaces/input/DispatchInputModel.ts +4 -0
- package/src/library/custom-component/usecases/interfaces/input/InitailizeInputModel.ts +5 -0
- package/src/library/custom-component/usecases/interfaces/input/UpdatePropertiesInputModel.ts +2 -0
- package/src/library/custom-component/usecases/interfaces/input/UpdateStateInputModel.ts +2 -0
- package/src/library/custom-component/usecases/interfaces/output/OutputBoundary.ts +6 -0
- package/src/library/dot/components/action-location/adapters/controllers/MountController.ts +15 -0
- package/src/library/dot/components/action-location/adapters/controllers/PropertiesChangeController.ts +20 -0
- package/src/library/dot/components/action-location/adapters/controllers/UnmountController.ts +15 -0
- package/src/library/dot/components/action-location/adapters/gateway/Repository.ts +26 -0
- package/src/library/dot/components/action-location/adapters/presenters/Presenter.ts +19 -0
- package/src/library/dot/components/action-location/entities/ActionLocationEntity.ts +98 -0
- package/src/library/dot/components/action-location/entities/interfaces/ActionViewModel.ts +9 -0
- package/src/library/dot/components/action-location/entities/interfaces/EventMappingViewModel.ts +10 -0
- package/src/library/dot/components/action-location/entities/interfaces/IActionLocation.ts +8 -0
- package/src/library/dot/components/action-location/frameworks/ui/ActionLocation.tsx +13 -0
- package/src/library/dot/components/action-location/frameworks/ui/ActionLocationView.tsx +23 -0
- package/src/library/dot/components/action-location/frameworks/ui/EventHandlersFactory.ts +35 -0
- package/src/library/dot/components/action-location/usecases/interactors/AbstractUseCase.ts +13 -0
- package/src/library/dot/components/action-location/usecases/interactors/DestroyUseCase.ts +12 -0
- package/src/library/dot/components/action-location/usecases/interactors/InitializeUseCase.ts +12 -0
- package/src/library/dot/components/action-location/usecases/interactors/PropertiesChangeUseCase.ts +14 -0
- package/src/library/dot/components/action-location/usecases/interfaces/UseCaseDependencies.ts +4 -0
- package/src/library/dot/components/action-location/usecases/interfaces/gateways/IRepository.ts +6 -0
- package/src/library/dot/components/action-location/usecases/interfaces/input/PropertiesChangeUseCaseInputModel.ts +8 -0
- package/src/library/dot/components/action-location/usecases/interfaces/output/IPresenter.ts +4 -0
- package/src/library/dot/components/table-list/adapters/controllers/AbstractController.ts +9 -0
- package/src/library/dot/components/table-list/adapters/controllers/FieldChangeController.ts +22 -0
- package/src/library/dot/components/table-list/adapters/controllers/FieldClickController.ts +21 -0
- package/src/library/dot/components/table-list/adapters/controllers/RowClickController.ts +18 -0
- package/src/library/dot/components/table-list/adapters/controllers/ScrollController.ts +24 -0
- package/src/library/dot/components/table-list/adapters/controllers/SelectAllController.ts +14 -0
- package/src/library/dot/components/table-list/adapters/controllers/SelectItemController.ts +23 -0
- package/src/library/dot/components/table-list/adapters/controllers/SortByController.ts +16 -0
- package/src/library/dot/components/table-list/adapters/controllers/SortedController.ts +15 -0
- package/src/library/dot/components/table-list/adapters/controllers/index.ts +7 -0
- package/src/library/dot/components/table-list/adapters/presenters/TableTranslator.ts +35 -0
- package/src/library/dot/components/table-list/frameworks/ui/EventHandlersFactory.ts +31 -0
- package/src/library/dot/components/table-list/frameworks/ui/TableList.tsx +36 -0
- package/src/library/dot/components/table-list/frameworks/ui/TableListView.tsx +71 -0
- package/src/library/dot/components/table-list/frameworks/ui/css/TableList.module.css +25 -0
- package/src/library/dot/components/table-list/frameworks/ui/handlers/HandleAllSelect.ts +7 -0
- package/src/library/dot/components/table-list/frameworks/ui/handlers/HandleRowSelect.ts +8 -0
- package/src/library/dot/components/table-list/frameworks/ui/handlers/HandleScroll.ts +10 -0
- package/src/library/dot/components/table-list/frameworks/ui/handlers/HandleSortClick.ts +8 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/Body.tsx +15 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/ColumnResizingLine.tsx +20 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/Header.tsx +42 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/Loading.tsx +19 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/NoData.tsx +24 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/Rows.tsx +36 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/field/FieldComponent.tsx +17 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/ActionColumn.tsx +9 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/ColumnResizer.tsx +12 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/HeaderData.tsx +25 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/HeaderText.tsx +23 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/Headers.tsx +26 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/ResizerExtraSpace.tsx +19 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/header/SelectAll.tsx +24 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/row/Columns.tsx +22 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/row/Row.tsx +45 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/row/RowActions.tsx +14 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/row/RowData.tsx +24 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/row/RowEventHandlersFactory.ts +19 -0
- package/src/library/dot/components/table-list/frameworks/ui/sub-components/row/RowSelection.tsx +26 -0
- package/src/library/dot/legacy-to-new-arch/action-icon/ActionIcon.ts +13 -0
- package/src/library/dot/legacy-to-new-arch/action-icon/ActionIconView.tsx +24 -0
- package/src/library/dot/legacy-to-new-arch/avatar/frameworks/ui/Avatar.contract.md +17 -0
- package/src/library/dot/legacy-to-new-arch/avatar/frameworks/ui/Avatar.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/avatar/frameworks/ui/AvatarView.tsx +49 -0
- package/src/library/dot/legacy-to-new-arch/checkbox/frameworks/ui/Checkbox.contract.md +21 -0
- package/src/library/dot/legacy-to-new-arch/checkbox/frameworks/ui/Checkbox.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/checkbox/frameworks/ui/CheckboxView.tsx +25 -0
- package/src/library/dot/legacy-to-new-arch/common-empty-state/CommonEmptyState.ts +13 -0
- package/src/library/dot/legacy-to-new-arch/common-empty-state/CommonEmptyStateView.tsx +11 -0
- package/src/library/dot/legacy-to-new-arch/email/frameworks/ui/Email.contract.md +7 -0
- package/src/library/dot/legacy-to-new-arch/email/frameworks/ui/Email.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/email/frameworks/ui/EmailView.tsx +25 -0
- package/src/library/dot/legacy-to-new-arch/field-components/checkbox-field/frameworks/ui/CheckboxField.tsx +15 -0
- package/src/library/dot/legacy-to-new-arch/field-components/checkbox-field/frameworks/ui/CheckboxFieldView.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/field-components/checkbox-field/frameworks/ui/EventHandlersFactory.ts +24 -0
- package/src/library/dot/legacy-to-new-arch/field-components/email-field/frameworks/ui/EmailField.tsx +13 -0
- package/src/library/dot/legacy-to-new-arch/field-components/email-field/frameworks/ui/EmailFieldView.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/field-components/index.ts +16 -0
- package/src/library/dot/legacy-to-new-arch/field-components/lookup-field/frameworks/ui/LookupField.tsx +13 -0
- package/src/library/dot/legacy-to-new-arch/field-components/lookup-field/frameworks/ui/LookupFieldView.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/field-components/multiselect-field/frameworks/ui/MultiSelectField.tsx +13 -0
- package/src/library/dot/legacy-to-new-arch/field-components/multiselect-field/frameworks/ui/MultiSelectFieldView.tsx +15 -0
- package/src/library/dot/legacy-to-new-arch/field-components/phone-field/frameworks/ui/PhoneField.tsx +13 -0
- package/src/library/dot/legacy-to-new-arch/field-components/phone-field/frameworks/ui/PhoneFieldView.tsx +15 -0
- package/src/library/dot/legacy-to-new-arch/field-components/picklist-field/frameworks/ui/PickListField.tsx +13 -0
- package/src/library/dot/legacy-to-new-arch/field-components/picklist-field/frameworks/ui/PickListFieldView.tsx +14 -0
- package/src/library/dot/legacy-to-new-arch/field-components/switch-field/frameworks/ui/EventHandlersFactory.ts +25 -0
- package/src/library/dot/legacy-to-new-arch/field-components/switch-field/frameworks/ui/SwitchField.tsx +15 -0
- package/src/library/dot/legacy-to-new-arch/field-components/switch-field/frameworks/ui/SwitchFieldView.tsx +8 -0
- package/src/library/dot/legacy-to-new-arch/field-components/text-field/frameworks/ui/EventHandlersFactory.ts +23 -0
- package/src/library/dot/legacy-to-new-arch/field-components/text-field/frameworks/ui/TextField.tsx +15 -0
- package/src/library/dot/legacy-to-new-arch/field-components/text-field/frameworks/ui/TextFieldView.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/field-components/url-field/frameworks/ui/EventHandlersFactory.ts +23 -0
- package/src/library/dot/legacy-to-new-arch/field-components/url-field/frameworks/ui/UrlField.tsx +15 -0
- package/src/library/dot/legacy-to-new-arch/field-components/url-field/frameworks/ui/UrlFieldView.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/highlighted-value/frameworks/ui/HighlightedValue.contract.md +12 -0
- package/src/library/dot/legacy-to-new-arch/highlighted-value/frameworks/ui/HighlightedValue.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/highlighted-value/frameworks/ui/HighlightedValueView.tsx +24 -0
- package/src/library/dot/legacy-to-new-arch/index.ts +8 -0
- package/src/library/dot/legacy-to-new-arch/link/frameworks/ui/Link.contract.md +13 -0
- package/src/library/dot/legacy-to-new-arch/link/frameworks/ui/Link.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/link/frameworks/ui/LinkView.tsx +27 -0
- package/src/library/dot/legacy-to-new-arch/switch/frameworks/ui/Switch.contract.md +15 -0
- package/src/library/dot/legacy-to-new-arch/switch/frameworks/ui/Switch.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/switch/frameworks/ui/SwitchView.tsx +33 -0
- package/src/library/dot/legacy-to-new-arch/tags/frameworks/ui/TagContractAdapter.ts +16 -0
- package/src/library/dot/legacy-to-new-arch/tags/frameworks/ui/Tags.contract.md +8 -0
- package/src/library/dot/legacy-to-new-arch/tags/frameworks/ui/Tags.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/tags/frameworks/ui/TagsView.tsx +29 -0
- package/src/library/dot/legacy-to-new-arch/text/frameworks/ui/Text.contract.md +12 -0
- package/src/library/dot/legacy-to-new-arch/text/frameworks/ui/Text.tsx +12 -0
- package/src/library/dot/legacy-to-new-arch/text/frameworks/ui/TextView.tsx +27 -0
- package/src/library/index.ts +3 -0
- package/src/platform/data-broker/dbc/index.ts +77 -0
- package/src/platform/data-broker/http-template/deleteRecords.ts +31 -0
- package/src/platform/data-broker/http-template/getAvailableFields.ts +34 -0
- package/src/platform/data-broker/http-template/getRecords.ts +52 -0
- package/src/platform/data-broker/http-template/getSelectedFields.ts +48 -0
- package/src/platform/data-broker/http-template/getUIActions.ts +26 -0
- package/src/platform/data-broker/http-template/updateRecord.ts +37 -0
- package/src/platform/data-broker/index.ts +23 -0
- package/src/platform/data-broker/utils/transformer/createCf.ts +11 -0
- package/src/platform/data-broker/utils/transformer/transformer.ts +19 -0
- package/src/platform/index.js +1 -0
- package/src/platform/zfield/adapters/controllers/AbstractController.ts +12 -0
- package/src/platform/zfield/adapters/controllers/ExeucteActionController.ts +24 -0
- package/src/platform/zfield/adapters/controllers/FetchFailureController.ts +16 -0
- package/src/platform/zfield/adapters/controllers/FetchNoContentController.ts +16 -0
- package/src/platform/zfield/adapters/controllers/FetchSuccessController.ts +16 -0
- package/src/platform/zfield/adapters/controllers/InitializeController.ts +20 -0
- package/src/platform/zfield/adapters/controllers/RefetchController.ts +16 -0
- package/src/platform/zfield/adapters/gateways/Repository.ts +32 -0
- package/src/platform/zfield/adapters/gateways/Service.ts +28 -0
- package/src/platform/zfield/adapters/gateways/TemplateHelpers.ts +37 -0
- package/src/platform/zfield/adapters/presenters/Presenter.ts +32 -0
- package/src/platform/zfield/entities/BooleanField.ts +4 -0
- package/src/platform/zfield/entities/CurrencyField.ts +4 -0
- package/src/platform/zfield/entities/DateField.ts +4 -0
- package/src/platform/zfield/entities/DateTimeField.ts +4 -0
- package/src/platform/zfield/entities/EmailField.ts +6 -0
- package/src/platform/zfield/entities/Field.ts +45 -0
- package/src/platform/zfield/entities/LookupField.ts +12 -0
- package/src/platform/zfield/entities/MultiLineField.ts +4 -0
- package/src/platform/zfield/entities/MultiSelectField.ts +4 -0
- package/src/platform/zfield/entities/PercentageField.ts +4 -0
- package/src/platform/zfield/entities/PhoneField.ts +4 -0
- package/src/platform/zfield/entities/PickListField.ts +4 -0
- package/src/platform/zfield/entities/SingleLineField.ts +4 -0
- package/src/platform/zfield/entities/URLField.ts +4 -0
- package/src/platform/zfield/entities/api-template/APITemplate.ts +72 -0
- package/src/platform/zfield/entities/api-template/APITemplates.ts +22 -0
- package/src/platform/zfield/entities/fields-manager/AvailableFieldsManager.ts +86 -0
- package/src/platform/zfield/entities/fields-manager/FieldsManager.ts +117 -0
- package/src/platform/zfield/entities/fields-manager/SelectedFieldsManager.ts +87 -0
- package/src/platform/zfield/entities/index.ts +15 -0
- package/src/platform/zfield/entities/interfaces/ActionModel.ts +7 -0
- package/src/platform/zfield/entities/interfaces/BehaviourState.ts +16 -0
- package/src/platform/zfield/entities/interfaces/FieldModel.ts +18 -0
- package/src/platform/zfield/entities/interfaces/FieldTypes.ts +18 -0
- package/src/platform/zfield/entities/interfaces/IField.ts +6 -0
- package/src/platform/zfield/entities/interfaces/IFieldManger.ts +28 -0
- package/src/platform/zfield/entities/interfaces/MetaData.ts +20 -0
- package/src/platform/zfield/entities/interfaces/api-template/APIModels.ts +12 -0
- package/src/platform/zfield/entities/interfaces/api-template/IAPITemplate.ts +9 -0
- package/src/platform/zfield/entities/interfaces/api-template/IAPITemplates.ts +10 -0
- package/src/platform/zfield/entities/interfaces/api-template/ITemplateHelpers.ts +5 -0
- package/src/platform/zfield/frameworks/ActionHandlerFactory.ts +43 -0
- package/src/platform/zfield/frameworks/ZFieldBehaviourFactory.ts +17 -0
- package/src/platform/zfield/usecases/entity-factory/FieldBuilder.ts +106 -0
- package/src/platform/zfield/usecases/entity-factory/FieldFactory.ts +40 -0
- package/src/platform/zfield/usecases/entity-factory/FieldsManagerBuilder.ts +48 -0
- package/src/platform/zfield/usecases/interactors/AbstractUseCase.ts +16 -0
- package/src/platform/zfield/usecases/interactors/ExecuteActionUseCase.ts +16 -0
- package/src/platform/zfield/usecases/interactors/FetchFailureUseCase.ts +22 -0
- package/src/platform/zfield/usecases/interactors/FetchNoContentUseCase.ts +21 -0
- package/src/platform/zfield/usecases/interactors/FetchSuccessUseCase.ts +23 -0
- package/src/platform/zfield/usecases/interactors/InitializeUseCase.ts +13 -0
- package/src/platform/zfield/usecases/interactors/RefetchUseCase.ts +19 -0
- package/src/platform/zfield/usecases/interfaces/UsecaseDependencies.ts +10 -0
- package/src/platform/zfield/usecases/interfaces/gateways/IRepository.ts +8 -0
- package/src/platform/zfield/usecases/interfaces/gateways/IRestApi.ts +7 -0
- package/src/platform/zfield/usecases/interfaces/gateways/IService.ts +17 -0
- package/src/platform/zfield/usecases/interfaces/gateways/ITemplateHelpers.ts +1 -0
- package/src/platform/zfield/usecases/interfaces/input/ExecuteActionInputModel.ts +12 -0
- package/src/platform/zfield/usecases/interfaces/input/FetchInputModel.ts +18 -0
- package/src/platform/zfield/usecases/interfaces/input/InitialInputModel.ts +5 -0
- package/src/platform/zfield/usecases/interfaces/input/InputModel.ts +17 -0
- package/src/platform/zfield/usecases/interfaces/input/RefetchInputModel.ts +12 -0
- package/src/platform/zfield/usecases/interfaces/input/SetValueInputModel.ts +6 -0
- package/src/platform/zfield/usecases/interfaces/output/IPresenter.ts +9 -0
- package/src/platform/zhttp/adapters/controllers/FetchController.ts +18 -0
- package/src/platform/zhttp/adapters/gateway/FetchGateWay.ts +15 -0
- package/src/platform/zhttp/frameworks/ActionsHandlerFactory.ts +19 -0
- package/src/platform/zhttp/frameworks/ZHttpBehaviourFactory.ts +15 -0
- package/src/platform/zhttp/usecases/interactors/AbstractUseCase.ts +8 -0
- package/src/platform/zhttp/usecases/interactors/FetchUseCase.ts +44 -0
- package/src/platform/zhttp/usecases/interfaces/InputDependencies.ts +6 -0
- package/src/platform/zhttp/usecases/interfaces/UseCase.ts +4 -0
- package/src/platform/zhttp/usecases/interfaces/gateway/IFetchGateWay.ts +15 -0
- package/src/platform/zhttp/usecases/interfaces/input/FetchInputModel.ts +8 -0
- package/src/platform/zlist/adapters/controllers/AbstractController.ts +12 -0
- package/src/platform/zlist/adapters/controllers/DeleteMultipleRecordController.ts +12 -0
- package/src/platform/zlist/adapters/controllers/FetchMoreController.ts +11 -0
- package/src/platform/zlist/adapters/controllers/FieldChangeController.ts +12 -0
- package/src/platform/zlist/adapters/controllers/MountController.ts +12 -0
- package/src/platform/zlist/adapters/controllers/PropertiesChangeController.ts +14 -0
- package/src/platform/zlist/adapters/controllers/RecordUpdateController.ts +12 -0
- package/src/platform/zlist/adapters/controllers/SortController.ts +14 -0
- package/src/platform/zlist/adapters/gateways/Repository.ts +30 -0
- package/src/platform/zlist/adapters/gateways/Service.ts +31 -0
- package/src/platform/zlist/adapters/gateways/SortBy.ts +27 -0
- package/src/platform/zlist/adapters/presenters/TableTranslator.ts +43 -0
- package/src/platform/zlist/adapters/presenters/translators/ColumnTranslator.ts +29 -0
- package/src/platform/zlist/adapters/presenters/translators/EmptyViewModel.ts +10 -0
- package/src/platform/zlist/adapters/presenters/translators/Header.ts +16 -0
- package/src/platform/zlist/adapters/presenters/translators/HeadersTranslator.ts +27 -0
- package/src/platform/zlist/adapters/presenters/translators/Row.ts +23 -0
- package/src/platform/zlist/adapters/presenters/translators/RowActionTranslator.ts +34 -0
- package/src/platform/zlist/adapters/presenters/translators/RowsTranslator.ts +38 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/BooleanFieldTranslator.ts +20 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/CurrencyFieldTranslator.ts +15 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/DateFieldTranslator.ts +14 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/DateTimeFieldTranslator.ts +14 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/DecimalFieldTranslator.ts +15 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/EmailFieldTranslator.ts +14 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/LookUpFieldTranslator.ts +16 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/MultiLineFieldTranslator.ts +15 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/MultiSelectFieldTranslator.ts +20 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/NumberFieldTranslator.ts +15 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/PercentageFieldTranslator.ts +14 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/PhoneFieldTranslator.ts +14 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/PickListFieldTranslator.ts +14 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/SingleLineFieldTranslator.ts +15 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/URLFieldTranslator.ts +15 -0
- package/src/platform/zlist/adapters/presenters/translators/fields/index.ts +27 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/FieldModel.ts +19 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/FieldTranslator.ts +6 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/FieldUiMapping.ts +10 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/PageContext.ts +6 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/RowActionModel.ts +18 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/SelectedField.ts +2 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/State.ts +17 -0
- package/src/platform/zlist/adapters/presenters/translators/interfaces/ZFieldsBehaviourState.ts +9 -0
- package/src/platform/zlist/adapters/presenters/utils/pipeline.ts +16 -0
- package/src/platform/zlist/adapters/presenters/utils/replacer.ts +8 -0
- package/src/platform/zlist/adapters/presenters/utils/selectn.ts +6 -0
- package/src/platform/zlist/entities/List.ts +237 -0
- package/src/platform/zlist/entities/interfaces/ActionModel.ts +13 -0
- package/src/platform/zlist/entities/interfaces/ApiPropsModel.ts +10 -0
- package/src/platform/zlist/entities/interfaces/IList.ts +13 -0
- package/src/platform/zlist/entities/interfaces/Properties.ts +18 -0
- package/src/platform/zlist/frameworks/EventHandlersFactory.ts +44 -0
- package/src/platform/zlist/frameworks/ZListBehaviourFactory.ts +14 -0
- package/src/platform/zlist/usecases/entities-factory/ListFactory.ts +11 -0
- package/src/platform/zlist/usecases/interactors/AbstractUseCase.ts +18 -0
- package/src/platform/zlist/usecases/interactors/DeleteMultipleRecordUseCase.ts +14 -0
- package/src/platform/zlist/usecases/interactors/FetchMoreUseCase.ts +13 -0
- package/src/platform/zlist/usecases/interactors/FieldChangeUseCase.ts +14 -0
- package/src/platform/zlist/usecases/interactors/InitializeUseCase.ts +13 -0
- package/src/platform/zlist/usecases/interactors/PropertiesChangeUseCase.ts +14 -0
- package/src/platform/zlist/usecases/interactors/RecordUpdateUseCase.ts +14 -0
- package/src/platform/zlist/usecases/interactors/SortUseCase.ts +15 -0
- package/src/platform/zlist/usecases/interfaces/State.ts +5 -0
- package/src/platform/zlist/usecases/interfaces/UseCaseDependencies.ts +9 -0
- package/src/platform/zlist/usecases/interfaces/gateways/IRepository.ts +9 -0
- package/src/platform/zlist/usecases/interfaces/gateways/IService.ts +19 -0
- package/src/platform/zlist/usecases/interfaces/gateways/ISortBy.ts +9 -0
- package/src/platform/zlist/usecases/interfaces/gateways/ITransformState.ts +0 -0
- package/src/platform/zlist/usecases/interfaces/input/DeleteMultipleRecordUseCaseInput.ts +6 -0
- package/src/platform/zlist/usecases/interfaces/input/FetchMoreInput.ts +5 -0
- package/src/platform/zlist/usecases/interfaces/input/FieldChangeUseCaseInput.ts +8 -0
- package/src/platform/zlist/usecases/interfaces/input/InitializeInput.ts +4 -0
- package/src/platform/zlist/usecases/interfaces/input/PropertiesChangeUseCaseInput.ts +8 -0
- package/src/platform/zlist/usecases/interfaces/input/RecordUpdateUseCaseInput.ts +6 -0
- package/src/platform/zlist/usecases/interfaces/input/SortingInputModel.ts +12 -0
- package/src/platform/zrecord/adapters/controllers/AbstractController.ts +11 -0
- package/src/platform/zrecord/adapters/controllers/ActionExecutorController.ts +20 -0
- package/src/platform/zrecord/adapters/controllers/AppendRecordsController.ts +16 -0
- package/src/platform/zrecord/adapters/controllers/DeleteMultipleRecordLocalController.ts +16 -0
- package/src/platform/zrecord/adapters/controllers/FailureController.ts +23 -0
- package/src/platform/zrecord/adapters/controllers/FetchMoreController.ts +14 -0
- package/src/platform/zrecord/adapters/controllers/FieldChangeController.ts +12 -0
- package/src/platform/zrecord/adapters/controllers/MountController.ts +17 -0
- package/src/platform/zrecord/adapters/controllers/NoContentController.ts +20 -0
- package/src/platform/zrecord/adapters/controllers/RecordUpdateLocalController.ts +14 -0
- package/src/platform/zrecord/adapters/controllers/RefetchController.ts +24 -0
- package/src/platform/zrecord/adapters/controllers/SuccessController.ts +21 -0
- package/src/platform/zrecord/adapters/gateways/Repository.ts +23 -0
- package/src/platform/zrecord/adapters/gateways/Service.ts +42 -0
- package/src/platform/zrecord/adapters/gateways/TemplateHelpers.ts +37 -0
- package/src/platform/zrecord/adapters/presenters/Presenter.ts +23 -0
- package/src/platform/zrecord/entities/APITemplate.ts +68 -0
- package/src/platform/zrecord/entities/APITemplates.ts +22 -0
- package/src/platform/zrecord/entities/CustomFieldValues.ts +30 -0
- package/src/platform/zrecord/entities/Property.ts +26 -0
- package/src/platform/zrecord/entities/Record.ts +62 -0
- package/src/platform/zrecord/entities/Records.ts +83 -0
- package/src/platform/zrecord/entities/RecordsManager.ts +196 -0
- package/src/platform/zrecord/entities/interfaces/APIDetailsModel.ts +8 -0
- package/src/platform/zrecord/entities/interfaces/APITemplateModel.ts +3 -0
- package/src/platform/zrecord/entities/interfaces/APITemplatesModel.ts +3 -0
- package/src/platform/zrecord/entities/interfaces/ActionModel.ts +8 -0
- package/src/platform/zrecord/entities/interfaces/BehaviourState.ts +9 -0
- package/src/platform/zrecord/entities/interfaces/IAPITemplate.ts +10 -0
- package/src/platform/zrecord/entities/interfaces/IAPITemplates.ts +10 -0
- package/src/platform/zrecord/entities/interfaces/ICustomFieldValues.ts +9 -0
- package/src/platform/zrecord/entities/interfaces/IProperties.ts +7 -0
- package/src/platform/zrecord/entities/interfaces/IRecord.ts +6 -0
- package/src/platform/zrecord/entities/interfaces/IRecordName.ts +5 -0
- package/src/platform/zrecord/entities/interfaces/IRecords.ts +20 -0
- package/src/platform/zrecord/entities/interfaces/IRecordsManager.ts +33 -0
- package/src/platform/zrecord/entities/interfaces/ITemplateHelpers.ts +5 -0
- package/src/platform/zrecord/entities/interfaces/MetaData.ts +17 -0
- package/src/platform/zrecord/entities/interfaces/RecordModel.ts +22 -0
- package/src/platform/zrecord/entities/interfaces/RecordsModel.ts +7 -0
- package/src/platform/zrecord/entities/interfaces/apiEnum.ts +1 -0
- package/src/platform/zrecord/frameworks/ActionsHandlersFactory.ts +64 -0
- package/src/platform/zrecord/frameworks/RecordBehaviourFactory.ts +14 -0
- package/src/platform/zrecord/usecases/entities-factory/APITemplatesFactory.ts +27 -0
- package/src/platform/zrecord/usecases/entities-factory/RecordFactory.ts +12 -0
- package/src/platform/zrecord/usecases/entities-factory/RecordsManagerFactory.ts +15 -0
- package/src/platform/zrecord/usecases/interactors/AbstractUseCase.ts +14 -0
- package/src/platform/zrecord/usecases/interactors/AppendRecordsUseCase.ts +18 -0
- package/src/platform/zrecord/usecases/interactors/DeleteMultipleRecordUseCase.ts +16 -0
- package/src/platform/zrecord/usecases/interactors/ExecuteActionUseCase.ts +23 -0
- package/src/platform/zrecord/usecases/interactors/FailureUseCase.ts +20 -0
- package/src/platform/zrecord/usecases/interactors/FetchMoreUseCase.ts +24 -0
- package/src/platform/zrecord/usecases/interactors/FieldChangeUseCase.ts +16 -0
- package/src/platform/zrecord/usecases/interactors/InitializeUseCase.ts +10 -0
- package/src/platform/zrecord/usecases/interactors/NoContentUseCase.ts +22 -0
- package/src/platform/zrecord/usecases/interactors/RecordUpdateLocalUseCase.ts +16 -0
- package/src/platform/zrecord/usecases/interactors/RefetchUseCase.ts +23 -0
- package/src/platform/zrecord/usecases/interactors/SuccessUseCase.ts +25 -0
- package/src/platform/zrecord/usecases/interfaces/InputDependencies.ts +11 -0
- package/src/platform/zrecord/usecases/interfaces/gateways/IRepository.ts +10 -0
- package/src/platform/zrecord/usecases/interfaces/gateways/IService.ts +25 -0
- package/src/platform/zrecord/usecases/interfaces/gateways/ITemplateHelpers.ts +1 -0
- package/src/platform/zrecord/usecases/interfaces/gateways/State.ts +7 -0
- package/src/platform/zrecord/usecases/interfaces/input/AppendRecordsInputModel.ts +7 -0
- package/src/platform/zrecord/usecases/interfaces/input/DeleteMultipleRecordInputModel.ts +6 -0
- package/src/platform/zrecord/usecases/interfaces/input/ExecuteActionInputModel.ts +10 -0
- package/src/platform/zrecord/usecases/interfaces/input/FailureInputModel.ts +8 -0
- package/src/platform/zrecord/usecases/interfaces/input/FetchMoreInputModel.ts +10 -0
- package/src/platform/zrecord/usecases/interfaces/input/FieldChangeUseCaseInput.ts +6 -0
- package/src/platform/zrecord/usecases/interfaces/input/InitializeInputModel.ts +4 -0
- package/src/platform/zrecord/usecases/interfaces/input/NoContentInputModel.ts +7 -0
- package/src/platform/zrecord/usecases/interfaces/input/RecordUpdateLocalUseCaseInputModel.ts +7 -0
- package/src/platform/zrecord/usecases/interfaces/input/RefetchInputModel.ts +10 -0
- package/src/platform/zrecord/usecases/interfaces/input/SuccessInputModel.ts +8 -0
- package/src/platform/zrecord/usecases/interfaces/output/IPresenter.ts +7 -0
- package/tsconfig.json +114 -0
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
export const data = {
|
|
2
|
+
"headers": [
|
|
3
|
+
{
|
|
4
|
+
"id": "textColumn",
|
|
5
|
+
"text": "Text",
|
|
6
|
+
"size": "medium",
|
|
7
|
+
"alignment": "left"
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"id": "emailColumn",
|
|
11
|
+
"text": "Email",
|
|
12
|
+
"size": "large",
|
|
13
|
+
"alignment": "left"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"id": "switchColumn",
|
|
17
|
+
"text": "Switch",
|
|
18
|
+
"size": "medium",
|
|
19
|
+
"alignment": "center"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"id": "linkColumn",
|
|
23
|
+
"text": "Link",
|
|
24
|
+
"size": "medium",
|
|
25
|
+
"alignment": "left"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"id": "checkboxColumn",
|
|
29
|
+
"text": "Checkbox",
|
|
30
|
+
"size": "medium",
|
|
31
|
+
"alignment": "center"
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"id": "avatarColumn",
|
|
35
|
+
"text": "Avatar",
|
|
36
|
+
"size": "medium",
|
|
37
|
+
"alignment": "left"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"id": "statusboxColumn",
|
|
41
|
+
"text": "HighlightedValue",
|
|
42
|
+
"size": "large",
|
|
43
|
+
"alignment": "left"
|
|
44
|
+
}
|
|
45
|
+
],
|
|
46
|
+
"rows": []
|
|
47
|
+
};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
function cellModel(name, text) {
|
|
2
|
+
return { type: 'Text', name, text, style: {} };
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
function getSingleListData(data) {
|
|
6
|
+
return {
|
|
7
|
+
id: data.id,
|
|
8
|
+
columns: [
|
|
9
|
+
cellModel('ID', data.id),
|
|
10
|
+
cellModel('Subject', data.subject),
|
|
11
|
+
cellModel('First Name', data.firstName),
|
|
12
|
+
cellModel('First Name1', data.firstName),
|
|
13
|
+
cellModel('First Name2', data.firstName),
|
|
14
|
+
cellModel('First Name4', data.firstName),
|
|
15
|
+
cellModel('Full Name', data.firstName + ' ' + data.lastName),
|
|
16
|
+
cellModel('Last Name', data.lastName)
|
|
17
|
+
],
|
|
18
|
+
actions: [],
|
|
19
|
+
clickAction: {
|
|
20
|
+
name: 'Click',
|
|
21
|
+
label: 'Detail Page',
|
|
22
|
+
actionName: 'NAVIGATATION',
|
|
23
|
+
actionPayload: {
|
|
24
|
+
url: '/agent/arunalocal/arunalocal/raises/details/' + data.id
|
|
25
|
+
},
|
|
26
|
+
buttonType: 'Primary|Secondary',
|
|
27
|
+
icon: 'ZD-fontedit'
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const items = '*'
|
|
33
|
+
.repeat(200)
|
|
34
|
+
.split('')
|
|
35
|
+
.map((_, i) => ({
|
|
36
|
+
id: `list_ ${1 + i}`,
|
|
37
|
+
subject: `List - ${1 + i}`,
|
|
38
|
+
firstName: `firstName- ${1 + i}`,
|
|
39
|
+
lastName: `lastName- ${1 + i}`
|
|
40
|
+
}));
|
|
41
|
+
|
|
42
|
+
function headingModel(text) {
|
|
43
|
+
return {
|
|
44
|
+
id: text,
|
|
45
|
+
text,
|
|
46
|
+
size: 'large'
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export const data = {
|
|
51
|
+
headers: [
|
|
52
|
+
headingModel('ID'),
|
|
53
|
+
headingModel('Subject'),
|
|
54
|
+
headingModel('First Name'),
|
|
55
|
+
headingModel('First Name1'),
|
|
56
|
+
headingModel('First Name2'),
|
|
57
|
+
headingModel('First Name4'),
|
|
58
|
+
headingModel('Full Name'),
|
|
59
|
+
headingModel('Last Name')
|
|
60
|
+
],
|
|
61
|
+
rows: items.map((item) => getSingleListData(item))
|
|
62
|
+
};
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
export const data = {
|
|
2
|
+
"headers": [
|
|
3
|
+
{
|
|
4
|
+
"id": "nameColumn",
|
|
5
|
+
"text": "Task Name",
|
|
6
|
+
"size": "large",
|
|
7
|
+
"alignment": "left"
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"id": "descColumn",
|
|
11
|
+
"text": "Description",
|
|
12
|
+
"size": "xlarge",
|
|
13
|
+
"alignment": "left"
|
|
14
|
+
}
|
|
15
|
+
],
|
|
16
|
+
"rows": Array.from({length: 4}).map((_, i) => (
|
|
17
|
+
{
|
|
18
|
+
"id": "3760000000046024_"+i,
|
|
19
|
+
"columns": [
|
|
20
|
+
{
|
|
21
|
+
"type": "URLField",
|
|
22
|
+
"value": "https://www.zoho.com"
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"type": "SingleLineField",
|
|
26
|
+
"value": i === 2 ? "Lorem ipsum dolor sit amet." : i === 0 ? "Testing description" : "-"
|
|
27
|
+
}
|
|
28
|
+
],
|
|
29
|
+
"rowActions": [
|
|
30
|
+
{
|
|
31
|
+
"name": "Edit",
|
|
32
|
+
"label": "Edit Page",
|
|
33
|
+
"actionName": "NAVIGATATION",
|
|
34
|
+
"actionPayload": {
|
|
35
|
+
"url": "/agent/arunalocal/arunalocal/raises/edit/3760000000046024"
|
|
36
|
+
},
|
|
37
|
+
"buttonType": "primary",
|
|
38
|
+
"icon": "ZD-GN-edit"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"name": "Delete",
|
|
42
|
+
"label": "Delete",
|
|
43
|
+
"actionName": "DELETE",
|
|
44
|
+
"actionPayload": {
|
|
45
|
+
"id": "3760000000046024"
|
|
46
|
+
},
|
|
47
|
+
"buttonType": "danger",
|
|
48
|
+
"icon": "ZD-GN-delete"
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
"clickAction": {
|
|
52
|
+
"name": "Click",
|
|
53
|
+
"label": "Detail Page",
|
|
54
|
+
"actionName": "NAVIGATATION",
|
|
55
|
+
"actionPayload": {
|
|
56
|
+
"url": "/agent/arunalocal/arunalocal/raises/details/3760000000046024"
|
|
57
|
+
},
|
|
58
|
+
"buttonType": "Primary|Secondary",
|
|
59
|
+
"icon": "ZD-GN-edit"
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
))
|
|
63
|
+
};
|
package/jsconfig.json
ADDED
package/lint.config.js
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
const path = require("path");
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Configuration object for linting and reporting.
|
|
5
|
+
* @property {string} ruleConfigurationPath - The path to the ESLint configuration file.
|
|
6
|
+
* @property {boolean} impactBased - Indicates if the linting is impact-based.
|
|
7
|
+
* @property {string} lintReportPath - The path to the lint report JSON file.
|
|
8
|
+
* @property {string} sonar_host_URL - The URL of the SonarQube server.
|
|
9
|
+
* @property {string} loginName - The username for authentication with the SonarQube server.
|
|
10
|
+
* @property {string} password - The password for authentication with the SonarQube server.
|
|
11
|
+
* @property {string} gitEndPoint - API EndPoint for Git Actions
|
|
12
|
+
* @property {number} projectId - project id of repository
|
|
13
|
+
* @property {string} token - Encrypted Authentication Token
|
|
14
|
+
* @property {string} compareBranch - Branch to compare diff
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
module.exports = {
|
|
19
|
+
ruleConfigurationPath: path.resolve(process.cwd(), ".eslintrc.js"),
|
|
20
|
+
impactBased: true,
|
|
21
|
+
lintReportPath: path.resolve(process.cwd(), "lint-report", "lintReport.json"),
|
|
22
|
+
sonar_hostURL: "https://client-linters.zohodesk.csez.zohocorpin.com",
|
|
23
|
+
metric_token: "zxh_9737850jh2l53ml17223929ihii73072j54j2260",
|
|
24
|
+
branchDiffPath:path.resolve(process.cwd(),"diffBranch.json"),
|
|
25
|
+
gitEndPoint:"https://zgit.csez.zohocorpin.com",
|
|
26
|
+
projectId:`18537`,
|
|
27
|
+
token:"w-OkG3f5OOM1Rkly8phZ",
|
|
28
|
+
compareBranch:'v2'
|
|
29
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"strict": false,
|
|
4
|
+
"target": "es2019",
|
|
5
|
+
"module": "ES6",
|
|
6
|
+
"outDir": "./es",
|
|
7
|
+
"rootDir": "./src",
|
|
8
|
+
"lib": ["es2019", "DOM"],
|
|
9
|
+
"declaration": true,
|
|
10
|
+
"jsx": "react",
|
|
11
|
+
"typeRoots": ["node_modules/@types"],
|
|
12
|
+
"moduleResolution": "node",
|
|
13
|
+
"allowSyntheticDefaultImports": true
|
|
14
|
+
},
|
|
15
|
+
"include": [
|
|
16
|
+
"src/**/*.tsx",
|
|
17
|
+
"src/**/*.ts",
|
|
18
|
+
"src/**/*.js",
|
|
19
|
+
"../my-app/index.tsx",
|
|
20
|
+
"../_old/api json.js"
|
|
21
|
+
],
|
|
22
|
+
"exclude": ["node_modules"]
|
|
23
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@zohodesk/library-platform",
|
|
3
|
+
"version": "1.0.0-exp.1",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "es/index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"download": "react-cli clean ./node_modules ./package-lock.json && npm install",
|
|
8
|
+
"rtl": "react-cli rtl ./src ./es",
|
|
9
|
+
"cssVariableConvert": "react-cli variableConverter ./es ./es",
|
|
10
|
+
"build": "react-cli build:library:es",
|
|
11
|
+
"build:watch": "react-cli clean ./es && npm run build -- -w",
|
|
12
|
+
"test": "react-cli test",
|
|
13
|
+
"prepare": "npm run build && npm run rtl && npm run cssVariableConvert",
|
|
14
|
+
"publish:alpha": "npm publish --tag alpha",
|
|
15
|
+
"publish:beta": "npm publish --tag beta",
|
|
16
|
+
"publish:exp": "npm publish --tag experimental",
|
|
17
|
+
"postpublish": "node ./post_publish.js",
|
|
18
|
+
"lint": "eslint -c .eslintrc.js --ext .ts,.js,.tsx",
|
|
19
|
+
"lint:analytics": "ZDLintingFramework lint",
|
|
20
|
+
"prettify": "node prettify.js staged"
|
|
21
|
+
},
|
|
22
|
+
"author": "",
|
|
23
|
+
"license": "ISC",
|
|
24
|
+
"devDependencies": {
|
|
25
|
+
"@types/react": "18.2.55",
|
|
26
|
+
"@typescript-eslint/parser": "^7.11.0",
|
|
27
|
+
"@zoho/SecurityJS": "5.0.2",
|
|
28
|
+
"@zohodesk-private/css-variable-migrator": "^1.0.7",
|
|
29
|
+
"@zohodesk-private/desk-components": "1.2.0",
|
|
30
|
+
"@zohodesk-private/node-plugins": "1.1.7",
|
|
31
|
+
"@zohodesk/a11y": "2.2.3",
|
|
32
|
+
"@zohodesk/codestandard-analytics": "0.0.1-exp-21",
|
|
33
|
+
"@zohodesk/codestandard-validator": "0.0.3",
|
|
34
|
+
"@zohodesk/components": "1.2.39",
|
|
35
|
+
"@zohodesk/dot": "1.4.18",
|
|
36
|
+
"@zohodesk/eslint-plugin-architecturerules": "0.0.3",
|
|
37
|
+
"@zohodesk/hooks": "2.0.4",
|
|
38
|
+
"@zohodesk/i18n": "1.0.0-beta.26",
|
|
39
|
+
"@zohodesk/icons": "1.0.50",
|
|
40
|
+
"@zohodesk/layout": "3.1.0",
|
|
41
|
+
"@zohodesk/svg": "1.1.15",
|
|
42
|
+
"@zohodesk/utils": "1.3.13",
|
|
43
|
+
"@zohodesk/virtualizer": "1.0.13",
|
|
44
|
+
"color": "4.2.3",
|
|
45
|
+
"dependency-cruiser": "12.0.1",
|
|
46
|
+
"eslint": "^8.26.0",
|
|
47
|
+
"prettier": "3.3.3",
|
|
48
|
+
"typescript": "^4.9.5"
|
|
49
|
+
},
|
|
50
|
+
"peerDependencies": {
|
|
51
|
+
"color": "4.2.3",
|
|
52
|
+
"@zohodesk-private/desk-components": "1.2.0",
|
|
53
|
+
"@zohodesk/a11y": "2.2.3",
|
|
54
|
+
"@zohodesk/components": "1.2.39",
|
|
55
|
+
"@zohodesk/dot": "1.4.18",
|
|
56
|
+
"@zohodesk/hooks": "2.0.4",
|
|
57
|
+
"@zohodesk/i18n": "1.0.0-beta.26",
|
|
58
|
+
"@zohodesk/icons": "1.0.50",
|
|
59
|
+
"@zohodesk/layout": "3.1.0",
|
|
60
|
+
"@zohodesk/svg": "1.1.15",
|
|
61
|
+
"@zohodesk/utils": "1.3.13"
|
|
62
|
+
},
|
|
63
|
+
"dependencies": {
|
|
64
|
+
"@zohodesk/redux-modules": "1.2.1",
|
|
65
|
+
"object-path-immutable": "4.1.2"
|
|
66
|
+
}
|
|
67
|
+
}
|
package/post_publish.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
const path = require('path');
|
|
2
|
+
const { execSync } = require('child_process');
|
|
3
|
+
|
|
4
|
+
// eslint-disable-next-line import/no-dynamic-require
|
|
5
|
+
const { version, name } = require(path.join(process.cwd(), 'package.json'));
|
|
6
|
+
const tagName = `${name}@${version}`;
|
|
7
|
+
// const tagName = `${name.replace(/^@/g, "").replace(/\//g, "-")}-v-${version}}@${version}`;
|
|
8
|
+
|
|
9
|
+
// eslint-disable-next-line no-console
|
|
10
|
+
console.log(`going to add git tag... ${tagName}`);
|
|
11
|
+
|
|
12
|
+
execSync(`git tag -a ${tagName} -m "${tagName}" `, { stdio: 'inherit' });
|
|
13
|
+
execSync(`git push origin ${tagName}`, { stdio: 'inherit' });
|
package/prettify.js
ADDED
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/* eslint-disable no-console */
|
|
2
|
+
|
|
3
|
+
const { execSync } = require('child_process');
|
|
4
|
+
const path = require('path');
|
|
5
|
+
const fs = require('fs');
|
|
6
|
+
|
|
7
|
+
// Get command-line arguments
|
|
8
|
+
const args = process.argv.slice(2);
|
|
9
|
+
const formatStaged = args.includes('staged');
|
|
10
|
+
|
|
11
|
+
// Helper function to run a command and get the output
|
|
12
|
+
const runCommand = command => execSync(command, { encoding: 'utf-8', stdio: 'pipe' }).trim();
|
|
13
|
+
|
|
14
|
+
const listFilesAndFolders = (as = 'separate') => {
|
|
15
|
+
const output = runCommand('ls -p'); // -p appends a slash to directory names
|
|
16
|
+
if (as === 'combined') {
|
|
17
|
+
return output;
|
|
18
|
+
|
|
19
|
+
}
|
|
20
|
+
const items = output.split('\n');
|
|
21
|
+
|
|
22
|
+
const files = items.filter(item => !item.endsWith('/'));
|
|
23
|
+
const folders = items.filter(item => item.endsWith('/')).map(folder => folder.slice(0, -1)); // Remove trailing slash
|
|
24
|
+
|
|
25
|
+
return { files, folders };
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
// Read .gitignore and .prettierignore files
|
|
29
|
+
const readIgnoreFile = filePath => {
|
|
30
|
+
if (fs.existsSync(filePath)) {
|
|
31
|
+
return fs
|
|
32
|
+
.readFileSync(filePath, 'utf-8')
|
|
33
|
+
.split('\n')
|
|
34
|
+
.map(line => line.trim())
|
|
35
|
+
.filter(line => line && !line.startsWith('#'));
|
|
36
|
+
}
|
|
37
|
+
return [];
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
const ignorePatterns = readIgnoreFile(path.join(__dirname, '.prettierignore'));
|
|
41
|
+
|
|
42
|
+
// Helper function to check if a file should be ignored
|
|
43
|
+
const shouldIgnore = file => {
|
|
44
|
+
return ignorePatterns.some(pattern => {
|
|
45
|
+
const regex = new RegExp(
|
|
46
|
+
pattern
|
|
47
|
+
.replace(/[\*\?\[\]\(\)\+\.\|\^\$\{\}]/g, '\\$&')
|
|
48
|
+
.replace(/(\*)+/g, '.*')
|
|
49
|
+
.replace(/(\?)+/g, '.')
|
|
50
|
+
);
|
|
51
|
+
return regex.test(file);
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
// Get all files in the current directory that need formatting
|
|
56
|
+
const getAllFiles = () =>
|
|
57
|
+
listFilesAndFolders('combined')
|
|
58
|
+
.split('\n')
|
|
59
|
+
.filter(file => file && !shouldIgnore(file));
|
|
60
|
+
|
|
61
|
+
// Get all staged files that have changes
|
|
62
|
+
const getStagedFiles = () => {
|
|
63
|
+
const stagedFiles = runCommand('git diff --cached --name-only --diff-filter=ACMR');
|
|
64
|
+
return stagedFiles
|
|
65
|
+
.split('\n')
|
|
66
|
+
.filter(
|
|
67
|
+
file =>
|
|
68
|
+
(file.endsWith('.js') || file.endsWith('.jsx') || file.endsWith('.ts') || file.endsWith('.tsx') || file.endsWith('.json')) &&
|
|
69
|
+
!shouldIgnore(file)
|
|
70
|
+
);
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
// Determine which files to format (default to all if no arguments are provided)
|
|
74
|
+
const filesToFormat = formatStaged ? getStagedFiles() : getAllFiles();
|
|
75
|
+
|
|
76
|
+
// Format each file
|
|
77
|
+
filesToFormat.forEach(file => {
|
|
78
|
+
console.log(`Formatting ${file}...`);
|
|
79
|
+
try {
|
|
80
|
+
execSync(`npx prettier --write "${path.join(__dirname, file)}"`, { stdio: 'inherit' });
|
|
81
|
+
if (formatStaged) {
|
|
82
|
+
execSync(`git add "${path.join(__dirname, file)}"`, { stdio: 'inherit' }); // Re-add the formatted file to staging
|
|
83
|
+
}
|
|
84
|
+
} catch (error) {
|
|
85
|
+
console.error(`Error formatting ${file}:`, error.message);
|
|
86
|
+
process.exit(1);
|
|
87
|
+
}
|
|
88
|
+
});
|
|
89
|
+
|
|
90
|
+
console.log('Formatting complete.');
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
exports.config = {
|
|
2
|
+
enableTypeScript: true,
|
|
3
|
+
css: {
|
|
4
|
+
cssVariableReplacementConfig: './node_modules/@zohodesk-private/css-variable-migrator/es/config/cssVariableReplacementOptions.json'
|
|
5
|
+
},
|
|
6
|
+
babelCustomizationForLibrary: {
|
|
7
|
+
babelPlugins: ['@babel/plugin-proposal-optional-chaining', '@babel/plugin-proposal-class-properties']
|
|
8
|
+
},
|
|
9
|
+
alias: {
|
|
10
|
+
'@library': './src/library',
|
|
11
|
+
'@platform': './src/platform',
|
|
12
|
+
'@bc': './src/bc',
|
|
13
|
+
'@cc': './src/cc'
|
|
14
|
+
}
|
|
15
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import EventHandlers, { EventHandler } from '@cc/component/EventHandlers';
|
|
2
|
+
import { LIST_SELECTION_TOGGLE_ALL, LIST_SELECTION_TOGGLE_ITEMS, LIST_SELECTION_TOGGLE_ITEMS_IN_RANGE } from './Constants';
|
|
3
|
+
|
|
4
|
+
interface ListSelectionActionHandlers extends EventHandlers {
|
|
5
|
+
[LIST_SELECTION_TOGGLE_ITEMS]: EventHandler;
|
|
6
|
+
[LIST_SELECTION_TOGGLE_ALL]: EventHandler;
|
|
7
|
+
[LIST_SELECTION_TOGGLE_ITEMS_IN_RANGE]: EventHandler;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export default ListSelectionActionHandlers;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import Action from '@cc/component/Action';
|
|
2
|
+
import { LIST_SELECTION_TOGGLE_ALL, LIST_SELECTION_TOGGLE_ITEMS, LIST_SELECTION_TOGGLE_ITEMS_IN_RANGE } from './Constants';
|
|
3
|
+
|
|
4
|
+
const Actions: Action[] = [
|
|
5
|
+
{
|
|
6
|
+
type: LIST_SELECTION_TOGGLE_ITEMS,
|
|
7
|
+
payload: {
|
|
8
|
+
selected: {
|
|
9
|
+
name: 'selected',
|
|
10
|
+
typeMetadata: {
|
|
11
|
+
schema: {
|
|
12
|
+
type: 'array'
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
type: LIST_SELECTION_TOGGLE_ALL,
|
|
20
|
+
payload: {}
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
type: LIST_SELECTION_TOGGLE_ITEMS_IN_RANGE,
|
|
24
|
+
payload: {
|
|
25
|
+
startIndex: {
|
|
26
|
+
name: 'startIndex',
|
|
27
|
+
typeMetadata: {
|
|
28
|
+
schema: {
|
|
29
|
+
type: 'number'
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
endIndex: {
|
|
34
|
+
name: 'endIndex',
|
|
35
|
+
typeMetadata: {
|
|
36
|
+
schema: {
|
|
37
|
+
type: 'number'
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
];
|
|
44
|
+
|
|
45
|
+
export default Actions;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
type: 'object',
|
|
3
|
+
properties: {
|
|
4
|
+
isEnabled: {
|
|
5
|
+
type: 'boolean',
|
|
6
|
+
defaultValue: false
|
|
7
|
+
},
|
|
8
|
+
maxSelectionCount: {
|
|
9
|
+
type: 'number',
|
|
10
|
+
defaultValue: 50
|
|
11
|
+
},
|
|
12
|
+
limitExceedAlertMessage: {
|
|
13
|
+
type: 'string',
|
|
14
|
+
defaultValue: 'Max records selected'
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const UPDATE_REQUESTED: string = 'LOCAL_STORAGE#UPDATE_REQUESTED';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import SortOrder from './SortOrderEnum';
|
|
2
|
+
|
|
3
|
+
export default {
|
|
4
|
+
required: false,
|
|
5
|
+
defaultValue: {
|
|
6
|
+
id: '',
|
|
7
|
+
type: 'none'
|
|
8
|
+
},
|
|
9
|
+
typeMetadata: {
|
|
10
|
+
schema: {
|
|
11
|
+
id: {
|
|
12
|
+
required: true,
|
|
13
|
+
type: 'string'
|
|
14
|
+
},
|
|
15
|
+
order: {
|
|
16
|
+
type: 'string',
|
|
17
|
+
enum: Object.values(SortOrder),
|
|
18
|
+
defaultValue: 'none'
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import ActionHandlers, {
|
|
2
|
+
ActionHandler
|
|
3
|
+
} from '../../cc/component/ActionHandlers';
|
|
4
|
+
|
|
5
|
+
export default interface TableColumnResizerActionHandlers
|
|
6
|
+
extends ActionHandlers {
|
|
7
|
+
'TABLE_COLUMN_RESIZER#RESIZE_STARTED': ActionHandler;
|
|
8
|
+
'TABLE_COLUMN_RESIZER#RESIZE_MOUSE_MOVED': ActionHandler;
|
|
9
|
+
'TABLE_COLUMN_RESIZER#RESIZE_SCROLL_MOVED': ActionHandler;
|
|
10
|
+
'TABLE_COLUMN_RESIZER#RESIZE_ENDED': ActionHandler;
|
|
11
|
+
'TABLE_COLUMN_RESIZER#RESIZE_FINISHED': ActionHandler;
|
|
12
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export const RESIZE_STARTED: string = 'TABLE_COLUMN_RESIZER#RESIZE_STARTED';
|
|
2
|
+
|
|
3
|
+
export const RESIZE_MOUSE_MOVED: string = 'TABLE_COLUMN_RESIZER#RESIZE_MOUSE_MOVED';
|
|
4
|
+
|
|
5
|
+
export const RESIZE_SCROLL_MOVED: string = 'TABLE_COLUMN_RESIZER#RESIZE_SCROLL_MOVED';
|
|
6
|
+
|
|
7
|
+
export const RESIZE_ENDED: string = 'TABLE_COLUMN_RESIZER#RESIZE_ENDED';
|
|
8
|
+
|
|
9
|
+
export const RESIZE_FINISHED: string = 'TABLE_COLUMN_RESIZER#RESIZE_FINISHED';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
type: 'object',
|
|
3
|
+
properties: {
|
|
4
|
+
isEnabled: {
|
|
5
|
+
type: 'boolean',
|
|
6
|
+
defaultValue: false
|
|
7
|
+
},
|
|
8
|
+
minWidth: {
|
|
9
|
+
type: 'number',
|
|
10
|
+
defaultValue: 120
|
|
11
|
+
},
|
|
12
|
+
maxWidth: {
|
|
13
|
+
type: 'number',
|
|
14
|
+
defaultValue: 1000
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
required: ['isEnabled']
|
|
18
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import ActionHandlers, { ActionHandler } from '@cc/component/ActionHandlers';
|
|
2
|
+
import { FIELD_EXECUTE, FIELD_REFETCH } from './Constants';
|
|
3
|
+
import { FETCH_FAILED, FETCH_SUCCESS, FETCH_SUCCESS_NO_CONTENT } from '@bc/zhttp/Constants';
|
|
4
|
+
|
|
5
|
+
interface ZFieldActionHandlers extends ActionHandlers {
|
|
6
|
+
[FIELD_REFETCH]: ActionHandler;
|
|
7
|
+
[FIELD_EXECUTE]: ActionHandler;
|
|
8
|
+
[FETCH_SUCCESS]: ActionHandler;
|
|
9
|
+
[FETCH_SUCCESS_NO_CONTENT]: ActionHandler;
|
|
10
|
+
[FETCH_FAILED]: ActionHandler;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export default ZFieldActionHandlers;
|