@vendure/admin-ui 3.4.0-minor-202506250934 → 3.4.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.
@@ -1,5 +1,5 @@
1
1
  import { ChangeDetectorRef, OnDestroy, OnInit } from '@angular/core';
2
- import { DataService, Dialog, FacetWithValuesFragment } from '@vendure/admin-ui/core';
2
+ import { DataService, Dialog, FacetValueFragment } from '@vendure/admin-ui/core';
3
3
  import { Subscription } from 'rxjs';
4
4
  import * as i0 from "@angular/core";
5
5
  interface ProductOrVariant {
@@ -17,14 +17,14 @@ interface ProductOrVariant {
17
17
  }>;
18
18
  }>;
19
19
  }
20
- export declare class BulkAddFacetValuesDialogComponent implements OnInit, OnDestroy, Dialog<FacetWithValuesFragment[]> {
20
+ export declare class BulkAddFacetValuesDialogComponent implements OnInit, OnDestroy, Dialog<FacetValueFragment[]> {
21
21
  private dataService;
22
22
  private changeDetectorRef;
23
- resolveWith: (result?: FacetWithValuesFragment[]) => void;
23
+ resolveWith: (result?: FacetValueFragment[]) => void;
24
24
  mode: 'product' | 'variant';
25
25
  ids?: string[];
26
26
  state: 'loading' | 'ready' | 'saving';
27
- selectedValues: FacetWithValuesFragment[];
27
+ selectedValues: FacetValueFragment[];
28
28
  items: ProductOrVariant[];
29
29
  facetValuesRemoved: boolean;
30
30
  private subscription;
@@ -2090,6 +2090,10 @@ export declare enum JobState {
2090
2090
  RETRYING = "RETRYING",
2091
2091
  RUNNING = "RUNNING"
2092
2092
  }
2093
+ export type KeyValueInput = {
2094
+ key: Scalars['String']['input'];
2095
+ value: Scalars['JSON']['input'];
2096
+ };
2093
2097
  /**
2094
2098
  * @description
2095
2099
  * Languages in the form of a ISO 639-1 language code with optional
@@ -2811,10 +2815,18 @@ export type Mutation = {
2811
2815
  setDraftOrderShippingAddress: Order;
2812
2816
  /** Sets the shipping method by id, which can be obtained with the `eligibleShippingMethodsForDraftOrder` query */
2813
2817
  setDraftOrderShippingMethod: SetOrderShippingMethodResult;
2818
+ /** Set a single key-value pair (automatically scoped based on field configuration) */
2819
+ setKeyValue: SetKeyValueResult;
2820
+ /** Set multiple key-value pairs in a transaction (each automatically scoped) */
2821
+ setKeyValues: Array<SetKeyValueResult>;
2814
2822
  setMainNavExpanded: Scalars['Boolean']['output'];
2815
2823
  setOrderCustomFields?: Maybe<Order>;
2816
2824
  /** Allows a different Customer to be assigned to an Order. Added in v2.2.0. */
2817
2825
  setOrderCustomer?: Maybe<Order>;
2826
+ /** Set a single key-value pair (automatically scoped based on field configuration) */
2827
+ setSettingsStoreValue: SetSettingsStoreValueResult;
2828
+ /** Set multiple key-value pairs in a transaction (each automatically scoped) */
2829
+ setSettingsStoreValues: Array<SetSettingsStoreValueResult>;
2818
2830
  setUiLanguage: LanguageCode;
2819
2831
  setUiLocale?: Maybe<Scalars['String']['output']>;
2820
2832
  setUiTheme: Scalars['String']['output'];
@@ -3295,6 +3307,12 @@ export type MutationSetDraftOrderShippingMethodArgs = {
3295
3307
  orderId: Scalars['ID']['input'];
3296
3308
  shippingMethodId: Scalars['ID']['input'];
3297
3309
  };
3310
+ export type MutationSetKeyValueArgs = {
3311
+ input: KeyValueInput;
3312
+ };
3313
+ export type MutationSetKeyValuesArgs = {
3314
+ inputs: Array<KeyValueInput>;
3315
+ };
3298
3316
  export type MutationSetMainNavExpandedArgs = {
3299
3317
  expanded: Scalars['Boolean']['input'];
3300
3318
  };
@@ -3304,6 +3322,12 @@ export type MutationSetOrderCustomFieldsArgs = {
3304
3322
  export type MutationSetOrderCustomerArgs = {
3305
3323
  input: SetOrderCustomerInput;
3306
3324
  };
3325
+ export type MutationSetSettingsStoreValueArgs = {
3326
+ input: SettingsStoreInput;
3327
+ };
3328
+ export type MutationSetSettingsStoreValuesArgs = {
3329
+ inputs: Array<SettingsStoreInput>;
3330
+ };
3307
3331
  export type MutationSetUiLanguageArgs = {
3308
3332
  languageCode: LanguageCode;
3309
3333
  };
@@ -4570,6 +4594,14 @@ export type Query = {
4570
4594
  facetValues: FacetValueList;
4571
4595
  facets: FacetList;
4572
4596
  fulfillmentHandlers: Array<ConfigurableOperationDefinition>;
4597
+ /** Get value for a specific key (automatically scoped based on field configuration) */
4598
+ getKeyValue?: Maybe<Scalars['JSON']['output']>;
4599
+ /** Get multiple key-value pairs (each automatically scoped) */
4600
+ getKeyValues?: Maybe<Scalars['JSON']['output']>;
4601
+ /** Get value for a specific key (automatically scoped based on field configuration) */
4602
+ getSettingsStoreValue?: Maybe<Scalars['JSON']['output']>;
4603
+ /** Get multiple key-value pairs (each automatically scoped) */
4604
+ getSettingsStoreValues?: Maybe<Scalars['JSON']['output']>;
4573
4605
  globalSettings: GlobalSettings;
4574
4606
  job?: Maybe<Job>;
4575
4607
  jobBufferSize: Array<JobBufferSize>;
@@ -4685,6 +4717,18 @@ export type QueryFacetValuesArgs = {
4685
4717
  export type QueryFacetsArgs = {
4686
4718
  options?: InputMaybe<FacetListOptions>;
4687
4719
  };
4720
+ export type QueryGetKeyValueArgs = {
4721
+ key: Scalars['String']['input'];
4722
+ };
4723
+ export type QueryGetKeyValuesArgs = {
4724
+ keys: Array<Scalars['String']['input']>;
4725
+ };
4726
+ export type QueryGetSettingsStoreValueArgs = {
4727
+ key: Scalars['String']['input'];
4728
+ };
4729
+ export type QueryGetSettingsStoreValuesArgs = {
4730
+ keys: Array<Scalars['String']['input']>;
4731
+ };
4688
4732
  export type QueryJobArgs = {
4689
4733
  jobId: Scalars['ID']['input'];
4690
4734
  };
@@ -5150,12 +5194,28 @@ export type ServerConfig = {
5150
5194
  permittedAssetTypes: Array<Scalars['String']['output']>;
5151
5195
  };
5152
5196
  export type SetCustomerForDraftOrderResult = EmailAddressConflictError | Order;
5197
+ export type SetKeyValueResult = {
5198
+ __typename?: 'SetKeyValueResult';
5199
+ error?: Maybe<Scalars['String']['output']>;
5200
+ key: Scalars['String']['output'];
5201
+ result: Scalars['Boolean']['output'];
5202
+ };
5153
5203
  export type SetOrderCustomerInput = {
5154
5204
  customerId: Scalars['ID']['input'];
5155
5205
  note?: InputMaybe<Scalars['String']['input']>;
5156
5206
  orderId: Scalars['ID']['input'];
5157
5207
  };
5158
5208
  export type SetOrderShippingMethodResult = IneligibleShippingMethodError | NoActiveOrderError | Order | OrderModificationError;
5209
+ export type SetSettingsStoreValueResult = {
5210
+ __typename?: 'SetSettingsStoreValueResult';
5211
+ error?: Maybe<Scalars['String']['output']>;
5212
+ key: Scalars['String']['output'];
5213
+ result: Scalars['Boolean']['output'];
5214
+ };
5215
+ export type SettingsStoreInput = {
5216
+ key: Scalars['String']['input'];
5217
+ value: Scalars['JSON']['input'];
5218
+ };
5159
5219
  /** Returned if the Payment settlement fails */
5160
5220
  export type SettlePaymentError = ErrorResult & {
5161
5221
  __typename?: 'SettlePaymentError';
@@ -1 +1 @@
1
- export declare const ADMIN_UI_VERSION = "3.4.0-minor-202506250934";
1
+ export declare const ADMIN_UI_VERSION = "3.4.0";
@@ -4055,11 +4055,11 @@ class ProductListComponent extends TypedBaseListComponent {
4055
4055
  });
4056
4056
  }
4057
4057
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: ProductListComponent, deps: [{ token: i1.DataService }, { token: i1.ModalService }, { token: i1.NotificationService }, { token: i1.JobQueueService }], target: i0.ɵɵFactoryTarget.Component }); }
4058
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.10", type: ProductListComponent, isStandalone: false, selector: "vdr-products-list", usesInheritance: true, ngImport: i0, template: "<vdr-page-block>\n <vdr-action-bar>\n <vdr-ab-left>\n <vdr-language-selector\n [availableLanguageCodes]=\"availableLanguages$ | async\"\n [currentLanguageCode]=\"contentLanguage$ | async\"\n (languageCodeChange)=\"setLanguage($event)\"\n ></vdr-language-selector>\n </vdr-ab-left>\n <vdr-ab-right>\n <vdr-action-bar-items [locationId]=\"pageLocationId\"></vdr-action-bar-items>\n <a\n class=\"button primary mr-1\"\n [routerLink]=\"['./create']\"\n *vdrIfPermissions=\"['CreateCatalog', 'CreateProduct']\"\n >\n <clr-icon shape=\"plus\"></clr-icon>\n {{ 'catalog.create-new-product' | translate }}\n </a>\n <vdr-action-bar-dropdown-menu [alwaysShow]=\"true\" [locationId]=\"pageLocationId\">\n <button type=\"button\" vdrDropdownItem (click)=\"rebuildSearchIndex()\">\n <clr-icon shape=\"refresh\" class=\"\"></clr-icon>\n {{ 'catalog.rebuild-search-index' | translate }}\n </button>\n </vdr-action-bar-dropdown-menu>\n </vdr-ab-right>\n </vdr-action-bar>\n</vdr-page-block>\n<vdr-data-table-2\n class=\"mt-2\"\n [id]=\"dataTableListId\"\n [items]=\"items$ | async\"\n [itemsPerPage]=\"itemsPerPage$ | async\"\n [totalItems]=\"totalItems$ | async\"\n [currentPage]=\"currentPage$ | async\"\n [filters]=\"filters\"\n (pageChange)=\"setPageNumber($event)\"\n (itemsPerPageChange)=\"setItemsPerPage($event)\"\n (visibleColumnsChange)=\"setVisibleColumns($event)\"\n>\n <vdr-bulk-action-menu\n [locationId]=\"dataTableListId\"\n [hostComponent]=\"this\"\n [selectionManager]=\"selectionManager\"\n ></vdr-bulk-action-menu>\n <vdr-dt2-search\n [searchTermControl]=\"searchTermControl\"\n [searchTermPlaceholder]=\"'settings.search-by-product-name-or-sku' | translate\"\n />\n <vdr-dt2-column [heading]=\"'common.id' | translate\" id=\"id\" [hiddenByDefault]=\"true\" [sort]=\"sorts.get('id')\">\n <ng-template let-product=\"item\">\n {{ product.id }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.created-at' | translate\" id=\"created-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('createdAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.createdAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.updated-at' | translate\" id=\"updated-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('updatedAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.updatedAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.image' | translate\" id=\"image\">\n <ng-template let-product=\"item\">\n <div class=\"image-placeholder\">\n <img\n *ngIf=\"product.featuredAsset as asset; else imagePlaceholder\"\n [src]=\"asset | assetPreview : 'tiny'\"\n />\n <ng-template #imagePlaceholder>\n <div class=\"placeholder\">\n <clr-icon shape=\"image\" size=\"48\"></clr-icon>\n </div>\n </ng-template>\n </div>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.name' | translate\" id=\"name\" [optional]=\"false\" [sort]=\"sorts.get('name')\">\n <ng-template let-product=\"item\">\n <a class=\"button-ghost\" [routerLink]=\"['./', product.id]\"\n ><span>{{ product.name }}</span\n ><clr-icon shape=\"arrow right\"\n /></a>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.slug' | translate\" id=\"slug\" [sort]=\"sorts.get('slug')\">\n <ng-template let-product=\"item\">\n {{ product.slug }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.enabled' | translate\" id=\"enabled\">\n <ng-template let-product=\"item\">\n <vdr-chip *ngIf=\"product.enabled\" colorType=\"success\">{{\n 'common.enabled' | translate\n }}</vdr-chip>\n <vdr-chip *ngIf=\"!product.enabled\" colorType=\"warning\">{{\n 'common.disabled' | translate\n }}</vdr-chip>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.number-of-variants' | translate\" id=\"number-of-variants\">\n <ng-template let-product=\"item\">\n {{ 'catalog.variant-count' | translate : { count: product.variantList?.totalItems } }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-custom-field-column\n *ngFor=\"let customField of customFields\"\n [customField]=\"customField\"\n [sorts]=\"sorts\"\n />\n</vdr-data-table-2>\n", styles: [".image-col{width:70px}.image-placeholder{width:50px;height:50px;margin-top:calc(var(--space-unit) * -1);margin-bottom:calc(var(--space-unit) * -1);background-color:var(--color-component-bg-200)}.image-placeholder img{border-radius:var(--border-radius-img)}.image-placeholder .placeholder{text-align:center;color:var(--color-grey-300)}.search-form{display:flex;align-items:center;width:100%}vdr-product-search-input{min-width:300px}@media screen and (max-width: 768px){vdr-product-search-input{min-width:100px}}.search-settings-menu{margin:0 12px}td.disabled{background-color:var(--color-component-bg-200)}.search-index-button{position:relative}.search-index-button vdr-status-badge{right:0;top:0}.run-updates-button{position:relative}.run-updates-button vdr-status-badge{left:10px;top:10px}.edit-button{margin-inline-end:24px}.sku{color:var(--color-text-300)}\n"], dependencies: [{ kind: "directive", type: i3.ClrIconCustomTag, selector: "clr-icon" }, { kind: "directive", type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i1.ActionBarComponent, selector: "vdr-action-bar" }, { kind: "component", type: i1.ActionBarLeftComponent, selector: "vdr-ab-left", inputs: ["grow"] }, { kind: "component", type: i1.ActionBarRightComponent, selector: "vdr-ab-right", inputs: ["grow"] }, { kind: "component", type: i1.ActionBarDropdownMenuComponent, selector: "vdr-action-bar-dropdown-menu", inputs: ["alwaysShow"] }, { kind: "component", type: i1.ChipComponent, selector: "vdr-chip", inputs: ["icon", "invert", "colorFrom", "colorType"], outputs: ["iconClick"] }, { kind: "component", type: i1.LanguageSelectorComponent, selector: "vdr-language-selector", inputs: ["currentLanguageCode", "availableLanguageCodes", "disabled"], outputs: ["languageCodeChange"] }, { kind: "directive", type: i1.DropdownItemDirective, selector: "[vdrDropdownItem]" }, { kind: "directive", type: i1.IfPermissionsDirective, selector: "[vdrIfPermissions]", inputs: ["vdrIfPermissions", "vdrIfPermissionsElse"] }, { kind: "component", type: i1.ActionBarItemsComponent, selector: "vdr-action-bar-items" }, { kind: "component", type: i1.BulkActionMenuComponent, selector: "vdr-bulk-action-menu", inputs: ["locationId", "selectionManager", "hostComponent"] }, { kind: "component", type: i1.DataTable2Component, selector: "vdr-data-table-2", inputs: ["id", "items", "itemsPerPage", "currentPage", "totalItems", "emptyStateLabel", "filters", "activeIndex", "trackByPath"], outputs: ["pageChange", "itemsPerPageChange", "visibleColumnsChange"] }, { kind: "component", type: i1.DataTable2ColumnComponent, selector: "vdr-dt2-column", inputs: ["id", "expand", "heading", "align", "sort", "optional", "hiddenByDefault", "orderable"], exportAs: ["row"] }, { kind: "component", type: i1.DataTable2SearchComponent, selector: "vdr-dt2-search", inputs: ["searchTermControl", "searchTermPlaceholder"] }, { kind: "component", type: i1.DataTableCustomFieldColumnComponent, selector: "vdr-dt2-custom-field-column", inputs: ["customField", "sorts"], exportAs: ["row"] }, { kind: "component", type: i1.PageBlockComponent, selector: "vdr-page-block" }, { kind: "pipe", type: i3$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "pipe", type: i1.AssetPreviewPipe, name: "assetPreview" }, { kind: "pipe", type: i1.LocaleDatePipe, name: "localeDate" }] }); }
4058
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.10", type: ProductListComponent, isStandalone: false, selector: "vdr-products-list", usesInheritance: true, ngImport: i0, template: "<vdr-page-block>\n <vdr-action-bar>\n <vdr-ab-left>\n <vdr-language-selector\n [availableLanguageCodes]=\"availableLanguages$ | async\"\n [currentLanguageCode]=\"contentLanguage$ | async\"\n (languageCodeChange)=\"setLanguage($event)\"\n ></vdr-language-selector>\n </vdr-ab-left>\n <vdr-ab-right>\n <vdr-action-bar-items [locationId]=\"pageLocationId\"></vdr-action-bar-items>\n <a\n class=\"btn btn-primary mr-1\"\n [routerLink]=\"['./create']\"\n *vdrIfPermissions=\"['CreateCatalog', 'CreateProduct']\"\n >\n <clr-icon shape=\"plus\"></clr-icon>\n {{ 'catalog.create-new-product' | translate }}\n </a>\n <vdr-action-bar-dropdown-menu [alwaysShow]=\"true\" [locationId]=\"pageLocationId\">\n <button type=\"button\" vdrDropdownItem (click)=\"rebuildSearchIndex()\">\n <clr-icon shape=\"refresh\" class=\"\"></clr-icon>\n {{ 'catalog.rebuild-search-index' | translate }}\n </button>\n </vdr-action-bar-dropdown-menu>\n </vdr-ab-right>\n </vdr-action-bar>\n</vdr-page-block>\n<vdr-data-table-2\n class=\"mt-2\"\n [id]=\"dataTableListId\"\n [items]=\"items$ | async\"\n [itemsPerPage]=\"itemsPerPage$ | async\"\n [totalItems]=\"totalItems$ | async\"\n [currentPage]=\"currentPage$ | async\"\n [filters]=\"filters\"\n (pageChange)=\"setPageNumber($event)\"\n (itemsPerPageChange)=\"setItemsPerPage($event)\"\n (visibleColumnsChange)=\"setVisibleColumns($event)\"\n>\n <vdr-bulk-action-menu\n [locationId]=\"dataTableListId\"\n [hostComponent]=\"this\"\n [selectionManager]=\"selectionManager\"\n ></vdr-bulk-action-menu>\n <vdr-dt2-search\n [searchTermControl]=\"searchTermControl\"\n [searchTermPlaceholder]=\"'settings.search-by-product-name-or-sku' | translate\"\n />\n <vdr-dt2-column [heading]=\"'common.id' | translate\" id=\"id\" [hiddenByDefault]=\"true\" [sort]=\"sorts.get('id')\">\n <ng-template let-product=\"item\">\n {{ product.id }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.created-at' | translate\" id=\"created-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('createdAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.createdAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.updated-at' | translate\" id=\"updated-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('updatedAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.updatedAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.image' | translate\" id=\"image\">\n <ng-template let-product=\"item\">\n <div class=\"image-placeholder\">\n <img\n *ngIf=\"product.featuredAsset as asset; else imagePlaceholder\"\n [src]=\"asset | assetPreview : 'tiny'\"\n />\n <ng-template #imagePlaceholder>\n <div class=\"placeholder\">\n <clr-icon shape=\"image\" size=\"48\"></clr-icon>\n </div>\n </ng-template>\n </div>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.name' | translate\" id=\"name\" [optional]=\"false\" [sort]=\"sorts.get('name')\">\n <ng-template let-product=\"item\">\n <a class=\"button-ghost\" [routerLink]=\"['./', product.id]\"\n ><span>{{ product.name }}</span\n ><clr-icon shape=\"arrow right\"\n /></a>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.slug' | translate\" id=\"slug\" [sort]=\"sorts.get('slug')\">\n <ng-template let-product=\"item\">\n {{ product.slug }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.enabled' | translate\" id=\"enabled\">\n <ng-template let-product=\"item\">\n <vdr-chip *ngIf=\"product.enabled\" colorType=\"success\">{{\n 'common.enabled' | translate\n }}</vdr-chip>\n <vdr-chip *ngIf=\"!product.enabled\" colorType=\"warning\">{{\n 'common.disabled' | translate\n }}</vdr-chip>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.number-of-variants' | translate\" id=\"number-of-variants\">\n <ng-template let-product=\"item\">\n {{ 'catalog.variant-count' | translate : { count: product.variantList?.totalItems } }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-custom-field-column\n *ngFor=\"let customField of customFields\"\n [customField]=\"customField\"\n [sorts]=\"sorts\"\n />\n</vdr-data-table-2>\n", styles: [".image-col{width:70px}.image-placeholder{width:50px;height:50px;margin-top:calc(var(--space-unit) * -1);margin-bottom:calc(var(--space-unit) * -1);background-color:var(--color-component-bg-200)}.image-placeholder img{border-radius:var(--border-radius-img)}.image-placeholder .placeholder{text-align:center;color:var(--color-grey-300)}.search-form{display:flex;align-items:center;width:100%}vdr-product-search-input{min-width:300px}@media screen and (max-width: 768px){vdr-product-search-input{min-width:100px}}.search-settings-menu{margin:0 12px}td.disabled{background-color:var(--color-component-bg-200)}.search-index-button{position:relative}.search-index-button vdr-status-badge{right:0;top:0}.run-updates-button{position:relative}.run-updates-button vdr-status-badge{left:10px;top:10px}.edit-button{margin-inline-end:24px}.sku{color:var(--color-text-300)}\n"], dependencies: [{ kind: "directive", type: i3.ClrIconCustomTag, selector: "clr-icon" }, { kind: "directive", type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i1.ActionBarComponent, selector: "vdr-action-bar" }, { kind: "component", type: i1.ActionBarLeftComponent, selector: "vdr-ab-left", inputs: ["grow"] }, { kind: "component", type: i1.ActionBarRightComponent, selector: "vdr-ab-right", inputs: ["grow"] }, { kind: "component", type: i1.ActionBarDropdownMenuComponent, selector: "vdr-action-bar-dropdown-menu", inputs: ["alwaysShow"] }, { kind: "component", type: i1.ChipComponent, selector: "vdr-chip", inputs: ["icon", "invert", "colorFrom", "colorType"], outputs: ["iconClick"] }, { kind: "component", type: i1.LanguageSelectorComponent, selector: "vdr-language-selector", inputs: ["currentLanguageCode", "availableLanguageCodes", "disabled"], outputs: ["languageCodeChange"] }, { kind: "directive", type: i1.DropdownItemDirective, selector: "[vdrDropdownItem]" }, { kind: "directive", type: i1.IfPermissionsDirective, selector: "[vdrIfPermissions]", inputs: ["vdrIfPermissions", "vdrIfPermissionsElse"] }, { kind: "component", type: i1.ActionBarItemsComponent, selector: "vdr-action-bar-items" }, { kind: "component", type: i1.BulkActionMenuComponent, selector: "vdr-bulk-action-menu", inputs: ["locationId", "selectionManager", "hostComponent"] }, { kind: "component", type: i1.DataTable2Component, selector: "vdr-data-table-2", inputs: ["id", "items", "itemsPerPage", "currentPage", "totalItems", "emptyStateLabel", "filters", "activeIndex", "trackByPath"], outputs: ["pageChange", "itemsPerPageChange", "visibleColumnsChange"] }, { kind: "component", type: i1.DataTable2ColumnComponent, selector: "vdr-dt2-column", inputs: ["id", "expand", "heading", "align", "sort", "optional", "hiddenByDefault", "orderable"], exportAs: ["row"] }, { kind: "component", type: i1.DataTable2SearchComponent, selector: "vdr-dt2-search", inputs: ["searchTermControl", "searchTermPlaceholder"] }, { kind: "component", type: i1.DataTableCustomFieldColumnComponent, selector: "vdr-dt2-custom-field-column", inputs: ["customField", "sorts"], exportAs: ["row"] }, { kind: "component", type: i1.PageBlockComponent, selector: "vdr-page-block" }, { kind: "pipe", type: i3$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i5.TranslatePipe, name: "translate" }, { kind: "pipe", type: i1.AssetPreviewPipe, name: "assetPreview" }, { kind: "pipe", type: i1.LocaleDatePipe, name: "localeDate" }] }); }
4059
4059
  }
