@searchspring/snap-store-mobx 0.51.2 → 0.52.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.
Files changed (69) hide show
  1. package/dist/cjs/Autocomplete/AutocompleteStore.js +1 -2
  2. package/dist/cjs/Cart/CartStore.d.ts +15 -0
  3. package/dist/cjs/Cart/CartStore.d.ts.map +1 -0
  4. package/dist/cjs/Cart/CartStore.js +104 -0
  5. package/dist/cjs/Finder/FinderStore.js +1 -2
  6. package/dist/cjs/Finder/Stores/FinderSelectionStore.d.ts +4 -4
  7. package/dist/cjs/Finder/Stores/FinderSelectionStore.d.ts.map +1 -1
  8. package/dist/cjs/Finder/Stores/FinderSelectionStore.js +1 -2
  9. package/dist/cjs/Recommendation/RecommendationStore.d.ts +4 -2
  10. package/dist/cjs/Recommendation/RecommendationStore.d.ts.map +1 -1
  11. package/dist/cjs/Recommendation/RecommendationStore.js +6 -2
  12. package/dist/cjs/Recommendation/Stores/RecommendationProfileStore.d.ts +1 -0
  13. package/dist/cjs/Recommendation/Stores/RecommendationProfileStore.d.ts.map +1 -1
  14. package/dist/cjs/Recommendation/Stores/RecommendationProfileStore.js +3 -0
  15. package/dist/cjs/Search/SearchStore.js +1 -2
  16. package/dist/cjs/Search/Stores/SearchFacetStore.js +4 -4
  17. package/dist/cjs/Search/Stores/SearchHistoryStore.d.ts +1 -1
  18. package/dist/cjs/Search/Stores/SearchHistoryStore.d.ts.map +1 -1
  19. package/dist/cjs/Search/Stores/SearchMerchandisingStore.d.ts +1 -1
  20. package/dist/cjs/Search/Stores/SearchMerchandisingStore.d.ts.map +1 -1
  21. package/dist/cjs/Search/Stores/SearchMerchandisingStore.js +1 -1
  22. package/dist/cjs/Search/Stores/SearchResultStore.d.ts +54 -2
  23. package/dist/cjs/Search/Stores/SearchResultStore.d.ts.map +1 -1
  24. package/dist/cjs/Search/Stores/SearchResultStore.js +240 -5
  25. package/dist/cjs/Search/Stores/SearchSortingStore.d.ts +1 -1
  26. package/dist/cjs/Search/Stores/SearchSortingStore.d.ts.map +1 -1
  27. package/dist/cjs/Search/Stores/index.d.ts +1 -1
  28. package/dist/cjs/Search/Stores/index.d.ts.map +1 -1
  29. package/dist/cjs/Search/Stores/index.js +2 -1
  30. package/dist/cjs/Storage/StorageStore.d.ts +1 -1
  31. package/dist/cjs/Storage/StorageStore.d.ts.map +1 -1
  32. package/dist/cjs/Storage/StorageStore.js +1 -1
  33. package/dist/cjs/index.d.ts +1 -0
  34. package/dist/cjs/index.d.ts.map +1 -1
  35. package/dist/cjs/index.js +3 -1
  36. package/dist/cjs/types.d.ts +23 -12
  37. package/dist/cjs/types.d.ts.map +1 -1
  38. package/dist/cjs/types.js +1 -1
  39. package/dist/esm/Cart/CartStore.d.ts +15 -0
  40. package/dist/esm/Cart/CartStore.d.ts.map +1 -0
  41. package/dist/esm/Cart/CartStore.js +69 -0
  42. package/dist/esm/Finder/Stores/FinderSelectionStore.d.ts +4 -4
  43. package/dist/esm/Finder/Stores/FinderSelectionStore.d.ts.map +1 -1
  44. package/dist/esm/Recommendation/RecommendationStore.d.ts +4 -2
  45. package/dist/esm/Recommendation/RecommendationStore.d.ts.map +1 -1
  46. package/dist/esm/Recommendation/RecommendationStore.js +5 -0
  47. package/dist/esm/Recommendation/Stores/RecommendationProfileStore.d.ts +1 -0
  48. package/dist/esm/Recommendation/Stores/RecommendationProfileStore.d.ts.map +1 -1
  49. package/dist/esm/Recommendation/Stores/RecommendationProfileStore.js +3 -0
  50. package/dist/esm/Search/Stores/SearchHistoryStore.d.ts +1 -1
  51. package/dist/esm/Search/Stores/SearchHistoryStore.d.ts.map +1 -1
  52. package/dist/esm/Search/Stores/SearchMerchandisingStore.d.ts +1 -1
  53. package/dist/esm/Search/Stores/SearchMerchandisingStore.d.ts.map +1 -1
  54. package/dist/esm/Search/Stores/SearchResultStore.d.ts +54 -2
  55. package/dist/esm/Search/Stores/SearchResultStore.d.ts.map +1 -1
  56. package/dist/esm/Search/Stores/SearchResultStore.js +207 -2
  57. package/dist/esm/Search/Stores/SearchSortingStore.d.ts +1 -1
  58. package/dist/esm/Search/Stores/SearchSortingStore.d.ts.map +1 -1
  59. package/dist/esm/Search/Stores/index.d.ts +1 -1
  60. package/dist/esm/Search/Stores/index.d.ts.map +1 -1
  61. package/dist/esm/Search/Stores/index.js +1 -1
  62. package/dist/esm/Storage/StorageStore.d.ts +1 -1
  63. package/dist/esm/Storage/StorageStore.d.ts.map +1 -1
  64. package/dist/esm/index.d.ts +1 -0
  65. package/dist/esm/index.d.ts.map +1 -1
  66. package/dist/esm/index.js +1 -0
  67. package/dist/esm/types.d.ts +23 -12
  68. package/dist/esm/types.d.ts.map +1 -1
  69. package/package.json +6 -6
