zakeke-configurator-react 0.0.104 → 0.0.105

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.
@@ -23,8 +23,19 @@ export declare class Product {
23
23
  metadata?: any;
24
24
  areas: ProductArea[];
25
25
  quantityRule: ProductQuantityRule | null;
26
+ quoteRule: QuoteRule | null;
26
27
  static fromProduct(zkProduct: any): Product;
27
28
  }
29
+ export declare class QuoteRule {
30
+ quoteRuleID: number;
31
+ name: string;
32
+ sellerID: number;
33
+ formControlsData: string;
34
+ isValidForAllProducts: boolean;
35
+ allowAddToCart: boolean;
36
+ products: number[];
37
+ constructor(quoteRule: any);
38
+ }
28
39
  export declare class ProductArea {
29
40
  id: number;
30
41
  name: string;
@@ -192,6 +203,7 @@ export interface Settings {
192
203
  username: string;
193
204
  referrerID: number;
194
205
  ecommerceUrl: string;
206
+ ecommerceID: number | null;
195
207
  addons: Addon[];
196
208
  eventMessages: EventMessage[];
197
209
  }
@@ -293,4 +305,13 @@ export interface OnBeforeSendDataToParent {
293
305
  quantity: number;
294
306
  additionalProperties: any;
295
307
  }
308
+ export interface TemplateUploadRestrictictions {
309
+ isUserImageAllowed: boolean;
310
+ isJpgAllowed: boolean;
311
+ isPngAllowed: boolean;
312
+ isSvgAllowed: boolean;
313
+ isPdfAllowed: boolean;
314
+ isEpsAllowed: boolean;
315
+ isPdfWithRasterAllowed: boolean;
316
+ }
296
317
  export {};
package/dist/index.js CHANGED
@@ -19333,7 +19333,6 @@ class SceneEditor extends _SceneViewer__WEBPACK_IMPORTED_MODULE_10__.SceneViewer
19333
19333
  }
19334
19334
  // Applica la texture
19335
19335
  if (texture) {
19336
- console.log("texture prima di isReady ", texture);
19337
19336
  _Components_SceneHelper__WEBPACK_IMPORTED_MODULE_3__.SceneHelper.whenTextureIsReadyAsync(texture).then(() => {
19338
19337
  if (material) {
19339
19338
  const oldTexture = this.getMaterialTexture(material, type);
@@ -19341,13 +19340,11 @@ class SceneEditor extends _SceneViewer__WEBPACK_IMPORTED_MODULE_10__.SceneViewer
19341
19340
  if (oldTexture && !this.isTextureUsed(oldTexture))
19342
19341
  oldTexture.dispose();
19343
19342
  this.setRenderingNeeded();
19344
- console.log("sei prima del resolve");
19345
19343
  resolve();
19346
19344
  }
19347
19345
  });
19348
19346
  }
19349
19347
  else {
19350
- console.log("sei dopo il resolve 2");
19351
19348
  resolve();
19352
19349
  }
19353
19350
  });
@@ -26877,6 +26874,7 @@ __webpack_require__.r(__webpack_exports__);
26877
26874
  /* harmony export */ "Product": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.Product),
26878
26875
  /* harmony export */ "ProductArea": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.ProductArea),
26879
26876
  /* harmony export */ "ProductQuantityRule": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.ProductQuantityRule),
26877
+ /* harmony export */ "QuoteRule": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.QuoteRule),
26880
26878
  /* harmony export */ "Step": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.Step),
26881
26879
  /* harmony export */ "Template": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.Template),
26882
26880
  /* harmony export */ "TemplateArea": () => (/* reexport safe */ _models__WEBPACK_IMPORTED_MODULE_4__.TemplateArea),
@@ -27092,6 +27090,7 @@ __webpack_require__.r(__webpack_exports__);
27092
27090
  /* harmony export */ "Product": () => (/* binding */ Product),
27093
27091
  /* harmony export */ "ProductArea": () => (/* binding */ ProductArea),
27094
27092
  /* harmony export */ "ProductQuantityRule": () => (/* binding */ ProductQuantityRule),
27093
+ /* harmony export */ "QuoteRule": () => (/* binding */ QuoteRule),
27095
27094
  /* harmony export */ "Step": () => (/* binding */ Step),
27096
27095
  /* harmony export */ "Template": () => (/* binding */ Template),
27097
27096
  /* harmony export */ "TemplateArea": () => (/* binding */ TemplateArea),
@@ -27129,6 +27128,7 @@ class Product {
27129
27128
  constructor() {
27130
27129
  this.areas = [];
27131
27130
  this.quantityRule = null;
27131
+ this.quoteRule = null;
27132
27132
  }
27133
27133
  static fromProduct(zkProduct) {
27134
27134
  const product = new Product();
@@ -27138,9 +27138,21 @@ class Product {
27138
27138
  product.previewUrl = zkProduct.get("largeImageUrl");
27139
27139
  product.quantityRule = zkProduct.get("quantityRule") ? ProductQuantityRule.fromQuantityRule(zkProduct.get("quantityRule")) : null;
27140
27140
  product.areas = zkProduct.get("colors").length > 0 ? zkProduct.get("colors").at(0).get("sides").map(side => ProductArea.fromSide(side)) : [];
27141
+ product.quoteRule = zkProduct.get("quoteRule") ? new QuoteRule(zkProduct.get("quoteRule")) : null;
27141
27142
  return product;
27142
27143
  }
27143
27144
  }
27145
+ class QuoteRule {
27146
+ constructor(quoteRule) {
27147
+ this.quoteRuleID = quoteRule.quoteRuleID;
27148
+ this.name = quoteRule.name;
27149
+ this.sellerID = quoteRule.sellerID;
27150
+ this.formControlsData = quoteRule.formControlsData;
27151
+ this.isValidForAllProducts = quoteRule.isValidForAllProducts;
27152
+ this.allowAddToCart = quoteRule.allowAddToCart;
27153
+ this.products = quoteRule.products;
27154
+ }
27155
+ }
27144
27156
  class ProductArea {
27145
27157
  static fromSide(modelSide) {
27146
27158
  let area = new ProductArea();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zakeke-configurator-react",
3
- "version": "0.0.104",
3
+ "version": "0.0.105",
4
4
  "main": "dist/index.js",
5
5
  "module": "dist/index.js",
6
6
  "types": "dist/declarations/composer/Module/src/index.d.ts",