4060
4060
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: ProductListComponent, decorators: [{
4061
4061
  type: Component,
4062
- args: [{ selector: 'vdr-products-list', standalone: false, template: "<vdr-page-block>\n <vdr-action-bar>\n <vdr-ab-left>\n <vdr-language-selector\n [availableLanguageCodes]=\"availableLanguages$ | async\"\n [currentLanguageCode]=\"contentLanguage$ | async\"\n (languageCodeChange)=\"setLanguage($event)\"\n ></vdr-language-selector>\n </vdr-ab-left>\n <vdr-ab-right>\n <vdr-action-bar-items [locationId]=\"pageLocationId\"></vdr-action-bar-items>\n <a\n class=\"button primary mr-1\"\n [routerLink]=\"['./create']\"\n *vdrIfPermissions=\"['CreateCatalog', 'CreateProduct']\"\n >\n <clr-icon shape=\"plus\"></clr-icon>\n {{ 'catalog.create-new-product' | translate }}\n </a>\n <vdr-action-bar-dropdown-menu [alwaysShow]=\"true\" [locationId]=\"pageLocationId\">\n <button type=\"button\" vdrDropdownItem (click)=\"rebuildSearchIndex()\">\n <clr-icon shape=\"refresh\" class=\"\"></clr-icon>\n {{ 'catalog.rebuild-search-index' | translate }}\n </button>\n </vdr-action-bar-dropdown-menu>\n </vdr-ab-right>\n </vdr-action-bar>\n</vdr-page-block>\n<vdr-data-table-2\n class=\"mt-2\"\n [id]=\"dataTableListId\"\n [items]=\"items$ | async\"\n [itemsPerPage]=\"itemsPerPage$ | async\"\n [totalItems]=\"totalItems$ | async\"\n [currentPage]=\"currentPage$ | async\"\n [filters]=\"filters\"\n (pageChange)=\"setPageNumber($event)\"\n (itemsPerPageChange)=\"setItemsPerPage($event)\"\n (visibleColumnsChange)=\"setVisibleColumns($event)\"\n>\n <vdr-bulk-action-menu\n [locationId]=\"dataTableListId\"\n [hostComponent]=\"this\"\n [selectionManager]=\"selectionManager\"\n ></vdr-bulk-action-menu>\n <vdr-dt2-search\n [searchTermControl]=\"searchTermControl\"\n [searchTermPlaceholder]=\"'settings.search-by-product-name-or-sku' | translate\"\n />\n <vdr-dt2-column [heading]=\"'common.id' | translate\" id=\"id\" [hiddenByDefault]=\"true\" [sort]=\"sorts.get('id')\">\n <ng-template let-product=\"item\">\n {{ product.id }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.created-at' | translate\" id=\"created-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('createdAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.createdAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.updated-at' | translate\" id=\"updated-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('updatedAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.updatedAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.image' | translate\" id=\"image\">\n <ng-template let-product=\"item\">\n <div class=\"image-placeholder\">\n <img\n *ngIf=\"product.featuredAsset as asset; else imagePlaceholder\"\n [src]=\"asset | assetPreview : 'tiny'\"\n />\n <ng-template #imagePlaceholder>\n <div class=\"placeholder\">\n <clr-icon shape=\"image\" size=\"48\"></clr-icon>\n </div>\n </ng-template>\n </div>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.name' | translate\" id=\"name\" [optional]=\"false\" [sort]=\"sorts.get('name')\">\n <ng-template let-product=\"item\">\n <a class=\"button-ghost\" [routerLink]=\"['./', product.id]\"\n ><span>{{ product.name }}</span\n ><clr-icon shape=\"arrow right\"\n /></a>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.slug' | translate\" id=\"slug\" [sort]=\"sorts.get('slug')\">\n <ng-template let-product=\"item\">\n {{ product.slug }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.enabled' | translate\" id=\"enabled\">\n <ng-template let-product=\"item\">\n <vdr-chip *ngIf=\"product.enabled\" colorType=\"success\">{{\n 'common.enabled' | translate\n }}</vdr-chip>\n <vdr-chip *ngIf=\"!product.enabled\" colorType=\"warning\">{{\n 'common.disabled' | translate\n }}</vdr-chip>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.number-of-variants' | translate\" id=\"number-of-variants\">\n <ng-template let-product=\"item\">\n {{ 'catalog.variant-count' | translate : { count: product.variantList?.totalItems } }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-custom-field-column\n *ngFor=\"let customField of customFields\"\n [customField]=\"customField\"\n [sorts]=\"sorts\"\n />\n</vdr-data-table-2>\n", styles: [".image-col{width:70px}.image-placeholder{width:50px;height:50px;margin-top:calc(var(--space-unit) * -1);margin-bottom:calc(var(--space-unit) * -1);background-color:var(--color-component-bg-200)}.image-placeholder img{border-radius:var(--border-radius-img)}.image-placeholder .placeholder{text-align:center;color:var(--color-grey-300)}.search-form{display:flex;align-items:center;width:100%}vdr-product-search-input{min-width:300px}@media screen and (max-width: 768px){vdr-product-search-input{min-width:100px}}.search-settings-menu{margin:0 12px}td.disabled{background-color:var(--color-component-bg-200)}.search-index-button{position:relative}.search-index-button vdr-status-badge{right:0;top:0}.run-updates-button{position:relative}.run-updates-button vdr-status-badge{left:10px;top:10px}.edit-button{margin-inline-end:24px}.sku{color:var(--color-text-300)}\n"] }]
4062
+ args: [{ selector: 'vdr-products-list', standalone: false, template: "<vdr-page-block>\n <vdr-action-bar>\n <vdr-ab-left>\n <vdr-language-selector\n [availableLanguageCodes]=\"availableLanguages$ | async\"\n [currentLanguageCode]=\"contentLanguage$ | async\"\n (languageCodeChange)=\"setLanguage($event)\"\n ></vdr-language-selector>\n </vdr-ab-left>\n <vdr-ab-right>\n <vdr-action-bar-items [locationId]=\"pageLocationId\"></vdr-action-bar-items>\n <a\n class=\"btn btn-primary mr-1\"\n [routerLink]=\"['./create']\"\n *vdrIfPermissions=\"['CreateCatalog', 'CreateProduct']\"\n >\n <clr-icon shape=\"plus\"></clr-icon>\n {{ 'catalog.create-new-product' | translate }}\n </a>\n <vdr-action-bar-dropdown-menu [alwaysShow]=\"true\" [locationId]=\"pageLocationId\">\n <button type=\"button\" vdrDropdownItem (click)=\"rebuildSearchIndex()\">\n <clr-icon shape=\"refresh\" class=\"\"></clr-icon>\n {{ 'catalog.rebuild-search-index' | translate }}\n </button>\n </vdr-action-bar-dropdown-menu>\n </vdr-ab-right>\n </vdr-action-bar>\n</vdr-page-block>\n<vdr-data-table-2\n class=\"mt-2\"\n [id]=\"dataTableListId\"\n [items]=\"items$ | async\"\n [itemsPerPage]=\"itemsPerPage$ | async\"\n [totalItems]=\"totalItems$ | async\"\n [currentPage]=\"currentPage$ | async\"\n [filters]=\"filters\"\n (pageChange)=\"setPageNumber($event)\"\n (itemsPerPageChange)=\"setItemsPerPage($event)\"\n (visibleColumnsChange)=\"setVisibleColumns($event)\"\n>\n <vdr-bulk-action-menu\n [locationId]=\"dataTableListId\"\n [hostComponent]=\"this\"\n [selectionManager]=\"selectionManager\"\n ></vdr-bulk-action-menu>\n <vdr-dt2-search\n [searchTermControl]=\"searchTermControl\"\n [searchTermPlaceholder]=\"'settings.search-by-product-name-or-sku' | translate\"\n />\n <vdr-dt2-column [heading]=\"'common.id' | translate\" id=\"id\" [hiddenByDefault]=\"true\" [sort]=\"sorts.get('id')\">\n <ng-template let-product=\"item\">\n {{ product.id }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.created-at' | translate\" id=\"created-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('createdAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.createdAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column\n [heading]=\"'common.updated-at' | translate\" id=\"updated-at\"\n [hiddenByDefault]=\"true\"\n [sort]=\"sorts.get('updatedAt')\"\n >\n <ng-template let-product=\"item\">\n {{ product.updatedAt | localeDate : 'short' }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.image' | translate\" id=\"image\">\n <ng-template let-product=\"item\">\n <div class=\"image-placeholder\">\n <img\n *ngIf=\"product.featuredAsset as asset; else imagePlaceholder\"\n [src]=\"asset | assetPreview : 'tiny'\"\n />\n <ng-template #imagePlaceholder>\n <div class=\"placeholder\">\n <clr-icon shape=\"image\" size=\"48\"></clr-icon>\n </div>\n </ng-template>\n </div>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.name' | translate\" id=\"name\" [optional]=\"false\" [sort]=\"sorts.get('name')\">\n <ng-template let-product=\"item\">\n <a class=\"button-ghost\" [routerLink]=\"['./', product.id]\"\n ><span>{{ product.name }}</span\n ><clr-icon shape=\"arrow right\"\n /></a>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.slug' | translate\" id=\"slug\" [sort]=\"sorts.get('slug')\">\n <ng-template let-product=\"item\">\n {{ product.slug }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'common.enabled' | translate\" id=\"enabled\">\n <ng-template let-product=\"item\">\n <vdr-chip *ngIf=\"product.enabled\" colorType=\"success\">{{\n 'common.enabled' | translate\n }}</vdr-chip>\n <vdr-chip *ngIf=\"!product.enabled\" colorType=\"warning\">{{\n 'common.disabled' | translate\n }}</vdr-chip>\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-column [heading]=\"'catalog.number-of-variants' | translate\" id=\"number-of-variants\">\n <ng-template let-product=\"item\">\n {{ 'catalog.variant-count' | translate : { count: product.variantList?.totalItems } }}\n </ng-template>\n </vdr-dt2-column>\n <vdr-dt2-custom-field-column\n *ngFor=\"let customField of customFields\"\n [customField]=\"customField\"\n [sorts]=\"sorts\"\n />\n</vdr-data-table-2>\n", styles: [".image-col{width:70px}.image-placeholder{width:50px;height:50px;margin-top:calc(var(--space-unit) * -1);margin-bottom:calc(var(--space-unit) * -1);background-color:var(--color-component-bg-200)}.image-placeholder img{border-radius:var(--border-radius-img)}.image-placeholder .placeholder{text-align:center;color:var(--color-grey-300)}.search-form{display:flex;align-items:center;width:100%}vdr-product-search-input{min-width:300px}@media screen and (max-width: 768px){vdr-product-search-input{min-width:100px}}.search-settings-menu{margin:0 12px}td.disabled{background-color:var(--color-component-bg-200)}.search-index-button{position:relative}.search-index-button vdr-status-badge{right:0;top:0}.run-updates-button{position:relative}.run-updates-button vdr-status-badge{left:10px;top:10px}.edit-button{margin-inline-end:24px}.sku{color:var(--color-text-300)}\n"] }]
4063
4063
  }], ctorParameters: () => [{ type: i1.DataService }, { type: i1.ModalService }, { type: i1.NotificationService }, { type: i1.JobQueueService }] });
4064
4064
 
4065
4065
  class VariantPriceDetailComponent {