@plattar/plattar-ar-adapter 1.155.2 → 1.155.3
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/build/es2015/plattar-ar-adapter.js +193 -185
- package/build/es2015/plattar-ar-adapter.min.js +1 -1
- package/build/es2019/plattar-ar-adapter.js +13 -5
- package/build/es2019/plattar-ar-adapter.min.js +1 -1
- package/dist/util/configurator-state.js +12 -4
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
|
@@ -44,12 +44,14 @@ class ConfiguratorState {
|
|
|
44
44
|
* purposes of Configuration
|
|
45
45
|
*/
|
|
46
46
|
setVariationSKU(productVariationSKU) {
|
|
47
|
-
const
|
|
48
|
-
if (!
|
|
47
|
+
const variationIDs = this._mappedVariationSKUValues.get(productVariationSKU);
|
|
48
|
+
if (!variationIDs) {
|
|
49
49
|
console.warn("ConfiguratorState.setVariationSKU() - Variation SKU of " + productVariationSKU + " is not defined in any variations");
|
|
50
50
|
return;
|
|
51
51
|
}
|
|
52
|
-
|
|
52
|
+
variationIDs.forEach((variationID) => {
|
|
53
|
+
this.setVariationID(variationID);
|
|
54
|
+
});
|
|
53
55
|
}
|
|
54
56
|
/**
|
|
55
57
|
* Modifyes the SceneProduct that this Variation belongs to and changes for
|
|
@@ -319,7 +321,13 @@ class ConfiguratorState {
|
|
|
319
321
|
variations.forEach((variation) => {
|
|
320
322
|
configState._mappedVariationIDValues.set(variation.id, sceneProduct.id);
|
|
321
323
|
if (variation.attributes.sku) {
|
|
322
|
-
configState._mappedVariationSKUValues.
|
|
324
|
+
const existingSKUs = configState._mappedVariationSKUValues.get(variation.attributes.sku);
|
|
325
|
+
if (existingSKUs) {
|
|
326
|
+
existingSKUs.push(variation.id);
|
|
327
|
+
}
|
|
328
|
+
else {
|
|
329
|
+
configState._mappedVariationSKUValues.set(variation.attributes.sku, [variation.id]);
|
|
330
|
+
}
|
|
323
331
|
}
|
|
324
332
|
});
|
|
325
333
|
}
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: "1.155.
|
|
1
|
+
declare const _default: "1.155.3";
|
|
2
2
|
export default _default;
|
package/dist/version.js
CHANGED