@athoscommerce/snap-store-mobx 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 +21 -0
- package/README.md +17 -0
- package/dist/cjs/Abstract/AbstractStore.d.ts +17 -0
- package/dist/cjs/Abstract/AbstractStore.d.ts.map +1 -0
- package/dist/cjs/Abstract/AbstractStore.js +28 -0
- package/dist/cjs/Autocomplete/AutocompleteStore.d.ts +40 -0
- package/dist/cjs/Autocomplete/AutocompleteStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/AutocompleteStore.js +246 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteFacetStore.d.ts +13 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteFacetStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteFacetStore.js +67 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteHistoryStore.d.ts +19 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteHistoryStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteHistoryStore.js +57 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteQueryStore.d.ts +25 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteQueryStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteQueryStore.js +34 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteStateStore.d.ts +29 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteStateStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteStateStore.js +54 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteTermStore.d.ts +47 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteTermStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteTermStore.js +102 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteTrendingStore.d.ts +20 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteTrendingStore.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/AutocompleteTrendingStore.js +58 -0
- package/dist/cjs/Autocomplete/Stores/index.d.ts +7 -0
- package/dist/cjs/Autocomplete/Stores/index.d.ts.map +1 -0
- package/dist/cjs/Autocomplete/Stores/index.js +16 -0
- package/dist/cjs/Cart/CartStore.d.ts +15 -0
- package/dist/cjs/Cart/CartStore.d.ts.map +1 -0
- package/dist/cjs/Cart/CartStore.js +109 -0
- package/dist/cjs/Finder/FinderStore.d.ts +27 -0
- package/dist/cjs/Finder/FinderStore.d.ts.map +1 -0
- package/dist/cjs/Finder/FinderStore.js +156 -0
- package/dist/cjs/Finder/Stores/FinderSelectionStore.d.ts +73 -0
- package/dist/cjs/Finder/Stores/FinderSelectionStore.d.ts.map +1 -0
- package/dist/cjs/Finder/Stores/FinderSelectionStore.js +320 -0
- package/dist/cjs/Finder/Stores/index.d.ts +2 -0
- package/dist/cjs/Finder/Stores/index.d.ts.map +1 -0
- package/dist/cjs/Finder/Stores/index.js +5 -0
- package/dist/cjs/Meta/MetaStore.d.ts +20 -0
- package/dist/cjs/Meta/MetaStore.d.ts.map +1 -0
- package/dist/cjs/Meta/MetaStore.js +55 -0
- package/dist/cjs/Recommendation/RecommendationStore.d.ts +19 -0
- package/dist/cjs/Recommendation/RecommendationStore.d.ts.map +1 -0
- package/dist/cjs/Recommendation/RecommendationStore.js +97 -0
- package/dist/cjs/Recommendation/Stores/RecommendationProfileStore.d.ts +15 -0
- package/dist/cjs/Recommendation/Stores/RecommendationProfileStore.d.ts.map +1 -0
- package/dist/cjs/Recommendation/Stores/RecommendationProfileStore.js +30 -0
- package/dist/cjs/Recommendation/Stores/index.d.ts +2 -0
- package/dist/cjs/Recommendation/Stores/index.d.ts.map +1 -0
- package/dist/cjs/Recommendation/Stores/index.js +5 -0
- package/dist/cjs/Search/SearchStore.d.ts +27 -0
- package/dist/cjs/Search/SearchStore.d.ts.map +1 -0
- package/dist/cjs/Search/SearchStore.js +125 -0
- package/dist/cjs/Search/Stores/SearchFacetStore.d.ts +89 -0
- package/dist/cjs/Search/Stores/SearchFacetStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchFacetStore.js +368 -0
- package/dist/cjs/Search/Stores/SearchFilterStore.d.ts +44 -0
- package/dist/cjs/Search/Stores/SearchFilterStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchFilterStore.js +102 -0
- package/dist/cjs/Search/Stores/SearchHistoryStore.d.ts +20 -0
- package/dist/cjs/Search/Stores/SearchHistoryStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchHistoryStore.js +106 -0
- package/dist/cjs/Search/Stores/SearchMerchandisingStore.d.ts +36 -0
- package/dist/cjs/Search/Stores/SearchMerchandisingStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchMerchandisingStore.js +90 -0
- package/dist/cjs/Search/Stores/SearchPaginationStore.d.ts +57 -0
- package/dist/cjs/Search/Stores/SearchPaginationStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchPaginationStore.js +212 -0
- package/dist/cjs/Search/Stores/SearchQueryStore.d.ts +23 -0
- package/dist/cjs/Search/Stores/SearchQueryStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchQueryStore.js +41 -0
- package/dist/cjs/Search/Stores/SearchResultStore.d.ts +175 -0
- package/dist/cjs/Search/Stores/SearchResultStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchResultStore.js +749 -0
- package/dist/cjs/Search/Stores/SearchSortingStore.d.ts +32 -0
- package/dist/cjs/Search/Stores/SearchSortingStore.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/SearchSortingStore.js +77 -0
- package/dist/cjs/Search/Stores/index.d.ts +9 -0
- package/dist/cjs/Search/Stores/index.d.ts.map +1 -0
- package/dist/cjs/Search/Stores/index.js +30 -0
- package/dist/cjs/Storage/StorageStore.d.ts +27 -0
- package/dist/cjs/Storage/StorageStore.d.ts.map +1 -0
- package/dist/cjs/Storage/StorageStore.js +176 -0
- package/dist/cjs/index.d.ts +12 -0
- package/dist/cjs/index.d.ts.map +1 -0
- package/dist/cjs/index.js +37 -0
- package/dist/cjs/types.d.ts +170 -0
- package/dist/cjs/types.d.ts.map +1 -0
- package/dist/cjs/types.js +9 -0
- package/dist/esm/Abstract/AbstractStore.d.ts +17 -0
- package/dist/esm/Abstract/AbstractStore.d.ts.map +1 -0
- package/dist/esm/Abstract/AbstractStore.js +22 -0
- package/dist/esm/Autocomplete/AutocompleteStore.d.ts +40 -0
- package/dist/esm/Autocomplete/AutocompleteStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/AutocompleteStore.js +210 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteFacetStore.d.ts +13 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteFacetStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteFacetStore.js +35 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteHistoryStore.d.ts +19 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteHistoryStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteHistoryStore.js +27 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteQueryStore.d.ts +25 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteQueryStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteQueryStore.js +28 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteStateStore.d.ts +29 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteStateStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteStateStore.js +42 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteTermStore.d.ts +47 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteTermStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteTermStore.js +56 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteTrendingStore.d.ts +20 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteTrendingStore.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/AutocompleteTrendingStore.js +27 -0
- package/dist/esm/Autocomplete/Stores/index.d.ts +7 -0
- package/dist/esm/Autocomplete/Stores/index.d.ts.map +1 -0
- package/dist/esm/Autocomplete/Stores/index.js +6 -0
- package/dist/esm/Cart/CartStore.d.ts +15 -0
- package/dist/esm/Cart/CartStore.d.ts.map +1 -0
- package/dist/esm/Cart/CartStore.js +74 -0
- package/dist/esm/Finder/FinderStore.d.ts +27 -0
- package/dist/esm/Finder/FinderStore.d.ts.map +1 -0
- package/dist/esm/Finder/FinderStore.js +118 -0
- package/dist/esm/Finder/Stores/FinderSelectionStore.d.ts +73 -0
- package/dist/esm/Finder/Stores/FinderSelectionStore.d.ts.map +1 -0
- package/dist/esm/Finder/Stores/FinderSelectionStore.js +258 -0
- package/dist/esm/Finder/Stores/index.d.ts +2 -0
- package/dist/esm/Finder/Stores/index.d.ts.map +1 -0
- package/dist/esm/Finder/Stores/index.js +1 -0
- package/dist/esm/Meta/MetaStore.d.ts +20 -0
- package/dist/esm/Meta/MetaStore.d.ts.map +1 -0
- package/dist/esm/Meta/MetaStore.js +45 -0
- package/dist/esm/Recommendation/RecommendationStore.d.ts +19 -0
- package/dist/esm/Recommendation/RecommendationStore.d.ts.map +1 -0
- package/dist/esm/Recommendation/RecommendationStore.js +71 -0
- package/dist/esm/Recommendation/Stores/RecommendationProfileStore.d.ts +15 -0
- package/dist/esm/Recommendation/Stores/RecommendationProfileStore.d.ts.map +1 -0
- package/dist/esm/Recommendation/Stores/RecommendationProfileStore.js +25 -0
- package/dist/esm/Recommendation/Stores/index.d.ts +2 -0
- package/dist/esm/Recommendation/Stores/index.d.ts.map +1 -0
- package/dist/esm/Recommendation/Stores/index.js +1 -0
- package/dist/esm/Search/SearchStore.d.ts +27 -0
- package/dist/esm/Search/SearchStore.d.ts.map +1 -0
- package/dist/esm/Search/SearchStore.js +102 -0
- package/dist/esm/Search/Stores/SearchFacetStore.d.ts +89 -0
- package/dist/esm/Search/Stores/SearchFacetStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchFacetStore.js +292 -0
- package/dist/esm/Search/Stores/SearchFilterStore.d.ts +44 -0
- package/dist/esm/Search/Stores/SearchFilterStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchFilterStore.js +70 -0
- package/dist/esm/Search/Stores/SearchHistoryStore.d.ts +20 -0
- package/dist/esm/Search/Stores/SearchHistoryStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchHistoryStore.js +85 -0
- package/dist/esm/Search/Stores/SearchMerchandisingStore.d.ts +36 -0
- package/dist/esm/Search/Stores/SearchMerchandisingStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchMerchandisingStore.js +61 -0
- package/dist/esm/Search/Stores/SearchPaginationStore.d.ts +57 -0
- package/dist/esm/Search/Stores/SearchPaginationStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchPaginationStore.js +163 -0
- package/dist/esm/Search/Stores/SearchQueryStore.d.ts +23 -0
- package/dist/esm/Search/Stores/SearchQueryStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchQueryStore.js +33 -0
- package/dist/esm/Search/Stores/SearchResultStore.d.ts +175 -0
- package/dist/esm/Search/Stores/SearchResultStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchResultStore.js +648 -0
- package/dist/esm/Search/Stores/SearchSortingStore.d.ts +32 -0
- package/dist/esm/Search/Stores/SearchSortingStore.d.ts.map +1 -0
- package/dist/esm/Search/Stores/SearchSortingStore.js +67 -0
- package/dist/esm/Search/Stores/index.d.ts +9 -0
- package/dist/esm/Search/Stores/index.d.ts.map +1 -0
- package/dist/esm/Search/Stores/index.js +8 -0
- package/dist/esm/Storage/StorageStore.d.ts +27 -0
- package/dist/esm/Storage/StorageStore.d.ts.map +1 -0
- package/dist/esm/Storage/StorageStore.js +169 -0
- package/dist/esm/index.d.ts +12 -0
- package/dist/esm/index.d.ts.map +1 -0
- package/dist/esm/index.js +11 -0
- package/dist/esm/types.d.ts +170 -0
- package/dist/esm/types.d.ts.map +1 -0
- package/dist/esm/types.js +6 -0
- package/package.json +35 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchPaginationStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchPaginationStore.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AACpE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAClE,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAEpF,KAAK,2BAA2B,GAAG;IAClC,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,QAAQ,EAAE,aAAa,CAAC;IACxB,IAAI,EAAE;QACL,MAAM,CAAC,EAAE,mBAAmB,CAAC;QAC7B,IAAI,EAAE,iBAAiB,CAAC;KACxB,CAAC;CACF,CAAC;AAEF,qBAAa,qBAAqB;IAC1B,QAAQ,EAAE,aAAa,CAAC;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,eAAe,EAAE,cAAc,EAAE,CAAC;IAClC,eAAe,EAAE,MAAM,CAAC;IACxB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB,CAAC,EAAE,iBAAiB,CAAC;gBAEhC,MAAM,EAAE,2BAA2B;IA8D/C,IAAW,KAAK,IAAI,MAAM,CAKzB;IAED,IAAW,GAAG,IAAI,MAAM,CAMvB;IAED,IAAW,aAAa,IAAI,OAAO,CAElC;IAED,IAAW,OAAO,IAAI,IAAI,CAKzB;IAED,IAAW,KAAK,IAAI,IAAI,CAKvB;IAED,IAAW,IAAI,IAAI,IAAI,CAKtB;IAED,IAAW,IAAI,IAAI,IAAI,GAAG,SAAS,CAMlC;IAED,IAAW,QAAQ,IAAI,IAAI,GAAG,SAAS,CAMtC;IAEM,QAAQ,CAAC,GAAG,SAAI,EAAE,GAAG,CAAC,EAAE,MAAM,GAAG,IAAI,EAAE;IAmDvC,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;CAKrC;AAED,qBAAa,cAAc;IAC1B,OAAO,CAAC,QAAQ,CAAgB;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,UAAU,CAAC;IAChB,MAAM,EAAE,OAAO,CAAC;gBAGtB,QAAQ,EAAE,aAAa,EACvB,eAAe,EAAE,MAAM,EACvB,MAAM,EAAE;QACP,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;KACd;CAQF;AAED,qBAAa,IAAI;IAChB,OAAO,CAAC,QAAQ,CAAgB;IACzB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,UAAU,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;gBAGlB,QAAQ,EAAE,aAAa,EACvB,IAAI,EAAE;QACL,MAAM,EAAE,MAAM,CAAC;QACf,MAAM,CAAC,EAAE,OAAO,CAAC;KACjB;CAQF"}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
import { observable, action, computed, makeObservable } from 'mobx';
|
|
2
|
+
export class SearchPaginationStore {
|
|
3
|
+
constructor(params) {
|
|
4
|
+
const { services, data, config } = params || {};
|
|
5
|
+
const { search, meta } = data || {};
|
|
6
|
+
const { pagination } = search || {};
|
|
7
|
+
const paginationSettings = config?.settings?.pagination;
|
|
8
|
+
this.services = services;
|
|
9
|
+
this.controllerConfig = config;
|
|
10
|
+
this.page = pagination?.page;
|
|
11
|
+
this.pageSize = pagination?.pageSize;
|
|
12
|
+
this.totalResults = pagination?.totalResults;
|
|
13
|
+
this.defaultPageSize = meta?.pagination?.defaultPageSize;
|
|
14
|
+
this.totalPages = pagination?.totalPages;
|
|
15
|
+
const pageSizeOptions = paginationSettings?.pageSizeOptions || [
|
|
16
|
+
{
|
|
17
|
+
label: `Show ${this.defaultPageSize}`,
|
|
18
|
+
value: this.defaultPageSize,
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
label: `Show ${this.defaultPageSize * 2}`,
|
|
22
|
+
value: this.defaultPageSize * 2,
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
label: `Show ${this.defaultPageSize * 3}`,
|
|
26
|
+
value: this.defaultPageSize * 3,
|
|
27
|
+
},
|
|
28
|
+
];
|
|
29
|
+
//dont allow any page size options over the api limit of 100
|
|
30
|
+
this.pageSizeOptions = pageSizeOptions
|
|
31
|
+
.filter((option) => option.value <= 100)
|
|
32
|
+
.map((pageOption) => new PageSizeOption(this.services, this.pageSize, {
|
|
33
|
+
label: pageOption.label,
|
|
34
|
+
value: pageOption.value,
|
|
35
|
+
}));
|
|
36
|
+
this.pageSizeOption = this.pageSizeOptions.find((option) => option.active);
|
|
37
|
+
makeObservable(this, {
|
|
38
|
+
page: observable,
|
|
39
|
+
pageSize: observable,
|
|
40
|
+
totalResults: observable,
|
|
41
|
+
totalPages: observable,
|
|
42
|
+
begin: computed,
|
|
43
|
+
end: computed,
|
|
44
|
+
multiplePages: computed,
|
|
45
|
+
current: computed,
|
|
46
|
+
first: computed,
|
|
47
|
+
last: computed,
|
|
48
|
+
next: computed,
|
|
49
|
+
previous: computed,
|
|
50
|
+
getPages: action,
|
|
51
|
+
setPageSize: action,
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
get begin() {
|
|
55
|
+
if (this.controllerConfig?.settings?.infinite?.enabled) {
|
|
56
|
+
return 1;
|
|
57
|
+
}
|
|
58
|
+
return this.pageSize * (this.page - 1) + 1;
|
|
59
|
+
}
|
|
60
|
+
get end() {
|
|
61
|
+
if (this.pageSize * this.page > this.totalResults) {
|
|
62
|
+
return this.totalResults;
|
|
63
|
+
}
|
|
64
|
+
return this.pageSize * this.page;
|
|
65
|
+
}
|
|
66
|
+
get multiplePages() {
|
|
67
|
+
return this.pageSize < this.totalResults;
|
|
68
|
+
}
|
|
69
|
+
get current() {
|
|
70
|
+
return new Page(this.services, {
|
|
71
|
+
number: this.page,
|
|
72
|
+
active: true,
|
|
73
|
+
});
|
|
74
|
+
}
|
|
75
|
+
get first() {
|
|
76
|
+
return new Page(this.services, {
|
|
77
|
+
number: 1,
|
|
78
|
+
active: this.page == 1,
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
get last() {
|
|
82
|
+
return new Page(this.services, {
|
|
83
|
+
number: this.totalPages,
|
|
84
|
+
active: this.totalPages == this.page,
|
|
85
|
+
});
|
|
86
|
+
}
|
|
87
|
+
get next() {
|
|
88
|
+
if (this.page < this.totalPages) {
|
|
89
|
+
return new Page(this.services, {
|
|
90
|
+
number: this.page + 1,
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
get previous() {
|
|
95
|
+
if (this.page > 1) {
|
|
96
|
+
return new Page(this.services, {
|
|
97
|
+
number: this.page - 1,
|
|
98
|
+
});
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
getPages(min = 5, max) {
|
|
102
|
+
if (!Number.isInteger(min)) {
|
|
103
|
+
return [];
|
|
104
|
+
}
|
|
105
|
+
if (typeof max == 'undefined' || !Number.isInteger(max)) {
|
|
106
|
+
const surrounding = min - 1;
|
|
107
|
+
let from = this.page;
|
|
108
|
+
let to = this.page;
|
|
109
|
+
let last = to - from;
|
|
110
|
+
do {
|
|
111
|
+
last = to - from;
|
|
112
|
+
if (to < this.totalPages) {
|
|
113
|
+
to++;
|
|
114
|
+
}
|
|
115
|
+
if (to - from >= surrounding) {
|
|
116
|
+
break;
|
|
117
|
+
}
|
|
118
|
+
if (from > 1) {
|
|
119
|
+
from--;
|
|
120
|
+
}
|
|
121
|
+
} while (last != to - from && to - from < surrounding);
|
|
122
|
+
min = from - this.page;
|
|
123
|
+
max = to - this.page;
|
|
124
|
+
}
|
|
125
|
+
else {
|
|
126
|
+
min = -Math.abs(min);
|
|
127
|
+
max = Math.abs(max);
|
|
128
|
+
}
|
|
129
|
+
const pages = [];
|
|
130
|
+
for (let i = this.page + min; i <= this.page + max; i++) {
|
|
131
|
+
if (i > 0 && i <= this.totalPages) {
|
|
132
|
+
pages.push(new Page(this.services, {
|
|
133
|
+
number: i,
|
|
134
|
+
active: i == this.page,
|
|
135
|
+
}));
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
return pages;
|
|
139
|
+
}
|
|
140
|
+
setPageSize(num) {
|
|
141
|
+
if (num) {
|
|
142
|
+
this.services.urlManager.remove('page').set('pageSize', num).go();
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
export class PageSizeOption {
|
|
147
|
+
constructor(services, currentPageSize, option) {
|
|
148
|
+
this.services = services;
|
|
149
|
+
this.value = option.value;
|
|
150
|
+
this.label = option.label;
|
|
151
|
+
this.url = this.services?.urlManager.remove('page').set('pageSize', option.value);
|
|
152
|
+
this.active = Boolean(currentPageSize == option.value);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
export class Page {
|
|
156
|
+
constructor(services, page) {
|
|
157
|
+
this.services = services;
|
|
158
|
+
this.number = page.number;
|
|
159
|
+
this.active = page.active || false;
|
|
160
|
+
this.url = this.services?.urlManager?.set('page', this.number);
|
|
161
|
+
this.key = this.url.href;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { UrlManager } from '@athoscommerce/snap-url-manager';
|
|
2
|
+
import type { StoreServices } from '../../types';
|
|
3
|
+
import type { SearchResponseModel, SearchResponseModelSearchMatchTypeEnum } from '@athoscommerce/snapi-types';
|
|
4
|
+
type SearchQueryStoreConfig = {
|
|
5
|
+
services: StoreServices;
|
|
6
|
+
data: {
|
|
7
|
+
search?: SearchResponseModel;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export declare class SearchQueryStore {
|
|
11
|
+
query?: Query;
|
|
12
|
+
didYouMean?: Query;
|
|
13
|
+
originalQuery?: Query;
|
|
14
|
+
matchType: SearchResponseModelSearchMatchTypeEnum;
|
|
15
|
+
constructor(params: SearchQueryStoreConfig);
|
|
16
|
+
}
|
|
17
|
+
export declare class Query {
|
|
18
|
+
string: string;
|
|
19
|
+
url: UrlManager;
|
|
20
|
+
constructor(services: StoreServices, query: string);
|
|
21
|
+
}
|
|
22
|
+
export {};
|
|
23
|
+
//# sourceMappingURL=SearchQueryStore.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchQueryStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchQueryStore.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAClE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,KAAK,EAAE,mBAAmB,EAAE,sCAAsC,EAAE,MAAM,4BAA4B,CAAC;AAE9G,KAAK,sBAAsB,GAAG;IAC7B,QAAQ,EAAE,aAAa,CAAC;IACxB,IAAI,EAAE;QACL,MAAM,CAAC,EAAE,mBAAmB,CAAC;KAC7B,CAAC;CACF,CAAC;AAEF,qBAAa,gBAAgB;IACrB,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,UAAU,CAAC,EAAE,KAAK,CAAC;IACnB,aAAa,CAAC,EAAE,KAAK,CAAC;IACtB,SAAS,EAAE,sCAAsC,CAAC;gBAE7C,MAAM,EAAE,sBAAsB;CAyB1C;AASD,qBAAa,KAAK;IACV,MAAM,EAAE,MAAM,CAAC;IACf,GAAG,EAAE,UAAU,CAAC;gBAEX,QAAQ,EAAE,aAAa,EAAE,KAAK,EAAE,MAAM;CASlD"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { observable, makeObservable } from 'mobx';
|
|
2
|
+
import { escapeHTML } from '@athoscommerce/snap-toolbox';
|
|
3
|
+
export class SearchQueryStore {
|
|
4
|
+
constructor(params) {
|
|
5
|
+
const { services, data } = params || {};
|
|
6
|
+
const { search } = data.search || {};
|
|
7
|
+
const observables = {};
|
|
8
|
+
if (search?.query) {
|
|
9
|
+
this.query = new Query(services, search.query);
|
|
10
|
+
observables.query = observable;
|
|
11
|
+
}
|
|
12
|
+
if (search?.didYouMean) {
|
|
13
|
+
this.didYouMean = new Query(services, search.didYouMean);
|
|
14
|
+
observables.didYouMean = observable;
|
|
15
|
+
}
|
|
16
|
+
if (search?.originalQuery) {
|
|
17
|
+
this.originalQuery = new Query(services, search.originalQuery);
|
|
18
|
+
observables.originalQuery = observable;
|
|
19
|
+
}
|
|
20
|
+
this.matchType = search?.matchType;
|
|
21
|
+
observables.matchType = observable;
|
|
22
|
+
makeObservable(this, observables);
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
export class Query {
|
|
26
|
+
constructor(services, query) {
|
|
27
|
+
this.string = escapeHTML(query);
|
|
28
|
+
this.url = services?.urlManager?.remove('page').remove('filter').set('query', this.string);
|
|
29
|
+
makeObservable(this, {
|
|
30
|
+
string: observable,
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
import type { ResultBadge, VariantOptionConfig, VariantConfig, StoreConfigs } from '../../types';
|
|
2
|
+
import type { SearchResponseModelResult, SearchResponseModelResultMappings, SearchResponseModelMerchandisingContentInline, SearchResponseModelMerchandisingContentConfig, SearchResponseModel, MetaResponseModel, SearchResponseModelResultBadges, SearchResponseModelResultVariantsData, SearchResponseModelResultVariantsOptionConfig } from '@athoscommerce/snapi-types';
|
|
3
|
+
type SearchResultStoreConfig = {
|
|
4
|
+
config: StoreConfigs;
|
|
5
|
+
state: {
|
|
6
|
+
loaded: boolean;
|
|
7
|
+
};
|
|
8
|
+
stores?: {
|
|
9
|
+
previousResults?: SearchResultStore;
|
|
10
|
+
};
|
|
11
|
+
data: {
|
|
12
|
+
search?: Partial<SearchResponseModel>;
|
|
13
|
+
meta: MetaResponseModel;
|
|
14
|
+
previousSearch?: SearchResponseModel;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
export declare class SearchResultStore extends Array<Product | Banner> {
|
|
18
|
+
static get [Symbol.species](): ArrayConstructor;
|
|
19
|
+
constructor(params: SearchResultStoreConfig);
|
|
20
|
+
}
|
|
21
|
+
type BannerData = {
|
|
22
|
+
data: {
|
|
23
|
+
banner: SearchResponseModelMerchandisingContentInline;
|
|
24
|
+
responseId: string;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
export declare class Banner {
|
|
28
|
+
type: string;
|
|
29
|
+
id: string;
|
|
30
|
+
responseId: string;
|
|
31
|
+
attributes: Record<string, unknown>;
|
|
32
|
+
mappings: SearchResponseModelResultMappings;
|
|
33
|
+
custom: {};
|
|
34
|
+
config: SearchResponseModelMerchandisingContentConfig;
|
|
35
|
+
value: string;
|
|
36
|
+
constructor(bannerData: BannerData);
|
|
37
|
+
}
|
|
38
|
+
export type VariantData = SearchResponseModelResultVariantsData & {
|
|
39
|
+
attributes?: Record<string, unknown>;
|
|
40
|
+
};
|
|
41
|
+
export type VariantDataOptions = Record<string, {
|
|
42
|
+
value: string;
|
|
43
|
+
background?: string;
|
|
44
|
+
backgroundImageUrl?: string;
|
|
45
|
+
attributeId?: string;
|
|
46
|
+
optionId?: string;
|
|
47
|
+
optionValue?: string;
|
|
48
|
+
}>;
|
|
49
|
+
type ProductMinimal = {
|
|
50
|
+
id: string;
|
|
51
|
+
attributes: Record<string, unknown>;
|
|
52
|
+
mappings: SearchResponseModelResultMappings;
|
|
53
|
+
badges: Badges;
|
|
54
|
+
};
|
|
55
|
+
type ProductData = {
|
|
56
|
+
config: StoreConfigs;
|
|
57
|
+
data: {
|
|
58
|
+
result: SearchResponseModelResult & {
|
|
59
|
+
responseId?: string;
|
|
60
|
+
};
|
|
61
|
+
meta: MetaResponseModel;
|
|
62
|
+
};
|
|
63
|
+
position: number;
|
|
64
|
+
responseId: string;
|
|
65
|
+
};
|
|
66
|
+
export declare class Product {
|
|
67
|
+
type: string;
|
|
68
|
+
id: string;
|
|
69
|
+
responseId: string;
|
|
70
|
+
attributes: Record<string, unknown>;
|
|
71
|
+
mappings: SearchResponseModelResultMappings;
|
|
72
|
+
custom: {};
|
|
73
|
+
badges: Badges;
|
|
74
|
+
bundleSeed: boolean | undefined;
|
|
75
|
+
quantity: number;
|
|
76
|
+
mask: ProductMask;
|
|
77
|
+
variants?: Variants;
|
|
78
|
+
position?: number;
|
|
79
|
+
constructor(productData: ProductData);
|
|
80
|
+
get display(): ProductMinimal;
|
|
81
|
+
}
|
|
82
|
+
type BadgesData = {
|
|
83
|
+
data: {
|
|
84
|
+
meta: MetaResponseModel;
|
|
85
|
+
result: SearchResponseModelResult;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
export declare class Badges {
|
|
89
|
+
all: ResultBadge[];
|
|
90
|
+
constructor(badgesData: BadgesData);
|
|
91
|
+
atLocation(location?: string[] | string): ResultBadge[];
|
|
92
|
+
get tags(): Record<string, ResultBadge>;
|
|
93
|
+
get locations(): Record<string, Record<string, ResultBadge[]>>;
|
|
94
|
+
}
|
|
95
|
+
export declare class ProductMask {
|
|
96
|
+
data: Partial<Product>;
|
|
97
|
+
constructor();
|
|
98
|
+
merge(mask: Partial<Product>): void;
|
|
99
|
+
set(mask: Partial<Product>): void;
|
|
100
|
+
reset(): void;
|
|
101
|
+
}
|
|
102
|
+
type VariantsData = {
|
|
103
|
+
config?: VariantConfig;
|
|
104
|
+
data: {
|
|
105
|
+
mask: ProductMask;
|
|
106
|
+
variants: VariantData[];
|
|
107
|
+
preferences?: Record<string, string[]>;
|
|
108
|
+
meta: MetaResponseModel;
|
|
109
|
+
optionConfig?: {
|
|
110
|
+
[key: string]: SearchResponseModelResultVariantsOptionConfig;
|
|
111
|
+
};
|
|
112
|
+
};
|
|
113
|
+
};
|
|
114
|
+
export declare class Variants {
|
|
115
|
+
active?: Variant;
|
|
116
|
+
data: Variant[];
|
|
117
|
+
selections: VariantSelection[];
|
|
118
|
+
setActive: (variant: Variant) => void;
|
|
119
|
+
private config?;
|
|
120
|
+
optionConfig?: {
|
|
121
|
+
[key: string]: SearchResponseModelResultVariantsOptionConfig;
|
|
122
|
+
};
|
|
123
|
+
constructor(variantData: VariantsData);
|
|
124
|
+
update(variantData: VariantData[], config?: VariantConfig | undefined, preferences?: Record<string, string[]>): void;
|
|
125
|
+
makeSelections(options?: Record<string, string[]>): void;
|
|
126
|
+
refineSelections(fromSelection: VariantSelection): void;
|
|
127
|
+
}
|
|
128
|
+
export type VariantSelectionValue = {
|
|
129
|
+
value: string;
|
|
130
|
+
label?: string;
|
|
131
|
+
thumbnailImageUrl?: string;
|
|
132
|
+
backgroundImageUrl?: string;
|
|
133
|
+
background?: string;
|
|
134
|
+
available?: boolean;
|
|
135
|
+
disabled?: boolean;
|
|
136
|
+
};
|
|
137
|
+
type VariantSelectionData = {
|
|
138
|
+
config?: VariantOptionConfig;
|
|
139
|
+
optionConfig?: SearchResponseModelResultVariantsOptionConfig;
|
|
140
|
+
data: {
|
|
141
|
+
variants: Variants;
|
|
142
|
+
selectorField: string;
|
|
143
|
+
};
|
|
144
|
+
};
|
|
145
|
+
export declare class VariantSelection {
|
|
146
|
+
field: string;
|
|
147
|
+
label: string;
|
|
148
|
+
type?: string;
|
|
149
|
+
count?: number;
|
|
150
|
+
selected?: VariantSelectionValue;
|
|
151
|
+
previouslySelected?: VariantSelectionValue;
|
|
152
|
+
values: VariantSelectionValue[];
|
|
153
|
+
private config;
|
|
154
|
+
private variantsUpdate;
|
|
155
|
+
constructor(variantSelectionData: VariantSelectionData);
|
|
156
|
+
refineValues(variants: Variants): void;
|
|
157
|
+
reset(): void;
|
|
158
|
+
select(value: string | number, internalSelection?: boolean): void;
|
|
159
|
+
}
|
|
160
|
+
export declare class Variant {
|
|
161
|
+
type: string;
|
|
162
|
+
available: boolean;
|
|
163
|
+
attributes?: Record<string, unknown>;
|
|
164
|
+
options: VariantDataOptions;
|
|
165
|
+
badges: SearchResponseModelResultBadges[];
|
|
166
|
+
mappings: SearchResponseModelResultMappings;
|
|
167
|
+
custom: {};
|
|
168
|
+
constructor(variantData: {
|
|
169
|
+
data: {
|
|
170
|
+
variant: VariantData;
|
|
171
|
+
};
|
|
172
|
+
});
|
|
173
|
+
}
|
|
174
|
+
export {};
|
|
175
|
+
//# sourceMappingURL=SearchResultStore.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchResultStore.d.ts","sourceRoot":"","sources":["../../../../src/Search/Stores/SearchResultStore.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAEX,WAAW,EACX,mBAAmB,EACnB,aAAa,EACb,YAAY,EAGZ,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EACX,yBAAyB,EACzB,iCAAiC,EACjC,6CAA6C,EAC7C,6CAA6C,EAC7C,mBAAmB,EACnB,iBAAiB,EAEjB,+BAA+B,EAC/B,qCAAqC,EACrC,6CAA6C,EAC7C,MAAM,4BAA4B,CAAC;AAKpC,KAAK,uBAAuB,GAAG;IAC9B,MAAM,EAAE,YAAY,CAAC;IACrB,KAAK,EAAE;QACN,MAAM,EAAE,OAAO,CAAC;KAChB,CAAC;IACF,MAAM,CAAC,EAAE;QACR,eAAe,CAAC,EAAE,iBAAiB,CAAC;KACpC,CAAC;IACF,IAAI,EAAE;QACL,MAAM,CAAC,EAAE,OAAO,CAAC,mBAAmB,CAAC,CAAC;QACtC,IAAI,EAAE,iBAAiB,CAAC;QACxB,cAAc,CAAC,EAAE,mBAAmB,CAAC;KACrC,CAAC;CACF,CAAC;AAEF,qBAAa,iBAAkB,SAAQ,KAAK,CAAC,OAAO,GAAG,MAAM,CAAC;IAC7D,MAAM,KAAK,CAAC,MAAM,CAAC,OA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