@myparcel-dev/pdk-admin 2.1.0 → 2.2.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/CHANGELOG.md +15 -0
- package/dist/__tests__/doComponentTestSetup.d.ts +2 -0
- package/dist/__tests__/doComponentTestTeardown.d.ts +1 -0
- package/dist/__tests__/index.d.ts +3 -0
- package/dist/__tests__/mocks/index.d.ts +14 -0
- package/dist/__tests__/mocks/mockDefaultAccount.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultAppConfig.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultAppInfo.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultCarriers.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultConfig.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultDynamicContext.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultEndpoints.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultGlobalContext.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultLogger.d.ts +1 -0
- package/dist/__tests__/mocks/mockDefaultPluginSettings.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultPrintOptionsView.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultProposition.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultShop.d.ts +2 -0
- package/dist/__tests__/mocks/mockDefaultTranslations.d.ts +2 -0
- package/dist/actions/composables/index.d.ts +2 -0
- package/dist/actions/composables/mutations/account/index.d.ts +2 -0
- package/dist/actions/composables/mutations/account/useDeleteAccountMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/account/useUpdateAccountMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/debug/index.d.ts +3 -0
- package/dist/actions/composables/mutations/debug/useDownloadLogsMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/debug/useSwitchToAcceptanceApiMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/debug/useSwitchToProductionApiMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/index.d.ts +7 -0
- package/dist/actions/composables/mutations/orders/index.d.ts +3 -0
- package/dist/actions/composables/mutations/orders/useExportOrdersMutation.d.ts +5 -0
- package/dist/actions/composables/mutations/orders/usePrintOrdersMutation.d.ts +4 -0
- package/dist/actions/composables/mutations/orders/useUpdateOrdersMutation.d.ts +4 -0
- package/dist/actions/composables/mutations/settings/index.d.ts +2 -0
- package/dist/actions/composables/mutations/settings/useUpdatePluginSettingsMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/settings/useUpdateProductSettingsMutation.d.ts +3 -0
- package/dist/actions/composables/mutations/shipments/index.d.ts +4 -0
- package/dist/actions/composables/mutations/shipments/useDeleteShipmentsMutation.d.ts +4 -0
- package/dist/actions/composables/mutations/shipments/useExportReturnMutation.d.ts +4 -0
- package/dist/actions/composables/mutations/shipments/usePrintShipmentsMutation.d.ts +4 -0
- package/dist/actions/composables/mutations/shipments/useUpdateShipmentsMutation.d.ts +4 -0
- package/dist/actions/composables/mutations/usePdkMutation.d.ts +15 -0
- package/dist/actions/composables/mutations/webhooks/index.d.ts +2 -0
- package/dist/actions/composables/mutations/webhooks/useCreateWebhooksMutation.d.ts +1 -0
- package/dist/actions/composables/mutations/webhooks/useDeleteWebhooksMutation.d.ts +3 -0
- package/dist/actions/composables/queries/account/index.d.ts +1 -0
- package/dist/actions/composables/queries/account/useFetchContextQuery.d.ts +3 -0
- package/dist/actions/composables/queries/account/useOrderCapabilitiesQuery.d.ts +29 -0
- package/dist/actions/composables/queries/account/useShipmentCapabilitiesQuery.d.ts +45 -0
- package/dist/actions/composables/queries/index.d.ts +6 -0
- package/dist/actions/composables/queries/orders/index.d.ts +1 -0
- package/dist/actions/composables/queries/orders/useFetchOrdersQuery.d.ts +3 -0
- package/dist/actions/composables/queries/products/index.d.ts +1 -0
- package/dist/actions/composables/queries/products/useFetchProductsQuery.d.ts +3 -0
- package/dist/actions/composables/queries/queryKeys.d.ts +2 -0
- package/dist/actions/composables/queries/shipments/index.d.ts +1 -0
- package/dist/actions/composables/queries/shipments/useFetchShipmentsQuery.d.ts +4 -0
- package/dist/actions/composables/queries/webhooks/index.d.ts +1 -0
- package/dist/actions/composables/queries/webhooks/useFetchWebhooksQuery.d.ts +3 -0
- package/dist/actions/defineAction.d.ts +8 -0
- package/dist/actions/definitions/account.d.ts +13 -0
- package/dist/actions/definitions/context.d.ts +6 -0
- package/dist/actions/definitions/debug.d.ts +13 -0
- package/dist/actions/definitions/index.d.ts +8 -0
- package/dist/actions/definitions/modal.d.ts +17 -0
- package/dist/actions/definitions/orders.d.ts +39 -0
- package/dist/actions/definitions/settings.d.ts +2 -0
- package/dist/actions/definitions/shipments.d.ts +15 -0
- package/dist/actions/definitions/webhooks.d.ts +4 -0
- package/dist/actions/executors/createHandlerWithParameters.d.ts +5 -0
- package/dist/actions/executors/createMutationHandler.d.ts +3 -0
- package/dist/actions/executors/createOrdersMutationHandler.d.ts +3 -0
- package/dist/actions/executors/createQueryHandler.d.ts +3 -0
- package/dist/actions/executors/createShipmentsMutationHandler.d.ts +3 -0
- package/dist/actions/executors/doMutate.d.ts +4 -0
- package/dist/actions/executors/executeAction.d.ts +6 -0
- package/dist/actions/executors/executeAfterHandle.d.ts +3 -0
- package/dist/actions/executors/executeBeforeHandle.d.ts +4 -0
- package/dist/actions/executors/executeHandler.d.ts +3 -0
- package/dist/actions/executors/executeNextAction.d.ts +6 -0
- package/dist/actions/executors/index.d.ts +14 -0
- package/dist/actions/executors/resolveOrderParameters.d.ts +3 -0
- package/dist/actions/executors/resolveQuerySuffix.d.ts +3 -0
- package/dist/actions/executors/types.d.ts +19 -0
- package/dist/actions/index.d.ts +7 -0
- package/dist/actions/orderModeActions.d.ts +37 -0
- package/dist/actions/print/index.d.ts +3 -0
- package/dist/actions/print/openOrPrintPdf.d.ts +3 -0
- package/dist/actions/print/resolvePrintParameters.d.ts +3 -0
- package/dist/actions/print/waitForLabelPrompt.d.ts +3 -0
- package/dist/actions/stopActionHandler.d.ts +2 -0
- package/dist/components/OrderBox/OrderShipmentsTable.vue.d.ts +7 -0
- package/dist/components/OrderBox/OrderShipmentsTableRow.vue.d.ts +19 -0
- package/dist/components/OrderBox/ShipmentOptionsBox.vue.d.ts +3 -0
- package/dist/components/OrderBox/ShipmentTableBox.vue.d.ts +3 -0
- package/dist/components/OrderListItem/OrderModeOrderListItem.vue.d.ts +3 -0
- package/dist/components/OrderListItem/ShipmentLabel.vue.d.ts +14 -0
- package/dist/components/OrderListItem/ShipmentModeOrderListItem.vue.d.ts +3 -0
- package/dist/components/PluginSettings/AccountSettings.vue.d.ts +3 -0
- package/dist/components/PluginSettings/DebugOptions.vue.d.ts +3 -0
- package/dist/components/PluginSettings/EditApiKeyForm.vue.d.ts +8 -0
- package/dist/components/PluginSettings/PluginSettingsForms.vue.d.ts +3 -0
- package/dist/components/PluginSettings/WebhooksStatus.vue.d.ts +3 -0
- package/dist/components/PluginSettings/createUpdateAccountSettingsValidator.d.ts +4 -0
- package/dist/components/common/ActionButton.vue.d.ts +48 -0
- package/dist/components/common/BulkSelectCheckbox.vue.d.ts +20 -0
- package/dist/components/common/CarrierLogo.vue.d.ts +15 -0
- package/dist/components/common/DateRelative.vue.d.ts +15 -0
- package/dist/components/common/DeliveryOptionsDeliveryType.vue.d.ts +15 -0
- package/dist/components/common/DeliveryOptionsExcerpt.vue.d.ts +3 -0
- package/dist/components/common/DeliveryOptionsExcerptCarrierName.vue.d.ts +15 -0
- package/dist/components/common/DeliveryOptionsPackageType.vue.d.ts +15 -0
- package/dist/components/common/DigitalStampWeightRange.vue.d.ts +14 -0
- package/dist/components/common/NotificationContainer.vue.d.ts +17 -0
- package/dist/components/common/PackageType.vue.d.ts +15 -0
- package/dist/components/common/PlainElement.d.ts +2 -0
- package/dist/components/common/ResetButton.vue.d.ts +14 -0
- package/dist/components/common/ReturnsForm.vue.d.ts +15 -0
- package/dist/components/common/ShipmentBarcode.vue.d.ts +14 -0
- package/dist/components/common/ShipmentOptionsForm.vue.d.ts +15 -0
- package/dist/components/common/ShipmentStatus.vue.d.ts +14 -0
- package/dist/components/common/StatusIndicator.vue.d.ts +27 -0
- package/dist/components/common/SubmitButton.vue.d.ts +14 -0
- package/dist/components/common/TabNavigation.vue.d.ts +70 -0
- package/dist/components/common/index.d.ts +20 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/modals/PrintOptionsModal.vue.d.ts +3 -0
- package/dist/components/modals/PrintOptionsModalForm.vue.d.ts +3 -0
- package/dist/components/modals/ShipmentOptionsModal.vue.d.ts +3 -0
- package/dist/components/modals/ShipmentOptionsModalForm.vue.d.ts +15 -0
- package/dist/composables/components/index.d.ts +15 -0
- package/dist/composables/components/useBulkSelectCheckbox.d.ts +9 -0
- package/dist/composables/components/useCheckboxGroupContext.d.ts +4 -0
- package/dist/composables/components/useDropOffInputContext.d.ts +13 -0
- package/dist/composables/components/useDropdownButtonContext.d.ts +15 -0
- package/dist/composables/components/useElementContext.d.ts +7 -0
- package/dist/composables/components/useElementOptions.d.ts +6 -0
- package/dist/composables/components/useInputWithOptionsContext.d.ts +10 -0
- package/dist/composables/components/useModalElementContext.d.ts +11 -0
- package/dist/composables/components/useMultiSelectInputContext.d.ts +4 -0
- package/dist/composables/components/useRadioGroupContext.d.ts +10 -0
- package/dist/composables/components/useSelectInputContext.d.ts +4 -0
- package/dist/composables/components/useShippingMethodsInputContext.d.ts +13 -0
- package/dist/composables/components/useTableContext.d.ts +7 -0
- package/dist/composables/components/useToggleInputContext.d.ts +11 -0
- package/dist/composables/components/useTriStateInputContext.d.ts +17 -0
- package/dist/composables/context/index.d.ts +8 -0
- package/dist/composables/context/useAppInfo.d.ts +2 -0
- package/dist/composables/context/useContext.d.ts +3 -0
- package/dist/composables/context/useGlobalContext.d.ts +2 -0
- package/dist/composables/context/useInstanceContext.d.ts +8 -0
- package/dist/composables/context/useModalContext.d.ts +11 -0
- package/dist/composables/context/useModalOrder.d.ts +1 -0
- package/dist/composables/context/useOrderMode.d.ts +12 -0
- package/dist/composables/context/usePluginSettings.d.ts +2 -0
- package/dist/composables/formatter/default/createCurrencyFormat.d.ts +1 -0
- package/dist/composables/formatter/default/createLongDateFormat.d.ts +1 -0
- package/dist/composables/formatter/default/createRelativeTimeFormat.d.ts +1 -0
- package/dist/composables/formatter/default/defaultCurrencyFormatters.d.ts +2 -0
- package/dist/composables/formatter/default/defaultDateFormatters.d.ts +4 -0
- package/dist/composables/formatter/default/index.d.ts +6 -0
- package/dist/composables/formatter/default/parseDate.d.ts +1 -0
- package/dist/composables/formatter/formatter.types.d.ts +23 -0
- package/dist/composables/formatter/index.d.ts +4 -0
- package/dist/composables/formatter/useFormatter.d.ts +2 -0
- package/dist/composables/formatter/useLocalizedFormatter.d.ts +2 -0
- package/dist/composables/index.d.ts +17 -0
- package/dist/composables/language/index.d.ts +4 -0
- package/dist/composables/language/resolveTranslatedString.d.ts +3 -0
- package/dist/composables/language/resolveTranslationKey.d.ts +2 -0
- package/dist/composables/language/types.d.ts +1 -0
- package/dist/composables/language/useLanguage.d.ts +23 -0
- package/dist/composables/orders/index.d.ts +3 -0
- package/dist/composables/orders/useOrder.d.ts +3 -0
- package/dist/composables/orders/useOrderData.d.ts +9 -0
- package/dist/composables/orders/useOrdersData.d.ts +3 -0
- package/dist/composables/products/index.d.ts +1 -0
- package/dist/composables/products/useProductData.d.ts +8 -0
- package/dist/composables/shipments/index.d.ts +3 -0
- package/dist/composables/shipments/useShipment.d.ts +3 -0
- package/dist/composables/shipments/useShipmentData.d.ts +12 -0
- package/dist/composables/shipments/useShipmentsData.d.ts +2 -0
- package/dist/composables/useAdminConfig.d.ts +2 -0
- package/dist/composables/useAdminInstance.d.ts +2 -0
- package/dist/composables/useDigitalStampRanges.d.ts +12 -0
- package/dist/composables/useGlobalPdkAdmin.d.ts +2 -0
- package/dist/composables/useLoadMore.d.ts +14 -0
- package/dist/composables/useLoading.d.ts +10 -0
- package/dist/composables/useLogger.d.ts +2 -0
- package/dist/composables/useStoreContextQuery.d.ts +3 -0
- package/dist/composables/useStoreQuery.d.ts +4 -0
- package/dist/composables/useWeekdays.d.ts +9 -0
- package/dist/data/components.d.ts +195 -0
- package/dist/data/constants.d.ts +63 -0
- package/dist/data/endpoints.d.ts +5 -0
- package/dist/data/index.d.ts +5 -0
- package/dist/data/orderMode.d.ts +25 -0
- package/dist/data/view.d.ts +9 -0
- package/dist/deprecated.d.ts +6 -0
- package/dist/forms/createReturnsForm.d.ts +1 -0
- package/dist/forms/form-builder/builders/buildAfterUpdate.d.ts +3 -0
- package/dist/forms/form-builder/builders/buildFormStateWatcher.d.ts +3 -0
- package/dist/forms/form-builder/builders/index.d.ts +2 -0
- package/dist/forms/form-builder/conditions/index.d.ts +3 -0
- package/dist/forms/form-builder/conditions/validateIfCondition.d.ts +2 -0
- package/dist/forms/form-builder/conditions/validateIfConditions.d.ts +2 -0
- package/dist/forms/form-builder/conditions/validateIsTruthy.d.ts +2 -0
- package/dist/forms/form-builder/index.d.ts +5 -0
- package/dist/forms/form-builder/operations/executeCustomOperationHandlers.d.ts +2 -0
- package/dist/forms/form-builder/operations/executeOperation.d.ts +2 -0
- package/dist/forms/form-builder/operations/executeOperations.d.ts +2 -0
- package/dist/forms/form-builder/operations/executeSetPropOperation.d.ts +2 -0
- package/dist/forms/form-builder/operations/executeSetValueOperation.d.ts +2 -0
- package/dist/forms/form-builder/operations/index.d.ts +5 -0
- package/dist/forms/form-builder/operations/parseBuilders.d.ts +3 -0
- package/dist/forms/form-builder/types/FormCondition.types.d.ts +36 -0
- package/dist/forms/form-builder/types/FormOperations.types.d.ts +16 -0
- package/dist/forms/form-builder/types/SubOperationBuilder.types.d.ts +13 -0
- package/dist/forms/form-builder/types/common.types.d.ts +21 -0
- package/dist/forms/form-builder/types/index.d.ts +4 -0
- package/dist/forms/form-builder/utils/createPropSetter.d.ts +4 -0
- package/dist/forms/form-builder/utils/createValueGetter.d.ts +4 -0
- package/dist/forms/form-builder/utils/createValueSetter.d.ts +11 -0
- package/dist/forms/form-builder/utils/index.d.ts +4 -0
- package/dist/forms/formKeys.d.ts +10 -0
- package/dist/forms/helpers/addBulkEditNotification.d.ts +1 -0
- package/dist/forms/helpers/addCapabilitiesClearNotification.d.ts +15 -0
- package/dist/forms/helpers/createDefaultOption.d.ts +3 -0
- package/dist/forms/helpers/createLabel.d.ts +1 -0
- package/dist/forms/helpers/defineFormField.d.ts +2 -0
- package/dist/forms/helpers/getDeliveryTypes.d.ts +3 -0
- package/dist/forms/helpers/getFieldLabel.d.ts +7 -0
- package/dist/forms/helpers/getFormCarrierName.d.ts +2 -0
- package/dist/forms/helpers/getPackageTypes.d.ts +3 -0
- package/dist/forms/helpers/index.d.ts +14 -0
- package/dist/forms/helpers/resolveFormComponent.d.ts +3 -0
- package/dist/forms/helpers/setFieldProp.d.ts +8 -0
- package/dist/forms/helpers/triStateFieldIsEnabled.d.ts +2 -0
- package/dist/forms/helpers/updateFieldsDefaults.d.ts +6 -0
- package/dist/forms/helpers/useFormCapabilities.d.ts +66 -0
- package/dist/forms/index.d.ts +6 -0
- package/dist/forms/pluginSettings/createFormTab.d.ts +3 -0
- package/dist/forms/pluginSettings/createPluginSettingsForm.d.ts +4 -0
- package/dist/forms/pluginSettings/createPluginSettingsTabs.d.ts +4 -0
- package/dist/forms/pluginSettings/createPluginSettingsTabsComponent.d.ts +4 -0
- package/dist/forms/pluginSettings/filterPluginSettingsView.d.ts +15 -0
- package/dist/forms/pluginSettings/generateFormFields.d.ts +8 -0
- package/dist/forms/pluginSettings/index.d.ts +7 -0
- package/dist/forms/pluginSettings/resolveSettingsValues.d.ts +8 -0
- package/dist/forms/pluginSettings/types.d.ts +13 -0
- package/dist/forms/shipmentOptions/createShipmentOptionsForm.d.ts +4 -0
- package/dist/forms/shipmentOptions/field.d.ts +22 -0
- package/dist/forms/shipmentOptions/fieldFactoryRegistry.d.ts +21 -0
- package/dist/forms/shipmentOptions/fields/createCarrierField.d.ts +4 -0
- package/dist/forms/shipmentOptions/fields/createDeliveryTypeField.d.ts +3 -0
- package/dist/forms/shipmentOptions/fields/createDigitalStampRangeField.d.ts +4 -0
- package/dist/forms/shipmentOptions/fields/createDimensionFields.d.ts +3 -0
- package/dist/forms/shipmentOptions/fields/createInsuranceField.d.ts +17 -0
- package/dist/forms/shipmentOptions/fields/createLabelAmountField.d.ts +3 -0
- package/dist/forms/shipmentOptions/fields/createPackageTypeField.d.ts +3 -0
- package/dist/forms/shipmentOptions/fields/createRef.d.ts +3 -0
- package/dist/forms/shipmentOptions/fields/createShipmentOptionField.d.ts +15 -0
- package/dist/forms/shipmentOptions/fields/index.d.ts +7 -0
- package/dist/forms/shipmentOptions/index.d.ts +4 -0
- package/dist/forms/shipmentOptions/types.d.ts +2 -0
- package/dist/forms/shipmentOptions/useCapabilitiesAutoClear.d.ts +36 -0
- package/dist/forms/shipmentOptions/useCapabilitiesWatcher.d.ts +22 -0
- package/dist/forms/shipmentOptions/wireProxyCapabilities.d.ts +31 -0
- package/dist/index.d.ts +19 -0
- package/dist/pdk/PdkAdmin.d.ts +18 -0
- package/dist/pdk/boot.d.ts +3 -0
- package/dist/pdk/createAdminConfig.d.ts +2 -0
- package/dist/pdk/createPdkAdmin.d.ts +8 -0
- package/dist/pdk/createPdkAdminPlugin.d.ts +3 -0
- package/dist/pdk/fillShipmentsQueryData.d.ts +4 -0
- package/dist/pdk/index.d.ts +11 -0
- package/dist/pdk/instance/createInstanceContext.d.ts +5 -0
- package/dist/pdk/instance/createQueryClient.d.ts +2 -0
- package/dist/pdk/instance/index.d.ts +3 -0
- package/dist/pdk/instance/plugins/createContextPlugin.d.ts +2 -0
- package/dist/pdk/instance/plugins/createLoggerPlugin.d.ts +2 -0
- package/dist/pdk/instance/plugins/createRegisterComponentsPlugin.d.ts +5 -0
- package/dist/pdk/instance/plugins/createStorePlugin.d.ts +2 -0
- package/dist/pdk/instance/plugins/createVueQueryPlugin.d.ts +5 -0
- package/dist/pdk/instance/plugins/index.d.ts +6 -0
- package/dist/pdk/instance/plugins/plugins.types.d.ts +3 -0
- package/dist/pdk/renderMap.d.ts +3 -0
- package/dist/pdk/sendBootEvent.d.ts +3 -0
- package/dist/pdk/setupAdminApp.d.ts +3 -0
- package/dist/pdk/testIdDirective.d.ts +5 -0
- package/dist/sdk/PdkFetchClient.d.ts +11 -0
- package/dist/sdk/composables/api/index.d.ts +1 -0
- package/dist/sdk/composables/api/useFetchCarrier.d.ts +1 -0
- package/dist/sdk/composables/index.d.ts +3 -0
- package/dist/sdk/composables/useMyParcelApi.d.ts +5 -0
- package/dist/sdk/composables/usePdkAdminApi.d.ts +6 -0
- package/dist/sdk/endpoints/abstractPdkEndpoint.d.ts +7 -0
- package/dist/sdk/endpoints/index.d.ts +1 -0
- package/dist/sdk/index.d.ts +3 -0
- package/dist/services/actions/createAction.d.ts +4 -0
- package/dist/services/actions/createActionContext.d.ts +3 -0
- package/dist/services/actions/downloadFile.d.ts +4 -0
- package/dist/services/actions/getActionIdentifier.d.ts +2 -0
- package/dist/services/actions/index.d.ts +4 -0
- package/dist/services/addErrorToNotifications.d.ts +2 -0
- package/dist/services/context/getElementContext.d.ts +2 -0
- package/dist/services/context/index.d.ts +1 -0
- package/dist/services/createNotification.d.ts +5 -0
- package/dist/services/index.d.ts +9 -0
- package/dist/services/instantiateAction.d.ts +2 -0
- package/dist/services/instantiateActions.d.ts +8 -0
- package/dist/services/logger.d.ts +19 -0
- package/dist/services/mutations/getCallbackForMutationMode.d.ts +4 -0
- package/dist/services/mutations/getModalMutationOptions.d.ts +2 -0
- package/dist/services/mutations/index.d.ts +3 -0
- package/dist/services/mutations/mutationMode.d.ts +4 -0
- package/dist/services/print/index.d.ts +1 -0
- package/dist/services/print/openPdfInNewWindow.d.ts +4 -0
- package/dist/stores/createQueryCacheKey.d.ts +3 -0
- package/dist/stores/index.d.ts +6 -0
- package/dist/stores/types.d.ts +13 -0
- package/dist/stores/useActionStore.d.ts +25 -0
- package/dist/stores/useModalStore.d.ts +16 -0
- package/dist/stores/useNotificationStore.d.ts +60 -0
- package/dist/stores/useQueryStore.d.ts +80 -0
- package/dist/symbols.d.ts +5 -0
- package/dist/testing.d.ts +1 -0
- package/dist/types/actions/actions.types.d.ts +31 -0
- package/dist/types/actions/endpoints.types.d.ts +9 -0
- package/dist/types/actions/index.d.ts +4 -0
- package/dist/types/actions/parameters.types.d.ts +55 -0
- package/dist/types/actions/response.types.d.ts +7 -0
- package/dist/types/actions.types.d.ts +45 -0
- package/dist/types/admin.types.d.ts +26 -0
- package/dist/types/common.types.d.ts +53 -0
- package/dist/types/components-form.types.d.ts +107 -0
- package/dist/types/components.types.d.ts +273 -0
- package/dist/types/configuration.types.d.ts +95 -0
- package/dist/types/context.types.d.ts +20 -0
- package/dist/types/endpoints.types.d.ts +7 -0
- package/dist/types/form.types.d.ts +39 -0
- package/dist/types/index.d.ts +12 -0
- package/dist/types/language.types.d.ts +9 -0
- package/dist/types/sdk.types.d.ts +212 -0
- package/dist/utils/booleanToTriState.d.ts +2 -0
- package/dist/utils/convertDotNotationToObject.d.ts +1 -0
- package/dist/utils/createAssetUrl.d.ts +1 -0
- package/dist/utils/createClasses.d.ts +8 -0
- package/dist/utils/createObjectWithKeys.d.ts +3 -0
- package/dist/utils/decodeHtmlEntities.d.ts +7 -0
- package/dist/utils/downloadBlob.d.ts +1 -0
- package/dist/utils/downloadFileFromUrl.d.ts +1 -0
- package/dist/utils/encodeArrayParameter.d.ts +2 -0
- package/dist/utils/extendAdminInstance.d.ts +2 -0
- package/dist/utils/fakeLinkClick.d.ts +4 -0
- package/dist/utils/forms/createFormElement.d.ts +3 -0
- package/dist/utils/forms/createShipmentFormName.d.ts +1 -0
- package/dist/utils/forms/formToBody.d.ts +2 -0
- package/dist/utils/forms/generateFieldId.d.ts +3 -0
- package/dist/utils/forms/getEnabledValues.d.ts +11 -0
- package/dist/utils/forms/index.d.ts +5 -0
- package/dist/utils/generateLabelFilename.d.ts +3 -0
- package/dist/utils/getOrderId.d.ts +3 -0
- package/dist/utils/getOrderShipmentIds.d.ts +2 -0
- package/dist/utils/index.d.ts +22 -0
- package/dist/utils/openUrlInNewTab.d.ts +1 -0
- package/dist/utils/prefixComponent.d.ts +3 -0
- package/dist/utils/query/index.d.ts +3 -0
- package/dist/utils/query/setQueryData.d.ts +2 -0
- package/dist/utils/query/setQueryOrder.d.ts +10 -0
- package/dist/utils/query/setQueryShipment.d.ts +3 -0
- package/dist/utils/resolveCarrier.d.ts +1 -0
- package/dist/utils/translations/getDeliveryTypeTranslation.d.ts +2 -0
- package/dist/utils/translations/getDynamicTranslation.d.ts +1 -0
- package/dist/utils/translations/getPackageTypeTranslation.d.ts +2 -0
- package/dist/utils/translations/index.d.ts +4 -0
- package/dist/utils/translations/translateSelectOption.d.ts +3 -0
- package/dist/utils/triStateToBoolean.d.ts +2 -0
- package/dist/utils/unprefixComponent.d.ts +3 -0
- package/dist/utils/validateId.d.ts +2 -0
- package/dist/views/ChildProductSettings.vue.d.ts +3 -0
- package/dist/views/Modals.vue.d.ts +3 -0
- package/dist/views/Notifications.vue.d.ts +3 -0
- package/dist/views/OrderBox.vue.d.ts +3 -0
- package/dist/views/OrderListItem.vue.d.ts +3 -0
- package/dist/views/PluginSettings.vue.d.ts +3 -0
- package/dist/views/ProductSettings.vue.d.ts +35 -0
- package/dist/views/integrated/OrderBoxView.vue.d.ts +13 -0
- package/dist/views/integrated/OrderListItemView.vue.d.ts +13 -0
- package/dist/views/integrated/index.d.ts +7 -0
- package/package.json +5 -6
- package/src/forms/shipmentOptions/createShipmentOptionsForm.spec.ts +1 -0
- package/src/forms/shipmentOptions/createShipmentOptionsForm.ts +21 -2
- package/src/forms/shipmentOptions/field.ts +12 -0
- package/src/forms/shipmentOptions/fields/createDimensionFields.spec.ts +49 -0
- package/src/forms/shipmentOptions/fields/createDimensionFields.ts +32 -0
- package/src/forms/shipmentOptions/fields/index.ts +1 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type ComputedRef } from 'vue';
|
|
2
|
+
import { type MaybeRef } from '@vueuse/core';
|
|
3
|
+
import { type Plugin } from '@myparcel-dev/pdk-common';
|
|
4
|
+
import { type SelectOptionWithPlainLabel } from '../types';
|
|
5
|
+
interface UseDigitalStampRanges {
|
|
6
|
+
ranges: ComputedRef<SelectOptionWithPlainLabel<number, string>[]>;
|
|
7
|
+
currentRange: ComputedRef<SelectOptionWithPlainLabel<number, string>>;
|
|
8
|
+
}
|
|
9
|
+
export declare const useDigitalStampRanges: (weight: MaybeRef<number>, order?: MaybeRef<null | {
|
|
10
|
+
digitalStampRanges?: Plugin.DigitalStampRange[];
|
|
11
|
+
}>) => UseDigitalStampRanges;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type ComputedRef, type MaybeRef, type Ref } from 'vue';
|
|
2
|
+
import { type ReadonlyOr } from '@myparcel-dev/ts-utils';
|
|
3
|
+
export type UseLoadMoreOptions<Item = unknown> = {
|
|
4
|
+
step?: number;
|
|
5
|
+
start?: number;
|
|
6
|
+
items: ReadonlyOr<MaybeRef<Item[]>>;
|
|
7
|
+
};
|
|
8
|
+
export type UseLoadMore<Item = unknown> = {
|
|
9
|
+
loadMore(): void;
|
|
10
|
+
hasMore: ComputedRef<boolean>;
|
|
11
|
+
loaded: Ref<number>;
|
|
12
|
+
items: ComputedRef<Item[]>;
|
|
13
|
+
};
|
|
14
|
+
export declare const useLoadMore: <Item = unknown>(options: UseLoadMoreOptions<Item>) => UseLoadMore<Item>;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type BackendEndpoint } from '@myparcel-dev/pdk-common';
|
|
2
|
+
import { type ResolvedQuery } from '../stores';
|
|
3
|
+
import { type PlainModifier } from '../actions';
|
|
4
|
+
export declare const useStoreQuery: <E extends BackendEndpoint>(endpoint: E, suffix?: PlainModifier) => ResolvedQuery<E>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
declare const WEEKDAYS: readonly [0, 1, 2, 3, 4, 5, 6];
|
|
2
|
+
export type Weekdays = typeof WEEKDAYS;
|
|
3
|
+
export type Weekday = Weekdays[number];
|
|
4
|
+
type UseWeekdays = {
|
|
5
|
+
weekdays: Weekdays;
|
|
6
|
+
weekdaysObject: Record<Weekday, string>;
|
|
7
|
+
};
|
|
8
|
+
export declare const useWeekdays: () => UseWeekdays;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
export declare enum AdminComponent {
|
|
2
|
+
/**
|
|
3
|
+
* @see BadgeProps
|
|
4
|
+
*/
|
|
5
|
+
Badge = "Badge",
|
|
6
|
+
/**
|
|
7
|
+
* Used to wrap content in a block.
|
|
8
|
+
*
|
|
9
|
+
* @see BoxProps
|
|
10
|
+
*/
|
|
11
|
+
Box = "Box",
|
|
12
|
+
/**
|
|
13
|
+
* This component is used to render a button. The button can be used to trigger an action. The button can have
|
|
14
|
+
* multiple icons, a label and various sizes. The button can be disabled.
|
|
15
|
+
*
|
|
16
|
+
* @see ButtonProps
|
|
17
|
+
*/
|
|
18
|
+
Button = "Button",
|
|
19
|
+
/**
|
|
20
|
+
* @see ButtonGroupProps
|
|
21
|
+
*/
|
|
22
|
+
ButtonGroup = "ButtonGroup",
|
|
23
|
+
/**
|
|
24
|
+
* @see CheckboxGroupProps
|
|
25
|
+
*/
|
|
26
|
+
CheckboxGroup = "CheckboxGroup",
|
|
27
|
+
/**
|
|
28
|
+
* @see CheckboxInputProps
|
|
29
|
+
*/
|
|
30
|
+
CheckboxInput = "CheckboxInput",
|
|
31
|
+
/**
|
|
32
|
+
* @see CodeEditorProps
|
|
33
|
+
*/
|
|
34
|
+
CodeEditor = "CodeEditor",
|
|
35
|
+
/**
|
|
36
|
+
* @see ColProps
|
|
37
|
+
*/
|
|
38
|
+
Col = "Col",
|
|
39
|
+
/**
|
|
40
|
+
* @see ConceptBoxWrapperProps
|
|
41
|
+
*/
|
|
42
|
+
ConceptBoxWrapper = "ConceptBoxWrapper",
|
|
43
|
+
/**
|
|
44
|
+
* @see CurrencyInputProps
|
|
45
|
+
*/
|
|
46
|
+
CurrencyInput = "CurrencyInput",
|
|
47
|
+
/**
|
|
48
|
+
* @see DropOffInputProps
|
|
49
|
+
*/
|
|
50
|
+
DropOffInput = "DropOffInput",
|
|
51
|
+
/**
|
|
52
|
+
* The dropdown button is a button that can be clicked to open a dropdown menu. The dropdown menu can contain multiple
|
|
53
|
+
* items.
|
|
54
|
+
*
|
|
55
|
+
* @see DropdownButtonProps
|
|
56
|
+
*/
|
|
57
|
+
DropdownButton = "DropdownButton",
|
|
58
|
+
/**
|
|
59
|
+
* The form group is used to render a label and a form element.
|
|
60
|
+
*
|
|
61
|
+
* @see FormGroupProps
|
|
62
|
+
*/
|
|
63
|
+
FormGroup = "FormGroup",
|
|
64
|
+
/**
|
|
65
|
+
* @see HeadingProps
|
|
66
|
+
*/
|
|
67
|
+
Heading = "Heading",
|
|
68
|
+
/**
|
|
69
|
+
* @see IconProps
|
|
70
|
+
*/
|
|
71
|
+
Icon = "Icon",
|
|
72
|
+
/**
|
|
73
|
+
* @see ImageProps
|
|
74
|
+
*/
|
|
75
|
+
Image = "Image",
|
|
76
|
+
/**
|
|
77
|
+
* This component is used to render a link. The link can be used to trigger an action.
|
|
78
|
+
*
|
|
79
|
+
* @see LinkProps
|
|
80
|
+
*/
|
|
81
|
+
Link = "Link",
|
|
82
|
+
/**
|
|
83
|
+
* @see LoaderProps
|
|
84
|
+
*/
|
|
85
|
+
Loader = "Loader",
|
|
86
|
+
/**
|
|
87
|
+
* @see ModalProps
|
|
88
|
+
*/
|
|
89
|
+
Modal = "Modal",
|
|
90
|
+
/**
|
|
91
|
+
* A multi-select box. Renders a list of options which each have their own value. Allows multiple options to be selected.
|
|
92
|
+
*
|
|
93
|
+
* @see MultiSelectInputProps
|
|
94
|
+
*/
|
|
95
|
+
MultiSelectInput = "MultiSelectInput",
|
|
96
|
+
/**
|
|
97
|
+
* @see NotificationProps
|
|
98
|
+
*/
|
|
99
|
+
Notification = "Notification",
|
|
100
|
+
/**
|
|
101
|
+
* @see NumberInputProps
|
|
102
|
+
*/
|
|
103
|
+
NumberInput = "NumberInput",
|
|
104
|
+
/**
|
|
105
|
+
* @see PluginSettingsWrapperProps
|
|
106
|
+
*/
|
|
107
|
+
PluginSettingsWrapper = "PluginSettingsWrapper",
|
|
108
|
+
/**
|
|
109
|
+
* @see RadioGroupProps
|
|
110
|
+
*/
|
|
111
|
+
RadioGroup = "RadioGroup",
|
|
112
|
+
/**
|
|
113
|
+
* @see RadioInputProps
|
|
114
|
+
*/
|
|
115
|
+
RadioInput = "RadioInput",
|
|
116
|
+
/**
|
|
117
|
+
* Table row.
|
|
118
|
+
*
|
|
119
|
+
* @see RowProps
|
|
120
|
+
*/
|
|
121
|
+
Row = "Row",
|
|
122
|
+
/**
|
|
123
|
+
* A select element. Renders a list of options which each have their own value.
|
|
124
|
+
*
|
|
125
|
+
* @see SelectInputProps
|
|
126
|
+
*/
|
|
127
|
+
SelectInput = "SelectInput",
|
|
128
|
+
/**
|
|
129
|
+
* @see SettingsDividerProps
|
|
130
|
+
*/
|
|
131
|
+
SettingsDivider = "SettingsDivider",
|
|
132
|
+
/**
|
|
133
|
+
* @see ShipmentLabelWrapperProps
|
|
134
|
+
*/
|
|
135
|
+
ShipmentLabelWrapper = "ShipmentLabelWrapper",
|
|
136
|
+
/**
|
|
137
|
+
* @see ShippingMethodsInputProps
|
|
138
|
+
*/
|
|
139
|
+
ShippingMethodsInput = "ShippingMethodsInput",
|
|
140
|
+
/**
|
|
141
|
+
* @see TabNavButtonProps
|
|
142
|
+
*/
|
|
143
|
+
TabNavButton = "TabNavButton",
|
|
144
|
+
/**
|
|
145
|
+
* @see TabNavButtonWrapperProps
|
|
146
|
+
*/
|
|
147
|
+
TabNavButtonWrapper = "TabNavButtonWrapper",
|
|
148
|
+
/**
|
|
149
|
+
* @see TabNavContentWrapperProps
|
|
150
|
+
*/
|
|
151
|
+
TabNavContentWrapper = "TabNavContentWrapper",
|
|
152
|
+
/**
|
|
153
|
+
* A table component that can be used to render data via slots.
|
|
154
|
+
*
|
|
155
|
+
* @see TableProps
|
|
156
|
+
*/
|
|
157
|
+
Table = "Table",
|
|
158
|
+
/**
|
|
159
|
+
* @see TableColProps
|
|
160
|
+
*/
|
|
161
|
+
TableCol = "TableCol",
|
|
162
|
+
/**
|
|
163
|
+
* @see TableRowProps
|
|
164
|
+
*/
|
|
165
|
+
TableRow = "TableRow",
|
|
166
|
+
/**
|
|
167
|
+
* @see TextAreaProps
|
|
168
|
+
*/
|
|
169
|
+
TextArea = "TextArea",
|
|
170
|
+
/**
|
|
171
|
+
* @see TextInputProps
|
|
172
|
+
*/
|
|
173
|
+
TextInput = "TextInput",
|
|
174
|
+
/**
|
|
175
|
+
* @see TimeInputProps
|
|
176
|
+
*/
|
|
177
|
+
TimeInput = "TimeInput",
|
|
178
|
+
/**
|
|
179
|
+
* @see ToggleInputProps
|
|
180
|
+
*/
|
|
181
|
+
ToggleInput = "ToggleInput",
|
|
182
|
+
/**
|
|
183
|
+
* @see TriStateInputProps
|
|
184
|
+
*/
|
|
185
|
+
TriStateInput = "TriStateInput",
|
|
186
|
+
/**
|
|
187
|
+
* @see MultiDateInputProps
|
|
188
|
+
*/
|
|
189
|
+
MultiDateInput = "MultiDateInput"
|
|
190
|
+
}
|
|
191
|
+
export declare const requiredAdminComponentNames: readonly [AdminComponent.Box, AdminComponent.Button, AdminComponent.CheckboxGroup, AdminComponent.CheckboxInput, AdminComponent.CodeEditor, AdminComponent.Col, AdminComponent.CurrencyInput, AdminComponent.DropOffInput, AdminComponent.DropdownButton, AdminComponent.FormGroup, AdminComponent.Heading, AdminComponent.Icon, AdminComponent.Image, AdminComponent.Link, AdminComponent.Loader, AdminComponent.Modal, AdminComponent.MultiSelectInput, AdminComponent.Notification, AdminComponent.NumberInput, AdminComponent.RadioGroup, AdminComponent.RadioInput, AdminComponent.Row, AdminComponent.SelectInput, AdminComponent.TabNavButton, AdminComponent.Table, AdminComponent.TextArea, AdminComponent.TextInput, AdminComponent.TimeInput, AdminComponent.ToggleInput, AdminComponent.TriStateInput, AdminComponent.MultiDateInput];
|
|
192
|
+
export declare const optionalAdminComponentNames: readonly [AdminComponent.ShippingMethodsInput];
|
|
193
|
+
export declare const optionalAdminPlainWrapperComponentNames: readonly [AdminComponent.Badge, AdminComponent.ButtonGroup, AdminComponent.PluginSettingsWrapper, AdminComponent.SettingsDivider, AdminComponent.TabNavButtonWrapper, AdminComponent.TabNavContentWrapper, AdminComponent.TableCol, AdminComponent.TableRow];
|
|
194
|
+
export declare const optionalAdminActionContainerComponentNames: readonly [AdminComponent.ConceptBoxWrapper, AdminComponent.ShipmentLabelWrapper];
|
|
195
|
+
export declare const allAdminComponentNames: readonly [AdminComponent.Box, AdminComponent.Button, AdminComponent.CheckboxGroup, AdminComponent.CheckboxInput, AdminComponent.CodeEditor, AdminComponent.Col, AdminComponent.CurrencyInput, AdminComponent.DropOffInput, AdminComponent.DropdownButton, AdminComponent.FormGroup, AdminComponent.Heading, AdminComponent.Icon, AdminComponent.Image, AdminComponent.Link, AdminComponent.Loader, AdminComponent.Modal, AdminComponent.MultiSelectInput, AdminComponent.Notification, AdminComponent.NumberInput, AdminComponent.RadioGroup, AdminComponent.RadioInput, AdminComponent.Row, AdminComponent.SelectInput, AdminComponent.TabNavButton, AdminComponent.Table, AdminComponent.TextArea, AdminComponent.TextInput, AdminComponent.TimeInput, AdminComponent.ToggleInput, AdminComponent.TriStateInput, AdminComponent.MultiDateInput, AdminComponent.ShippingMethodsInput, AdminComponent.Badge, AdminComponent.ButtonGroup, AdminComponent.PluginSettingsWrapper, AdminComponent.SettingsDivider, AdminComponent.TabNavButtonWrapper, AdminComponent.TabNavContentWrapper, AdminComponent.TableCol, AdminComponent.TableRow, AdminComponent.ConceptBoxWrapper, AdminComponent.ShipmentLabelWrapper];
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
export declare const HASH_SEPARATOR = "--";
|
|
2
|
+
export declare const ADMIN_COMPONENT_PREFIX = "Pdk";
|
|
3
|
+
export declare enum AdminInstanceContextKey {
|
|
4
|
+
OrderIdentifier = "orderIdentifier",
|
|
5
|
+
ProductIdentifier = "productIdentifier"
|
|
6
|
+
}
|
|
7
|
+
export declare enum AdminModalKey {
|
|
8
|
+
PrintOptions = "printOptions",
|
|
9
|
+
ReturnOptions = "returnOptions",
|
|
10
|
+
ShipmentOptions = "shipmentOptions"
|
|
11
|
+
}
|
|
12
|
+
export declare enum NotificationCategory {
|
|
13
|
+
Action = "action",
|
|
14
|
+
Api = "api",
|
|
15
|
+
General = "general",
|
|
16
|
+
Modal = "modal"
|
|
17
|
+
}
|
|
18
|
+
export declare enum NotificationSource {
|
|
19
|
+
Api = "api"
|
|
20
|
+
}
|
|
21
|
+
export declare enum AdminIcon {
|
|
22
|
+
Add = "add",
|
|
23
|
+
ArrowDown = "arrow_down",
|
|
24
|
+
ArrowUp = "arrow_up",
|
|
25
|
+
Close = "close",
|
|
26
|
+
Delete = "delete",
|
|
27
|
+
Download = "download",
|
|
28
|
+
Edit = "edit",
|
|
29
|
+
Export = "export",
|
|
30
|
+
External = "external",
|
|
31
|
+
No = "no",
|
|
32
|
+
Print = "print",
|
|
33
|
+
Refresh = "refresh",
|
|
34
|
+
Return = "return",
|
|
35
|
+
Save = "save",
|
|
36
|
+
Shipment = "shipment",
|
|
37
|
+
Spinner = "spinner",
|
|
38
|
+
Yes = "yes"
|
|
39
|
+
}
|
|
40
|
+
export declare enum AdminAction {
|
|
41
|
+
ContextFetch = "contextFetch",
|
|
42
|
+
AccountDelete = "accountDelete",
|
|
43
|
+
AccountUpdate = "accountUpdate",
|
|
44
|
+
OrdersExport = "ordersExport",
|
|
45
|
+
OrdersExportPrint = "ordersExportPrint",
|
|
46
|
+
OrdersPrint = "ordersPrint",
|
|
47
|
+
OrdersFetch = "ordersFetch",
|
|
48
|
+
OrdersUpdate = "ordersUpdate",
|
|
49
|
+
OrdersEdit = "ordersEdit",
|
|
50
|
+
ShipmentsDelete = "shipmentsDelete",
|
|
51
|
+
ShipmentsPrint = "shipmentsPrint",
|
|
52
|
+
ShipmentsUpdate = "shipmentsUpdate",
|
|
53
|
+
ShipmentsFetch = "shipmentsFetch",
|
|
54
|
+
ShipmentsExportReturn = "shipmentsExportReturn",
|
|
55
|
+
PluginSettingsUpdate = "pluginSettingsUpdate",
|
|
56
|
+
ProductSettingsUpdate = "productSettingsUpdate",
|
|
57
|
+
WebhooksCreate = "webhooksCreate",
|
|
58
|
+
WebhooksDelete = "webhooksDelete",
|
|
59
|
+
WebhooksFetch = "webhooksFetch",
|
|
60
|
+
DownloadLogs = "downloadLogs",
|
|
61
|
+
SwitchToAcceptanceApi = "switchToAcceptanceApi",
|
|
62
|
+
SwitchToProductionApi = "switchToProductionApi"
|
|
63
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { BackendEndpoint } from '@myparcel-dev/pdk-common';
|
|
2
|
+
export declare const BACKEND_ENDPOINTS_ORDERS: readonly [BackendEndpoint.ExportOrders, BackendEndpoint.FetchOrders, BackendEndpoint.PrintOrders, BackendEndpoint.UpdateOrders];
|
|
3
|
+
export declare const BACKEND_ENDPOINTS_SHIPMENTS: readonly [BackendEndpoint.DeleteShipments, BackendEndpoint.ExportReturn, BackendEndpoint.FetchShipments, BackendEndpoint.PrintShipments, BackendEndpoint.UpdateShipments];
|
|
4
|
+
export declare const BACKEND_ENDPOINTS_WEBHOOKS: readonly [BackendEndpoint.CreateWebhooks, BackendEndpoint.DeleteWebhooks, BackendEndpoint.FetchWebhooks];
|
|
5
|
+
export declare const BACKEND_ENDPOINTS_DEBUG: readonly [BackendEndpoint.DownloadLogs, BackendEndpoint.SwitchToAcceptanceApi, BackendEndpoint.SwitchToProductionApi];
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare enum OrderMode {
|
|
2
|
+
Shipments = "Shipments",
|
|
3
|
+
OrderV1 = "OrderV1",
|
|
4
|
+
OrderV2 = "OrderV2"
|
|
5
|
+
}
|
|
6
|
+
export declare enum SubscriptionFeature {
|
|
7
|
+
LegacyOrderManagement = "LEGACY_ORDER_MANAGEMENT",
|
|
8
|
+
OrderManagement = "ORDER_MANAGEMENT"
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Translate the numeric `effectiveOrderMode` emitted by the PDK admin context
|
|
12
|
+
* (when present) into the JS-side {@see OrderMode} enum. Returns `undefined`
|
|
13
|
+
* when the value is missing or not one of the known modes, so callers can fall
|
|
14
|
+
* back to feature-based resolution.
|
|
15
|
+
*/
|
|
16
|
+
export declare const orderModeFromContextValue: (value: unknown) => OrderMode | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* Derive the active {@see OrderMode} from the raw IAM subscription features.
|
|
19
|
+
*
|
|
20
|
+
* Use this only as a fallback for environments where the PDK admin context does
|
|
21
|
+
* not yet surface a pre-computed `effectiveOrderMode`. Prefer the context value
|
|
22
|
+
* so any business rules layered on top in PHP (e.g. INT-1590's sales-channel
|
|
23
|
+
* downgrade) take effect on the JS side automatically.
|
|
24
|
+
*/
|
|
25
|
+
export declare const resolveOrderMode: (features: string[]) => OrderMode;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare enum AdminView {
|
|
2
|
+
ChildProductSettings = "ChildProductSettings",
|
|
3
|
+
Modals = "Modals",
|
|
4
|
+
Notifications = "Notifications",
|
|
5
|
+
OrderBox = "OrderBox",
|
|
6
|
+
OrderListItem = "OrderListItem",
|
|
7
|
+
PluginSettings = "PluginSettings",
|
|
8
|
+
ProductSettings = "ProductSettings"
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const createReturnsForm: (id: string) => import("@myparcel-vfb/core").FormInstance<import("@myparcel-vfb/core").FormValues>;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { type InteractiveElementInstance } from '@myparcel-dev/vue-form-builder';
|
|
2
|
+
import { type FormOperation, type HandlerDefinition } from '../types';
|
|
3
|
+
export declare const buildAfterUpdate: (operations: FormOperation[], prefix: string, customHandlers?: HandlerDefinition[]) => ((instance: InteractiveElementInstance) => void);
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { type InteractiveElementConfiguration } from '@myparcel-dev/vue-form-builder';
|
|
2
|
+
import { type FormBuilder, type HandlerDefinition } from '../types';
|
|
3
|
+
export declare const parseBuilders: (builders: FormBuilder[], prefix: string, customHandlers?: HandlerDefinition[]) => Partial<InteractiveElementConfiguration>;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { type AnyVal, type WithTarget } from './common.types';
|
|
2
|
+
export interface EqualMatcher {
|
|
3
|
+
$eq: AnyVal;
|
|
4
|
+
}
|
|
5
|
+
export interface GreaterThanMatcher {
|
|
6
|
+
$gt: number;
|
|
7
|
+
}
|
|
8
|
+
export interface GreaterThanOrEqualMatcher {
|
|
9
|
+
$gte: number;
|
|
10
|
+
}
|
|
11
|
+
export interface InMatcher {
|
|
12
|
+
$in: AnyVal[];
|
|
13
|
+
}
|
|
14
|
+
export interface LessThanMatcher {
|
|
15
|
+
$lt: number;
|
|
16
|
+
}
|
|
17
|
+
export interface LessThanOrEqualMatcher {
|
|
18
|
+
$lte: number;
|
|
19
|
+
}
|
|
20
|
+
export interface NotEqualMatcher {
|
|
21
|
+
$ne: AnyVal;
|
|
22
|
+
}
|
|
23
|
+
export interface NotInMatcher {
|
|
24
|
+
$nin: AnyVal[];
|
|
25
|
+
}
|
|
26
|
+
export type Matcher = EqualMatcher | GreaterThanMatcher | GreaterThanOrEqualMatcher | InMatcher | LessThanMatcher | LessThanOrEqualMatcher | NotEqualMatcher | NotInMatcher;
|
|
27
|
+
export type SingleIfMatcher = Partial<WithTarget> & Partial<Matcher>;
|
|
28
|
+
export interface IfOrMatcher {
|
|
29
|
+
$or: SingleIfMatcher[];
|
|
30
|
+
}
|
|
31
|
+
export interface IfAndMatcher {
|
|
32
|
+
$and: SingleIfMatcher[];
|
|
33
|
+
}
|
|
34
|
+
export interface WithCondition {
|
|
35
|
+
$if: (SingleIfMatcher | IfOrMatcher | IfAndMatcher)[];
|
|
36
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type FormOperationMethods, type PropVal, type WithTarget, type WithValue } from './common.types';
|
|
2
|
+
import { type WithCondition } from './FormCondition.types';
|
|
3
|
+
export type FormSetValueOperation = {
|
|
4
|
+
$setValue: WithValue & Partial<WithCondition> & Partial<WithTarget>;
|
|
5
|
+
};
|
|
6
|
+
export type FormSetPropOperation = {
|
|
7
|
+
$setProp: {
|
|
8
|
+
$prop: string;
|
|
9
|
+
} & WithValue<PropVal> & Partial<WithCondition> & Partial<WithTarget>;
|
|
10
|
+
};
|
|
11
|
+
type HandlerCallback<T extends string> = (operation: Record<T, unknown>, methods: FormOperationMethods) => void;
|
|
12
|
+
export type HandlerDefinition<T extends string = string> = {
|
|
13
|
+
name: T;
|
|
14
|
+
callback: HandlerCallback<T>;
|
|
15
|
+
};
|
|
16
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type FormOperation, type WithTarget } from './common.types';
|
|
2
|
+
import { type WithCondition } from './FormCondition.types';
|
|
3
|
+
export type WhenArguments = Partial<WithCondition> & Partial<WithTarget>;
|
|
4
|
+
type FormWhenBuilder<T extends string = string> = {
|
|
5
|
+
[K in T]: WhenArguments;
|
|
6
|
+
};
|
|
7
|
+
export type FormVisibleWhenBuilder = FormWhenBuilder<'$visibleWhen'>;
|
|
8
|
+
export type FormDisabledWhenBuilder = FormWhenBuilder<'$disabledWhen'>;
|
|
9
|
+
export type FormReadOnlyWhenBuilder = FormWhenBuilder<'$readOnlyWhen'>;
|
|
10
|
+
export interface FormAfterUpdateBuilder {
|
|
11
|
+
$afterUpdate: FormOperation[];
|
|
12
|
+
}
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { type OneOrMore } from '@myparcel-dev/ts-utils';
|
|
2
|
+
import { type FormPropSetter, type FormValueGetter, type FormValueSetter } from '../utils';
|
|
3
|
+
import { type FormAfterUpdateBuilder, type FormDisabledWhenBuilder, type FormReadOnlyWhenBuilder, type FormVisibleWhenBuilder } from './SubOperationBuilder.types';
|
|
4
|
+
import { type WithCondition } from './FormCondition.types';
|
|
5
|
+
export type AnyVal = string | number | boolean;
|
|
6
|
+
export type PropVal = OneOrMore<AnyVal> | OneOrMore<Record<string, AnyVal>>;
|
|
7
|
+
export interface WithTarget {
|
|
8
|
+
$target: string;
|
|
9
|
+
}
|
|
10
|
+
export interface WithValue<V = AnyVal> {
|
|
11
|
+
$value: V;
|
|
12
|
+
}
|
|
13
|
+
export type FormWhenBuilder = FormVisibleWhenBuilder | FormDisabledWhenBuilder | FormReadOnlyWhenBuilder;
|
|
14
|
+
export type OperationArguments = Partial<WithTarget | WithValue | WithCondition>;
|
|
15
|
+
export type FormOperation = Record<string, OperationArguments>;
|
|
16
|
+
export type FormBuilder = FormWhenBuilder | FormAfterUpdateBuilder;
|
|
17
|
+
export type FormOperationMethods = {
|
|
18
|
+
getValue: FormValueGetter;
|
|
19
|
+
setValue: FormValueSetter;
|
|
20
|
+
setProp: FormPropSetter;
|
|
21
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type InteractiveElementInstance } from '@myparcel-dev/vue-form-builder';
|
|
2
|
+
import { type PropVal } from '../types';
|
|
3
|
+
export type FormPropSetter = (prop: string, value: PropVal, target?: string) => void;
|
|
4
|
+
export declare const createPropSetter: (instance: InteractiveElementInstance, prefix: string) => FormPropSetter;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type InteractiveElementInstance } from '@myparcel-dev/vue-form-builder';
|
|
2
|
+
import { type AnyVal } from '../types';
|
|
3
|
+
export type FormValueGetter = (target?: string) => AnyVal;
|
|
4
|
+
export declare const createValueGetter: (instance: InteractiveElementInstance, prefix: string) => FormValueGetter;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type InteractiveElementInstance } from '@myparcel-dev/vue-form-builder';
|
|
2
|
+
import { type AnyVal } from '../types';
|
|
3
|
+
export type FormValueSetter = (value: AnyVal, target?: string) => void;
|
|
4
|
+
/**
|
|
5
|
+
* Set a field's ref value, handling both Vue Ref and raw value cases.
|
|
6
|
+
*
|
|
7
|
+
* vue-form-builder replaces `field.ref` with a raw value after the first
|
|
8
|
+
* render cycle, so we can't always rely on `field.ref.value = x`.
|
|
9
|
+
*/
|
|
10
|
+
export declare const setFieldRef: (field: InteractiveElementInstance, value: AnyVal) => void;
|
|
11
|
+
export declare const createValueSetter: (instance: InteractiveElementInstance, prefix: string) => FormValueSetter;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { AdminModalKey } from '../data';
|
|
2
|
+
export declare const FORM_KEY_ACCOUNT_SETTINGS = "accountSettings";
|
|
3
|
+
export declare const FORM_KEY_MODAL = "modal";
|
|
4
|
+
export declare const FORM_KEY_MODAL_PRINT_OPTIONS = AdminModalKey.PrintOptions;
|
|
5
|
+
export declare const FORM_KEY_MODAL_RETURN_OPTIONS = AdminModalKey.ReturnOptions;
|
|
6
|
+
export declare const FORM_KEY_MODAL_SHIPMENT_OPTIONS = AdminModalKey.ShipmentOptions;
|
|
7
|
+
export declare const FORM_KEY_PLUGIN_SETTINGS = "pluginSettings";
|
|
8
|
+
export declare const FORM_KEY_PRODUCT_SETTINGS = "productSettings";
|
|
9
|
+
export declare const FORM_KEY_CHILD_PRODUCT_SETTINGS = "childProductSettings";
|
|
10
|
+
export declare const FORM_KEYS: readonly ["accountSettings", "childProductSettings", "modal", AdminModalKey.PrintOptions, AdminModalKey.ReturnOptions, AdminModalKey.ShipmentOptions, "pluginSettings", "productSettings"];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const addBulkEditNotification: (isModal: boolean) => void;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type useNotificationStore } from '../../stores';
|
|
2
|
+
export declare const CAPABILITIES_CLEARED_NOTIFICATION_ID = "capabilities_cleared";
|
|
3
|
+
/**
|
|
4
|
+
* Add (or replace) the rolling "capabilities cleared" notification.
|
|
5
|
+
*
|
|
6
|
+
* The notification store skips `add` when an entry with the same id is already present, so
|
|
7
|
+
* we explicitly remove the prior one first to surface the new content list. Pass an
|
|
8
|
+
* already-localized `title` and `lines` — translation happens at the call site (auto-clear)
|
|
9
|
+
* because that's the layer holding the carrier name + axis context for parameterized lookups.
|
|
10
|
+
*
|
|
11
|
+
* Targets `NotificationCategory.Modal` when the shipment-options modal is open and
|
|
12
|
+
* `NotificationCategory.Action` otherwise — the modal shells (preset packages) only mount a
|
|
13
|
+
* `Modal` container, while the order-detail `ShipmentOptionsBox` mounts an `Action` container.
|
|
14
|
+
*/
|
|
15
|
+
export declare const addCapabilitiesClearNotification: (notificationStore: ReturnType<typeof useNotificationStore>, title: string, lines: string[]) => void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const createLabel: <Label extends string | undefined>(label: Label, type: string) => Label;
|