@@ -24,9 +24,8 @@ var Stores_2 = require("./Stores");
24
24
  var AutocompleteStore = /** @class */ (function (_super) {
25
25
  __extends(AutocompleteStore, _super);
26
26
  function AutocompleteStore(config, services) {
27
- var _this = this;
28
27
  var _a;
29
- _this = _super.call(this, config) || this;
28
+ var _this = _super.call(this, config) || this;
30
29
  if (typeof services != 'object' || typeof ((_a = services.urlManager) === null || _a === void 0 ? void 0 : _a.subscribe) != 'function') {
31
30
  throw new Error("Invalid service 'urlManager' passed to AutocompleteStore. Missing \"subscribe\" function.");
32
31
  }
@@ -0,0 +1,15 @@
1
+ import type { Middleware } from '@searchspring/snap-event-manager';
2
+ import type { Product } from '../Search/Stores';
3
+ export declare class CartStore {
4
+ items: Product[];
5
+ private eventManager;
6
+ constructor();
7
+ on<T>(event: string, ...func: Middleware<T>[]): void;
8
+ get count(): number;
9
+ get price(): number;
10
+ get msrp(): number;
11
+ addItems(items: Product[]): void;
12
+ removeItems(items: Product[]): void;
13
+ reset(): void;
14
+ }
15
+ //# sourceMappingURL=CartStore.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CartStore.d.ts","sourceRoot":"","sources":["../../../src/Cart/CartStore.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AACnE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAEhD,qBAAa,SAAS;IACd,KAAK,EAAE,OAAO,EAAE,CAAM;IAC7B,OAAO,CAAC,YAAY,CAAC;;IAYd,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,UAAU,CAAC,CAAC,CAAC,EAAE,GAAG,IAAI;IAI3D,IAAI,KAAK,IAAI,MAAM,CAMlB;IAED,IAAI,KAAK,IAAI,MAAM,CAMlB;IAED,IAAI,IAAI,IAAI,MAAM,CAMjB;IAEM,QAAQ,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,IAAI;IAahC,WAAW,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,IAAI;IAsBnC,KAAK,IAAI,IAAI;CAIpB"}
@@ -0,0 +1,104 @@
1
+ "use strict";
2
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
3
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
4
+ if (ar || !(i in from)) {
5
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
6
+ ar[i] = from[i];
7
+ }
8
+ }
9
+ return to.concat(ar || Array.prototype.slice.call(from));
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.CartStore = void 0;
13
+ var mobx_1 = require("mobx");
14
+ var snap_event_manager_1 = require("@searchspring/snap-event-manager");
15
+ var CartStore = /** @class */ (function () {
16
+ function CartStore() {
17
+ this.items = [];
18
+ (0, mobx_1.makeObservable)(this, {
19
+ items: mobx_1.observable,
20
+ price: mobx_1.computed,
21
+ count: mobx_1.computed,
22
+ msrp: mobx_1.computed,
23
+ });
24
+ this.eventManager = new snap_event_manager_1.EventManager();
25
+ }
26
+ CartStore.prototype.on = function (event) {
27
+ var _a;
28
+ var func = [];
29
+ for (var _i = 1; _i < arguments.length; _i++) {
30
+ func[_i - 1] = arguments[_i];
31
+ }
32
+ (_a = this.eventManager).on.apply(_a, __spreadArray([event], func, false));
33
+ };
34
+ Object.defineProperty(CartStore.prototype, "count", {
35
+ get: function () {
36
+ var count = 0;
37
+ this.items.forEach(function (item) {
38
+ count += item.quantity;
39
+ });
40
+ return count;
41
+ },
42
+ enumerable: false,
43
+ configurable: true
44
+ });
45
+ Object.defineProperty(CartStore.prototype, "price", {
46
+ get: function () {
47
+ var price = 0;
48
+ this.items.forEach(function (item) {
49
+ var _a;
50
+ price += (((_a = item.display.mappings.core) === null || _a === void 0 ? void 0 : _a.price) || 0) * item.quantity;
51
+ });
52
+ return price;
53
+ },
54
+ enumerable: false,
55
+ configurable: true
56
+ });
57
+ Object.defineProperty(CartStore.prototype, "msrp", {
58
+ get: function () {
59
+ var price = 0;
60
+ this.items.forEach(function (item) {
61
+ var _a, _b;
62
+ price += (((_a = item.display.mappings.core) === null || _a === void 0 ? void 0 : _a.msrp) || ((_b = item.display.mappings.core) === null || _b === void 0 ? void 0 : _b.price) || 0) * item.quantity;
63
+ });
64
+ return price;
65
+ },
66
+ enumerable: false,
67
+ configurable: true
68
+ });
69
+ CartStore.prototype.addItems = function (items) {
70
+ var _this = this;
71
+ items.forEach(function (item) {
72
+ var idx = _this.items.findIndex(function (result) { return result.id == item.id; });
73
+ //is it in the items list?
74
+ if (idx == -1) {
75
+ _this.items.push(item);
76
+ }
77
+ });
78
+ this.eventManager.fire('addItems', { cart: this, items: items });
79
+ };
80
+ CartStore.prototype.removeItems = function (items) {
81
+ var _this = this;
82
+ var newIds = __spreadArray([], this.items, true);
83
+ items.forEach(function (item) {
84
+ var idx = newIds.findIndex(function (result) { return result.id == item.id; });
85
+ //is it in the selected items?
86
+ if (idx > -1) {
87
+ // remove it entirely
88
+ newIds.splice(idx, 1);
89
+ // when emptied fire empty event
90
+ if (newIds.length == 0) {
91
+ _this.eventManager.fire('emptied', { cart: _this });
92
+ }
93
+ }
94
+ });
95
+ this.items = newIds;
96
+ this.eventManager.fire('removeItems', { cart: this, items: items });
97
+ };
98
+ CartStore.prototype.reset = function () {
99
+ this.items = [];
100
+ this.eventManager.fire('reset', { cart: this });
101
+ };
102
+ return CartStore;
103
+ }());
104
+ exports.CartStore = CartStore;
@@ -35,9 +35,8 @@ var Stores_2 = require("./Stores");
35
35
  var FinderStore = /** @class */ (function (_super) {
36
36
  __extends(FinderStore, _super);
37
37
  function FinderStore(config, services) {
38
- var _this = this;
39
38
  var _a, _b;
40
- _this = _super.call(this, config) || this;
39
+ var _this = _super.call(this, config) || this;
41
40
  _this.meta = {};
42
41
  _this.state = {
43
42
  persisted: false,
@@ -1,7 +1,7 @@
1
1
  import type { FinderStoreConfig, FinderFieldConfig, StoreServices, SelectedSelection, FinderStoreState } from '../../types';
2
2
  import type { StorageStore } from '../../Storage/StorageStore';
3
3
  import type { MetaResponseModel, MetaResponseModelFacetGrid, MetaResponseModelFacetHierarchy, MetaResponseModelFacetList, MetaResponseModelFacetPalette, MetaResponseModelFacetSlider, SearchResponseModelFacet, SearchResponseModelFacetRange, SearchResponseModelFacetRangeBuckets, SearchResponseModelFacetValue, SearchResponseModelFacetValueAllOfValues } from '@searchspring/snapi-types';
4
- export declare type FinderSelectionStoreData = {
4
+ export type FinderSelectionStoreData = {
5
5
  state: FinderStoreState;
6
6
  facets: SearchResponseModelFacet[];
7
7
  meta: MetaResponseModel;
@@ -9,7 +9,7 @@ export declare type FinderSelectionStoreData = {
9
9
  storage: StorageStore;
10
10
  selections: SelectedSelection[];
11
11
  };
12
- declare type FacetWithMeta = MetaResponseModelFacetGrid & MetaResponseModelFacetHierarchy & MetaResponseModelFacetList & MetaResponseModelFacetPalette & MetaResponseModelFacetSlider & SearchResponseModelFacetValue & SearchResponseModelFacetRange & SearchResponseModelFacetRangeBuckets;
12
+ type FacetWithMeta = MetaResponseModelFacetGrid & MetaResponseModelFacetHierarchy & MetaResponseModelFacetList & MetaResponseModelFacetPalette & MetaResponseModelFacetSlider & SearchResponseModelFacetValue & SearchResponseModelFacetRange & SearchResponseModelFacetRangeBuckets;
13
13
  export declare class FinderSelectionStore extends Array<Selection | SelectionHierarchy> {
14
14
  static get [Symbol.species](): ArrayConstructor;
15
15
  constructor(config: FinderStoreConfig, services: StoreServices, { state, facets, meta, loading, storage, selections }: FinderSelectionStoreData);
@@ -34,7 +34,7 @@ declare class SelectionBase {
34
34
  data?: SearchResponseModelFacetValueAllOfValues[];
35
35
  storage: {
36
36
  key: string;
37
- get: (key?: string | undefined) => any;
37
+ get: (key?: string) => any;
38
38
  set: (key: string, value: unknown) => void;
39
39
  };
40
40
  constructor(services: StoreServices, id: string, state: FinderStoreState, facet: FacetWithMeta, selectionConfig: FinderFieldConfig | LevelConfig, loading: boolean, storageStore: StorageStore);
@@ -51,7 +51,7 @@ declare class SelectionHierarchy extends SelectionBase {
51
51
  constructor(services: StoreServices, id: string, state: FinderStoreState, facet: FacetWithMeta, config: LevelConfig, loading: boolean, storageStore: StorageStore);
52
52
  select(value?: string): void;
53
53
  }
54
- declare type LevelConfig = {
54
+ type LevelConfig = {
55
55
  index: number;
56
56
  label?: string;
57
57
  key: string;
@@ -1 +1 @@
1
- {"version":3,"file":"FinderSelectionStore.d.ts","sourceRoot":"","sources":["../../../../src/Finder/Stores/FinderSelectionStore.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,aAAa,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC5H,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC/D,OAAO,KAAK,EACX,iBAAiB,EACjB,0BAA0B,EAC1B,+BAA+B,EAC/B,0BAA0B,EAC1B,6BAA6B,EAC7B,4BAA4B,EAC5B,wBAAwB,EACxB,6BAA6B,EAC7B,oCAAoC,EACpC,6BAA6B,EAC7B,wCAAwC,EACxC,MAAM,2BAA2B,CAAC;AAEnC,oBAAY,wBAAwB,GAAG;IACtC,KAAK,EAAE,gBAAgB,C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AAC;IACxC,IAAI,CAAC,EAAE,wCAAwC,EAAE,CAAC;IAClD,OAAO;;oBA8BS,MAAM;mBAIP,MAAM,SAAS,OAAO;MAlC7B;gBAGd,QAAQ,EAAE,aAAa,EACvB,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,gBAAgB,EACvB,KAAK,EAAE,aAAa,EACpB,eAAe,EAAE,iBAAiB,GAAG,WAAW,EAChD,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,YAAY;IAgC3B,IAAW,MAAM,+CAUhB;CACD;AAED,cAAM,SAAU,SAAQ,aAAa;IAC7B,MAAM,EAAG,iBAAiB,CAAC;gBAGjC,QAAQ,EAAE,aAAa,EACvB,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,gBAAgB,EACvB,KAAK,EAAE,aAAa,EACpB,MAAM,EAAE,iBAAiB,EACzB,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,YAAY;IAepB,MAAM,CAAC,KAAK,SAAK;CAaxB;AAED,cAAM,kBAAmB,SAAQ,aAAa;IACtC,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAG,WAAW,CAAC;gBAG3B,QAAQ,EAAE,aAAa,EACvB,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,gBAAgB,EACvB,KAAK,EAAE,aAAa,EACpB,MAAM,EAAE,WAAW,EACnB,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,YAAY;IAsCpB,MAAM,CAAC,KAAK,SAAK;CA6BxB;AAED,KAAK,WAAW,GAAG;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,GAAG,EAAE,MAAM,CAAC;CACZ,CAAC"}
@@ -210,9 +210,8 @@ var Selection = /** @class */ (function (_super) {
210
210
  var SelectionHierarchy = /** @class */ (function (_super) {
211
211
  __extends(SelectionHierarchy, _super);
212
212
  function SelectionHierarchy(services, id, state, facet, config, loading, storageStore) {
213
- var _this = this;
214
213
  var _a, _b, _c;
215
- _this = _super.call(this, services, id, state, facet, config, loading, storageStore) || this;
214
+ var _this = _super.call(this, services, id, state, facet, config, loading, storageStore) || this;
216
215
  // inherit additional facet properties
217
216
  _this.hierarchyDelimiter = facet.hierarchyDelimiter;
218
217
  var storageData = _this.storage.get();
@@ -1,5 +1,6 @@
1
1
  import { AbstractStore } from '../Abstract/AbstractStore';
2
- import { SearchResultStore } from '../Search/Stores';
2
+ import { Product } from '../Search/Stores';
3
+ import { CartStore } from '../Cart/CartStore';
3
4
  import { RecommendationProfileStore } from './Stores';
4
5
  import type { RecommendationStoreConfig, StoreServices } from '../types';
5
6
  import type { RecommendCombinedResponseModel } from '@searchspring/snap-client';
@@ -7,7 +8,8 @@ export declare class RecommendationStore extends AbstractStore {
7
8
  services: StoreServices;
8
9
  loaded: boolean;
9
10
  profile: RecommendationProfileStore;
10
- results: SearchResultStore;
11
+ results: Product[];
12
+ cart: CartStore;
11
13
  constructor(config: RecommendationStoreConfig, services: StoreServices);
12
14
  reset(): void;
13
15
  update(data?: RecommendCombinedResponseModel): void;
@@ -1 +1 @@
1
- {"version":3,"file":"RecommendationStore.d.ts","sourceRoot":"","sources":["../../../src/Recommendation/RecommendationStore.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAC1D,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAC;AACtD,OAAO,KAAK,EAAE,yBAAyB,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzE,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,2BAA2B,CAAC;AAEhF,qBAAa,mBAAoB,SAAQ,aAAa;IAC9C,QAAQ,EAAE,aAAa,CAAC;IACxB,MAAM,UAAS;IACf,OAAO,EAAG,0BAA0B,CAAC;IACrC,OAAO,EAAG,iBAAiB,CAAC;gBAEvB,MAAM,EAAE,yBAAyB,EAAE,QAAQ,EAAE,aAAa;IAiB/D,KAAK,IAAI,IAAI;IAIb,MAAM,CAAC,IAAI,CAAC,EAAE,8BAA8B,GAAG,IAAI;CAM1D"}
1
+ {"version":3,"file":"RecommendationStore.d.ts","sourceRoot":"","sources":["../../../src/Recommendation/RecommendationStore.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAC1D,OAAO,EAAE,OAAO,EAAqB,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAC;AACtD,OAAO,KAAK,EAAE,yBAAyB,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzE,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,2BAA2B,CAAC;AAEhF,qBAAa,mBAAoB,SAAQ,aAAa;IAC9C,QAAQ,EAAE,aAAa,CAAC;IACxB,MAAM,UAAS;IACf,OAAO,EAAG,0BAA0B,CAAC;IACrC,OAAO,EAAG,OAAO,EAAE,CAAC;IACpB,IAAI,EAAG,SAAS,CAAC;gBAEZ,MAAM,EAAE,yBAAyB,EAAE,QAAQ,EAAE,aAAa;IAiB/D,KAAK,IAAI,IAAI;IAIb,MAAM,CAAC,IAAI,CAAC,EAAE,8BAA8B,GAAG,IAAI;CAW1D"}
@@ -19,13 +19,13 @@ exports.RecommendationStore = void 0;
19
19
  var mobx_1 = require("mobx");
20
20
  var AbstractStore_1 = require("../Abstract/AbstractStore");
21
21
  var Stores_1 = require("../Search/Stores");
22
+ var CartStore_1 = require("../Cart/CartStore");
22
23
  var Stores_2 = require("./Stores");
23
24
  var RecommendationStore = /** @class */ (function (_super) {
24
25
  __extends(RecommendationStore, _super);
25
26
  function RecommendationStore(config, services) {
26
- var _this = this;
27
27
  var _a;
28
- _this = _super.call(this, config) || this;
28
+ var _this = _super.call(this, config) || this;
29
29
  _this.loaded = false;
30
30
  if (typeof services != 'object' || typeof ((_a = services.urlManager) === null || _a === void 0 ? void 0 : _a.subscribe) != 'function') {
31
31
  throw new Error("Invalid service 'urlManager' passed to AutocompleteStore. Missing \"subscribe\" function.");
@@ -46,6 +46,10 @@ var RecommendationStore = /** @class */ (function (_super) {
46
46
  this.loaded = !!(data === null || data === void 0 ? void 0 : data.profile);
47
47
  this.profile = new Stores_2.RecommendationProfileStore(this.services, data);
48
48
  this.results = new Stores_1.SearchResultStore(this.config, this.services, data === null || data === void 0 ? void 0 : data.results);
49
+ // only create a cart store when type is bundle
50
+ if (this.profile.type == 'bundle') {
51
+ this.cart = new CartStore_1.CartStore();
52
+ }
49
53
  };
50
54
  return RecommendationStore;
51
55
  }(AbstractStore_1.AbstractStore));
@@ -4,6 +4,7 @@ export declare class RecommendationProfileStore {
4
4
  tag: string;
5
5
  placement: string;
6
6
  display: Record<string, any>;
7
+ type?: string | undefined;
7
8
  constructor(services: StoreServices, data?: RecommendCombinedResponseModel);
8
9
  }
9
10
  //# sourceMappingURL=RecommendationProfileStore.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RecommendationProfileStore.d.ts","sourceRoot":"","sources":["../../../../src/Recommendation/Stores/RecommendationProfileStore.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,2BAA2B,CAAC;AAEhF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAEjD,qBAAa,0BAA0B;IAC/B,GAAG,EAAG,MAAM,CAAC;IACb,SAAS,EAAG,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAM;gBAE7B,QAAQ,EAAE,aAAa,EAAE,IAAI,CAAC,EAAE,8BAA8B;CAe1E"}
1
+ {"version":3,"file":"RecommendationProfileStore.d.ts","sourceRoot":"","sources":["../../../../src/Recommendation/Stores/RecommendationProfileStore.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,2BAA2B,CAAC;AAEhF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAEjD,qBAAa,0BAA0B;IAC/B,GAAG,EAAG,MAAM,CAAC;IACb,SAAS,EAAG,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAM;IAClC,IAAI,CAAC,qBAAa;gBAEb,QAAQ,EAAE,aAAa,EAAE,IAAI,CAAC,EAAE,8BAA8B;CAiB1E"}
@@ -6,16 +6,19 @@ var RecommendationProfileStore = /** @class */ (function () {
6
6
  function RecommendationProfileStore(services, data) {
7
7
  var _a;
8
8
  this.display = {};
9
+ this.type = 'default';
9
10
  if (!((_a = data === null || data === void 0 ? void 0 : data.profile) === null || _a === void 0 ? void 0 : _a.tag)) {
10
11
  return;
11
12
  }
12
13
  this.tag = data.profile.tag;
13
14
  this.placement = data.profile.placement;
14
15
  this.display = data.profile.display;
16
+ this.type = data.profile.display.template.type;
15
17
  (0, mobx_1.makeObservable)(this, {
16
18
  tag: mobx_1.observable,
17
19
  placement: mobx_1.observable,
18
20
  display: mobx_1.observable,
21
+ type: mobx_1.observable,
19
22
  });
20
23
  }
21
24
  return RecommendationProfileStore;
@@ -23,9 +23,8 @@ var StorageStore_1 = require("../Storage/StorageStore");
23
23
  var SearchStore = /** @class */ (function (_super) {
24
24
  __extends(SearchStore, _super);
25
25
  function SearchStore(config, services) {
26
- var _this = this;
27
26
  var _a, _b, _c, _d, _e, _f, _g;
28
- _this = _super.call(this, config) || this;
27
+ var _this = _super.call(this, config) || this;
29
28
  if (typeof services != 'object' || typeof ((_a = services.urlManager) === null || _a === void 0 ? void 0 : _a.subscribe) != 'function') {
30
29
  throw new Error("Invalid service 'urlManager' passed to SearchStore. Missing \"subscribe\" function.");
31
30
  }
@@ -84,6 +84,8 @@ var SearchFacetStore = /** @class */ (function (_super) {
84
84
  return new ValueFacet(services, storage, facet, facetMeta || {}, facetConfig);
85
85
  }
86
86
  });
87
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
88
+ // @ts-ignore
87
89
  return _super.apply(this, facets) || this;
88
90
  }
89
91
  Object.defineProperty(SearchFacetStore, Symbol.species, {
@@ -142,9 +144,8 @@ exports.Facet = Facet;
142
144
  var RangeFacet = /** @class */ (function (_super) {
143
145
  __extends(RangeFacet, _super);
144
146
  function RangeFacet(services, storage, facet, facetMeta, config) {
145
- var _this = this;
146
147
  var _a, _b;
147
- _this = _super.call(this, services, storage, facet, facetMeta, config) || this;
148
+ var _this = _super.call(this, services, storage, facet, facetMeta, config) || this;
148
149
  _this.range = {
149
150
  low: 0,
150
151
  high: 0,
@@ -320,9 +321,8 @@ exports.FacetValue = FacetValue;
320
321
  var FacetHierarchyValue = /** @class */ (function (_super) {
321
322
  __extends(FacetHierarchyValue, _super);
322
323
  function FacetHierarchyValue(services, facet, value, filteredValues) {
323
- var _this = this;
324
324
  var _a;
325
- _this = _super.call(this, services, facet, value) || this;
325
+ var _this = _super.call(this, services, facet, value) || this;
326
326
  _this.level = 0;
327
327
  _this.history = false;
328
328
  if (value.value && facet.hierarchyDelimiter) {
@@ -1,6 +1,6 @@
1
1
  import type { StoreServices } from '../../types';
2
2
  import { Query } from './SearchQueryStore';
3
- export declare type HistoryStoreConfig = {
3
+ export type HistoryStoreConfig = {
4
4
  siteId?: string;
5
5
  max?: number;
6
6
  url?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"SearchHistoryStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchHistoryStore.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAE3C,oBAAY,kBAAkB,GAAG;IAChC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;CACb,CAAC;AACF,qBAAa,kBAAkB;IAC9B,OAAO,CAAC,MAAM,CAAqB;IACnC,OAAO,CAAC,OAAO,CAAe;IAC9B,OAAO,CAAC,QAAQ,CAAgB;gBAEpB,MAAM,EAAE,kBAAkB,EAAE,QAAQ,EAAE,aAAa;IAqC/D,IAAI,OAAO,IAAI,KAAK,EAAE,CAGrB;IAEM,IAAI,CAAC,IAAI,EAAE,MAAM;IAoBjB,MAAM,CAAC,IAAI,EAAE,MAAM;IAWnB,KAAK,IAAI,IAAI;IAIb,aAAa,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE;CAmB9C"}
1
+ {"version":3,"file":"SearchHistoryStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchHistoryStore.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAE3C,MAAM,MAAM,kBAAkB,GAAG;IAChC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;CACb,CAAC;AACF,qBAAa,kBAAkB;IAC9B,OAAO,CAAC,MAAM,CAAqB;IACnC,OAAO,CAAC,OAAO,CAAe;IAC9B,OAAO,CAAC,QAAQ,CAAgB;gBAEpB,MAAM,EAAE,kBAAkB,EAAE,QAAQ,EAAE,aAAa;IAqC/D,IAAI,OAAO,IAAI,KAAK,EAAE,CAGrB;IAEM,IAAI,CAAC,IAAI,EAAE,MAAM;IAoBjB,MAAM,CAAC,IAAI,EAAE,MAAM;IAWnB,KAAK,IAAI,IAAI;IAIb,aAAa,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE;CAmB9C"}
@@ -7,7 +7,7 @@ export declare enum ContentType {
7
7
  LEFT = "left",
8
8
  INLINE = "inline"
9
9
  }
10
- export declare type BannerContent = Partial<Record<ContentType, Content>>;
10
+ export type BannerContent = Partial<Record<ContentType, Content>>;
11
11
  export declare class SearchMerchandisingStore {
12
12
  redirect: string;
13
13
  content: BannerContent;
@@ -1 +1 @@
1
- {"version":3,"file":"SearchMerchandisingStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchMerchandisingStore.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,KAAK,EACX,gCAAgC,EAChC,6CAA6C,EAC7C,yCAAyC,EACzC,MAAM,2BAA2B,CAAC;AAEnC,oBAAY,WAAW;IACtB,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,IAAI,SAAS;IACb,MAAM,WAAW;CACjB;AAED,oBAAY,aAAa,GAAG,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC,CAAC;AAElE,qBAAa,wBAAwB;IAC7B,QAAQ,SAAM;IACd,OAAO,EAAE,aAAa,CAAM;IAC5B,SAAS,EAAE,yCAAyC,EAAE,CAAM;IAC5D,WAAW,CAAC,EAAE,yCAAyC,CAAC;IACxD,YAAY,CAAC,EAAE,OAAO,CAAC;gBAElB,QAAQ,EAAE,aAAa,EAAE,SAAS,EAAE,gCAAgC;CAwBhF;AAED,cAAM,OAAQ,SAAQ,KAAK,CAAC,MAAM,GAAG,6CAA6C,CAAC;IAClF,MAAM,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,gBAAgB,CAE9C;gBAEW,OAAO,EAAE,MAAM,EAAE,GAAG,6CAA6C,EAAE;CAG/E"}
1
+ {"version":3,"file":"SearchMerchandisingStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchMerchandisingStore.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,KAAK,EACX,gCAAgC,EAChC,6CAA6C,EAC7C,yCAAyC,EACzC,MAAM,2BAA2B,CAAC;AAEnC,oBAAY,WAAW;IACtB,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,IAAI,SAAS;IACb,MAAM,WAAW;CACjB;AAED,MAAM,MAAM,aAAa,GAAG,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC,CAAC;AAElE,qBAAa,wBAAwB;IAC7B,QAAQ,SAAM;IACd,OAAO,EAAE,aAAa,CAAM;IAC5B,SAAS,EAAE,yCAAyC,EAAE,CAAM;IAC5D,WAAW,CAAC,EAAE,yCAAyC,CAAC;IACxD,YAAY,CAAC,EAAE,OAAO,CAAC;gBAElB,QAAQ,EAAE,aAAa,EAAE,SAAS,EAAE,gCAAgC;CAwBhF;AAED,cAAM,OAAQ,SAAQ,KAAK,CAAC,MAAM,GAAG,6CAA6C,CAAC;IAClF,MAAM,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,gBAAgB,CAE9C;gBAEW,OAAO,EAAE,MAAM,EAAE,GAAG,6CAA6C,EAAE;CAG/E"}
@@ -23,7 +23,7 @@ var ContentType;
23
23
  ContentType["FOOTER"] = "footer";
24
24
  ContentType["LEFT"] = "left";
25
25
  ContentType["INLINE"] = "inline";
26
- })(ContentType = exports.ContentType || (exports.ContentType = {}));
26
+ })(ContentType || (exports.ContentType = ContentType = {}));
27
27
  var SearchMerchandisingStore = /** @class */ (function () {
28
28
  function SearchMerchandisingStore(services, merchData) {
29
29
  var _this = this;
@@ -1,4 +1,4 @@
1
- import type { StoreServices, StoreConfigs } from '../../types';
1
+ import type { StoreServices, StoreConfigs, VariantSelectionOptions } from '../../types';
2
2
  import type { SearchResponseModelResult, SearchResponseModelPagination, SearchResponseModelMerchandising, SearchResponseModelResultMappings, SearchResponseModelMerchandisingContentInline, SearchResponseModelMerchandisingContentConfig } from '@searchspring/snapi-types';
3
3
  export declare class SearchResultStore extends Array<Product | Banner> {
4
4
  static get [Symbol.species](): ArrayConstructor;
@@ -14,6 +14,11 @@ export declare class Banner {
14
14
  value: string;
15
15
  constructor(services: StoreServices, banner: SearchResponseModelMerchandisingContentInline);
16
16
  }
17
+ type VariantData = {
18
+ mappings: SearchResponseModelResultMappings;
19
+ attributes: Record<string, unknown>;
20
+ options: Record<string, string>;
21
+ };
17
22
  export declare class Product {
18
23
  type: string;
19
24
  id: string;
@@ -21,7 +26,54 @@ export declare class Product {
21
26
  mappings: SearchResponseModelResultMappings;
22
27
  custom: {};
23
28
  children?: Array<Child>;
24
- constructor(services: StoreServices, result: SearchResponseModelResult);
29
+ quantity: number;
30
+ display: VariantData;
31
+ variants?: Variants;
32
+ constructor(services: StoreServices, result: SearchResponseModelResult, config?: StoreConfigs);
33
+ updateDisplay: (display?: {
34
+ mappings: SearchResponseModelResultMappings;
35
+ attributes: Record<string, unknown>;
36
+ options: Record<string, string>;
37
+ }) => void;
38
+ }
39
+ declare class Variants {
40
+ active?: Variant;
41
+ data: Variant[];
42
+ selections: VariantSelection[];
43
+ config: StoreConfigs;
44
+ updateDisplay: (variant: VariantData) => void;
45
+ constructor(config: StoreConfigs, services: StoreServices, variantData: VariantData[], updateDisplay: (variant: VariantData) => void);
46
+ setActive(variant: Variant): void;
47
+ makeSelections(options?: Record<string, string>): void;
48
+ update(fromSelection: VariantSelection): void;
49
+ }
50
+ type SelectionValue = {
51
+ value: string;
52
+ label?: string;
53
+ thumbnailImageUrl?: string;
54
+ background?: string;
55
+ available?: boolean;
56
+ };
57
+ export declare class VariantSelection {
58
+ field: string;
59
+ label: string;
60
+ selected?: string;
61
+ previouslySelected?: string;
62
+ values: SelectionValue[];
63
+ private variants;
64
+ constructor(config: StoreConfigs, services: StoreServices, variants: Variants, selectorConfig: VariantSelectionOptions, data: Variant[]);
65
+ refineSelections(allVariants: Variant[]): void;
66
+ reset(): void;
67
+ select(value: string, internalSelection?: boolean): void;
68
+ }
69
+ declare class Variant {
70
+ type: string;
71
+ available: boolean;
72
+ attributes: Record<string, unknown>;
73
+ options: Record<string, string>;
74
+ mappings: SearchResponseModelResultMappings;
75
+ custom: {};
76
+ constructor(services: StoreServices, variantData: VariantData);
25
77
  }
26
78
  declare class Child {
27
79
  type: string;
@@ -1 +1 @@
1
- {"version":3,"file":"SearchResultStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchResultStore.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAqB,aAAa,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAClF,OAAO,KAAK,EACX,yBAAyB,EACzB,6BAA6B,EAC7B,gCAAgC,EAChC,iCAAiC,EACjC,6CAA6C,EAC7C,6CAA6C,EAC7C,MAAM,2BAA2B,CAAC;AAEnC,qBAAa,iBAAkB,SAAQ,KAAK,CAAC,OAAO,GAAG,MAAM,CAAC;IAC7D,MAAM,KAAK,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,gBAAgB,CAE9C;gBAGA,MAAM,EAAE,YAAY,EACpB,QAAQ,EAAE,aAAa,EACvB,UAAU,CAAC,EAAE,yBAAyB,EAAE,EACxC,cAAc,CAAC,EAAE,6BAA6B,EAC9C,SAAS,CAAC,EAAE,gCAAgC;CAqB7C;AAED,qBAAa,MAAM;IACX,IAAI,SAAY;IAChB,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAM;IACzC,QAAQ,EAAE,iCAAiC,CAEhD;IACK,MAAM,KAAM;IACZ,MAAM,EAAE,6CAA6C,CAAC;IACtD,KAAK,EAAE,MAAM,CAAC;gBAET,QAAQ,EAAE,aAAa,EAAE,MAAM,EAAE,6CAA6C;CAW1F;AAED,qBAAa,OAAO;IACZ,IAAI,SAAa;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAM;IACzC,QAAQ,EAAE,iCAAiC,CAEhD;IACK,MAAM,KAAM;IACZ,QAAQ,CAAC,EAAE,KAAK,CAAC,KAAK,CAAC,CAAM;gBAEx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