@salla.sa/twilight-components 2.9.37 → 2.9.38

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.
@@ -1441,8 +1441,8 @@ const SallaCartSummary = class {
1441
1441
  this.cartSummaryCount = salla.storage.get('cart.summary.count') || 0;
1442
1442
  this.cartSummaryTotal = salla.storage.get('cart.summary.total') || 0;
1443
1443
  salla.cart.event.onUpdated((response) => {
1444
- this.cartSummaryCount = salla.helpers.number(response.count || 0);
1445
- this.cartSummaryTotal = salla.money(response.total || 0);
1444
+ this.cartSummaryCount = response.count || 0;
1445
+ this.cartSummaryTotal = response.total || 0;
1446
1446
  });
1447
1447
  }
1448
1448
  /**
@@ -20947,7 +20947,7 @@ const SallaRatingStars = class {
20947
20947
  return stars;
20948
20948
  }
20949
20949
  render() {
20950
- return (index$1.h(index$1.Host, null, this.value ?
20950
+ return (index$1.h(index$1.Host, null, this.value || this.value == 0 ?
20951
20951
  index$1.h("div", { class: "s-rating-stars-wrapper" }, " ", this.createStars(this.value), " ")
20952
20952
  :
20953
20953
  index$1.h("div", { class: "s-rating-stars-element", ref: (el) => this.startsElem = el }, index$1.h("input", { type: "hidden", class: "rating_hidden_input", name: this.name, value: "" }), [1, 2, 3, 4, 5].map(star => index$1.h("button", { class: `s-rating-stars-btn-star s-rating-stars-` + this.size, "data-star": star }, index$1.h("span", { innerHTML: Rate }))))));
@@ -9,8 +9,8 @@ export class SallaCartSummary {
9
9
  this.cartSummaryCount = salla.storage.get('cart.summary.count') || 0;
10
10
  this.cartSummaryTotal = salla.storage.get('cart.summary.total') || 0;
11
11
  salla.cart.event.onUpdated((response) => {
12
- this.cartSummaryCount = salla.helpers.number(response.count || 0);
13
- this.cartSummaryTotal = salla.money(response.total || 0);
12
+ this.cartSummaryCount = response.count || 0;
13
+ this.cartSummaryTotal = response.total || 0;
14
14
  });
15
15
  }
16
16
  /**
@@ -59,7 +59,7 @@ export class SallaRatingStars {
59
59
  return stars;
60
60
  }
61
61
  render() {
62
- return (h(Host, null, this.value ?
62
+ return (h(Host, null, this.value || this.value == 0 ?
63
63
  h("div", { class: "s-rating-stars-wrapper" },
64
64
  " ",
65
65
  this.createStars(this.value),
@@ -14,8 +14,8 @@ const SallaCartSummary$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLEl
14
14
  this.cartSummaryCount = salla.storage.get('cart.summary.count') || 0;
15
15
  this.cartSummaryTotal = salla.storage.get('cart.summary.total') || 0;
16
16
  salla.cart.event.onUpdated((response) => {
17
- this.cartSummaryCount = salla.helpers.number(response.count || 0);
18
- this.cartSummaryTotal = salla.money(response.total || 0);
17
+ this.cartSummaryCount = response.count || 0;
18
+ this.cartSummaryTotal = response.total || 0;
19
19
  });
20
20
  }
21
21
  /**
@@ -64,7 +64,7 @@ const SallaRatingStars = /*@__PURE__*/ proxyCustomElement(class extends HTMLElem
64
64
  return stars;
65
65
  }
66
66
  render() {
67
- return (h(Host, null, this.value ?
67
+ return (h(Host, null, this.value || this.value == 0 ?
68
68
  h("div", { class: "s-rating-stars-wrapper" }, " ", this.createStars(this.value), " ")
69
69
  :
70
70
  h("div", { class: "s-rating-stars-element", ref: (el) => this.startsElem = el }, h("input", { type: "hidden", class: "rating_hidden_input", name: this.name, value: "" }), [1, 2, 3, 4, 5].map(star => h("button", { class: `s-rating-stars-btn-star s-rating-stars-` + this.size, "data-star": star }, h("span", { innerHTML: Rate }))))));
@@ -1437,8 +1437,8 @@ const SallaCartSummary = class {
1437
1437
  this.cartSummaryCount = salla.storage.get('cart.summary.count') || 0;
1438
1438
  this.cartSummaryTotal = salla.storage.get('cart.summary.total') || 0;
1439
1439
  salla.cart.event.onUpdated((response) => {
1440
- this.cartSummaryCount = salla.helpers.number(response.count || 0);
1441
- this.cartSummaryTotal = salla.money(response.total || 0);
1440
+ this.cartSummaryCount = response.count || 0;
1441
+ this.cartSummaryTotal = response.total || 0;
1442
1442
  });
1443
1443
  }
1444
1444
  /**
@@ -20943,7 +20943,7 @@ const SallaRatingStars = class {
20943
20943
  return stars;
20944
20944
  }
20945
20945
  render() {
20946
- return (h(Host, null, this.value ?
20946
+ return (h(Host, null, this.value || this.value == 0 ?
20947
20947
  h("div", { class: "s-rating-stars-wrapper" }, " ", this.createStars(this.value), " ")
20948
20948
  :
20949
20949
  h("div", { class: "s-rating-stars-element", ref: (el) => this.startsElem = el }, h("input", { type: "hidden", class: "rating_hidden_input", name: this.name, value: "" }), [1, 2, 3, 4, 5].map(star => h("button", { class: `s-rating-stars-btn-star s-rating-stars-` + this.size, "data-star": star }, h("span", { innerHTML: Rate }))))));