@searchspring/snap-controller 0.67.4 → 0.68.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.
@@ -756,12 +756,12 @@ function createResultSchemaMapping(_a) {
756
756
  params: request,
757
757
  response: searchResponse,
758
758
  });
759
- (_b = searchResponse.results) === null || _b === void 0 ? void 0 : _b.forEach(function (result) {
759
+ (_b = searchResponse.results) === null || _b === void 0 ? void 0 : _b.forEach(function (result, idx) {
760
760
  var _a, _b, _c, _d;
761
761
  schemaMap[result.id] = __assign(__assign({}, schema), { results: [
762
762
  {
763
763
  type: beacon_1.ItemTypeEnum.Product,
764
- position: result.position,
764
+ position: idx + 1,
765
765
  uid: ((_b = (_a = result.mappings) === null || _a === void 0 ? void 0 : _a.core) === null || _b === void 0 ? void 0 : _b.uid) || '',
766
766
  sku: (_d = (_c = result.mappings) === null || _c === void 0 ? void 0 : _c.core) === null || _d === void 0 ? void 0 : _d.sku,
767
767
  },
@@ -552,13 +552,13 @@ function createResultSchemaMapping({ request, response }) {
552
552
  params: request,
553
553
  response: searchResponse,
554
554
  });
555
- searchResponse.results?.forEach((result) => {
555
+ searchResponse.results?.forEach((result, idx) => {
556
556
  schemaMap[result.id] = {
557
557
  ...schema,
558
558
  results: [
559
559
  {
560
560
  type: ItemTypeEnum.Product,
561
- position: result.position,
561
+ position: idx + 1,
562
562
  uid: result.mappings?.core?.uid || '',
563
563
  sku: result.mappings?.core?.sku,
564
564
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@searchspring/snap-controller",
3
- "version": "0.67.4",
3
+ "version": "0.68.0",
4
4
  "description": "Snap Controllers",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -20,22 +20,22 @@
20
20
  "test:watch": "jest --watch"
21
21
  },
22
22
  "dependencies": {
23
- "@searchspring/snap-toolbox": "0.67.4",
23
+ "@searchspring/snap-toolbox": "0.68.0",
24
24
  "css.escape": "1.5.1",
25
25
  "deepmerge": "4.3.1"
26
26
  },
27
27
  "devDependencies": {
28
- "@searchspring/snap-client": "0.67.4",
29
- "@searchspring/snap-event-manager": "0.67.4",
30
- "@searchspring/snap-logger": "0.67.4",
31
- "@searchspring/snap-profiler": "0.67.4",
32
- "@searchspring/snap-store-mobx": "0.67.4",
33
- "@searchspring/snap-tracker": "0.67.4",
34
- "@searchspring/snap-url-manager": "0.67.4"
28
+ "@searchspring/snap-client": "0.68.0",
29
+ "@searchspring/snap-event-manager": "0.68.0",
30
+ "@searchspring/snap-logger": "0.68.0",
31
+ "@searchspring/snap-profiler": "0.68.0",
32
+ "@searchspring/snap-store-mobx": "0.68.0",
33
+ "@searchspring/snap-tracker": "0.68.0",
34
+ "@searchspring/snap-url-manager": "0.68.0"
35
35
  },
36
36
  "sideEffects": false,
37
37
  "files": [
38
38
  "dist/**/*"
39
39
  ],
40
- "gitHead": "d633f577c8635101e322d589ba83cf45c4719bab"
40
+ "gitHead": "4b0e2291cc4e6cef4f0357f376fb7403c651701e"
41
41
  }