@deenruv/admin-ui 1.0.0
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/LICENSE +23 -0
- package/catalog/catalog.module.d.ts +43 -0
- package/catalog/catalog.routes.d.ts +4 -0
- package/catalog/components/apply-facet-dialog/apply-facet-dialog.component.d.ts +16 -0
- package/catalog/components/asset-detail/asset-detail.component.d.ts +28 -0
- package/catalog/components/asset-list/asset-list.component.d.ts +23 -0
- package/catalog/components/assign-products-to-channel-dialog/assign-products-to-channel-dialog.component.d.ts +35 -0
- package/catalog/components/bulk-add-facet-values-dialog/bulk-add-facet-values-dialog.component.d.ts +40 -0
- package/catalog/components/bulk-add-facet-values-dialog/bulk-add-facet-values-dialog.graphql.d.ts +4 -0
- package/catalog/components/collection-contents/collection-contents.component.d.ts +39 -0
- package/catalog/components/collection-data-table/collection-data-table.component.d.ts +80 -0
- package/catalog/components/collection-detail/collection-detail.component.d.ts +71 -0
- package/catalog/components/collection-list/collection-breadcrumb.pipe.d.ts +11 -0
- package/catalog/components/collection-list/collection-list-bulk-actions.d.ts +8 -0
- package/catalog/components/collection-list/collection-list.component.d.ts +25 -0
- package/catalog/components/collection-tree/array-to-tree.d.ts +19 -0
- package/catalog/components/collection-tree/collection-tree-node.component.d.ts +44 -0
- package/catalog/components/collection-tree/collection-tree.component.d.ts +22 -0
- package/catalog/components/collection-tree/collection-tree.service.d.ts +33 -0
- package/catalog/components/collection-tree/collection-tree.types.d.ts +7 -0
- package/catalog/components/confirm-variant-deletion-dialog/confirm-variant-deletion-dialog.component.d.ts +10 -0
- package/catalog/components/create-facet-value-dialog/create-facet-value-dialog.component.d.ts +19 -0
- package/catalog/components/create-product-option-group-dialog/create-product-option-group-dialog.component.d.ts +18 -0
- package/catalog/components/create-product-variant-dialog/create-product-variant-dialog.component.d.ts +27 -0
- package/catalog/components/facet-detail/facet-detail.component.d.ts +76 -0
- package/catalog/components/facet-list/facet-list-bulk-actions.d.ts +7 -0
- package/catalog/components/facet-list/facet-list.component.d.ts +19 -0
- package/catalog/components/generate-product-variants/generate-product-variants.component.d.ts +65 -0
- package/catalog/components/move-collections-dialog/move-collections-dialog.component.d.ts +23 -0
- package/catalog/components/option-value-input/option-value-input.component.d.ts +48 -0
- package/catalog/components/product-detail/product-detail.component.d.ts +75 -0
- package/catalog/components/product-list/product-list-bulk-actions.d.ts +7 -0
- package/catalog/components/product-list/product-list.component.d.ts +18 -0
- package/catalog/components/product-list/product-list.graphql.d.ts +1 -0
- package/catalog/components/product-options-editor/product-options-editor.component.d.ts +47 -0
- package/catalog/components/product-variant-detail/product-variant-detail.component.d.ts +79 -0
- package/catalog/components/product-variant-detail/product-variant-detail.graphql.d.ts +3 -0
- package/catalog/components/product-variant-list/product-variant-list-bulk-actions.d.ts +6 -0
- package/catalog/components/product-variant-list/product-variant-list.component.d.ts +14 -0
- package/catalog/components/product-variant-list/product-variant-list.graphql.d.ts +1 -0
- package/catalog/components/product-variant-quick-jump/product-variant-quick-jump.component.d.ts +18 -0
- package/catalog/components/product-variants-editor/product-variants-editor.component.d.ts +88 -0
- package/catalog/components/product-variants-table/product-variants-table.component.d.ts +55 -0
- package/catalog/components/update-product-option-dialog/update-product-option-dialog.component.d.ts +25 -0
- package/catalog/components/variant-price-detail/variant-price-detail.component.d.ts +20 -0
- package/catalog/components/variant-price-strategy-detail/variant-price-strategy-detail.component.d.ts +10 -0
- package/catalog/index.d.ts +5 -0
- package/catalog/providers/product-detail/product-detail.service.d.ts +286 -0
- package/catalog/providers/product-detail/replace-last.d.ts +6 -0
- package/catalog/providers/routing/product-variants-resolver.d.ts +8 -0
- package/catalog/public_api.d.ts +48 -0
- package/core/app.component.d.ts +19 -0
- package/core/app.component.module.d.ts +9 -0
- package/core/app.config.d.ts +3 -0
- package/core/common/base-detail.component.d.ts +146 -0
- package/core/common/base-entity-resolver.d.ts +45 -0
- package/core/common/base-list.component.d.ts +138 -0
- package/core/common/component-registry-types.d.ts +65 -0
- package/core/common/deactivate-aware.d.ts +8 -0
- package/core/common/detail-breadcrumb.d.ts +12 -0
- package/core/common/generated-types.d.ts +20279 -0
- package/core/common/introspection-result-wrapper.d.ts +1 -0
- package/core/common/introspection-result.d.ts +7 -0
- package/core/common/single-search-selection-model.d.ts +16 -0
- package/core/common/title-setter.d.ts +4 -0
- package/core/common/utilities/bulk-action-utils.d.ts +49 -0
- package/core/common/utilities/configurable-operation-utils.d.ts +48 -0
- package/core/common/utilities/create-updated-translatable.d.ts +25 -0
- package/core/common/utilities/custom-field-default-value.d.ts +6 -0
- package/core/common/utilities/find-translation.d.ts +14 -0
- package/core/common/utilities/get-default-ui-language.d.ts +3 -0
- package/core/common/utilities/interpolate-description.d.ts +7 -0
- package/core/common/utilities/selection-manager.d.ts +30 -0
- package/core/common/utilities/string-to-color.d.ts +4 -0
- package/core/common/version.d.ts +1 -0
- package/core/components/alerts/alerts.component.d.ts +11 -0
- package/core/components/app-shell/app-shell.component.d.ts +41 -0
- package/core/components/base-nav/base-nav.component.d.ts +30 -0
- package/core/components/breadcrumb/breadcrumb.component.d.ts +27 -0
- package/core/components/channel-switcher/channel-switcher.component.d.ts +21 -0
- package/core/components/main-nav/main-nav.component.d.ts +22 -0
- package/core/components/notification/notification.component.d.ts +37 -0
- package/core/components/overlay-host/overlay-host.component.d.ts +12 -0
- package/core/components/settings-nav/settings-nav.component.d.ts +11 -0
- package/core/components/theme-switcher/theme-switcher.component.d.ts +16 -0
- package/core/components/ui-language-switcher-dialog/ui-language-switcher-dialog.component.d.ts +30 -0
- package/core/components/user-menu/user-menu.component.d.ts +12 -0
- package/core/core.module.d.ts +39 -0
- package/core/data/check-jobs-link.d.ts +19 -0
- package/core/data/client-state/client-defaults.d.ts +32 -0
- package/core/data/client-state/client-resolvers.d.ts +12 -0
- package/core/data/data.module.d.ts +17 -0
- package/core/data/definitions/administrator-definitions.d.ts +14 -0
- package/core/data/definitions/auth-definitions.d.ts +4 -0
- package/core/data/definitions/client-definitions.d.ts +17 -0
- package/core/data/definitions/collection-definitions.d.ts +13 -0
- package/core/data/definitions/customer-definitions.d.ts +23 -0
- package/core/data/definitions/facet-definitions.d.ts +13 -0
- package/core/data/definitions/order-definitions.d.ts +39 -0
- package/core/data/definitions/product-definitions.d.ts +49 -0
- package/core/data/definitions/promotion-definitions.d.ts +6 -0
- package/core/data/definitions/settings-definitions.d.ts +69 -0
- package/core/data/definitions/shared-definitions.d.ts +3 -0
- package/core/data/definitions/shipping-definitions.d.ts +8 -0
- package/core/data/omit-typename-link.d.ts +11 -0
- package/core/data/providers/administrator-data.service.d.ts +19 -0
- package/core/data/providers/auth-data.service.d.ts +9 -0
- package/core/data/providers/base-data.service.d.ts +26 -0
- package/core/data/providers/client-data.service.d.ts +26 -0
- package/core/data/providers/collection-data.service.d.ts +25 -0
- package/core/data/providers/customer-data.service.d.ts +36 -0
- package/core/data/providers/data.service.d.ts +86 -0
- package/core/data/providers/facet-data.service.d.ts +19 -0
- package/core/data/providers/fetch-adapter.d.ts +14 -0
- package/core/data/providers/interceptor.d.ts +49 -0
- package/core/data/providers/order-data.service.d.ts +48 -0
- package/core/data/providers/product-data.service.d.ts +86 -0
- package/core/data/providers/promotion-data.service.d.ts +11 -0
- package/core/data/providers/settings-data.service.d.ts +74 -0
- package/core/data/providers/shipping-method-data.service.d.ts +17 -0
- package/core/data/query-result.d.ts +43 -0
- package/core/data/server-config.d.ts +39 -0
- package/core/data/utils/add-custom-fields.d.ts +7 -0
- package/core/data/utils/get-server-location.d.ts +4 -0
- package/core/data/utils/is-entity-create-or-update-mutation.d.ts +6 -0
- package/core/data/utils/remove-readonly-custom-fields.d.ts +17 -0
- package/core/data/utils/transform-relation-custom-field-inputs.d.ts +8 -0
- package/core/extension/add-action-bar-dropdown-menu-item.d.ts +25 -0
- package/core/extension/add-action-bar-item.d.ts +21 -0
- package/core/extension/add-nav-menu-item.d.ts +56 -0
- package/core/extension/components/angular-route.component.d.ts +26 -0
- package/core/extension/components/route.component.d.ts +20 -0
- package/core/extension/providers/page-metadata.service.d.ts +9 -0
- package/core/extension/register-alert.d.ts +11 -0
- package/core/extension/register-bulk-action.d.ts +49 -0
- package/core/extension/register-custom-detail-component.d.ts +55 -0
- package/core/extension/register-dashboard-widget.d.ts +17 -0
- package/core/extension/register-data-table-component.d.ts +45 -0
- package/core/extension/register-form-input-component.d.ts +51 -0
- package/core/extension/register-history-entry-component.d.ts +66 -0
- package/core/extension/register-page-tab.d.ts +23 -0
- package/core/extension/register-route-component.d.ts +109 -0
- package/core/extension/types.d.ts +11 -0
- package/core/index.d.ts +5 -0
- package/core/providers/alerts/alerts.service.d.ts +150 -0
- package/core/providers/auth/auth.service.d.ts +40 -0
- package/core/providers/breadcrumb/breadcrumb.service.d.ts +39 -0
- package/core/providers/bulk-action-registry/bulk-action-registry.service.d.ts +9 -0
- package/core/providers/bulk-action-registry/bulk-action-types.d.ts +149 -0
- package/core/providers/channel/channel.service.d.ts +16 -0
- package/core/providers/component-registry/component-registry.service.d.ts +13 -0
- package/core/providers/currency/currency.service.d.ts +10 -0
- package/core/providers/custom-detail-component/custom-detail-component-types.d.ts +26 -0
- package/core/providers/custom-detail-component/custom-detail-component.service.d.ts +9 -0
- package/core/providers/custom-field-component/custom-field-component.service.d.ts +25 -0
- package/core/providers/custom-history-entry-component/history-entry-component-types.d.ts +81 -0
- package/core/providers/custom-history-entry-component/history-entry-component.service.d.ts +10 -0
- package/core/providers/dashboard-widget/dashboard-widget-types.d.ts +56 -0
- package/core/providers/dashboard-widget/dashboard-widget.service.d.ts +24 -0
- package/core/providers/data-table/data-table-filter-collection.d.ts +48 -0
- package/core/providers/data-table/data-table-filter.d.ts +108 -0
- package/core/providers/data-table/data-table-sort-collection.d.ts +24 -0
- package/core/providers/data-table/data-table-sort.d.ts +14 -0
- package/core/providers/guard/auth.guard.d.ts +17 -0
- package/core/providers/health-check/health-check.service.d.ts +40 -0
- package/core/providers/i18n/custom-http-loader.d.ts +21 -0
- package/core/providers/i18n/custom-message-format-compiler.d.ts +15 -0
- package/core/providers/i18n/i18n.service.d.ts +39 -0
- package/core/providers/job-queue/job-queue.service.d.ts +22 -0
- package/core/providers/local-storage/local-storage.service.d.ts +66 -0
- package/core/providers/localization/localization.service.d.ts +21 -0
- package/core/providers/modal/modal.service.d.ts +67 -0
- package/core/providers/modal/modal.types.d.ts +69 -0
- package/core/providers/nav-builder/nav-builder-types.d.ts +279 -0
- package/core/providers/nav-builder/nav-builder.service.d.ts +64 -0
- package/core/providers/notification/notification.service.d.ts +105 -0
- package/core/providers/overlay-host/overlay-host.service.d.ts +25 -0
- package/core/providers/page/page.service.d.ts +61 -0
- package/core/providers/permissions/permissions.service.d.ts +26 -0
- package/core/public_api.d.ts +313 -0
- package/core/shared/components/action-bar/action-bar.component.d.ts +17 -0
- package/core/shared/components/action-bar-dropdown-menu/action-bar-dropdown-menu.component.d.ts +15 -0
- package/core/shared/components/action-bar-items/action-bar-base.component.d.ts +29 -0
- package/core/shared/components/action-bar-items/action-bar-items.component.d.ts +11 -0
- package/core/shared/components/address-form/address-form.component.d.ts +10 -0
- package/core/shared/components/affixed-input/affixed-input.component.d.ts +10 -0
- package/core/shared/components/affixed-input/percentage-suffix-input.component.d.ts +22 -0
- package/core/shared/components/asset-file-input/asset-file-input.component.d.ts +39 -0
- package/core/shared/components/asset-gallery/asset-gallery.component.d.ts +97 -0
- package/core/shared/components/asset-gallery/asset-gallery.types.d.ts +3 -0
- package/core/shared/components/asset-picker-dialog/asset-picker-dialog.component.d.ts +60 -0
- package/core/shared/components/asset-preview/asset-preview.component.d.ts +61 -0
- package/core/shared/components/asset-preview-dialog/asset-preview-dialog.component.d.ts +22 -0
- package/core/shared/components/asset-preview-links/asset-preview-links.component.d.ts +8 -0
- package/core/shared/components/asset-search-input/asset-search-input.component.d.ts +26 -0
- package/core/shared/components/assets/assets.component.d.ts +36 -0
- package/core/shared/components/assign-to-channel-dialog/assign-to-channel-dialog.component.d.ts +28 -0
- package/core/shared/components/bulk-action-menu/bulk-action-menu.component.d.ts +34 -0
- package/core/shared/components/card/card.component.d.ts +13 -0
- package/core/shared/components/channel-assignment-control/channel-assignment-control.component.d.ts +32 -0
- package/core/shared/components/channel-badge/channel-badge.component.d.ts +7 -0
- package/core/shared/components/chart/chart.component.d.ts +28 -0
- package/core/shared/components/chart/tooltip-plugin.d.ts +21 -0
- package/core/shared/components/chip/chip.component.d.ts +38 -0
- package/core/shared/components/configurable-input/configurable-input.component.d.ts +43 -0
- package/core/shared/components/currency-code-selector/currency-code-selector.component.d.ts +21 -0
- package/core/shared/components/currency-input/currency-input.component.d.ts +53 -0
- package/core/shared/components/custom-detail-component-host/custom-detail-component-host.component.d.ts +20 -0
- package/core/shared/components/custom-field-control/custom-field-control.component.d.ts +31 -0
- package/core/shared/components/customer-label/customer-label.component.d.ts +7 -0
- package/core/shared/components/data-table/data-table-column.component.d.ts +11 -0
- package/core/shared/components/data-table/data-table.component.d.ts +107 -0
- package/core/shared/components/data-table-2/data-table-column.component.d.ts +25 -0
- package/core/shared/components/data-table-2/data-table-custom-component.service.d.ts +52 -0
- package/core/shared/components/data-table-2/data-table-custom-field-column.component.d.ts +18 -0
- package/core/shared/components/data-table-2/data-table-search.component.d.ts +10 -0
- package/core/shared/components/data-table-2/data-table2.component.d.ts +134 -0
- package/core/shared/components/data-table-column-picker/data-table-column-picker.component.d.ts +19 -0
- package/core/shared/components/data-table-filter-label/data-table-filter-label.component.d.ts +11 -0
- package/core/shared/components/data-table-filter-presets/add-filter-preset-button.component.d.ts +25 -0
- package/core/shared/components/data-table-filter-presets/data-table-filter-presets.component.d.ts +30 -0
- package/core/shared/components/data-table-filter-presets/filter-preset.service.d.ts +34 -0
- package/core/shared/components/data-table-filter-presets/rename-filter-preset-dialog.component.d.ts +9 -0
- package/core/shared/components/data-table-filters/custom-filter-component.directive.d.ts +8 -0
- package/core/shared/components/data-table-filters/data-table-filters.component.d.ts +30 -0
- package/core/shared/components/datetime-picker/constants.d.ts +5 -0
- package/core/shared/components/datetime-picker/datetime-picker.component.d.ts +100 -0
- package/core/shared/components/datetime-picker/datetime-picker.service.d.ts +37 -0
- package/core/shared/components/datetime-picker/types.d.ts +11 -0
- package/core/shared/components/dropdown/dropdown-item.directive.d.ts +9 -0
- package/core/shared/components/dropdown/dropdown-menu.component.d.ts +42 -0
- package/core/shared/components/dropdown/dropdown-trigger.directive.d.ts +11 -0
- package/core/shared/components/dropdown/dropdown.component.d.ts +39 -0
- package/core/shared/components/duplicate-entity-dialog/duplicate-entity-dialog.component.d.ts +33 -0
- package/core/shared/components/duplicate-entity-dialog/duplicate-entity-dialog.graphql.d.ts +2 -0
- package/core/shared/components/edit-note-dialog/edit-note-dialog.component.d.ts +18 -0
- package/core/shared/components/empty-placeholder/empty-placeholder.component.d.ts +6 -0
- package/core/shared/components/entity-info/entity-info.component.d.ts +11 -0
- package/core/shared/components/extension-host/extension-host-config.d.ts +9 -0
- package/core/shared/components/extension-host/extension-host.component.d.ts +28 -0
- package/core/shared/components/extension-host/extension-host.service.d.ts +23 -0
- package/core/shared/components/extension-host/host-external-frame.d.ts +28 -0
- package/core/shared/components/facet-value-chip/facet-value-chip.component.d.ts +11 -0
- package/core/shared/components/facet-value-selector/facet-value-selector.component.d.ts +49 -0
- package/core/shared/components/focal-point-control/focal-point-control.component.d.ts +24 -0
- package/core/shared/components/form-field/form-field-control.directive.d.ts +15 -0
- package/core/shared/components/form-field/form-field.component.d.ts +32 -0
- package/core/shared/components/form-item/form-item.component.d.ts +11 -0
- package/core/shared/components/formatted-address/formatted-address.component.d.ts +13 -0
- package/core/shared/components/help-tooltip/help-tooltip.component.d.ts +7 -0
- package/core/shared/components/history-entry-detail/history-entry-detail.component.d.ts +5 -0
- package/core/shared/components/items-per-page-controls/items-per-page-controls.component.d.ts +11 -0
- package/core/shared/components/labeled-data/labeled-data.component.d.ts +6 -0
- package/core/shared/components/language-code-selector/language-code-selector.component.d.ts +20 -0
- package/core/shared/components/language-selector/language-selector.component.d.ts +11 -0
- package/core/shared/components/localized-text/localized-text.component.d.ts +13 -0
- package/core/shared/components/manage-tags-dialog/manage-tags-dialog.component.d.ts +24 -0
- package/core/shared/components/modal-dialog/dialog-buttons.directive.d.ts +14 -0
- package/core/shared/components/modal-dialog/dialog-component-outlet.component.d.ts +14 -0
- package/core/shared/components/modal-dialog/dialog-title.directive.d.ts +14 -0
- package/core/shared/components/modal-dialog/modal-dialog.component.d.ts +44 -0
- package/core/shared/components/object-tree/object-tree.component.d.ts +32 -0
- package/core/shared/components/order-state-label/order-state-label.component.d.ts +17 -0
- package/core/shared/components/page/page.component.d.ts +21 -0
- package/core/shared/components/page-block/page-block.component.d.ts +5 -0
- package/core/shared/components/page-body/page-body.component.d.ts +5 -0
- package/core/shared/components/page-detail-layout/page-detail-layout.component.d.ts +5 -0
- package/core/shared/components/page-detail-layout/page-detail-sidebar.component.d.ts +5 -0
- package/core/shared/components/page-entity-info/page-entity-info.component.d.ts +10 -0
- package/core/shared/components/page-header/page-header.component.d.ts +5 -0
- package/core/shared/components/page-header-description/page-header-description.component.d.ts +5 -0
- package/core/shared/components/page-header-tabs/page-header-tabs.component.d.ts +14 -0
- package/core/shared/components/page-title/page-title.component.d.ts +16 -0
- package/core/shared/components/pagination-controls/pagination-controls.component.d.ts +11 -0
- package/core/shared/components/product-multi-selector-dialog/product-multi-selector-dialog.component.d.ts +38 -0
- package/core/shared/components/product-multi-selector-dialog/product-multi-selector-dialog.graphql.d.ts +1 -0
- package/core/shared/components/product-search-input/product-search-input.component.d.ts +28 -0
- package/core/shared/components/product-variant-selector/product-variant-selector.component.d.ts +58 -0
- package/core/shared/components/radio-card/radio-card-fieldset.component.d.ts +24 -0
- package/core/shared/components/radio-card/radio-card.component.d.ts +22 -0
- package/core/shared/components/rich-text-editor/external-image-dialog/external-image-dialog.component.d.ts +21 -0
- package/core/shared/components/rich-text-editor/link-dialog/link-dialog.component.d.ts +19 -0
- package/core/shared/components/rich-text-editor/prosemirror/context-menu/context-menu.component.d.ts +31 -0
- package/core/shared/components/rich-text-editor/prosemirror/context-menu/context-menu.service.d.ts +34 -0
- package/core/shared/components/rich-text-editor/prosemirror/custom-nodes.d.ts +5 -0
- package/core/shared/components/rich-text-editor/prosemirror/inputrules.d.ts +8 -0
- package/core/shared/components/rich-text-editor/prosemirror/keymap.d.ts +3 -0
- package/core/shared/components/rich-text-editor/prosemirror/menu/links.d.ts +4 -0
- package/core/shared/components/rich-text-editor/prosemirror/menu/menu-common.d.ts +16 -0
- package/core/shared/components/rich-text-editor/prosemirror/menu/menu-plugin.d.ts +9 -0
- package/core/shared/components/rich-text-editor/prosemirror/menu/menu.d.ts +3 -0
- package/core/shared/components/rich-text-editor/prosemirror/menu/sub-menu-with-icon.d.ts +14 -0
- package/core/shared/components/rich-text-editor/prosemirror/plugins/image-plugin.d.ts +7 -0
- package/core/shared/components/rich-text-editor/prosemirror/plugins/link-select-plugin.d.ts +5 -0
- package/core/shared/components/rich-text-editor/prosemirror/plugins/raw-editor-plugin.d.ts +7 -0
- package/core/shared/components/rich-text-editor/prosemirror/plugins/tables-plugin.d.ts +13 -0
- package/core/shared/components/rich-text-editor/prosemirror/prosemirror.service.d.ts +34 -0
- package/core/shared/components/rich-text-editor/prosemirror/types.d.ts +9 -0
- package/core/shared/components/rich-text-editor/prosemirror/utils.d.ts +9 -0
- package/core/shared/components/rich-text-editor/raw-html-dialog/raw-html-dialog.component.d.ts +21 -0
- package/core/shared/components/rich-text-editor/rich-text-editor.component.d.ts +42 -0
- package/core/shared/components/select-toggle/select-toggle.component.d.ts +15 -0
- package/core/shared/components/simple-dialog/simple-dialog.component.d.ts +14 -0
- package/core/shared/components/split-view/split-view.component.d.ts +23 -0
- package/core/shared/components/split-view/split-view.directive.d.ts +13 -0
- package/core/shared/components/status-badge/status-badge.component.d.ts +6 -0
- package/core/shared/components/tabbed-custom-fields/tabbed-custom-fields.component.d.ts +25 -0
- package/core/shared/components/table-row-action/table-row-action.component.d.ts +12 -0
- package/core/shared/components/tag-selector/tag-selector.component.d.ts +24 -0
- package/core/shared/components/timeline-entry/timeline-entry.component.d.ts +19 -0
- package/core/shared/components/title-input/title-input.component.d.ts +6 -0
- package/core/shared/components/ui-extension-point/ui-extension-point.component.d.ts +27 -0
- package/core/shared/components/zone-selector/zone-selector.component.d.ts +51 -0
- package/core/shared/directives/disabled.directive.d.ts +14 -0
- package/core/shared/directives/if-default-channel-active.directive.d.ts +16 -0
- package/core/shared/directives/if-directive-base.d.ts +27 -0
- package/core/shared/directives/if-multichannel.directive.d.ts +28 -0
- package/core/shared/directives/if-permissions.directive.d.ts +37 -0
- package/core/shared/dynamic-form-inputs/boolean-form-input/boolean-form-input.component.d.ts +19 -0
- package/core/shared/dynamic-form-inputs/code-editor-form-input/base-code-editor-form-input.component.d.ts +30 -0
- package/core/shared/dynamic-form-inputs/code-editor-form-input/html-editor-form-input.component.d.ts +22 -0
- package/core/shared/dynamic-form-inputs/code-editor-form-input/json-editor-form-input.component.d.ts +23 -0
- package/core/shared/dynamic-form-inputs/combination-mode-form-input/combination-mode-form-input.component.d.ts +28 -0
- package/core/shared/dynamic-form-inputs/currency-form-input/currency-form-input.component.d.ts +25 -0
- package/core/shared/dynamic-form-inputs/customer-group-form-input/customer-group-form-input.component.d.ts +33 -0
- package/core/shared/dynamic-form-inputs/date-form-input/date-form-input.component.d.ts +22 -0
- package/core/shared/dynamic-form-inputs/default-form-inputs.d.ts +19 -0
- package/core/shared/dynamic-form-inputs/dynamic-form-input/dynamic-form-input.component.d.ts +58 -0
- package/core/shared/dynamic-form-inputs/facet-value-form-input/facet-value-form-input.component.d.ts +23 -0
- package/core/shared/dynamic-form-inputs/number-form-input/number-form-input.component.d.ts +24 -0
- package/core/shared/dynamic-form-inputs/password-form-input/password-form-input.component.d.ts +19 -0
- package/core/shared/dynamic-form-inputs/product-multi-selector-form-input/product-multi-selector-form-input.component.d.ts +25 -0
- package/core/shared/dynamic-form-inputs/product-selector-form-input/product-selector-form-input.component.d.ts +34 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/asset/relation-asset-input.component.d.ts +23 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/customer/relation-customer-input.component.d.ts +25 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/generic/relation-generic-input.component.d.ts +18 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/product/relation-product-input.component.d.ts +26 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/product-variant/relation-product-variant-input.component.d.ts +26 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/relation-card/relation-card.component.d.ts +23 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/relation-form-input.component.d.ts +22 -0
- package/core/shared/dynamic-form-inputs/relation-form-input/relation-selector-dialog/relation-selector-dialog.component.d.ts +10 -0
- package/core/shared/dynamic-form-inputs/rich-text-form-input/rich-text-form-input.component.d.ts +19 -0
- package/core/shared/dynamic-form-inputs/select-form-input/select-form-input.component.d.ts +30 -0
- package/core/shared/dynamic-form-inputs/text-form-input/text-form-input.component.d.ts +21 -0
- package/core/shared/dynamic-form-inputs/textarea-form-input/textarea-form-input.component.d.ts +20 -0
- package/core/shared/pipes/asset-preview.pipe.d.ts +22 -0
- package/core/shared/pipes/channel-label.pipe.d.ts +7 -0
- package/core/shared/pipes/custom-field-description.pipe.d.ts +11 -0
- package/core/shared/pipes/custom-field-label.pipe.d.ts +13 -0
- package/core/shared/pipes/duration.pipe.d.ts +22 -0
- package/core/shared/pipes/file-size.pipe.d.ts +18 -0
- package/core/shared/pipes/has-permission.pipe.d.ts +27 -0
- package/core/shared/pipes/locale-base.pipe.d.ts +21 -0
- package/core/shared/pipes/locale-currency-name.pipe.d.ts +21 -0
- package/core/shared/pipes/locale-currency.pipe.d.ts +25 -0
- package/core/shared/pipes/locale-date.pipe.d.ts +23 -0
- package/core/shared/pipes/locale-language-name.pipe.d.ts +21 -0
- package/core/shared/pipes/locale-region-name.pipe.d.ts +21 -0
- package/core/shared/pipes/sentence-case.pipe.d.ts +10 -0
- package/core/shared/pipes/sort.pipe.d.ts +12 -0
- package/core/shared/pipes/state-i18n-token.pipe.d.ts +9 -0
- package/core/shared/pipes/string-to-color.pipe.d.ts +7 -0
- package/core/shared/pipes/time-ago.pipe.d.ts +21 -0
- package/core/shared/providers/routing/can-deactivate-detail-guard.d.ts +11 -0
- package/core/shared/shared.module.d.ts +168 -0
- package/core/validators/unicode-pattern.validator.d.ts +2 -0
- package/customer/components/add-customer-to-group-dialog/add-customer-to-group-dialog.component.d.ts +22 -0
- package/customer/components/address-card/address-card.component.d.ts +28 -0
- package/customer/components/address-detail-dialog/address-detail-dialog.component.d.ts +17 -0
- package/customer/components/customer-detail/customer-detail.component.d.ts +70 -0
- package/customer/components/customer-group-detail/customer-group-detail.component.d.ts +26 -0
- package/customer/components/customer-group-detail-dialog/customer-group-detail-dialog.component.d.ts +24 -0
- package/customer/components/customer-group-list/customer-group-list-bulk-actions.d.ts +1 -0
- package/customer/components/customer-group-list/customer-group-list.component.d.ts +29 -0
- package/customer/components/customer-group-member-list/customer-group-member-list-bulk-actions.d.ts +3 -0
- package/customer/components/customer-group-member-list/customer-group-member-list.component.d.ts +39 -0
- package/customer/components/customer-history/customer-history-entry-host.component.d.ts +18 -0
- package/customer/components/customer-history/customer-history.component.d.ts +51 -0
- package/customer/components/customer-list/customer-list-bulk-actions.d.ts +1 -0
- package/customer/components/customer-list/customer-list.component.d.ts +12 -0
- package/customer/components/customer-status-label/customer-status-label.component.d.ts +7 -0
- package/customer/components/select-customer-group-dialog/select-customer-group-dialog.component.d.ts +16 -0
- package/customer/customer.module.d.ts +24 -0
- package/customer/customer.routes.d.ts +4 -0
- package/customer/index.d.ts +5 -0
- package/customer/public_api.d.ts +18 -0
- package/dashboard/components/dashboard/dashboard.component.d.ts +34 -0
- package/dashboard/components/dashboard-widget/dashboard-widget.component.d.ts +13 -0
- package/dashboard/dashboard.module.d.ts +13 -0
- package/dashboard/dashboard.routes.d.ts +2 -0
- package/dashboard/default-widgets.d.ts +5 -0
- package/dashboard/index.d.ts +5 -0
- package/dashboard/public_api.d.ts +10 -0
- package/dashboard/widgets/latest-orders-widget/latest-orders-widget.component.d.ts +18 -0
- package/dashboard/widgets/order-chart-widget/order-chart-widget.component.d.ts +17 -0
- package/dashboard/widgets/order-summary-widget/order-summary-widget.component.d.ts +32 -0
- package/dashboard/widgets/test-widget/test-widget.component.d.ts +10 -0
- package/dashboard/widgets/welcome-widget/welcome-widget.component.d.ts +22 -0
- package/esm2022/catalog/catalog.module.mjs +331 -0
- package/esm2022/catalog/catalog.routes.mjs +144 -0
- package/esm2022/catalog/components/apply-facet-dialog/apply-facet-dialog.component.mjs +30 -0
- package/esm2022/catalog/components/asset-detail/asset-detail.component.mjs +77 -0
- package/esm2022/catalog/components/asset-list/asset-list.component.mjs +120 -0
- package/esm2022/catalog/components/assign-products-to-channel-dialog/assign-products-to-channel-dialog.component.mjs +102 -0
- package/esm2022/catalog/components/bulk-add-facet-values-dialog/bulk-add-facet-values-dialog.component.mjs +83 -0
- package/esm2022/catalog/components/bulk-add-facet-values-dialog/bulk-add-facet-values-dialog.graphql.mjs +69 -0
- package/esm2022/catalog/components/collection-contents/collection-contents.component.mjs +124 -0
- package/esm2022/catalog/components/collection-data-table/collection-data-table.component.mjs +95 -0
- package/esm2022/catalog/components/collection-detail/collection-detail.component.mjs +263 -0
- package/esm2022/catalog/components/collection-list/collection-breadcrumb.pipe.mjs +19 -0
- package/esm2022/catalog/components/collection-list/collection-list-bulk-actions.mjs +97 -0
- package/esm2022/catalog/components/collection-list/collection-list.component.mjs +157 -0
- package/esm2022/catalog/components/collection-tree/array-to-tree.mjs +56 -0
- package/esm2022/catalog/components/collection-tree/collection-tree-node.component.mjs +125 -0
- package/esm2022/catalog/components/collection-tree/collection-tree.component.mjs +49 -0
- package/esm2022/catalog/components/collection-tree/collection-tree.service.mjs +68 -0
- package/esm2022/catalog/components/collection-tree/collection-tree.types.mjs +2 -0
- package/esm2022/catalog/components/confirm-variant-deletion-dialog/confirm-variant-deletion-dialog.component.mjs +23 -0
- package/esm2022/catalog/components/create-facet-value-dialog/create-facet-value-dialog.component.mjs +44 -0
- package/esm2022/catalog/components/create-product-option-group-dialog/create-product-option-group-dialog.component.mjs +44 -0
- package/esm2022/catalog/components/create-product-variant-dialog/create-product-variant-dialog.component.mjs +80 -0
- package/esm2022/catalog/components/facet-detail/facet-detail.component.mjs +338 -0
- package/esm2022/catalog/components/facet-list/facet-list-bulk-actions.mjs +148 -0
- package/esm2022/catalog/components/facet-list/facet-list.component.mjs +91 -0
- package/esm2022/catalog/components/generate-product-variants/generate-product-variants.component.mjs +133 -0
- package/esm2022/catalog/components/move-collections-dialog/move-collections-dialog.component.mjs +100 -0
- package/esm2022/catalog/components/option-value-input/option-value-input.component.mjs +156 -0
- package/esm2022/catalog/components/product-detail/product-detail.component.mjs +321 -0
- package/esm2022/catalog/components/product-list/product-list-bulk-actions.mjs +144 -0
- package/esm2022/catalog/components/product-list/product-list.component.mjs +159 -0
- package/esm2022/catalog/components/product-list/product-list.graphql.mjs +37 -0
- package/esm2022/catalog/components/product-options-editor/product-options-editor.component.mjs +207 -0
- package/esm2022/catalog/components/product-variant-detail/product-variant-detail.component.mjs +266 -0
- package/esm2022/catalog/components/product-variant-detail/product-variant-detail.graphql.mjs +129 -0
- package/esm2022/catalog/components/product-variant-list/product-variant-list-bulk-actions.mjs +123 -0
- package/esm2022/catalog/components/product-variant-list/product-variant-list.component.mjs +118 -0
- package/esm2022/catalog/components/product-variant-list/product-variant-list.graphql.mjs +51 -0
- package/esm2022/catalog/components/product-variant-quick-jump/product-variant-quick-jump.component.mjs +53 -0
- package/esm2022/catalog/components/product-variants-editor/product-variants-editor.component.mjs +292 -0
- package/esm2022/catalog/components/product-variants-table/product-variants-table.component.mjs +72 -0
- package/esm2022/catalog/components/update-product-option-dialog/update-product-option-dialog.component.mjs +64 -0
- package/esm2022/catalog/components/variant-price-detail/variant-price-detail.component.mjs +59 -0
- package/esm2022/catalog/components/variant-price-strategy-detail/variant-price-strategy-detail.component.mjs +33 -0
- package/esm2022/catalog/deenruv-admin-ui-catalog.mjs +5 -0
- package/esm2022/catalog/providers/product-detail/product-detail.service.mjs +236 -0
- package/esm2022/catalog/providers/product-detail/replace-last.mjs +18 -0
- package/esm2022/catalog/providers/routing/product-variants-resolver.mjs +28 -0
- package/esm2022/catalog/public_api.mjs +50 -0
- package/esm2022/core/app.component.mjs +94 -0
- package/esm2022/core/app.component.module.mjs +19 -0
- package/esm2022/core/app.config.mjs +11 -0
- package/esm2022/core/common/base-detail.component.mjs +208 -0
- package/esm2022/core/common/base-entity-resolver.mjs +60 -0
- package/esm2022/core/common/base-list.component.mjs +186 -0
- package/esm2022/core/common/component-registry-types.mjs +2 -0
- package/esm2022/core/common/deactivate-aware.mjs +2 -0
- package/esm2022/core/common/detail-breadcrumb.mjs +26 -0
- package/esm2022/core/common/generated-types.mjs +1371 -0
- package/esm2022/core/common/introspection-result-wrapper.mjs +3 -0
- package/esm2022/core/common/introspection-result.mjs +329 -0
- package/esm2022/core/common/single-search-selection-model.mjs +51 -0
- package/esm2022/core/common/title-setter.mjs +14 -0
- package/esm2022/core/common/utilities/bulk-action-utils.mjs +271 -0
- package/esm2022/core/common/utilities/configurable-operation-utils.mjs +116 -0
- package/esm2022/core/common/utilities/create-updated-translatable.mjs +58 -0
- package/esm2022/core/common/utilities/custom-field-default-value.mjs +28 -0
- package/esm2022/core/common/utilities/find-translation.mjs +9 -0
- package/esm2022/core/common/utilities/get-default-ui-language.mjs +12 -0
- package/esm2022/core/common/utilities/interpolate-description.mjs +27 -0
- package/esm2022/core/common/utilities/selection-manager.mjs +96 -0
- package/esm2022/core/common/utilities/string-to-color.mjs +36 -0
- package/esm2022/core/common/version.mjs +3 -0
- package/esm2022/core/components/alerts/alerts.component.mjs +26 -0
- package/esm2022/core/components/app-shell/app-shell.component.mjs +104 -0
- package/esm2022/core/components/base-nav/base-nav.component.mjs +298 -0
- package/esm2022/core/components/breadcrumb/breadcrumb.component.mjs +33 -0
- package/esm2022/core/components/channel-switcher/channel-switcher.component.mjs +50 -0
- package/esm2022/core/components/main-nav/main-nav.component.mjs +62 -0
- package/esm2022/core/components/notification/notification.component.mjs +85 -0
- package/esm2022/core/components/overlay-host/overlay-host.component.mjs +22 -0
- package/esm2022/core/components/settings-nav/settings-nav.component.mjs +27 -0
- package/esm2022/core/components/theme-switcher/theme-switcher.component.mjs +39 -0
- package/esm2022/core/components/ui-language-switcher-dialog/ui-language-switcher-dialog.component.mjs +75 -0
- package/esm2022/core/components/user-menu/user-menu.component.mjs +37 -0
- package/esm2022/core/core.module.mjs +165 -0
- package/esm2022/core/data/check-jobs-link.mjs +32 -0
- package/esm2022/core/data/client-state/client-defaults.mjs +33 -0
- package/esm2022/core/data/client-state/client-resolvers.mjs +136 -0
- package/esm2022/core/data/data.module.mjs +135 -0
- package/esm2022/core/data/definitions/administrator-definitions.mjs +135 -0
- package/esm2022/core/data/definitions/auth-definitions.mjs +40 -0
- package/esm2022/core/data/definitions/client-definitions.mjs +137 -0
- package/esm2022/core/data/definitions/collection-definitions.mjs +184 -0
- package/esm2022/core/data/definitions/customer-definitions.mjs +261 -0
- package/esm2022/core/data/definitions/facet-definitions.mjs +155 -0
- package/esm2022/core/data/definitions/order-definitions.mjs +594 -0
- package/esm2022/core/data/definitions/product-definitions.mjs +828 -0
- package/esm2022/core/data/definitions/promotion-definitions.mjs +76 -0
- package/esm2022/core/data/definitions/settings-definitions.mjs +735 -0
- package/esm2022/core/data/definitions/shared-definitions.mjs +33 -0
- package/esm2022/core/data/definitions/shipping-definitions.mjs +98 -0
- package/esm2022/core/data/omit-typename-link.mjs +20 -0
- package/esm2022/core/data/providers/administrator-data.service.mjs +53 -0
- package/esm2022/core/data/providers/auth-data.service.mjs +20 -0
- package/esm2022/core/data/providers/base-data.service.mjs +66 -0
- package/esm2022/core/data/providers/client-data.service.mjs +82 -0
- package/esm2022/core/data/providers/collection-data.service.mjs +84 -0
- package/esm2022/core/data/providers/customer-data.service.mjs +125 -0
- package/esm2022/core/data/providers/data.service.mjs +90 -0
- package/esm2022/core/data/providers/facet-data.service.mjs +63 -0
- package/esm2022/core/data/providers/fetch-adapter.mjs +34 -0
- package/esm2022/core/data/providers/interceptor.mjs +162 -0
- package/esm2022/core/data/providers/order-data.service.mjs +135 -0
- package/esm2022/core/data/providers/product-data.service.mjs +257 -0
- package/esm2022/core/data/providers/promotion-data.service.mjs +50 -0
- package/esm2022/core/data/providers/settings-data.service.mjs +246 -0
- package/esm2022/core/data/providers/shipping-method-data.service.mjs +58 -0
- package/esm2022/core/data/query-result.mjs +77 -0
- package/esm2022/core/data/server-config.mjs +78 -0
- package/esm2022/core/data/utils/add-custom-fields.mjs +84 -0
- package/esm2022/core/data/utils/get-server-location.mjs +17 -0
- package/esm2022/core/data/utils/is-entity-create-or-update-mutation.mjs +45 -0
- package/esm2022/core/data/utils/remove-readonly-custom-fields.mjs +30 -0
- package/esm2022/core/data/utils/transform-relation-custom-field-inputs.mjs +46 -0
- package/esm2022/core/deenruv-admin-ui-core.mjs +5 -0
- package/esm2022/core/extension/add-action-bar-dropdown-menu-item.mjs +35 -0
- package/esm2022/core/extension/add-action-bar-item.mjs +31 -0
- package/esm2022/core/extension/add-nav-menu-item.mjs +75 -0
- package/esm2022/core/extension/components/angular-route.component.mjs +67 -0
- package/esm2022/core/extension/components/route.component.mjs +80 -0
- package/esm2022/core/extension/providers/page-metadata.service.mjs +20 -0
- package/esm2022/core/extension/register-alert.mjs +22 -0
- package/esm2022/core/extension/register-bulk-action.mjs +59 -0
- package/esm2022/core/extension/register-custom-detail-component.mjs +65 -0
- package/esm2022/core/extension/register-dashboard-widget.mjs +36 -0
- package/esm2022/core/extension/register-data-table-component.mjs +51 -0
- package/esm2022/core/extension/register-form-input-component.mjs +61 -0
- package/esm2022/core/extension/register-history-entry-component.mjs +76 -0
- package/esm2022/core/extension/register-page-tab.mjs +36 -0
- package/esm2022/core/extension/register-route-component.mjs +95 -0
- package/esm2022/core/extension/types.mjs +2 -0
- package/esm2022/core/providers/alerts/alerts.service.mjs +114 -0
- package/esm2022/core/providers/auth/auth.service.mjs +124 -0
- package/esm2022/core/providers/breadcrumb/breadcrumb.service.mjs +109 -0
- package/esm2022/core/providers/bulk-action-registry/bulk-action-registry.service.mjs +28 -0
- package/esm2022/core/providers/bulk-action-registry/bulk-action-types.mjs +2 -0
- package/esm2022/core/providers/channel/channel.service.mjs +39 -0
- package/esm2022/core/providers/component-registry/component-registry.service.mjs +25 -0
- package/esm2022/core/providers/currency/currency.service.mjs +21 -0
- package/esm2022/core/providers/custom-detail-component/custom-detail-component-types.mjs +2 -0
- package/esm2022/core/providers/custom-detail-component/custom-detail-component.service.mjs +27 -0
- package/esm2022/core/providers/custom-field-component/custom-field-component.service.mjs +38 -0
- package/esm2022/core/providers/custom-history-entry-component/history-entry-component-types.mjs +2 -0
- package/esm2022/core/providers/custom-history-entry-component/history-entry-component.service.mjs +22 -0
- package/esm2022/core/providers/dashboard-widget/dashboard-widget-types.mjs +2 -0
- package/esm2022/core/providers/dashboard-widget/dashboard-widget.service.mjs +91 -0
- package/esm2022/core/providers/data-table/data-table-filter-collection.mjs +295 -0
- package/esm2022/core/providers/data-table/data-table-filter.mjs +114 -0
- package/esm2022/core/providers/data-table/data-table-sort-collection.mjs +115 -0
- package/esm2022/core/providers/data-table/data-table-sort.mjs +34 -0
- package/esm2022/core/providers/guard/auth.guard.mjs +38 -0
- package/esm2022/core/providers/health-check/health-check.service.mjs +34 -0
- package/esm2022/core/providers/i18n/custom-http-loader.mjs +39 -0
- package/esm2022/core/providers/i18n/custom-message-format-compiler.mjs +31 -0
- package/esm2022/core/providers/i18n/i18n.service.mjs +78 -0
- package/esm2022/core/providers/job-queue/job-queue.service.mjs +91 -0
- package/esm2022/core/providers/local-storage/local-storage.service.mjs +97 -0
- package/esm2022/core/providers/localization/localization.service.mjs +31 -0
- package/esm2022/core/providers/modal/modal.service.mjs +96 -0
- package/esm2022/core/providers/modal/modal.types.mjs +2 -0
- package/esm2022/core/providers/nav-builder/nav-builder-types.mjs +2 -0
- package/esm2022/core/providers/nav-builder/nav-builder.service.mjs +174 -0
- package/esm2022/core/providers/notification/notification.service.mjs +157 -0
- package/esm2022/core/providers/overlay-host/overlay-host.service.mjs +48 -0
- package/esm2022/core/providers/page/page.service.mjs +63 -0
- package/esm2022/core/providers/permissions/permissions.service.mjs +46 -0
- package/esm2022/core/public_api.mjs +315 -0
- package/esm2022/core/shared/components/action-bar/action-bar.component.mjs +54 -0
- package/esm2022/core/shared/components/action-bar-dropdown-menu/action-bar-dropdown-menu.component.mjs +69 -0
- package/esm2022/core/shared/components/action-bar-items/action-bar-base.component.mjs +72 -0
- package/esm2022/core/shared/components/action-bar-items/action-bar-items.component.mjs +50 -0
- package/esm2022/core/shared/components/address-form/address-form.component.mjs +24 -0
- package/esm2022/core/shared/components/affixed-input/affixed-input.component.mjs +19 -0
- package/esm2022/core/shared/components/affixed-input/percentage-suffix-input.component.mjs +86 -0
- package/esm2022/core/shared/components/asset-file-input/asset-file-input.component.mjs +97 -0
- package/esm2022/core/shared/components/asset-gallery/asset-gallery.component.mjs +96 -0
- package/esm2022/core/shared/components/asset-gallery/asset-gallery.types.mjs +2 -0
- package/esm2022/core/shared/components/asset-picker-dialog/asset-picker-dialog.component.mjs +144 -0
- package/esm2022/core/shared/components/asset-preview/asset-preview.component.mjs +229 -0
- package/esm2022/core/shared/components/asset-preview-dialog/asset-preview-dialog.component.mjs +49 -0
- package/esm2022/core/shared/components/asset-preview-links/asset-preview-links.component.mjs +25 -0
- package/esm2022/core/shared/components/asset-search-input/asset-search-input.component.mjs +102 -0
- package/esm2022/core/shared/components/assets/assets.component.mjs +109 -0
- package/esm2022/core/shared/components/assign-to-channel-dialog/assign-to-channel-dialog.component.mjs +56 -0
- package/esm2022/core/shared/components/bulk-action-menu/bulk-action-menu.component.mjs +100 -0
- package/esm2022/core/shared/components/card/card.component.mjs +32 -0
- package/esm2022/core/shared/components/channel-assignment-control/channel-assignment-control.component.mjs +116 -0
- package/esm2022/core/shared/components/channel-badge/channel-badge.component.mjs +19 -0
- package/esm2022/core/shared/components/chart/chart.component.mjs +100 -0
- package/esm2022/core/shared/components/chart/tooltip-plugin.mjs +143 -0
- package/esm2022/core/shared/components/chip/chip.component.mjs +47 -0
- package/esm2022/core/shared/components/configurable-input/configurable-input.component.mjs +161 -0
- package/esm2022/core/shared/components/currency-code-selector/currency-code-selector.component.mjs +64 -0
- package/esm2022/core/shared/components/currency-input/currency-input.component.mjs +155 -0
- package/esm2022/core/shared/components/custom-detail-component-host/custom-detail-component-host.component.mjs +44 -0
- package/esm2022/core/shared/components/custom-field-control/custom-field-control.component.mjs +88 -0
- package/esm2022/core/shared/components/customer-label/customer-label.component.mjs +17 -0
- package/esm2022/core/shared/components/data-table/data-table-column.component.mjs +29 -0
- package/esm2022/core/shared/components/data-table/data-table.component.mjs +177 -0
- package/esm2022/core/shared/components/data-table-2/data-table-column.component.mjs +64 -0
- package/esm2022/core/shared/components/data-table-2/data-table-custom-component.service.mjs +26 -0
- package/esm2022/core/shared/components/data-table-2/data-table-custom-field-column.component.mjs +52 -0
- package/esm2022/core/shared/components/data-table-2/data-table-search.component.mjs +21 -0
- package/esm2022/core/shared/components/data-table-2/data-table2.component.mjs +308 -0
- package/esm2022/core/shared/components/data-table-column-picker/data-table-column-picker.component.mjs +44 -0
- package/esm2022/core/shared/components/data-table-filter-label/data-table-filter-label.component.mjs +32 -0
- package/esm2022/core/shared/components/data-table-filter-presets/add-filter-preset-button.component.mjs +69 -0
- package/esm2022/core/shared/components/data-table-filter-presets/data-table-filter-presets.component.mjs +80 -0
- package/esm2022/core/shared/components/data-table-filter-presets/filter-preset.service.mjs +79 -0
- package/esm2022/core/shared/components/data-table-filter-presets/rename-filter-preset-dialog.component.mjs +20 -0
- package/esm2022/core/shared/components/data-table-filters/custom-filter-component.directive.mjs +16 -0
- package/esm2022/core/shared/components/data-table-filters/data-table-filters.component.mjs +220 -0
- package/esm2022/core/shared/components/datetime-picker/constants.mjs +20 -0
- package/esm2022/core/shared/components/datetime-picker/datetime-picker.component.mjs +226 -0
- package/esm2022/core/shared/components/datetime-picker/datetime-picker.service.mjs +201 -0
- package/esm2022/core/shared/components/datetime-picker/types.mjs +2 -0
- package/esm2022/core/shared/components/dropdown/dropdown-item.directive.mjs +28 -0
- package/esm2022/core/shared/components/dropdown/dropdown-menu.component.mjs +202 -0
- package/esm2022/core/shared/components/dropdown/dropdown-trigger.directive.mjs +25 -0
- package/esm2022/core/shared/components/dropdown/dropdown.component.mjs +58 -0
- package/esm2022/core/shared/components/duplicate-entity-dialog/duplicate-entity-dialog.component.mjs +111 -0
- package/esm2022/core/shared/components/duplicate-entity-dialog/duplicate-entity-dialog.graphql.mjs +38 -0
- package/esm2022/core/shared/components/edit-note-dialog/edit-note-dialog.component.mjs +32 -0
- package/esm2022/core/shared/components/empty-placeholder/empty-placeholder.component.mjs +16 -0
- package/esm2022/core/shared/components/entity-info/entity-info.component.mjs +26 -0
- package/esm2022/core/shared/components/extension-host/extension-host-config.mjs +7 -0
- package/esm2022/core/shared/components/extension-host/extension-host.component.mjs +81 -0
- package/esm2022/core/shared/components/extension-host/extension-host.service.mjs +99 -0
- package/esm2022/core/shared/components/extension-host/host-external-frame.mjs +41 -0
- package/esm2022/core/shared/components/facet-value-chip/facet-value-chip.component.mjs +26 -0
- package/esm2022/core/shared/components/facet-value-selector/facet-value-selector.component.mjs +150 -0
- package/esm2022/core/shared/components/focal-point-control/focal-point-control.component.mjs +71 -0
- package/esm2022/core/shared/components/form-field/form-field-control.directive.mjs +37 -0
- package/esm2022/core/shared/components/form-field/form-field.component.mjs +73 -0
- package/esm2022/core/shared/components/form-item/form-item.component.mjs +21 -0
- package/esm2022/core/shared/components/formatted-address/formatted-address.component.mjs +38 -0
- package/esm2022/core/shared/components/help-tooltip/help-tooltip.component.mjs +16 -0
- package/esm2022/core/shared/components/history-entry-detail/history-entry-detail.component.mjs +16 -0
- package/esm2022/core/shared/components/items-per-page-controls/items-per-page-controls.component.mjs +28 -0
- package/esm2022/core/shared/components/labeled-data/labeled-data.component.mjs +13 -0
- package/esm2022/core/shared/components/language-code-selector/language-code-selector.component.mjs +72 -0
- package/esm2022/core/shared/components/language-selector/language-selector.component.mjs +30 -0
- package/esm2022/core/shared/components/localized-text/localized-text.component.mjs +24 -0
- package/esm2022/core/shared/components/manage-tags-dialog/manage-tags-dialog.component.mjs +61 -0
- package/esm2022/core/shared/components/modal-dialog/dialog-buttons.directive.mjs +23 -0
- package/esm2022/core/shared/components/modal-dialog/dialog-component-outlet.component.mjs +29 -0
- package/esm2022/core/shared/components/modal-dialog/dialog-title.directive.mjs +23 -0
- package/esm2022/core/shared/components/modal-dialog/modal-dialog.component.mjs +69 -0
- package/esm2022/core/shared/components/object-tree/object-tree.component.mjs +56 -0
- package/esm2022/core/shared/components/order-state-label/order-state-label.component.mjs +47 -0
- package/esm2022/core/shared/components/page/page.component.mjs +38 -0
- package/esm2022/core/shared/components/page-block/page-block.component.mjs +11 -0
- package/esm2022/core/shared/components/page-body/page-body.component.mjs +11 -0
- package/esm2022/core/shared/components/page-detail-layout/page-detail-layout.component.mjs +11 -0
- package/esm2022/core/shared/components/page-detail-layout/page-detail-sidebar.component.mjs +15 -0
- package/esm2022/core/shared/components/page-entity-info/page-entity-info.component.mjs +16 -0
- package/esm2022/core/shared/components/page-header/page-header.component.mjs +11 -0
- package/esm2022/core/shared/components/page-header-description/page-header-description.component.mjs +11 -0
- package/esm2022/core/shared/components/page-header-tabs/page-header-tabs.component.mjs +26 -0
- package/esm2022/core/shared/components/page-title/page-title.component.mjs +40 -0
- package/esm2022/core/shared/components/pagination-controls/pagination-controls.component.mjs +26 -0
- package/esm2022/core/shared/components/product-multi-selector-dialog/product-multi-selector-dialog.component.mjs +138 -0
- package/esm2022/core/shared/components/product-multi-selector-dialog/product-multi-selector-dialog.graphql.mjs +44 -0
- package/esm2022/core/shared/components/product-search-input/product-search-input.component.mjs +104 -0
- package/esm2022/core/shared/components/product-variant-selector/product-variant-selector.component.mjs +62 -0
- package/esm2022/core/shared/components/radio-card/radio-card-fieldset.component.mjs +54 -0
- package/esm2022/core/shared/components/radio-card/radio-card.component.mjs +53 -0
- package/esm2022/core/shared/components/rich-text-editor/external-image-dialog/external-image-dialog.component.mjs +37 -0
- package/esm2022/core/shared/components/rich-text-editor/link-dialog/link-dialog.component.mjs +35 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/context-menu/context-menu.component.mjs +136 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/context-menu/context-menu.service.mjs +44 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/custom-nodes.mjs +97 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/inputrules.mjs +61 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/keymap.mjs +118 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/menu/links.mjs +69 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/menu/menu-common.mjs +41 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/menu/menu-plugin.mjs +12 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/menu/menu.mjs +247 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/menu/sub-menu-with-icon.mjs +16 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/plugins/image-plugin.mjs +98 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/plugins/link-select-plugin.mjs +22 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/plugins/raw-editor-plugin.mjs +96 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/plugins/tables-plugin.mjs +164 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/prosemirror.service.mjs +155 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/types.mjs +2 -0
- package/esm2022/core/shared/components/rich-text-editor/prosemirror/utils.mjs +26 -0
- package/esm2022/core/shared/components/rich-text-editor/raw-html-dialog/raw-html-dialog.component.mjs +59 -0
- package/esm2022/core/shared/components/rich-text-editor/rich-text-editor.component.mjs +106 -0
- package/esm2022/core/shared/components/select-toggle/select-toggle.component.mjs +35 -0
- package/esm2022/core/shared/components/simple-dialog/simple-dialog.component.mjs +24 -0
- package/esm2022/core/shared/components/split-view/split-view.component.mjs +62 -0
- package/esm2022/core/shared/components/split-view/split-view.directive.mjs +28 -0
- package/esm2022/core/shared/components/status-badge/status-badge.component.mjs +16 -0
- package/esm2022/core/shared/components/tabbed-custom-fields/tabbed-custom-fields.component.mjs +70 -0
- package/esm2022/core/shared/components/table-row-action/table-row-action.component.mjs +28 -0
- package/esm2022/core/shared/components/tag-selector/tag-selector.component.mjs +60 -0
- package/esm2022/core/shared/components/timeline-entry/timeline-entry.component.mjs +54 -0
- package/esm2022/core/shared/components/title-input/title-input.component.mjs +21 -0
- package/esm2022/core/shared/components/ui-extension-point/ui-extension-point.component.mjs +142 -0
- package/esm2022/core/shared/components/zone-selector/zone-selector.component.mjs +99 -0
- package/esm2022/core/shared/directives/disabled.directive.mjs +41 -0
- package/esm2022/core/shared/directives/if-default-channel-active.directive.mjs +37 -0
- package/esm2022/core/shared/directives/if-directive-base.mjs +73 -0
- package/esm2022/core/shared/directives/if-multichannel.directive.mjs +43 -0
- package/esm2022/core/shared/directives/if-permissions.directive.mjs +66 -0
- package/esm2022/core/shared/dynamic-form-inputs/boolean-form-input/boolean-form-input.component.mjs +23 -0
- package/esm2022/core/shared/dynamic-form-inputs/code-editor-form-input/base-code-editor-form-input.component.mjs +62 -0
- package/esm2022/core/shared/dynamic-form-inputs/code-editor-form-input/html-editor-form-input.component.mjs +59 -0
- package/esm2022/core/shared/dynamic-form-inputs/code-editor-form-input/json-editor-form-input.component.mjs +85 -0
- package/esm2022/core/shared/dynamic-form-inputs/combination-mode-form-input/combination-mode-form-input.component.mjs +45 -0
- package/esm2022/core/shared/dynamic-form-inputs/currency-form-input/currency-form-input.component.mjs +32 -0
- package/esm2022/core/shared/dynamic-form-inputs/customer-group-form-input/customer-group-form-input.component.mjs +47 -0
- package/esm2022/core/shared/dynamic-form-inputs/date-form-input/date-form-input.component.mjs +32 -0
- package/esm2022/core/shared/dynamic-form-inputs/default-form-inputs.mjs +44 -0
- package/esm2022/core/shared/dynamic-form-inputs/dynamic-form-input/dynamic-form-input.component.mjs +271 -0
- package/esm2022/core/shared/dynamic-form-inputs/facet-value-form-input/facet-value-form-input.component.mjs +34 -0
- package/esm2022/core/shared/dynamic-form-inputs/number-form-input/number-form-input.component.mjs +39 -0
- package/esm2022/core/shared/dynamic-form-inputs/password-form-input/password-form-input.component.mjs +21 -0
- package/esm2022/core/shared/dynamic-form-inputs/product-multi-selector-form-input/product-multi-selector-form-input.component.mjs +49 -0
- package/esm2022/core/shared/dynamic-form-inputs/product-selector-form-input/product-selector-form-input.component.mjs +66 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/asset/relation-asset-input.component.mjs +84 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/customer/relation-customer-input.component.mjs +66 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/generic/relation-generic-input.component.mjs +54 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/product/relation-product-input.component.mjs +87 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/product-variant/relation-product-variant-input.component.mjs +87 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/relation-card/relation-card.component.mjs +60 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/relation-form-input.component.mjs +29 -0
- package/esm2022/core/shared/dynamic-form-inputs/relation-form-input/relation-selector-dialog/relation-selector-dialog.component.mjs +14 -0
- package/esm2022/core/shared/dynamic-form-inputs/rich-text-form-input/rich-text-form-input.component.mjs +21 -0
- package/esm2022/core/shared/dynamic-form-inputs/select-form-input/select-form-input.component.mjs +40 -0
- package/esm2022/core/shared/dynamic-form-inputs/text-form-input/text-form-input.component.mjs +28 -0
- package/esm2022/core/shared/dynamic-form-inputs/textarea-form-input/textarea-form-input.component.mjs +24 -0
- package/esm2022/core/shared/pipes/asset-preview.pipe.mjs +42 -0
- package/esm2022/core/shared/pipes/channel-label.pipe.mjs +23 -0
- package/esm2022/core/shared/pipes/custom-field-description.pipe.mjs +30 -0
- package/esm2022/core/shared/pipes/custom-field-label.pipe.mjs +39 -0
- package/esm2022/core/shared/pipes/duration.pipe.mjs +49 -0
- package/esm2022/core/shared/pipes/file-size.pipe.mjs +47 -0
- package/esm2022/core/shared/pipes/has-permission.pipe.mjs +54 -0
- package/esm2022/core/shared/pipes/locale-base.pipe.mjs +55 -0
- package/esm2022/core/shared/pipes/locale-currency-name.pipe.mjs +60 -0
- package/esm2022/core/shared/pipes/locale-currency.pipe.mjs +56 -0
- package/esm2022/core/shared/pipes/locale-date.pipe.mjs +90 -0
- package/esm2022/core/shared/pipes/locale-language-name.pipe.mjs +51 -0
- package/esm2022/core/shared/pipes/locale-region-name.pipe.mjs +51 -0
- package/esm2022/core/shared/pipes/sentence-case.pipe.mjs +30 -0
- package/esm2022/core/shared/pipes/sort.pipe.mjs +34 -0
- package/esm2022/core/shared/pipes/state-i18n-token.pipe.mjs +54 -0
- package/esm2022/core/shared/pipes/string-to-color.pipe.mjs +18 -0
- package/esm2022/core/shared/pipes/time-ago.pipe.mjs +52 -0
- package/esm2022/core/shared/providers/routing/can-deactivate-detail-guard.mjs +33 -0
- package/esm2022/core/shared/shared.module.mjs +707 -0
- package/esm2022/core/validators/unicode-pattern.validator.mjs +8 -0
- package/esm2022/customer/components/add-customer-to-group-dialog/add-customer-to-group-dialog.component.mjs +39 -0
- package/esm2022/customer/components/address-card/address-card.component.mjs +97 -0
- package/esm2022/customer/components/address-detail-dialog/address-detail-dialog.component.mjs +28 -0
- package/esm2022/customer/components/customer-detail/customer-detail.component.mjs +441 -0
- package/esm2022/customer/components/customer-group-detail/customer-group-detail.component.mjs +90 -0
- package/esm2022/customer/components/customer-group-detail-dialog/customer-group-detail-dialog.component.mjs +46 -0
- package/esm2022/customer/components/customer-group-list/customer-group-list-bulk-actions.mjs +9 -0
- package/esm2022/customer/components/customer-group-list/customer-group-list.component.mjs +148 -0
- package/esm2022/customer/components/customer-group-member-list/customer-group-member-list-bulk-actions.mjs +27 -0
- package/esm2022/customer/components/customer-group-member-list/customer-group-member-list.component.mjs +91 -0
- package/esm2022/customer/components/customer-history/customer-history-entry-host.component.mjs +62 -0
- package/esm2022/customer/components/customer-history/customer-history.component.mjs +89 -0
- package/esm2022/customer/components/customer-list/customer-list-bulk-actions.mjs +9 -0
- package/esm2022/customer/components/customer-list/customer-list.component.mjs +108 -0
- package/esm2022/customer/components/customer-status-label/customer-status-label.component.mjs +17 -0
- package/esm2022/customer/components/select-customer-group-dialog/select-customer-group-dialog.component.mjs +31 -0
- package/esm2022/customer/customer.module.mjs +146 -0
- package/esm2022/customer/customer.routes.mjs +50 -0
- package/esm2022/customer/deenruv-admin-ui-customer.mjs +5 -0
- package/esm2022/customer/public_api.mjs +20 -0
- package/esm2022/dashboard/components/dashboard/dashboard.component.mjs +124 -0
- package/esm2022/dashboard/components/dashboard-widget/dashboard-widget.component.mjs +32 -0
- package/esm2022/dashboard/dashboard.module.mjs +34 -0
- package/esm2022/dashboard/dashboard.routes.mjs +9 -0
- package/esm2022/dashboard/deenruv-admin-ui-dashboard.mjs +5 -0
- package/esm2022/dashboard/default-widgets.mjs +31 -0
- package/esm2022/dashboard/public_api.mjs +12 -0
- package/esm2022/dashboard/widgets/latest-orders-widget/latest-orders-widget.component.mjs +73 -0
- package/esm2022/dashboard/widgets/order-chart-widget/order-chart-widget.component.mjs +66 -0
- package/esm2022/dashboard/widgets/order-summary-widget/order-summary-widget.component.mjs +68 -0
- package/esm2022/dashboard/widgets/test-widget/test-widget.component.mjs +22 -0
- package/esm2022/dashboard/widgets/welcome-widget/welcome-widget.component.mjs +39 -0
- package/esm2022/deenruv-admin-ui.mjs +5 -0
- package/esm2022/login/components/login/login.component.mjs +97 -0
- package/esm2022/login/deenruv-admin-ui-login.mjs +5 -0
- package/esm2022/login/login.module.mjs +21 -0
- package/esm2022/login/login.routes.mjs +11 -0
- package/esm2022/login/providers/login.guard.mjs +31 -0
- package/esm2022/login/public_api.mjs +6 -0
- package/esm2022/marketing/components/promotion-detail/promotion-detail.component.mjs +269 -0
- package/esm2022/marketing/components/promotion-list/promotion-list-bulk-actions.mjs +78 -0
- package/esm2022/marketing/components/promotion-list/promotion-list.component.mjs +128 -0
- package/esm2022/marketing/deenruv-admin-ui-marketing.mjs +5 -0
- package/esm2022/marketing/marketing.module.mjs +75 -0
- package/esm2022/marketing/marketing.routes.mjs +32 -0
- package/esm2022/marketing/public_api.mjs +7 -0
- package/esm2022/order/common/get-refundable-payments.mjs +19 -0
- package/esm2022/order/common/modify-order-types.mjs +2 -0
- package/esm2022/order/components/add-manual-payment-dialog/add-manual-payment-dialog.component.mjs +61 -0
- package/esm2022/order/components/cancel-order-dialog/cancel-order-dialog.component.mjs +80 -0
- package/esm2022/order/components/coupon-code-selector/coupon-code-selector.component.mjs +62 -0
- package/esm2022/order/components/draft-order-detail/draft-order-detail.component.mjs +183 -0
- package/esm2022/order/components/draft-order-variant-selector/draft-order-variant-selector.component.mjs +59 -0
- package/esm2022/order/components/fulfill-order-dialog/fulfill-order-dialog.component.mjs +79 -0
- package/esm2022/order/components/fulfillment-card/fulfillment-card.component.mjs +48 -0
- package/esm2022/order/components/fulfillment-detail/fulfillment-detail.component.mjs +50 -0
- package/esm2022/order/components/fulfillment-state-label/fulfillment-state-label.component.mjs +28 -0
- package/esm2022/order/components/line-fulfillment/line-fulfillment.component.mjs +62 -0
- package/esm2022/order/components/line-refunds/line-refunds.component.mjs +28 -0
- package/esm2022/order/components/modification-detail/modification-detail.component.mjs +71 -0
- package/esm2022/order/components/order-custom-fields-card/order-custom-fields-card.component.mjs +64 -0
- package/esm2022/order/components/order-data-table/order-data-table.component.mjs +59 -0
- package/esm2022/order/components/order-data-table/order-total-column.component.mjs +20 -0
- package/esm2022/order/components/order-detail/order-detail.component.mjs +602 -0
- package/esm2022/order/components/order-editor/order-editor.component.mjs +485 -0
- package/esm2022/order/components/order-edits-preview-dialog/order-edits-preview-dialog.component.mjs +93 -0
- package/esm2022/order/components/order-history/order-history-entry-host.component.mjs +62 -0
- package/esm2022/order/components/order-history/order-history.component.mjs +184 -0
- package/esm2022/order/components/order-list/order-list.component.mjs +154 -0
- package/esm2022/order/components/order-modification-summary/order-modification-summary.component.mjs +76 -0
- package/esm2022/order/components/order-payment-card/order-payment-card.component.mjs +43 -0
- package/esm2022/order/components/order-process-graph/constants.mjs +2 -0
- package/esm2022/order/components/order-process-graph/order-process-edge.component.mjs +45 -0
- package/esm2022/order/components/order-process-graph/order-process-graph.component.mjs +96 -0
- package/esm2022/order/components/order-process-graph/order-process-node.component.mjs +53 -0
- package/esm2022/order/components/order-process-graph/types.mjs +2 -0
- package/esm2022/order/components/order-process-graph-dialog/order-process-graph-dialog.component.mjs +21 -0
- package/esm2022/order/components/order-state-select-dialog/order-state-select-dialog.component.mjs +28 -0
- package/esm2022/order/components/order-table/order-table.component.mjs +96 -0
- package/esm2022/order/components/payment-detail/payment-detail.component.mjs +18 -0
- package/esm2022/order/components/payment-for-refund-selector/payment-for-refund-selector.component.mjs +24 -0
- package/esm2022/order/components/payment-state-label/payment-state-label.component.mjs +28 -0
- package/esm2022/order/components/refund-detail/refund-detail.component.mjs +18 -0
- package/esm2022/order/components/refund-order-dialog/refund-order-dialog.component.mjs +173 -0
- package/esm2022/order/components/refund-state-label/refund-state-label.component.mjs +27 -0
- package/esm2022/order/components/select-address-dialog/select-address-dialog.component.mjs +89 -0
- package/esm2022/order/components/select-address-dialog/select-address-dialog.graphql.mjs +14 -0
- package/esm2022/order/components/select-customer-dialog/select-customer-dialog.component.mjs +65 -0
- package/esm2022/order/components/select-shipping-method-dialog/select-shipping-method-dialog.component.mjs +30 -0
- package/esm2022/order/components/seller-orders-card/seller-orders-card.component.mjs +39 -0
- package/esm2022/order/components/seller-orders-card/seller-orders-card.graphql.mjs +25 -0
- package/esm2022/order/components/settle-refund-dialog/settle-refund-dialog.component.mjs +24 -0
- package/esm2022/order/components/simple-item-list/simple-item-list.component.mjs +15 -0
- package/esm2022/order/deenruv-admin-ui-order.mjs +5 -0
- package/esm2022/order/order.module.mjs +244 -0
- package/esm2022/order/order.routes.mjs +56 -0
- package/esm2022/order/providers/order-transition.service.mjs +112 -0
- package/esm2022/order/providers/routing/order.guard.mjs +57 -0
- package/esm2022/order/public_api.mjs +53 -0
- package/esm2022/public_api.mjs +5 -0
- package/esm2022/react/components/react-custom-column.component.mjs +25 -0
- package/esm2022/react/components/react-custom-detail.component.mjs +23 -0
- package/esm2022/react/components/react-form-input.component.mjs +24 -0
- package/esm2022/react/components/react-route.component.mjs +26 -0
- package/esm2022/react/deenruv-admin-ui-react.mjs +5 -0
- package/esm2022/react/directives/react-component-host.directive.mjs +54 -0
- package/esm2022/react/public_api.mjs +27 -0
- package/esm2022/react/react-components/ActionBar.mjs +26 -0
- package/esm2022/react/react-components/Card.mjs +28 -0
- package/esm2022/react/react-components/CdsIcon.mjs +30 -0
- package/esm2022/react/react-components/FormField.mjs +28 -0
- package/esm2022/react/react-components/Link.mjs +30 -0
- package/esm2022/react/react-components/PageBlock.mjs +24 -0
- package/esm2022/react/react-components/PageDetailLayout.mjs +26 -0
- package/esm2022/react/react-components/RichTextEditor.mjs +73 -0
- package/esm2022/react/react-hooks/use-detail-component-data.mjs +48 -0
- package/esm2022/react/react-hooks/use-form-control.mjs +66 -0
- package/esm2022/react/react-hooks/use-injector.mjs +33 -0
- package/esm2022/react/react-hooks/use-page-metadata.mjs +41 -0
- package/esm2022/react/react-hooks/use-query.mjs +198 -0
- package/esm2022/react/react-hooks/use-rich-text-editor.mjs +50 -0
- package/esm2022/react/react-hooks/use-route-params.mjs +39 -0
- package/esm2022/react/register-react-custom-detail-component.mjs +33 -0
- package/esm2022/react/register-react-data-table-component.mjs +64 -0
- package/esm2022/react/register-react-form-input-component.mjs +27 -0
- package/esm2022/react/register-react-route-component.mjs +25 -0
- package/esm2022/react/types.mjs +2 -0
- package/esm2022/settings/components/add-country-to-zone-dialog/add-country-to-zone-dialog.component.mjs +57 -0
- package/esm2022/settings/components/admin-detail/admin-detail.component.mjs +205 -0
- package/esm2022/settings/components/administrator-list/administrator-list-bulk-actions.mjs +9 -0
- package/esm2022/settings/components/administrator-list/administrator-list.component.mjs +120 -0
- package/esm2022/settings/components/channel-detail/channel-detail.component.mjs +202 -0
- package/esm2022/settings/components/channel-list/channel-list-bulk-actions.mjs +16 -0
- package/esm2022/settings/components/channel-list/channel-list.component.mjs +81 -0
- package/esm2022/settings/components/country-detail/country-detail.component.mjs +126 -0
- package/esm2022/settings/components/country-list/country-list-bulk-actions.mjs +10 -0
- package/esm2022/settings/components/country-list/country-list.component.mjs +91 -0
- package/esm2022/settings/components/global-settings/global-settings.component.mjs +102 -0
- package/esm2022/settings/components/payment-method-detail/payment-method-detail.component.mjs +206 -0
- package/esm2022/settings/components/payment-method-list/payment-method-list-bulk-actions.mjs +56 -0
- package/esm2022/settings/components/payment-method-list/payment-method-list.component.mjs +99 -0
- package/esm2022/settings/components/permission-grid/permission-grid.component.mjs +81 -0
- package/esm2022/settings/components/profile/profile.component.mjs +96 -0
- package/esm2022/settings/components/role-detail/role-detail.component.mjs +119 -0
- package/esm2022/settings/components/role-list/role-list-bulk-actions.mjs +9 -0
- package/esm2022/settings/components/role-list/role-list.component.mjs +82 -0
- package/esm2022/settings/components/seller-detail/seller-detail.component.mjs +119 -0
- package/esm2022/settings/components/seller-list/seller-list-bulk-actions.mjs +9 -0
- package/esm2022/settings/components/seller-list/seller-list.component.mjs +75 -0
- package/esm2022/settings/components/shipping-eligibility-test-result/shipping-eligibility-test-result.component.mjs +30 -0
- package/esm2022/settings/components/shipping-method-detail/shipping-method-detail.component.mjs +256 -0
- package/esm2022/settings/components/shipping-method-list/shipping-method-list-bulk-actions.mjs +54 -0
- package/esm2022/settings/components/shipping-method-list/shipping-method-list.component.mjs +99 -0
- package/esm2022/settings/components/shipping-method-test-result/shipping-method-test-result.component.mjs +30 -0
- package/esm2022/settings/components/stock-location-detail/stock-location-detail.component.mjs +137 -0
- package/esm2022/settings/components/stock-location-list/stock-location-list-bulk-actions.mjs +68 -0
- package/esm2022/settings/components/stock-location-list/stock-location-list.component.mjs +87 -0
- package/esm2022/settings/components/tax-category-detail/tax-category-detail.component.mjs +114 -0
- package/esm2022/settings/components/tax-category-list/tax-category-list-bulk-actions.mjs +10 -0
- package/esm2022/settings/components/tax-category-list/tax-category-list.component.mjs +69 -0
- package/esm2022/settings/components/tax-rate-detail/tax-rate-detail.component.mjs +137 -0
- package/esm2022/settings/components/tax-rate-list/tax-rate-list-bulk-actions.mjs +10 -0
- package/esm2022/settings/components/tax-rate-list/tax-rate-list.component.mjs +83 -0
- package/esm2022/settings/components/test-address-form/test-address-form.component.mjs +48 -0
- package/esm2022/settings/components/test-order-builder/test-order-builder.component.mjs +71 -0
- package/esm2022/settings/components/test-shipping-methods/test-shipping-methods.component.mjs +52 -0
- package/esm2022/settings/components/zone-detail/zone-detail.component.mjs +117 -0
- package/esm2022/settings/components/zone-list/zone-list-bulk-actions.mjs +10 -0
- package/esm2022/settings/components/zone-list/zone-list.component.mjs +143 -0
- package/esm2022/settings/components/zone-member-list/zone-member-controls.directive.mjs +16 -0
- package/esm2022/settings/components/zone-member-list/zone-member-list-bulk-actions.mjs +26 -0
- package/esm2022/settings/components/zone-member-list/zone-member-list-header.directive.mjs +16 -0
- package/esm2022/settings/components/zone-member-list/zone-member-list.component.mjs +95 -0
- package/esm2022/settings/deenruv-admin-ui-settings.mjs +5 -0
- package/esm2022/settings/providers/routing/profile-resolver.mjs +30 -0
- package/esm2022/settings/public_api.mjs +51 -0
- package/esm2022/settings/settings.module.mjs +467 -0
- package/esm2022/settings/settings.routes.mjs +232 -0
- package/esm2022/system/components/health-check/health-check.component.mjs +18 -0
- package/esm2022/system/components/job-list/job-list.component.mjs +72 -0
- package/esm2022/system/components/job-state-label/job-state-label.component.mjs +46 -0
- package/esm2022/system/deenruv-admin-ui-system.mjs +5 -0
- package/esm2022/system/public_api.mjs +7 -0
- package/esm2022/system/system.module.mjs +22 -0
- package/esm2022/system/system.routes.mjs +20 -0
- package/fesm2022/deenruv-admin-ui-catalog.mjs +5171 -0
- package/fesm2022/deenruv-admin-ui-catalog.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-core.mjs +22758 -0
- package/fesm2022/deenruv-admin-ui-core.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-customer.mjs +1400 -0
- package/fesm2022/deenruv-admin-ui-customer.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-dashboard.mjs +454 -0
- package/fesm2022/deenruv-admin-ui-dashboard.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-login.mjs +157 -0
- package/fesm2022/deenruv-admin-ui-login.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-marketing.mjs +566 -0
- package/fesm2022/deenruv-admin-ui-marketing.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-order.mjs +3664 -0
- package/fesm2022/deenruv-admin-ui-order.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-react.mjs +999 -0
- package/fesm2022/deenruv-admin-ui-react.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-settings.mjs +4067 -0
- package/fesm2022/deenruv-admin-ui-settings.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui-system.mjs +164 -0
- package/fesm2022/deenruv-admin-ui-system.mjs.map +1 -0
- package/fesm2022/deenruv-admin-ui.mjs +11 -0
- package/fesm2022/deenruv-admin-ui.mjs.map +1 -0
- package/index.d.ts +5 -0
- package/login/components/login/login.component.d.ts +37 -0
- package/login/index.d.ts +5 -0
- package/login/login.module.d.ts +9 -0
- package/login/login.routes.d.ts +2 -0
- package/login/providers/login.guard.d.ts +15 -0
- package/login/public_api.d.ts +4 -0
- package/marketing/components/promotion-detail/promotion-detail.component.d.ts +70 -0
- package/marketing/components/promotion-list/promotion-list-bulk-actions.d.ts +6 -0
- package/marketing/components/promotion-list/promotion-list.component.d.ts +13 -0
- package/marketing/index.d.ts +5 -0
- package/marketing/marketing.module.d.ts +14 -0
- package/marketing/marketing.routes.d.ts +4 -0
- package/marketing/public_api.d.ts +5 -0
- package/order/common/get-refundable-payments.d.ts +9 -0
- package/order/common/modify-order-types.d.ts +29 -0
- package/order/components/add-manual-payment-dialog/add-manual-payment-dialog.component.d.ts +19 -0
- package/order/components/cancel-order-dialog/cancel-order-dialog.component.d.ts +24 -0
- package/order/components/coupon-code-selector/coupon-code-selector.component.d.ts +22 -0
- package/order/components/draft-order-detail/draft-order-detail.component.d.ts +51 -0
- package/order/components/draft-order-variant-selector/draft-order-variant-selector.component.d.ts +24 -0
- package/order/components/fulfill-order-dialog/fulfill-order-dialog.component.d.ts +28 -0
- package/order/components/fulfillment-card/fulfillment-card.component.d.ts +12 -0
- package/order/components/fulfillment-detail/fulfillment-detail.component.d.ts +23 -0
- package/order/components/fulfillment-state-label/fulfillment-state-label.component.d.ts +7 -0
- package/order/components/line-fulfillment/line-fulfillment.component.d.ts +26 -0
- package/order/components/line-refunds/line-refunds.component.d.ts +9 -0
- package/order/components/modification-detail/modification-detail.component.d.ts +34 -0
- package/order/components/order-custom-fields-card/order-custom-fields-card.component.d.ts +21 -0
- package/order/components/order-data-table/order-data-table.component.d.ts +15 -0
- package/order/components/order-data-table/order-total-column.component.d.ts +7 -0
- package/order/components/order-detail/order-detail.component.d.ts +68 -0
- package/order/components/order-editor/order-editor.component.d.ts +99 -0
- package/order/components/order-edits-preview-dialog/order-edits-preview-dialog.component.d.ts +51 -0
- package/order/components/order-history/order-history-entry-host.component.d.ts +18 -0
- package/order/components/order-history/order-history.component.d.ts +92 -0
- package/order/components/order-list/order-list.component.d.ts +21 -0
- package/order/components/order-modification-summary/order-modification-summary.component.d.ts +19 -0
- package/order/components/order-payment-card/order-payment-card.component.d.ts +67 -0
- package/order/components/order-process-graph/constants.d.ts +1 -0
- package/order/components/order-process-graph/order-process-edge.component.d.ts +21 -0
- package/order/components/order-process-graph/order-process-graph.component.d.ts +32 -0
- package/order/components/order-process-graph/order-process-node.component.d.ts +26 -0
- package/order/components/order-process-graph/types.d.ts +4 -0
- package/order/components/order-process-graph-dialog/order-process-graph-dialog.component.d.ts +13 -0
- package/order/components/order-state-select-dialog/order-state-select-dialog.component.d.ts +13 -0
- package/order/components/order-table/order-table.component.d.ts +43 -0
- package/order/components/payment-detail/payment-detail.component.d.ts +8 -0
- package/order/components/payment-for-refund-selector/payment-for-refund-selector.component.d.ts +14 -0
- package/order/components/payment-state-label/payment-state-label.component.d.ts +7 -0
- package/order/components/refund-detail/refund-detail.component.d.ts +8 -0
- package/order/components/refund-order-dialog/refund-order-dialog.component.d.ts +46 -0
- package/order/components/refund-state-label/refund-state-label.component.d.ts +7 -0
- package/order/components/select-address-dialog/select-address-dialog.component.d.ts +27 -0
- package/order/components/select-address-dialog/select-address-dialog.graphql.d.ts +1 -0
- package/order/components/select-customer-dialog/select-customer-dialog.component.d.ts +32 -0
- package/order/components/select-shipping-method-dialog/select-shipping-method-dialog.component.d.ts +18 -0
- package/order/components/seller-orders-card/seller-orders-card.component.d.ts +24 -0
- package/order/components/seller-orders-card/seller-orders-card.graphql.d.ts +1 -0
- package/order/components/settle-refund-dialog/settle-refund-dialog.component.d.ts +11 -0
- package/order/components/simple-item-list/simple-item-list.component.d.ts +9 -0
- package/order/index.d.ts +5 -0
- package/order/order.module.d.ts +52 -0
- package/order/order.routes.d.ts +3 -0
- package/order/providers/order-transition.service.d.ts +32 -0
- package/order/providers/routing/order.guard.d.ts +13 -0
- package/order/public_api.d.ts +51 -0
- package/package.json +133 -0
- package/public_api.d.ts +4 -0
- package/react/components/react-custom-column.component.d.ts +17 -0
- package/react/components/react-custom-detail.component.d.ts +24 -0
- package/react/components/react-form-input.component.d.ts +20 -0
- package/react/components/react-route.component.d.ts +10 -0
- package/react/directives/react-component-host.directive.d.ts +23 -0
- package/react/index.d.ts +5 -0
- package/react/public_api.d.ts +25 -0
- package/react/react-components/ActionBar.d.ts +23 -0
- package/react/react-components/Card.d.ts +24 -0
- package/react/react-components/CdsIcon.d.ts +45 -0
- package/react/react-components/FormField.d.ts +27 -0
- package/react/react-components/Link.d.ts +22 -0
- package/react/react-components/PageBlock.d.ts +21 -0
- package/react/react-components/PageDetailLayout.d.ts +23 -0
- package/react/react-components/RichTextEditor.d.ts +62 -0
- package/react/react-hooks/use-detail-component-data.d.ts +32 -0
- package/react/react-hooks/use-form-control.d.ts +29 -0
- package/react/react-hooks/use-injector.d.ts +24 -0
- package/react/react-hooks/use-page-metadata.d.ts +30 -0
- package/react/react-hooks/use-query.d.ts +163 -0
- package/react/react-hooks/use-rich-text-editor.d.ts +37 -0
- package/react/react-hooks/use-route-params.d.ts +22 -0
- package/react/register-react-custom-detail-component.d.ts +38 -0
- package/react/register-react-data-table-component.d.ts +83 -0
- package/react/register-react-form-input-component.d.ts +9 -0
- package/react/register-react-route-component.d.ts +32 -0
- package/react/types.d.ts +17 -0
- package/settings/components/add-country-to-zone-dialog/add-country-to-zone-dialog.component.d.ts +20 -0
- package/settings/components/admin-detail/admin-detail.component.d.ts +64 -0
- package/settings/components/administrator-list/administrator-list-bulk-actions.d.ts +1 -0
- package/settings/components/administrator-list/administrator-list.component.d.ts +29 -0
- package/settings/components/channel-detail/channel-detail.component.d.ts +46 -0
- package/settings/components/channel-list/channel-list-bulk-actions.d.ts +1 -0
- package/settings/components/channel-list/channel-list.component.d.ts +13 -0
- package/settings/components/country-detail/country-detail.component.d.ts +29 -0
- package/settings/components/country-list/country-list-bulk-actions.d.ts +1 -0
- package/settings/components/country-list/country-list.component.d.ts +11 -0
- package/settings/components/global-settings/global-settings.component.d.ts +29 -0
- package/settings/components/payment-method-detail/payment-method-detail.component.d.ts +64 -0
- package/settings/components/payment-method-list/payment-method-list-bulk-actions.d.ts +3 -0
- package/settings/components/payment-method-list/payment-method-list.component.d.ts +11 -0
- package/settings/components/permission-grid/permission-grid.component.d.ts +28 -0
- package/settings/components/profile/profile.component.d.ts +28 -0
- package/settings/components/role-detail/role-detail.component.d.ts +31 -0
- package/settings/components/role-list/role-list-bulk-actions.d.ts +1 -0
- package/settings/components/role-list/role-list.component.d.ts +17 -0
- package/settings/components/seller-detail/seller-detail.component.d.ts +31 -0
- package/settings/components/seller-list/seller-list-bulk-actions.d.ts +1 -0
- package/settings/components/seller-list/seller-list.component.d.ts +11 -0
- package/settings/components/shipping-eligibility-test-result/shipping-eligibility-test-result.component.d.ts +12 -0
- package/settings/components/shipping-method-detail/shipping-method-detail.component.d.ts +76 -0
- package/settings/components/shipping-method-list/shipping-method-list-bulk-actions.d.ts +3 -0
- package/settings/components/shipping-method-list/shipping-method-list.component.d.ts +12 -0
- package/settings/components/shipping-method-test-result/shipping-method-test-result.component.d.ts +12 -0
- package/settings/components/stock-location-detail/stock-location-detail.component.d.ts +32 -0
- package/settings/components/stock-location-list/stock-location-list-bulk-actions.d.ts +3 -0
- package/settings/components/stock-location-list/stock-location-list.component.d.ts +12 -0
- package/settings/components/tax-category-detail/tax-category-detail.component.d.ts +32 -0
- package/settings/components/tax-category-list/tax-category-list-bulk-actions.d.ts +1 -0
- package/settings/components/tax-category-list/tax-category-list.component.d.ts +11 -0
- package/settings/components/tax-rate-detail/tax-rate-detail.component.d.ts +39 -0
- package/settings/components/tax-rate-list/tax-rate-list-bulk-actions.d.ts +1 -0
- package/settings/components/tax-rate-list/tax-rate-list.component.d.ts +11 -0
- package/settings/components/test-address-form/test-address-form.component.d.ts +25 -0
- package/settings/components/test-order-builder/test-order-builder.component.d.ts +31 -0
- package/settings/components/test-shipping-methods/test-shipping-methods.component.d.ts +23 -0
- package/settings/components/zone-detail/zone-detail.component.d.ts +31 -0
- package/settings/components/zone-list/zone-list-bulk-actions.d.ts +1 -0
- package/settings/components/zone-list/zone-list.component.d.ts +26 -0
- package/settings/components/zone-member-list/zone-member-controls.directive.d.ts +8 -0
- package/settings/components/zone-member-list/zone-member-list-bulk-actions.d.ts +3 -0
- package/settings/components/zone-member-list/zone-member-list-header.directive.d.ts +8 -0
- package/settings/components/zone-member-list/zone-member-list.component.d.ts +40 -0
- package/settings/index.d.ts +5 -0
- package/settings/providers/routing/profile-resolver.d.ts +8 -0
- package/settings/public_api.d.ts +49 -0
- package/settings/settings.module.d.ts +45 -0
- package/settings/settings.routes.d.ts +3 -0
- package/static/assets/.gitkeep +0 -0
- package/static/assets/logo-login.webp +0 -0
- package/static/assets/logo-top.webp +0 -0
- package/static/deenruv-ui-config.json +290 -0
- package/static/favicon.ico +0 -0
- package/static/fonts/fonts.scss +253 -0
- package/static/fonts/inter-cyrillic-ext.woff2 +0 -0
- package/static/fonts/inter-cyrillic.woff2 +0 -0
- package/static/fonts/inter-greek-ext.woff2 +0 -0
- package/static/fonts/inter-greek.woff2 +0 -0
- package/static/fonts/inter-latin-ext.woff2 +0 -0
- package/static/fonts/inter-latin.woff2 +0 -0
- package/static/fonts/inter-vietnamese.woff2 +0 -0
- package/static/i18n-messages/ar.json +814 -0
- package/static/i18n-messages/cs.json +814 -0
- package/static/i18n-messages/de.json +814 -0
- package/static/i18n-messages/en.json +814 -0
- package/static/i18n-messages/es.json +814 -0
- package/static/i18n-messages/fa.json +814 -0
- package/static/i18n-messages/fr.json +814 -0
- package/static/i18n-messages/he.json +814 -0
- package/static/i18n-messages/hr.json +814 -0
- package/static/i18n-messages/it.json +814 -0
- package/static/i18n-messages/nb.json +812 -0
- package/static/i18n-messages/ne.json +814 -0
- package/static/i18n-messages/pl.json +814 -0
- package/static/i18n-messages/pt_BR.json +814 -0
- package/static/i18n-messages/pt_PT.json +814 -0
- package/static/i18n-messages/ru.json +814 -0
- package/static/i18n-messages/sv.json +807 -0
- package/static/i18n-messages/uk.json +814 -0
- package/static/i18n-messages/zh_Hans.json +814 -0
- package/static/i18n-messages/zh_Hant.json +814 -0
- package/static/index.html +14 -0
- package/static/polyfills.ts +66 -0
- package/static/styles/_mixins.scss +60 -0
- package/static/styles/_variables.scss +11 -0
- package/static/styles/component/prosemirror.scss +511 -0
- package/static/styles/global/_buttons.scss +147 -0
- package/static/styles/global/_clarity.scss +140 -0
- package/static/styles/global/_forms.scss +187 -0
- package/static/styles/global/_global.scss +41 -0
- package/static/styles/global/_overrides.scss +165 -0
- package/static/styles/global/_sass-overrides.scss +8 -0
- package/static/styles/global/_utilities.scss +155 -0
- package/static/styles/rtl.scss +143 -0
- package/static/styles/styles.scss +19 -0
- package/static/styles/theme/dark.scss +591 -0
- package/static/styles/theme/default.scss +254 -0
- package/static/styles/ui-extension-theme.scss +13 -0
- package/static/theme.min.css +1 -0
- package/system/components/health-check/health-check.component.d.ts +8 -0
- package/system/components/job-list/job-list.component.d.ts +19 -0
- package/system/components/job-state-label/job-state-label.component.d.ts +9 -0
- package/system/index.d.ts +5 -0
- package/system/public_api.d.ts +5 -0
- package/system/system.module.d.ts +11 -0
- package/system/system.routes.d.ts +2 -0
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, EventEmitter, Output, ViewChild } from '@angular/core';
|
|
2
|
+
import { concat, merge, of, Subject } from 'rxjs';
|
|
3
|
+
import { debounceTime, distinctUntilChanged, mapTo, switchMap, tap } from 'rxjs/operators';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
import * as i1 from "../../../data/providers/data.service";
|
|
6
|
+
import * as i2 from "@ng-select/ng-select";
|
|
7
|
+
import * as i3 from "@angular/common";
|
|
8
|
+
import * as i4 from "@ngx-translate/core";
|
|
9
|
+
import * as i5 from "../../pipes/asset-preview.pipe";
|
|
10
|
+
/**
|
|
11
|
+
* @description
|
|
12
|
+
* A component for selecting product variants via an autocomplete-style select input.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```HTML
|
|
16
|
+
* <vdr-product-variant-selector
|
|
17
|
+
* (productSelected)="selectResult($event)"></vdr-product-selector>
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* @docsCategory components
|
|
21
|
+
*/
|
|
22
|
+
export class ProductVariantSelectorComponent {
|
|
23
|
+
constructor(dataService) {
|
|
24
|
+
this.dataService = dataService;
|
|
25
|
+
this.searchInput$ = new Subject();
|
|
26
|
+
this.searchLoading = false;
|
|
27
|
+
this.productSelected = new EventEmitter();
|
|
28
|
+
}
|
|
29
|
+
ngOnInit() {
|
|
30
|
+
this.initSearchResults();
|
|
31
|
+
}
|
|
32
|
+
initSearchResults() {
|
|
33
|
+
const searchItems$ = this.searchInput$.pipe(debounceTime(200), distinctUntilChanged(), tap(() => (this.searchLoading = true)), switchMap(term => {
|
|
34
|
+
if (!term) {
|
|
35
|
+
return of([]);
|
|
36
|
+
}
|
|
37
|
+
return this.dataService.product
|
|
38
|
+
.productSelectorSearch(term, 10)
|
|
39
|
+
.mapSingle(result => result.search.items);
|
|
40
|
+
}), tap(() => (this.searchLoading = false)));
|
|
41
|
+
const clear$ = this.productSelected.pipe(mapTo([]));
|
|
42
|
+
this.searchResults$ = concat(of([]), merge(searchItems$, clear$));
|
|
43
|
+
}
|
|
44
|
+
selectResult(product) {
|
|
45
|
+
if (product) {
|
|
46
|
+
this.productSelected.emit(product);
|
|
47
|
+
this.ngSelect.clearModel();
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ProductVariantSelectorComponent, deps: [{ token: i1.DataService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
51
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: ProductVariantSelectorComponent, selector: "vdr-product-variant-selector", outputs: { productSelected: "productSelected" }, viewQueries: [{ propertyName: "ngSelect", first: true, predicate: ["autoComplete"], descendants: true, static: true }], ngImport: i0, template: "<ng-select\n #autoComplete\n [items]=\"searchResults$ | async\"\n [addTag]=\"false\"\n [multiple]=\"false\"\n [hideSelected]=\"true\"\n [loading]=\"searchLoading\"\n [typeahead]=\"searchInput$\"\n [appendTo]=\"'body'\"\n [placeholder]=\"'settings.search-by-product-name-or-sku' | translate\"\n (change)=\"selectResult($event)\"\n>\n <ng-template ng-option-tmp let-item=\"item\">\n <img [src]=\"item.productAsset | assetPreview: 32\">\n {{ item.productVariantName }}\n <small class=\"sku\">{{ item.sku }}</small>\n </ng-template>\n</ng-select>\n", styles: [":host{display:block}.sku{margin-inline-start:12px;color:var(--color-grey-500)}img{border-radius:var(--border-radius-img)}\n"], dependencies: [{ kind: "component", type: i2.NgSelectComponent, selector: "ng-select", inputs: ["bindLabel", "bindValue", "markFirst", "placeholder", "notFoundText", "typeToSearchText", "addTagText", "loadingText", "clearAllText", "appearance", "dropdownPosition", "appendTo", "loading", "closeOnSelect", "hideSelected", "selectOnTab", "openOnEnter", "maxSelectedItems", "groupBy", "groupValue", "bufferAmount", "virtualScroll", "selectableGroup", "selectableGroupAsModel", "searchFn", "trackByFn", "clearOnBackspace", "labelForId", "inputAttrs", "tabIndex", "readonly", "searchWhileComposing", "minTermLength", "editableSearchTerm", "keyDownFn", "typeahead", "multiple", "addTag", "searchable", "clearable", "isOpen", "items", "compareWith", "clearSearchOnAdd", "deselectOnClick"], outputs: ["blur", "focus", "change", "open", "close", "search", "clear", "add", "remove", "scroll", "scrollToEnd"] }, { kind: "directive", type: i2.NgOptionTemplateDirective, selector: "[ng-option-tmp]" }, { kind: "pipe", type: i3.AsyncPipe, name: "async" }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }, { kind: "pipe", type: i5.AssetPreviewPipe, name: "assetPreview" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
52
|
+
}
|
|
53
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ProductVariantSelectorComponent, decorators: [{
|
|
54
|
+
type: Component,
|
|
55
|
+
args: [{ selector: 'vdr-product-variant-selector', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-select\n #autoComplete\n [items]=\"searchResults$ | async\"\n [addTag]=\"false\"\n [multiple]=\"false\"\n [hideSelected]=\"true\"\n [loading]=\"searchLoading\"\n [typeahead]=\"searchInput$\"\n [appendTo]=\"'body'\"\n [placeholder]=\"'settings.search-by-product-name-or-sku' | translate\"\n (change)=\"selectResult($event)\"\n>\n <ng-template ng-option-tmp let-item=\"item\">\n <img [src]=\"item.productAsset | assetPreview: 32\">\n {{ item.productVariantName }}\n <small class=\"sku\">{{ item.sku }}</small>\n </ng-template>\n</ng-select>\n", styles: [":host{display:block}.sku{margin-inline-start:12px;color:var(--color-grey-500)}img{border-radius:var(--border-radius-img)}\n"] }]
|
|
56
|
+
}], ctorParameters: () => [{ type: i1.DataService }], propDecorators: { productSelected: [{
|
|
57
|
+
type: Output
|
|
58
|
+
}], ngSelect: [{
|
|
59
|
+
type: ViewChild,
|
|
60
|
+
args: ['autoComplete', { static: true }]
|
|
61
|
+
}] } });
|
|
62
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJvZHVjdC12YXJpYW50LXNlbGVjdG9yLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3NyYy9saWIvY29yZS9zcmMvc2hhcmVkL2NvbXBvbmVudHMvcHJvZHVjdC12YXJpYW50LXNlbGVjdG9yL3Byb2R1Y3QtdmFyaWFudC1zZWxlY3Rvci5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2NvcmUvc3JjL3NoYXJlZC9jb21wb25lbnRzL3Byb2R1Y3QtdmFyaWFudC1zZWxlY3Rvci9wcm9kdWN0LXZhcmlhbnQtc2VsZWN0b3IuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLHVCQUF1QixFQUFFLFNBQVMsRUFBRSxZQUFZLEVBQVUsTUFBTSxFQUFFLFNBQ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gICAgZGVib3VuY2VUaW1lKDIwMCksXG4gICAgICAgICAgICBkaXN0aW5jdFVudGlsQ2hhbmdlZCgpLFxuICAgICAgICAgICAgdGFwKCgpID0+ICh0aGlzLnNlYXJjaExvYWRpbmcgPSB0cnVlKSksXG4gICAgICAgICAgICBzd2l0Y2hNYXAodGVybSA9PiB7XG4gICAgICAgICAgICAgICAgaWYgKCF0ZXJtKSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBvZihbXSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLmRhdGFTZXJ2aWNlLnByb2R1Y3RcbiAgICAgICAgICAgICAgICAgICAgLnByb2R1Y3RTZWxlY3RvclNlYXJjaCh0ZXJtLCAxMClcbiAgICAgICAgICAgICAgICAgICAgLm1hcFNpbmdsZShyZXN1bHQgPT4gcmVzdWx0LnNlYXJjaC5pdGVtcyk7XG4gICAgICAgICAgICB9KSxcbiAgICAgICAgICAgIHRhcCgoKSA9PiAodGhpcy5zZWFyY2hMb2FkaW5nID0gZmFsc2UpKSxcbiAgICAgICAgKTtcblxuICAgICAgICBjb25zdCBjbGVhciQgPSB0aGlzLnByb2R1Y3RTZWxlY3RlZC5waXBlKG1hcFRvKFtdKSk7XG4gICAgICAgIHRoaXMuc2VhcmNoUmVzdWx0cyQgPSBjb25jYXQob2YoW10pLCBtZXJnZShzZWFyY2hJdGVtcyQsIGNsZWFyJCkpO1xuICAgIH1cblxuICAgIHNlbGVjdFJlc3VsdChwcm9kdWN0PzogUHJvZHVjdFNlbGVjdG9yU2VhcmNoUXVlcnlbJ3NlYXJjaCddWydpdGVtcyddW251bWJlcl0pIHtcbiAgICAgICAgaWYgKHByb2R1Y3QpIHtcbiAgICAgICAgICAgIHRoaXMucHJvZHVjdFNlbGVjdGVkLmVtaXQocHJvZHVjdCk7XG4gICAgICAgICAgICB0aGlzLm5nU2VsZWN0LmNsZWFyTW9kZWwoKTtcbiAgICAgICAgfVxuICAgIH1cbn1cbiIsIjxuZy1zZWxlY3RcbiAgICAjYXV0b0NvbXBsZXRlXG4gICAgW2l0ZW1zXT1cInNlYXJjaFJlc3VsdHMkIHwgYXN5bmNcIlxuICAgIFthZGRUYWddPVwiZmFsc2VcIlxuICAgIFttdWx0aXBsZV09XCJmYWxzZVwiXG4gICAgW2hpZGVTZWxlY3RlZF09XCJ0cnVlXCJcbiAgICBbbG9hZGluZ109XCJzZWFyY2hMb2FkaW5nXCJcbiAgICBbdHlwZWFoZWFkXT1cInNlYXJjaElucHV0JFwiXG4gICAgW2FwcGVuZFRvXT1cIidib2R5J1wiXG4gICAgW3BsYWNlaG9sZGVyXT1cIidzZXR0aW5ncy5zZWFyY2gtYnktcHJvZHVjdC1uYW1lLW9yLXNrdScgfCB0cmFuc2xhdGVcIlxuICAgIChjaGFuZ2UpPVwic2VsZWN0UmVzdWx0KCRldmVudClcIlxuPlxuICAgIDxuZy10ZW1wbGF0ZSBuZy1vcHRpb24tdG1wIGxldC1pdGVtPVwiaXRlbVwiPlxuICAgICAgICA8aW1nIFtzcmNdPVwiaXRlbS5wcm9kdWN0QXNzZXQgfCBhc3NldFByZXZpZXc6IDMyXCI+XG4gICAgICAgIHt7IGl0ZW0ucHJvZHVjdFZhcmlhbnROYW1lIH19XG4gICAgICAgIDxzbWFsbCBjbGFzcz1cInNrdVwiPnt7IGl0ZW0uc2t1IH19PC9zbWFsbD5cbiAgICA8L25nLXRlbXBsYXRlPlxuPC9uZy1zZWxlY3Q+XG4iXX0=
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, EventEmitter, Input, Output, } from '@angular/core';
|
|
2
|
+
import { Subject } from 'rxjs';
|
|
3
|
+
import { throttleTime } from 'rxjs/operators';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export class RadioCardFieldsetComponent {
|
|
6
|
+
constructor(changeDetector) {
|
|
7
|
+
this.changeDetector = changeDetector;
|
|
8
|
+
this.selectItem = new EventEmitter();
|
|
9
|
+
this.groupName = 'radio-group-' + Math.random().toString(36);
|
|
10
|
+
this.selectedIdChange$ = new Subject();
|
|
11
|
+
this.focussedId = undefined;
|
|
12
|
+
this.idChange$ = new Subject();
|
|
13
|
+
}
|
|
14
|
+
ngOnInit() {
|
|
15
|
+
this.subscription = this.idChange$
|
|
16
|
+
.pipe(throttleTime(200))
|
|
17
|
+
.subscribe(item => this.selectItem.emit(item));
|
|
18
|
+
}
|
|
19
|
+
ngOnChanges(changes) {
|
|
20
|
+
if ('selectedItemId' in changes) {
|
|
21
|
+
this.selectedIdChange$.next(this.selectedItemId);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
ngOnDestroy() {
|
|
25
|
+
if (this.subscription) {
|
|
26
|
+
this.subscription.unsubscribe();
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
isSelected(item) {
|
|
30
|
+
return this.selectedItemId === this.idFn(item);
|
|
31
|
+
}
|
|
32
|
+
isFocussed(item) {
|
|
33
|
+
return this.focussedId === this.idFn(item);
|
|
34
|
+
}
|
|
35
|
+
selectChanged(item) {
|
|
36
|
+
this.idChange$.next(item);
|
|
37
|
+
}
|
|
38
|
+
setFocussedId(item) {
|
|
39
|
+
this.focussedId = item && this.idFn(item);
|
|
40
|
+
}
|
|
41
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: RadioCardFieldsetComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
42
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: RadioCardFieldsetComponent, selector: "vdr-radio-card-fieldset", inputs: { selectedItemId: "selectedItemId", idFn: "idFn" }, outputs: { selectItem: "selectItem" }, usesOnChanges: true, ngImport: i0, template: `<fieldset><ng-content></ng-content></fieldset> `, isInline: true, styles: ["fieldset{display:flex;align-items:flex-start;overflow-x:auto}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
43
|
+
}
|
|
44
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: RadioCardFieldsetComponent, decorators: [{
|
|
45
|
+
type: Component,
|
|
46
|
+
args: [{ selector: 'vdr-radio-card-fieldset', template: `<fieldset><ng-content></ng-content></fieldset> `, changeDetection: ChangeDetectionStrategy.OnPush, styles: ["fieldset{display:flex;align-items:flex-start;overflow-x:auto}\n"] }]
|
|
47
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { selectedItemId: [{
|
|
48
|
+
type: Input
|
|
49
|
+
}], idFn: [{
|
|
50
|
+
type: Input
|
|
51
|
+
}], selectItem: [{
|
|
52
|
+
type: Output
|
|
53
|
+
}] } });
|
|
54
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmFkaW8tY2FyZC1maWVsZHNldC5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2NvcmUvc3JjL3NoYXJlZC9jb21wb25lbnRzL3JhZGlvLWNhcmQvcmFkaW8tY2FyZC1maWVsZHNldC5jb21wb25lbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUNILHVCQUF1QixFQUV2QixTQUFTLEVBRVQsWUFBWSxFQUNaLEtBQUssRUFJTCxNQUFNLEdBR1QsTUFBTSxlQUFlLENBQUM7QUFDdkIsT0FBTyxFQUFFLE9BQU8sRUFBZ0IsTUFBTSxNQUFNLENBQUM7QUFDN0MsT0FBTyxFQUFnQixZQUFZLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQzs7QUFRNUQsTUFBTSxPQUFPLDBCQUEwQjtJQVVuQyxZQUFvQixjQUFpQztRQUFqQyxtQkFBYyxHQUFkLGNBQWMsQ0FBbUI7UUFQ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 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, ContentChild, Input, TemplateRef, } from '@angular/core';
|
|
2
|
+
import { Subject } from 'rxjs';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
import * as i1 from "./radio-card-fieldset.component";
|
|
5
|
+
import * as i2 from "@clr/angular";
|
|
6
|
+
import * as i3 from "@angular/common";
|
|
7
|
+
import * as i4 from "../form-field/form-field-control.directive";
|
|
8
|
+
import * as i5 from "../select-toggle/select-toggle.component";
|
|
9
|
+
export class RadioCardComponent {
|
|
10
|
+
constructor(fieldset, changeDetector) {
|
|
11
|
+
this.fieldset = fieldset;
|
|
12
|
+
this.changeDetector = changeDetector;
|
|
13
|
+
this.idChange$ = new Subject();
|
|
14
|
+
this.name = this.fieldset.groupName;
|
|
15
|
+
}
|
|
16
|
+
ngOnInit() {
|
|
17
|
+
this.subscription = this.fieldset.selectedIdChange$.subscribe(id => {
|
|
18
|
+
this.changeDetector.markForCheck();
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
ngOnDestroy() {
|
|
22
|
+
if (this.subscription) {
|
|
23
|
+
this.subscription.unsubscribe();
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
isSelected(item) {
|
|
27
|
+
return this.fieldset.isSelected(item);
|
|
28
|
+
}
|
|
29
|
+
isFocussed(item) {
|
|
30
|
+
return this.fieldset.isFocussed(item);
|
|
31
|
+
}
|
|
32
|
+
selectChanged(item) {
|
|
33
|
+
this.fieldset.selectChanged(item);
|
|
34
|
+
}
|
|
35
|
+
setFocussedId(item) {
|
|
36
|
+
this.fieldset.setFocussedId(item);
|
|
37
|
+
}
|
|
38
|
+
getItemId(item) {
|
|
39
|
+
return this.fieldset.idFn(item);
|
|
40
|
+
}
|
|
41
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: RadioCardComponent, deps: [{ token: i1.RadioCardFieldsetComponent }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
42
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: RadioCardComponent, selector: "vdr-radio-card", inputs: { item: "item" }, queries: [{ propertyName: "itemTemplate", first: true, predicate: TemplateRef, descendants: true }], exportAs: ["VdrRadioCard"], ngImport: i0, template: "<label\n [ngClass]=\"{\n 'selected': isSelected(item),\n 'focussed': isFocussed(item)\n }\"\n class=\"radio-card\"\n>\n <input\n type=\"radio\"\n [name]=\"name\"\n [value]=\"getItemId(item)\"\n class=\"hidden\"\n (focus)=\"setFocussedId(item)\"\n (blur)=\"setFocussedId(undefined)\"\n (change)=\"selectChanged(item)\"\n />\n <vdr-select-toggle [selected]=\"isSelected(item)\" size=\"small\"></vdr-select-toggle>\n <div class=\"content\">\n <ng-content></ng-content>\n </div>\n</label>\n", styles: [":host{display:inline-block}.radio-card{background:none;position:relative;display:block;border:1px solid var(--clr-btn-default-border-color, #0072a3);border-radius:var(--clr-btn-border-radius, .15rem);padding:6px;text-align:start;margin:6px}.radio-card:hover{cursor:pointer;outline:1px solid var(--color-primary-500)}.radio-card.selected{outline:1px solid var(--color-primary-500);background-color:var(--color-primary-100)}input.hidden{visibility:hidden;position:absolute}vdr-select-toggle{position:absolute;top:3px;left:3px}.content{margin-inline-start:24px}\n"], dependencies: [{ kind: "directive", type: i2.ClrLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i4.FormFieldControlDirective, selector: "input, textarea, select, vdr-currency-input" }, { kind: "component", type: i5.SelectToggleComponent, selector: "vdr-select-toggle", inputs: ["size", "selected", "hiddenWhenOff", "disabled", "label"], outputs: ["selectedChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
43
|
+
}
|
|
44
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: RadioCardComponent, decorators: [{
|
|
45
|
+
type: Component,
|
|
46
|
+
args: [{ selector: 'vdr-radio-card', exportAs: 'VdrRadioCard', changeDetection: ChangeDetectionStrategy.OnPush, template: "<label\n [ngClass]=\"{\n 'selected': isSelected(item),\n 'focussed': isFocussed(item)\n }\"\n class=\"radio-card\"\n>\n <input\n type=\"radio\"\n [name]=\"name\"\n [value]=\"getItemId(item)\"\n class=\"hidden\"\n (focus)=\"setFocussedId(item)\"\n (blur)=\"setFocussedId(undefined)\"\n (change)=\"selectChanged(item)\"\n />\n <vdr-select-toggle [selected]=\"isSelected(item)\" size=\"small\"></vdr-select-toggle>\n <div class=\"content\">\n <ng-content></ng-content>\n </div>\n</label>\n", styles: [":host{display:inline-block}.radio-card{background:none;position:relative;display:block;border:1px solid var(--clr-btn-default-border-color, #0072a3);border-radius:var(--clr-btn-border-radius, .15rem);padding:6px;text-align:start;margin:6px}.radio-card:hover{cursor:pointer;outline:1px solid var(--color-primary-500)}.radio-card.selected{outline:1px solid var(--color-primary-500);background-color:var(--color-primary-100)}input.hidden{visibility:hidden;position:absolute}vdr-select-toggle{position:absolute;top:3px;left:3px}.content{margin-inline-start:24px}\n"] }]
|
|
47
|
+
}], ctorParameters: () => [{ type: i1.RadioCardFieldsetComponent }, { type: i0.ChangeDetectorRef }], propDecorators: { item: [{
|
|
48
|
+
type: Input
|
|
49
|
+
}], itemTemplate: [{
|
|
50
|
+
type: ContentChild,
|
|
51
|
+
args: [TemplateRef]
|
|
52
|
+
}] } });
|
|
53
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmFkaW8tY2FyZC5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2NvcmUvc3JjL3NoYXJlZC9jb21wb25lbnRzL3JhZGlvLWNhcmQvcmFkaW8tY2FyZC5jb21wb25lbnQudHMiLCIuLi8uLi8u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b1wiXG4gICAgICAgIFtuYW1lXT1cIm5hbWVcIlxuICAgICAgICBbdmFsdWVdPVwiZ2V0SXRlbUlkKGl0ZW0pXCJcbiAgICAgICAgY2xhc3M9XCJoaWRkZW5cIlxuICAgICAgICAoZm9jdXMpPVwic2V0Rm9jdXNzZWRJZChpdGVtKVwiXG4gICAgICAgIChibHVyKT1cInNldEZvY3Vzc2VkSWQodW5kZWZpbmVkKVwiXG4gICAgICAgIChjaGFuZ2UpPVwic2VsZWN0Q2hhbmdlZChpdGVtKVwiXG4gICAgLz5cbiAgICA8dmRyLXNlbGVjdC10b2dnbGUgW3NlbGVjdGVkXT1cImlzU2VsZWN0ZWQoaXRlbSlcIiBzaXplPVwic21hbGxcIj48L3Zkci1zZWxlY3QtdG9nZ2xlPlxuICAgIDxkaXYgY2xhc3M9XCJjb250ZW50XCI+XG4gICAgICAgIDxuZy1jb250ZW50PjwvbmctY29udGVudD5cbiAgICA8L2Rpdj5cbjwvbGFiZWw+XG4iXX0=
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
import * as i1 from "@clr/angular";
|
|
5
|
+
import * as i2 from "@angular/common";
|
|
6
|
+
import * as i3 from "@angular/forms";
|
|
7
|
+
import * as i4 from "../../form-field/form-field-control.directive";
|
|
8
|
+
import * as i5 from "../../modal-dialog/dialog-buttons.directive";
|
|
9
|
+
import * as i6 from "@ngx-translate/core";
|
|
10
|
+
export class ExternalImageDialogComponent {
|
|
11
|
+
constructor() {
|
|
12
|
+
this.previewLoaded = false;
|
|
13
|
+
}
|
|
14
|
+
ngOnInit() {
|
|
15
|
+
this.form = new UntypedFormGroup({
|
|
16
|
+
src: new UntypedFormControl(this.existing ? this.existing.src : '', Validators.required),
|
|
17
|
+
title: new UntypedFormControl(this.existing ? this.existing.title : ''),
|
|
18
|
+
alt: new UntypedFormControl(this.existing ? this.existing.alt : ''),
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
select() {
|
|
22
|
+
this.resolveWith(this.form.value);
|
|
23
|
+
}
|
|
24
|
+
onImageLoad(event) {
|
|
25
|
+
this.previewLoaded = true;
|
|
26
|
+
}
|
|
27
|
+
onImageError(event) {
|
|
28
|
+
this.previewLoaded = false;
|
|
29
|
+
}
|
|
30
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ExternalImageDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
31
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: ExternalImageDialogComponent, selector: "vdr-external-image-dialog", ngImport: i0, template: "<div class=\"flex\">\n <form [formGroup]=\"form\" class=\"flex-spacer\" clrForm clrLayout=\"vertical\">\n <clr-input-container class=\"expand\">\n <label>{{ 'editor.image-src' | translate }}</label>\n <input clrInput type=\"text\" formControlName=\"src\" />\n </clr-input-container>\n <clr-input-container class=\"expand\">\n <label>{{ 'editor.image-title' | translate }}</label>\n <input clrInput type=\"text\" formControlName=\"title\" />\n </clr-input-container>\n <clr-input-container class=\"expand\">\n <label>{{ 'editor.image-alt' | translate }}</label>\n <input clrInput type=\"text\" formControlName=\"alt\" />\n </clr-input-container>\n </form>\n <div class=\"preview\">\n <img\n [src]=\"form.get('src')?.value\"\n [class.visible]=\"previewLoaded\"\n (load)=\"onImageLoad($event)\"\n (error)=\"onImageError($event)\"\n />\n <div class=\"placeholder\" *ngIf=\"!previewLoaded\">\n <clr-icon shape=\"image\" size=\"128\"></clr-icon>\n </div>\n </div>\n</div>\n\n<ng-template vdrDialogButtons>\n <button type=\"submit\" (click)=\"select()\" class=\"btn btn-primary\" [disabled]=\"form.invalid || !previewLoaded\">\n <ng-container *ngIf=\"existing; else doesNotExist\">{{ 'common.update' | translate }}</ng-container>\n <ng-template #doesNotExist>{{ 'editor.insert-image' | translate }}</ng-template>\n </button>\n</ng-template>\n", styles: [".preview{display:flex;align-items:center;justify-content:center;max-width:150px;margin-inline-start:12px}.preview img{max-width:100%;display:none}.preview img.visible{display:block}.preview .placeholder{color:var(--color-grey-300)}\n"], dependencies: [{ kind: "directive", type: i1.ClrIconCustomTag, selector: "clr-icon" }, { kind: "directive", type: i1.ClrLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i1.ClrForm, selector: "[clrForm]", inputs: ["clrLabelSize"] }, { kind: "directive", type: i1.ClrLayout, selector: "[clrForm][clrLayout]", inputs: ["clrLayout"] }, { kind: "directive", type: i1.ClrInput, selector: "[clrInput]" }, { kind: "component", type: i1.ClrInputContainer, selector: "clr-input-container" }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i4.FormFieldControlDirective, selector: "input, textarea, select, vdr-currency-input" }, { kind: "directive", type: i5.DialogButtonsDirective, selector: "[vdrDialogButtons]" }, { kind: "pipe", type: i6.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
32
|
+
}
|
|
33
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ExternalImageDialogComponent, decorators: [{
|
|
34
|
+
type: Component,
|
|
35
|
+
args: [{ selector: 'vdr-external-image-dialog', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"flex\">\n <form [formGroup]=\"form\" class=\"flex-spacer\" clrForm clrLayout=\"vertical\">\n <clr-input-container class=\"expand\">\n <label>{{ 'editor.image-src' | translate }}</label>\n <input clrInput type=\"text\" formControlName=\"src\" />\n </clr-input-container>\n <clr-input-container class=\"expand\">\n <label>{{ 'editor.image-title' | translate }}</label>\n <input clrInput type=\"text\" formControlName=\"title\" />\n </clr-input-container>\n <clr-input-container class=\"expand\">\n <label>{{ 'editor.image-alt' | translate }}</label>\n <input clrInput type=\"text\" formControlName=\"alt\" />\n </clr-input-container>\n </form>\n <div class=\"preview\">\n <img\n [src]=\"form.get('src')?.value\"\n [class.visible]=\"previewLoaded\"\n (load)=\"onImageLoad($event)\"\n (error)=\"onImageError($event)\"\n />\n <div class=\"placeholder\" *ngIf=\"!previewLoaded\">\n <clr-icon shape=\"image\" size=\"128\"></clr-icon>\n </div>\n </div>\n</div>\n\n<ng-template vdrDialogButtons>\n <button type=\"submit\" (click)=\"select()\" class=\"btn btn-primary\" [disabled]=\"form.invalid || !previewLoaded\">\n <ng-container *ngIf=\"existing; else doesNotExist\">{{ 'common.update' | translate }}</ng-container>\n <ng-template #doesNotExist>{{ 'editor.insert-image' | translate }}</ng-template>\n </button>\n</ng-template>\n", styles: [".preview{display:flex;align-items:center;justify-content:center;max-width:150px;margin-inline-start:12px}.preview img{max-width:100%;display:none}.preview img.visible{display:block}.preview .placeholder{color:var(--color-grey-300)}\n"] }]
|
|
36
|
+
}] });
|
|
37
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXh0ZXJuYW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gICAgICAgIDxuZy1jb250YWluZXIgKm5nSWY9XCJleGlzdGluZzsgZWxzZSBkb2VzTm90RXhpc3RcIj57eyAnY29tbW9uLnVwZGF0ZScgfCB0cmFuc2xhdGUgfX08L25nLWNvbnRhaW5lcj5cbiAgICAgICAgPG5nLXRlbXBsYXRlICNkb2VzTm90RXhpc3Q+e3sgJ2VkaXRvci5pbnNlcnQtaW1hZ2UnIHwgdHJhbnNsYXRlIH19PC9uZy10ZW1wbGF0ZT5cbiAgICA8L2J1dHRvbj5cbjwvbmctdGVtcGxhdGU+XG4iXX0=
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { FormControl, UntypedFormGroup, Validators } from '@angular/forms';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
import * as i1 from "@clr/angular";
|
|
5
|
+
import * as i2 from "@angular/common";
|
|
6
|
+
import * as i3 from "@angular/forms";
|
|
7
|
+
import * as i4 from "../../form-field/form-field.component";
|
|
8
|
+
import * as i5 from "../../form-field/form-field-control.directive";
|
|
9
|
+
import * as i6 from "../../modal-dialog/dialog-buttons.directive";
|
|
10
|
+
import * as i7 from "@ngx-translate/core";
|
|
11
|
+
export class LinkDialogComponent {
|
|
12
|
+
ngOnInit() {
|
|
13
|
+
this.form = new UntypedFormGroup({
|
|
14
|
+
href: new FormControl(this.existing ? this.existing.href : '', Validators.required),
|
|
15
|
+
title: new FormControl(this.existing ? this.existing.title : ''),
|
|
16
|
+
target: new FormControl(this.existing ? this.existing.target : null),
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
remove() {
|
|
20
|
+
this.resolveWith({
|
|
21
|
+
title: '',
|
|
22
|
+
href: '',
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
select() {
|
|
26
|
+
this.resolveWith(this.form.value);
|
|
27
|
+
}
|
|
28
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: LinkDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
29
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: LinkDialogComponent, selector: "vdr-link-dialog", ngImport: i0, template: "<form [formGroup]=\"form\">\n <div class=\"form-grid\">\n <vdr-form-field [label]=\"'editor.link-href' | translate\" for=\"href\" class=\"form-grid-span\">\n <input id=\"href\" type=\"text\" formControlName=\"href\"/>\n </vdr-form-field>\n <vdr-form-field [label]=\"'editor.link-title' | translate\" for=\"title\">\n <input id=\"title\" type=\"text\" formControlName=\"title\"/>\n </vdr-form-field>\n <vdr-form-field [label]=\"'editor.link-target' | translate\" for=\"target\">\n <select id=\"target\" formControlName=\"target\">\n <option value=\"\"></option>\n <option value=\"_self\">_self</option>\n <option value=\"_blank\">_blank</option>\n <option value=\"_parent\">_parent</option>\n <option value=\"_top\">_top</option>\n </select>\n </vdr-form-field>\n </div>\n</form>\n<ng-template vdrDialogButtons>\n <button type=\"button\" class=\"btn btn-secondary\" (click)=\"remove()\" *ngIf=\"existing\">\n <clr-icon shape=\"unlink\"></clr-icon>\n {{ 'editor.remove-link' | translate }}\n </button>\n <button type=\"submit\" (click)=\"select()\" class=\"btn btn-primary\" [disabled]=\"form.invalid\">\n {{ 'editor.set-link' | translate }}\n </button>\n</ng-template>\n", styles: [""], dependencies: [{ kind: "directive", type: i1.ClrIconCustomTag, selector: "clr-icon" }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i4.FormFieldComponent, selector: "vdr-form-field", inputs: ["label", "for", "tooltip", "errors", "readOnlyToggle"], outputs: ["readOnlyToggleChange"] }, { kind: "directive", type: i5.FormFieldControlDirective, selector: "input, textarea, select, vdr-currency-input" }, { kind: "directive", type: i6.DialogButtonsDirective, selector: "[vdrDialogButtons]" }, { kind: "pipe", type: i7.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
30
|
+
}
|
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: LinkDialogComponent, decorators: [{
|
|
32
|
+
type: Component,
|
|
33
|
+
args: [{ selector: 'vdr-link-dialog', changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"form\">\n <div class=\"form-grid\">\n <vdr-form-field [label]=\"'editor.link-href' | translate\" for=\"href\" class=\"form-grid-span\">\n <input id=\"href\" type=\"text\" formControlName=\"href\"/>\n </vdr-form-field>\n <vdr-form-field [label]=\"'editor.link-title' | translate\" for=\"title\">\n <input id=\"title\" type=\"text\" formControlName=\"title\"/>\n </vdr-form-field>\n <vdr-form-field [label]=\"'editor.link-target' | translate\" for=\"target\">\n <select id=\"target\" formControlName=\"target\">\n <option value=\"\"></option>\n <option value=\"_self\">_self</option>\n <option value=\"_blank\">_blank</option>\n <option value=\"_parent\">_parent</option>\n <option value=\"_top\">_top</option>\n </select>\n </vdr-form-field>\n </div>\n</form>\n<ng-template vdrDialogButtons>\n <button type=\"button\" class=\"btn btn-secondary\" (click)=\"remove()\" *ngIf=\"existing\">\n <clr-icon shape=\"unlink\"></clr-icon>\n {{ 'editor.remove-link' | translate }}\n </button>\n <button type=\"submit\" (click)=\"select()\" class=\"btn btn-primary\" [disabled]=\"form.invalid\">\n {{ 'editor.set-link' | translate }}\n </button>\n</ng-template>\n" }]
|
|
34
|
+
}] });
|
|
35
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGluay1kaWFsb2cuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vc3JjL2xpYi9jb3JlL3NyYy9zaGFyZWQvY29tcG9uZW50cy9yaWNoLXRleHQtZWRpdG9yL2xpbmstZGlhbG9nL2xpbmstZGlhbG9nLmNvbXBvbmVudC50cyIsIi4uLy4uLy4uLy4uLy4uLy4uLy4uL3NyYy9saWIvY29yZS9zcmMvc2hhcmVkL2NvbXBvbmVudHMvcmljaC10ZXh0LWVkaXRvci9saW5rLWRpYWxvZy9saW5rLWRpYWxvZy5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsU0FBUyxFQUFVLE1BQU0sZUFBZSxDQUFDO0FBQzNFLE9BQU8sRUFBRSxXQUFXLEVBQUUsZ0JBQWdCLEVBQUUsVUFBVSxFQUFFLE1BQU0sZ0JBQWdCLENBQUM7Ozs7Ozs7OztBQWdCM0UsTUFBTSxPQUFPLG1CQUFtQjtJQU01QixRQUFRO1FBQ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iZm9ybS5pbnZhbGlkXCI+XG4gICAgICAgIHt7ICdlZGl0b3Iuc2V0LWxpbmsnIHwgdHJhbnNsYXRlIH19XG4gICAgPC9idXR0b24+XG48L25nLXRlbXBsYXRlPlxuIl19
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
import { TemplatePortal } from '@angular/cdk/portal';
|
|
2
|
+
import { ChangeDetectionStrategy, Component, Input, ViewChild, } from '@angular/core';
|
|
3
|
+
import { BehaviorSubject } from 'rxjs';
|
|
4
|
+
import { distinctUntilChanged } from 'rxjs/operators';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
import * as i1 from "@angular/cdk/overlay";
|
|
7
|
+
import * as i2 from "./context-menu.service";
|
|
8
|
+
import * as i3 from "@clr/angular";
|
|
9
|
+
import * as i4 from "@angular/common";
|
|
10
|
+
import * as i5 from "../../../dropdown/dropdown.component";
|
|
11
|
+
import * as i6 from "../../../dropdown/dropdown-menu.component";
|
|
12
|
+
import * as i7 from "../../../dropdown/dropdown-trigger.directive";
|
|
13
|
+
export class ContextMenuComponent {
|
|
14
|
+
constructor(overlay, viewContainerRef, contextMenuService) {
|
|
15
|
+
this.overlay = overlay;
|
|
16
|
+
this.viewContainerRef = viewContainerRef;
|
|
17
|
+
this.contextMenuService = contextMenuService;
|
|
18
|
+
this.triggerIsHidden = new BehaviorSubject(false);
|
|
19
|
+
this.onScroll = () => {
|
|
20
|
+
if (this.overlayRef?.hasAttached()) {
|
|
21
|
+
this.overlayRef.updatePosition();
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
ngAfterViewInit() {
|
|
26
|
+
this.contentArea = document.querySelector('.content-area');
|
|
27
|
+
this.menuPortal = new TemplatePortal(this.menuTemplate, this.viewContainerRef);
|
|
28
|
+
this.hideTrigger$ = this.triggerIsHidden.asObservable().pipe(distinctUntilChanged());
|
|
29
|
+
this.contentArea?.addEventListener('scroll', this.onScroll, { passive: true });
|
|
30
|
+
this.contextMenuSub = this.contextMenuService.contextMenu$.subscribe(contextMenuConfig => {
|
|
31
|
+
this.overlayRef?.dispose();
|
|
32
|
+
this.menuConfig = contextMenuConfig;
|
|
33
|
+
if (contextMenuConfig) {
|
|
34
|
+
this.overlayRef = this.overlay.create({
|
|
35
|
+
hasBackdrop: false,
|
|
36
|
+
positionStrategy: this.getPositionStrategy(contextMenuConfig.element),
|
|
37
|
+
maxHeight: '70vh',
|
|
38
|
+
});
|
|
39
|
+
this.overlayRef.attach(this.menuPortal);
|
|
40
|
+
this.triggerIsHidden.next(false);
|
|
41
|
+
const triggerButton = this.overlayRef.hostElement.querySelector('.context-menu-trigger');
|
|
42
|
+
const editorMenu = this.editorMenuElement;
|
|
43
|
+
if (triggerButton) {
|
|
44
|
+
const overlapMarginPx = 5;
|
|
45
|
+
this.hideTriggerHandler = () => {
|
|
46
|
+
if (editorMenu && triggerButton) {
|
|
47
|
+
if (triggerButton.getBoundingClientRect().top + overlapMarginPx <
|
|
48
|
+
editorMenu.getBoundingClientRect().bottom) {
|
|
49
|
+
this.triggerIsHidden.next(true);
|
|
50
|
+
}
|
|
51
|
+
else {
|
|
52
|
+
this.triggerIsHidden.next(false);
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
};
|
|
56
|
+
this.contentArea?.addEventListener('scroll', this.hideTriggerHandler, { passive: true });
|
|
57
|
+
requestAnimationFrame(() => this.hideTriggerHandler?.());
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
else {
|
|
61
|
+
if (this.hideTriggerHandler) {
|
|
62
|
+
this.contentArea?.removeEventListener('scroll', this.hideTriggerHandler);
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
triggerClick() {
|
|
68
|
+
this.contextMenuService.setVisibility(true);
|
|
69
|
+
}
|
|
70
|
+
ngOnDestroy() {
|
|
71
|
+
this.overlayRef?.dispose();
|
|
72
|
+
this.contextMenuSub?.unsubscribe();
|
|
73
|
+
this.contentArea?.removeEventListener('scroll', this.onScroll);
|
|
74
|
+
if (this.hideTriggerHandler) {
|
|
75
|
+
this.contentArea?.removeEventListener('scroll', this.hideTriggerHandler);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
clickItem(item) {
|
|
79
|
+
item.onClick();
|
|
80
|
+
}
|
|
81
|
+
getPositionStrategy(element) {
|
|
82
|
+
const position = {
|
|
83
|
+
['top-left']: {
|
|
84
|
+
originX: 'start',
|
|
85
|
+
originY: 'top',
|
|
86
|
+
overlayX: 'start',
|
|
87
|
+
overlayY: 'bottom',
|
|
88
|
+
},
|
|
89
|
+
['top-right']: {
|
|
90
|
+
originX: 'end',
|
|
91
|
+
originY: 'top',
|
|
92
|
+
overlayX: 'end',
|
|
93
|
+
overlayY: 'bottom',
|
|
94
|
+
},
|
|
95
|
+
['bottom-left']: {
|
|
96
|
+
originX: 'start',
|
|
97
|
+
originY: 'bottom',
|
|
98
|
+
overlayX: 'start',
|
|
99
|
+
overlayY: 'top',
|
|
100
|
+
},
|
|
101
|
+
['bottom-right']: {
|
|
102
|
+
originX: 'end',
|
|
103
|
+
originY: 'bottom',
|
|
104
|
+
overlayX: 'end',
|
|
105
|
+
overlayY: 'top',
|
|
106
|
+
},
|
|
107
|
+
};
|
|
108
|
+
const pos = position['top-left'];
|
|
109
|
+
return this.overlay
|
|
110
|
+
.position()
|
|
111
|
+
.flexibleConnectedTo(element)
|
|
112
|
+
.withPositions([pos, this.invertPosition(pos)])
|
|
113
|
+
.withViewportMargin(0)
|
|
114
|
+
.withLockedPosition(false)
|
|
115
|
+
.withPush(false);
|
|
116
|
+
}
|
|
117
|
+
/** Inverts an overlay position. */
|
|
118
|
+
invertPosition(pos) {
|
|
119
|
+
const inverted = { ...pos };
|
|
120
|
+
inverted.originY = pos.originY === 'top' ? 'bottom' : 'top';
|
|
121
|
+
inverted.overlayY = pos.overlayY === 'top' ? 'bottom' : 'top';
|
|
122
|
+
return inverted;
|
|
123
|
+
}
|
|
124
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ContextMenuComponent, deps: [{ token: i1.Overlay }, { token: i0.ViewContainerRef }, { token: i2.ContextMenuService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
125
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: ContextMenuComponent, selector: "vdr-context-menu", inputs: { editorMenuElement: "editorMenuElement" }, viewQueries: [{ propertyName: "menuTemplate", first: true, predicate: ["contextMenu"], descendants: true, static: true }], ngImport: i0, template: "<ng-template #contextMenu>\n <vdr-dropdown>\n <button class=\"context-menu-trigger\" vdrDropdownTrigger [class.hidden]=\"hideTrigger$ | async\" (click)=\"triggerClick()\">\n <clr-icon\n *ngIf=\"menuConfig?.iconShape as shape\"\n [attr.shape]=\"shape\"\n size=\"16\"\n class=\"mr2\"\n ></clr-icon>\n <span class=\"title-label\">{{ menuConfig?.title }}</span>\n </button>\n <vdr-dropdown-menu vdrPosition=\"bottom-right\" customClasses=\"context-menu\">\n <ng-container *ngFor=\"let item of menuConfig?.items\">\n <button\n class=\"context-menu-item\"\n *ngIf=\"item.enabled && item.separator !== true\"\n type=\"button\"\n (click)=\"clickItem(item)\"\n >\n <div *ngIf=\"item.iconClass\" class=\"cm-icon\" [ngClass]=\"item.iconClass\"></div>\n <clr-icon\n *ngIf=\"item.iconShape as shape\"\n [attr.shape]=\"shape\"\n size=\"16\"\n class=\"mr2\"\n ></clr-icon>\n {{ item.label }}\n </button>\n <div *ngIf=\"item.enabled && item.separator\" class=\"dropdown-divider\" role=\"separator\"></div>\n </ng-container>\n </vdr-dropdown-menu>\n </vdr-dropdown>\n</ng-template>\n", styles: [".context-menu-trigger{margin:0;display:flex;align-items:center;border:1px solid var(--color-component-border-200);font-size:90%;color:var(--color-text-200);border-radius:var(--border-radius-input);background-color:var(--color-component-bg-100)}.title-label{padding-inline-end:15px;position:relative}.title-label:after{content:\"\";border-inline-start:4px solid transparent;border-inline-end:4px solid transparent;border-top:4px solid currentColor;opacity:.6;position:absolute;right:4px;top:calc(50% - 2px)}.context-menu-item{display:flex;align-items:center;width:100%;text-align:start;font-size:90%;color:var(--color-text-200);background-color:var(--color-component-bg-100);cursor:pointer;border:none}.context-menu-item:hover{background-color:var(--color-component-bg-200)}::ng-deep .dropdown-menu.context-menu{padding:0;background-color:var(--color-component-bg-100)}::ng-deep .context-menu-trigger{min-height:16px}::ng-deep .context-menu-trigger.hidden{visibility:hidden}::ng-deep .cm-icon.add-column{height:14px;width:4px;border:1px solid;margin:0 6px 0 8px;position:relative}::ng-deep .cm-icon.add-column:before{content:\"+\";position:absolute;font-size:16px;line-height:14px;left:-10px}::ng-deep .cm-icon.add-row{height:4px;width:14px;border:1px solid;margin:6px 4px 2px 0;position:relative}::ng-deep .cm-icon.add-row:before{content:\"+\";position:absolute;font-size:16px;line-height:14px;left:-2px;top:-10px}\n"], dependencies: [{ kind: "directive", type: i3.ClrIconCustomTag, selector: "clr-icon" }, { kind: "directive", type: i4.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i4.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.DropdownComponent, selector: "vdr-dropdown", inputs: ["manualToggle"] }, { kind: "component", type: i6.DropdownMenuComponent, selector: "vdr-dropdown-menu", inputs: ["vdrPosition", "customClasses"] }, { kind: "directive", type: i7.DropdownTriggerDirective, selector: "[vdrDropdownTrigger]" }, { kind: "pipe", type: i4.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
126
|
+
}
|
|
127
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ContextMenuComponent, decorators: [{
|
|
128
|
+
type: Component,
|
|
129
|
+
args: [{ selector: 'vdr-context-menu', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-template #contextMenu>\n <vdr-dropdown>\n <button class=\"context-menu-trigger\" vdrDropdownTrigger [class.hidden]=\"hideTrigger$ | async\" (click)=\"triggerClick()\">\n <clr-icon\n *ngIf=\"menuConfig?.iconShape as shape\"\n [attr.shape]=\"shape\"\n size=\"16\"\n class=\"mr2\"\n ></clr-icon>\n <span class=\"title-label\">{{ menuConfig?.title }}</span>\n </button>\n <vdr-dropdown-menu vdrPosition=\"bottom-right\" customClasses=\"context-menu\">\n <ng-container *ngFor=\"let item of menuConfig?.items\">\n <button\n class=\"context-menu-item\"\n *ngIf=\"item.enabled && item.separator !== true\"\n type=\"button\"\n (click)=\"clickItem(item)\"\n >\n <div *ngIf=\"item.iconClass\" class=\"cm-icon\" [ngClass]=\"item.iconClass\"></div>\n <clr-icon\n *ngIf=\"item.iconShape as shape\"\n [attr.shape]=\"shape\"\n size=\"16\"\n class=\"mr2\"\n ></clr-icon>\n {{ item.label }}\n </button>\n <div *ngIf=\"item.enabled && item.separator\" class=\"dropdown-divider\" role=\"separator\"></div>\n </ng-container>\n </vdr-dropdown-menu>\n </vdr-dropdown>\n</ng-template>\n", styles: [".context-menu-trigger{margin:0;display:flex;align-items:center;border:1px solid var(--color-component-border-200);font-size:90%;color:var(--color-text-200);border-radius:var(--border-radius-input);background-color:var(--color-component-bg-100)}.title-label{padding-inline-end:15px;position:relative}.title-label:after{content:\"\";border-inline-start:4px solid transparent;border-inline-end:4px solid transparent;border-top:4px solid currentColor;opacity:.6;position:absolute;right:4px;top:calc(50% - 2px)}.context-menu-item{display:flex;align-items:center;width:100%;text-align:start;font-size:90%;color:var(--color-text-200);background-color:var(--color-component-bg-100);cursor:pointer;border:none}.context-menu-item:hover{background-color:var(--color-component-bg-200)}::ng-deep .dropdown-menu.context-menu{padding:0;background-color:var(--color-component-bg-100)}::ng-deep .context-menu-trigger{min-height:16px}::ng-deep .context-menu-trigger.hidden{visibility:hidden}::ng-deep .cm-icon.add-column{height:14px;width:4px;border:1px solid;margin:0 6px 0 8px;position:relative}::ng-deep .cm-icon.add-column:before{content:\"+\";position:absolute;font-size:16px;line-height:14px;left:-10px}::ng-deep .cm-icon.add-row{height:4px;width:14px;border:1px solid;margin:6px 4px 2px 0;position:relative}::ng-deep .cm-icon.add-row:before{content:\"+\";position:absolute;font-size:16px;line-height:14px;left:-2px;top:-10px}\n"] }]
|
|
130
|
+
}], ctorParameters: () => [{ type: i1.Overlay }, { type: i0.ViewContainerRef }, { type: i2.ContextMenuService }], propDecorators: { editorMenuElement: [{
|
|
131
|
+
type: Input
|
|
132
|
+
}], menuTemplate: [{
|
|
133
|
+
type: ViewChild,
|
|
134
|
+
args: ['contextMenu', { static: true }]
|
|
135
|
+
}] } });
|
|
136
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29udGV4dC1tZW51LmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL3NyYy9saWIvY29yZS9zcmMvc2hhcmVkL2NvbXBvbmVudHMvcmljaC10ZXh0LWVkaXRvci9wcm9zZW1pcnJvci9jb250ZXh0LW1lbnUvY29udGV4dC1tZW51LmNvbXBvbmVudC50cyIsIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL3NyYy9saWIvY29yZS9zcmMvc2hhcmVkL2NvbXBvbmVudHMvcmljaC10ZXh0LWVkaXRvci9wcm9zZW1pcnJvci9jb250ZXh0LW1lbnUvY29udGV4dC1tZW51LmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUNBLE9BQU8sRUFBRSxjQUFjLEVBQUUsTUFBTSxxQkFBcUIsQ0FBQztBQUNyRCxPQUFPLEVBRUgsdUJBQXVCLEVBQ3ZCLFNBQVMsRUFDVCxLQUFLLEVBR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51Q29uZmlnKSB7XG4gICAgICAgICAgICAgICAgdGhpcy5vdmVybGF5UmVmID0gdGhpcy5vdmVybGF5LmNyZWF0ZSh7XG4gICAgICAgICAgICAgICAgICAgIGhhc0JhY2tkcm9wOiBmYWxzZSxcbiAgICAgICAgICAgICAgICAgICAgcG9zaXRpb25TdHJhdGVneTogdGhpcy5nZXRQb3NpdGlvblN0cmF0ZWd5KGNvbnRleHRNZW51Q29uZmlnLmVsZW1lbnQpLFxuICAgICAgICAgICAgICAgICAgICBtYXhIZWlnaHQ6ICc3MHZoJyxcbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICB0aGlzLm92ZXJsYXlSZWYuYXR0YWNoKHRoaXMubWVudVBvcnRhbCk7XG4gICAgICAgICAgICAgICAgdGhpcy50cmlnZ2VySXNIaWRkZW4ubmV4dChmYWxzZSk7XG5cbiAgICAgICAgICAgICAgICBjb25zdCB0cmlnZ2VyQnV0dG9uID0gdGhpcy5vdmVybGF5UmVmLmhvc3RFbGVtZW50LnF1ZXJ5U2VsZWN0b3IoJy5jb250ZXh0LW1lbnUtdHJpZ2dlcicpO1xuICAgICAgICAgICAgICAgIGNvbnN0IGVkaXRvck1lbnUgPSB0aGlzLmVkaXRvck1lbnVFbGVtZW50O1xuICAgICAgICAgICAgICAgIGlmICh0cmlnZ2VyQnV0dG9uKSB7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IG92ZXJsYXBNYXJnaW5QeCA9IDU7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuaGlkZVRyaWdnZXJIYW5kbGVyID0gKCkgPT4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGVkaXRvck1lbnUgJiYgdHJpZ2dlckJ1dHRvbikge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdHJpZ2dlckJ1dHRvbi5nZXRCb3VuZGluZ0NsaWVudFJlY3QoKS50b3AgKyBvdmVybGFwTWFyZ2luUHggPFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlZGl0b3JNZW51LmdldEJvdW5kaW5nQ2xpZW50UmVjdCgpLmJvdHRvbVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnRyaWdnZXJJc0hpZGRlbi5uZXh0KHRydWUpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMudHJpZ2dlcklzSGlkZGVuLm5leHQoZmFsc2UpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5jb250ZW50QXJlYT8uYWRkRXZlbnRMaXN0ZW5lcignc2Nyb2xsJywgdGhpcy5oaWRlVHJpZ2dlckhhbmRsZXIsIHsgcGFzc2l2ZTogdHJ1ZSB9KTtcbiAgICAgICAgICAgICAgICAgICAgcmVxdWVzdEFuaW1hdGlvbkZyYW1lKCgpID0+IHRoaXMuaGlkZVRyaWdnZXJIYW5kbGVyPy4oKSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICBpZiAodGhpcy5oaWRlVHJpZ2dlckhhbmRsZXIpIHtcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5jb250ZW50QXJlYT8ucmVtb3ZlRXZlbnRMaXN0ZW5lcignc2Nyb2xsJywgdGhpcy5oaWRlVHJpZ2dlckhhbmRsZXIpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfSk7XG4gICAgfVxuXG4gICAgdHJpZ2dlckNsaWNrKCkge1xuICAgICAgICB0aGlzLmNvbnRleHRNZW51U2VydmljZS5zZXRWaXNpYmlsaXR5KHRydWUpO1xuICAgIH1cblxuICAgIG5nT25EZXN0cm95KCk6IHZvaWQge1xuICAgICAgICB0aGlzLm92ZXJsYXlSZWY/LmRpc3Bvc2UoKTtcbiAgICAgICAgdGhpcy5jb250ZXh0TWVudVN1Yj8udW5zdWJzY3JpYmUoKTtcbiAgICAgICAgdGhpcy5jb250ZW50QXJlYT8ucmVtb3ZlRXZlbnRMaXN0ZW5lcignc2Nyb2xsJywgdGhpcy5vblNjcm9sbCk7XG4gICAgICAgIGlmICh0aGlzLmhpZGVUcmlnZ2VySGFuZGxlcikge1xuICAgICAgICAgICAgdGhpcy5jb250ZW50QXJlYT8ucmVtb3ZlRXZlbnRMaXN0ZW5lcignc2Nyb2xsJywgdGhpcy5oaWRlVHJpZ2dlckhhbmRsZXIpO1xuICAgICAgICB9XG4gICAgfVxuXG4gICAgY2xpY2tJdGVtKGl0ZW06IENvbnRleHRNZW51SXRlbSkge1xuICAgICAgICBpdGVtLm9uQ2xpY2soKTtcbiAgICB9XG5cbiAgICBwcml2YXRlIGdldFBvc2l0aW9uU3RyYXRlZ3koZWxlbWVudDogRWxlbWVudCk6IFBvc2l0aW9uU3RyYXRlZ3kge1xuICAgICAgICBjb25zdCBwb3NpdGlvbjogeyBbSyBpbiBEcm9wZG93blBvc2l0aW9uXTogQ29ubmVjdGVkUG9zaXRpb24gfSA9IHtcbiAgICAgICAgICAgIFsndG9wLWxlZnQnXToge1xuICAgICAgICAgICAgICAgIG9yaWdpblg6ICdzdGFydCcsXG4gICAgICAgICAgICAgICAgb3JpZ2luWTogJ3RvcCcsXG4gICAgICAgICAgICAgICAgb3ZlcmxheVg6ICdzdGFydCcsXG4gICAgICAgICAgICAgICAgb3ZlcmxheVk6ICdib3R0b20nLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIFsndG9wLXJpZ2h0J106IHtcbiAgICAgICAgICAgICAgICBvcmlnaW5YOiAnZW5kJyxcbiAgICAgICAgICAgICAgICBvcmlnaW5ZOiAndG9wJyxcbiAgICAgICAgICAgICAgICBvdmVybGF5WDogJ2VuZCcsXG4gICAgICAgICAgICAgICAgb3ZlcmxheVk6ICdib3R0b20nLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIFsnYm90dG9tLWxlZnQnXToge1xuICAgICAgICAgICAgICAgIG9yaWdpblg6ICdzdGFydCcsXG4gICAgICAgICAgICAgICAgb3JpZ2luWTogJ2JvdHRvbScsXG4gICAgICAgICAgICAgICAgb3ZlcmxheVg6ICdzdGFydCcsXG4gICAgICAgICAgICAgICAgb3ZlcmxheVk6ICd0b3AnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIFsnYm90dG9tLXJpZ2h0J106IHtcbiAgICAgICAgICAgICAgICBvcmlnaW5YOiAnZW5kJyxcbiAgICAgICAgICAgICAgICBvcmlnaW5ZOiAnYm90dG9tJyxcbiAgICAgICAgICAgICAgICBvdmVybGF5WDogJ2VuZCcsXG4gICAgICAgICAgICAgICAgb3ZlcmxheVk6ICd0b3AnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgfTtcblxuICAgICAgICBjb25zdCBwb3MgPSBwb3NpdGlvblsndG9wLWxlZnQnXTtcblxuICAgICAgICByZXR1cm4gdGhpcy5vdmVybGF5XG4gICAgICAgICAgICAucG9zaXRpb24oKVxuICAgICAgICAgICAgLmZsZXhpYmxlQ29ubmVjdGVkVG8oZWxlbWVudClcbiAgICAgICAgICAgIC53aXRoUG9zaXRpb25zKFtwb3MsIHRoaXMuaW52ZXJ0UG9zaXRpb24ocG9zKV0pXG4gICAgICAgICAgICAud2l0aFZpZXdwb3J0TWFyZ2luKDApXG4gICAgICAgICAgICAud2l0aExvY2tlZFBvc2l0aW9uKGZhbHNlKVxuICAgICAgICAgICAgLndpdGhQdXNoKGZhbHNlKTtcbiAgICB9XG5cbiAgICAvKiogSW52ZXJ0cyBhbiBvdmVybGF5IHBvc2l0aW9uLiAqL1xuICAgIHByaXZhdGUgaW52ZXJ0UG9zaXRpb24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PlxuICAgICAgICAgICAgPG5nLWNvbnRhaW5lciAqbmdGb3I9XCJsZXQgaXRlbSBvZiBtZW51Q29uZmlnPy5pdGVtc1wiPlxuICAgICAgICAgICAgICAgIDxidXR0b25cbiAgICAgICAgICAgICAgICAgICAgY2xhc3M9XCJjb250ZXh0LW1lbnUtaXRlbVwiXG4gICAgICAgICAgICAgICAgICAgICpuZ0lmPVwiaXRlbS5lbmFibGVkICYmIGl0ZW0uc2VwYXJhdG9yICE9PSB0cnVlXCJcbiAgICAgICAgICAgICAgICAgICAgdHlwZT1cImJ1dHRvblwiXG4gICAgICAgICAgICAgICAgICAgIChjbGljayk9XCJjbGlja0l0ZW0oaXRlbSlcIlxuICAgICAgICAgICAgICAgID5cbiAgICAgICAgICAgICAgICAgICAgPGRpdiAqbmdJZj1cIml0ZW0uaWNvbkNsYXNzXCIgY2xhc3M9XCJjbS1pY29uXCIgW25nQ2xhc3NdPVwiaXRlbS5pY29uQ2xhc3NcIj48L2Rpdj5cbiAgICAgICAgICAgICAgICAgICAgPGNsci1pY29uXG4gICAgICAgICAgICAgICAgICAgICAgICAqbmdJZj1cIml0ZW0uaWNvblNoYXBlIGFzIHNoYXBlXCJcbiAgICAgICAgICAgICAgICAgICAgICAgIFthdHRyLnNoYXBlXT1cInNoYXBlXCJcbiAgICAgICAgICAgICAgICAgICAgICAgIHNpemU9XCIxNlwiXG4gICAgICAgICAgICAgICAgICAgICAgICBjbGFzcz1cIm1yMlwiXG4gICAgICAgICAgICAgICAgICAgID48L2Nsci1pY29uPlxuICAgICAgICAgICAgICAgICAgICB7eyBpdGVtLmxhYmVsIH19XG4gICAgICAgICAgICAgICAgPC9idXR0b24+XG4gICAgICAgICAgICAgICAgPGRpdiAqbmdJZj1cIml0ZW0uZW5hYmxlZCAmJiBpdGVtLnNlcGFyYXRvclwiIGNsYXNzPVwiZHJvcGRvd24tZGl2aWRlclwiIHJvbGU9XCJzZXBhcmF0b3JcIj48L2Rpdj5cbiAgICAgICAgICAgIDwvbmctY29udGFpbmVyPlxuICAgICAgICA8L3Zkci1kcm9wZG93bi1tZW51PlxuICAgIDwvdmRyLWRyb3Bkb3duPlxuPC9uZy10ZW1wbGF0ZT5cbiJdfQ==
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { Injectable } from '@angular/core';
|
|
2
|
+
import { BehaviorSubject, combineLatest, interval, of, Subject } from 'rxjs';
|
|
3
|
+
import { bufferWhen, debounceTime, delayWhen, distinctUntilChanged, filter, map, takeUntil, } from 'rxjs/operators';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export class ContextMenuService {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.menuIsVisible$ = new BehaviorSubject(false);
|
|
8
|
+
this.setContextMenuConfig$ = new Subject();
|
|
9
|
+
const source$ = this.setContextMenuConfig$.asObservable();
|
|
10
|
+
const groupedConfig$ = source$.pipe(bufferWhen(() => source$.pipe(debounceTime(50))), map(group => group.reduce((acc, cur) => {
|
|
11
|
+
if (!acc) {
|
|
12
|
+
return cur;
|
|
13
|
+
}
|
|
14
|
+
else {
|
|
15
|
+
if (cur?.ref === acc.ref) {
|
|
16
|
+
acc.items.push(
|
|
17
|
+
// de-duplicate items
|
|
18
|
+
...(cur?.items.filter(i => !acc.items.find(ai => ai.label === i.label)) ??
|
|
19
|
+
[]));
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
return acc;
|
|
23
|
+
}, undefined)));
|
|
24
|
+
const visible$ = this.menuIsVisible$.pipe(filter(val => val === true));
|
|
25
|
+
const isVisible$ = this.menuIsVisible$.pipe(delayWhen(value => (value ? of(value) : interval(250).pipe(takeUntil(visible$)))), distinctUntilChanged());
|
|
26
|
+
this.contextMenu$ = combineLatest(groupedConfig$, isVisible$).pipe(map(([config, isVisible]) => (isVisible ? config : undefined)));
|
|
27
|
+
}
|
|
28
|
+
setVisibility(isVisible) {
|
|
29
|
+
this.menuIsVisible$.next(isVisible);
|
|
30
|
+
}
|
|
31
|
+
setContextMenu(config) {
|
|
32
|
+
this.setContextMenuConfig$.next(config);
|
|
33
|
+
}
|
|
34
|
+
clearContextMenu() {
|
|
35
|
+
this.setContextMenuConfig$.next(undefined);
|
|
36
|
+
}
|
|
37
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ContextMenuService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
38
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ContextMenuService, providedIn: 'root' }); }
|
|
39
|
+
}
|
|
40
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: ContextMenuService, decorators: [{
|
|
41
|
+
type: Injectable,
|
|
42
|
+
args: [{ providedIn: 'root' }]
|
|
43
|
+
}], ctorParameters: () => [] });
|
|
44
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29udGV4dC1tZW51LnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi8uLi9zcmMvbGliL2NvcmUvc3JjL3NoYXJlZC9jb21wb25lbnRzL3JpY2gtdGV4dC1lZGl0b3IvcHJvc2VtaXJyb3IvY29udGV4dC1tZW51L2NvbnRleHQtbWVudS5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDM0MsT0FBTyxFQUFFLGVBQWUsRUFBRSxhQUFhLEVBQUUsUUFBUSxFQUFjLEVBQUUsRUFBRSxPQUFPLEVBQUUsTUFBTSxNQUFNLENBQUM7QUFDekYsT0FBTyxFQUNILFVBQVUsRUFDVixZQUFZLEVBQ1osU0FBUyxFQUNULG9CQUFvQixFQUNwQixNQUFNLEVBQ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G4gICAgc2VwYXJhdG9yPzogYm9vbGVhbjtcbiAgICBpY29uQ2xhc3M/OiBzdHJpbmc7XG4gICAgaWNvblNoYXBlPzogc3RyaW5nO1xuICAgIGxhYmVsOiBzdHJpbmc7XG4gICAgZW5hYmxlZDogYm9vbGVhbjtcbiAgICBvbkNsaWNrOiAoKSA9PiB2b2lkO1xufVxuXG5ASW5qZWN0YWJsZSh7IHByb3ZpZGVkSW46ICdyb290JyB9KVxuZXhwb3J0IGNsYXNzIENvbnRleHRNZW51U2VydmljZSB7XG4gICAgY29udGV4dE1lbnUkOiBPYnNlcnZhYmxlPENvbnRleHRNZW51Q29uZmlnIHwgdW5kZWZpbmVkPjtcbiAgICBwcml2YXRlIG1lbnVJc1Zpc2libGUkID0gbmV3IEJlaGF2aW9yU3ViamVjdDxib29sZWFuPihmYWxzZSk7XG4gICAgcHJpdmF0ZSBzZXRDb250ZXh0TWVudUNvbmZpZyQgPSBuZXcgU3ViamVjdDxDb250ZXh0TWVudUNvbmZpZyB8IHVuZGVmaW5lZD4oKTtcbiAgICBjb25zdHJ1Y3RvcigpIHtcbiAgICAgICAgY29uc3Qgc291cmNlJCA9IHRoaXMuc2V0Q29udGV4dE1lbnVDb25maWckLmFzT2JzZXJ2YWJsZSgpO1xuICAgICAgICBjb25zdCBncm91cGVkQ29uZmlnJCA9IHNvdXJjZSQucGlwZShcbiAgICAgICAgICAgIGJ1ZmZlcldoZW4oKCkgPT4gc291cmNlJC5waXBlKGRlYm91bmNlVGltZSg1MCkpKSxcbiAgICAgICAgICAgIG1hcChncm91cCA9PlxuICAgICAgICAgICAgICAgIGdyb3VwLnJlZHVjZSgoYWNjLCBjdXIpID0+IHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKCFhY2MpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBjdXI7XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoY3VyPy5yZWYgPT09IGFjYy5yZWYpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhY2MuaXRlbXMucHVzaChcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gZGUtZHVwbGljYXRlIGl0ZW1zXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC4uLihjdXI/Lml0ZW1zLmZpbHRlcihpID0+ICFhY2MuaXRlbXMuZmluZChhaSA9PiBhaS5sYWJlbCA9PT0gaS5sYWJlbCkpID8/XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBbXSksXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gYWNjO1xuICAgICAgICAgICAgICAgIH0sIHVuZGVmaW5lZCBhcyBDb250ZXh0TWVudUNvbmZpZyB8IHVuZGVmaW5lZCksXG4gICAgICAgICAgICApLFxuICAgICAgICApO1xuXG4gICAgICAgIGNvbnN0IHZpc2libGUkID0gdGhpcy5tZW51SXNWaXNpYmxlJC5waXBlKGZpbHRlcih2YWwgPT4gdmFsID09PSB0cnVlKSk7XG5cbiAgICAgICAgY29uc3QgaXNWaXNpYmxlJCA9IHRoaXMubWVudUlzVmlzaWJsZSQucGlwZShcbiAgICAgICAgICAgIGRlbGF5V2hlbih2YWx1ZSA9PiAodmFsdWUgPyBvZih2YWx1ZSkgOiBpbnRlcnZhbCgyNTApLnBpcGUodGFrZVVudGlsKHZpc2libGUkKSkpKSxcbiAgICAgICAgICAgIGRpc3RpbmN0VW50aWxDaGFuZ2VkKCksXG4gICAgICAgICk7XG4gICAgICAgIHRoaXMuY29udGV4dE1lbnUkID0gY29tYmluZUxhdGVzdChncm91cGVkQ29uZmlnJCwgaXNWaXNpYmxlJCkucGlwZShcbiAgICAgICAgICAgIG1hcCgoW2NvbmZpZywgaXNWaXNpYmxlXSkgPT4gKGlzVmlzaWJsZSA/IGNvbmZpZyA6IHVuZGVmaW5lZCkpLFxuICAgICAgICApO1xuICAgIH1cblxuICAgIHNldFZpc2liaWxpdHkoaXNWaXNpYmxlOiBib29sZWFuKSB7XG4gICAgICAgIHRoaXMubWVudUlzVmlzaWJsZSQubmV4dChpc1Zpc2libGUpO1xuICAgIH1cblxuICAgIHNldENvbnRleHRNZW51KGNvbmZpZzogQ29udGV4dE1lbnVDb25maWcpIHtcbiAgICAgICAgdGhpcy5zZXRDb250ZXh0TWVudUNvbmZpZyQubmV4dChjb25maWcpO1xuICAgIH1cblxuICAgIGNsZWFyQ29udGV4dE1lbnUoKSB7XG4gICAgICAgIHRoaXMuc2V0Q29udGV4dE1lbnVDb25maWckLm5leHQodW5kZWZpbmVkKTtcbiAgICB9XG59XG4iXX0=
|