@getlupa/client 0.7.0-alpha-16 → 0.7.0-alpha-17

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.
@@ -26,6 +26,8 @@ export default class TermFacet extends Vue {
26
26
  get facetMin(): number;
27
27
  get facetMax(): number;
28
28
  get statsSummary(): string;
29
+ get separator(): string;
30
+ get sliderInputFormat(): string | undefined;
29
31
  onMinValueChange(): void;
30
32
  onMaxValueChange(): void;
31
33
  handleInputChange(): void;
@@ -14806,7 +14806,7 @@ let TermFacet = class TermFacet extends Vue$1 {
14806
14806
  }
14807
14807
  get fromValue() {
14808
14808
  return this.isPrice
14809
- ? this.sliderRange[0].toFixed(2)
14809
+ ? this.sliderRange[0].toFixed(2).replace(".", this.separator)
14810
14810
  : `${this.sliderRange[0]}`;
14811
14811
  }
14812
14812
  set fromValue(stringValue) {
@@ -14822,7 +14822,7 @@ let TermFacet = class TermFacet extends Vue$1 {
14822
14822
  }
14823
14823
  get toValue() {
14824
14824
  return this.isPrice
14825
- ? this.sliderRange[1].toFixed(2)
14825
+ ? this.sliderRange[1].toFixed(2).replace(".", this.separator)
14826
14826
  : `${this.sliderRange[1]}`;
14827
14827
  }
14828
14828
  set toValue(stringValue) {
@@ -14881,9 +14881,16 @@ let TermFacet = class TermFacet extends Vue$1 {
14881
14881
  get statsSummary() {
14882
14882
  const [min, max] = this.sliderRange;
14883
14883
  return this.isPrice
14884
- ? formatPriceSummary([min, max], this.currency, this.searchResultOptions.labels.priceSeparator)
14884
+ ? formatPriceSummary([min, max], this.currency, this.separator)
14885
14885
  : formatRange({ gte: min, lte: max });
14886
14886
  }
14887
+ get separator() {
14888
+ var _a, _b, _c;
14889
+ return (_c = (_b = (_a = this.searchResultOptions) === null || _a === void 0 ? void 0 : _a.labels) === null || _b === void 0 ? void 0 : _b.priceSeparator) !== null && _c !== void 0 ? _c : ",";
14890
+ }
14891
+ get sliderInputFormat() {
14892
+ return this.isPrice ? `[0-9]+([${this.separator}][0-9]{1,2})?` : undefined;
14893
+ }
14887
14894
  onMinValueChange() {
14888
14895
  this.innerSliderRange = [];
14889
14896
  }
@@ -14974,10 +14981,10 @@ var __vue_render__$N = function () {
14974
14981
  },
14975
14982
  ],
14976
14983
  attrs: {
14977
- type: "number",
14984
+ type: "text",
14978
14985
  max: _vm.facetMax,
14979
14986
  min: _vm.facetMin,
14980
- step: _vm.isPrice ? "0.01" : "1",
14987
+ pattern: _vm.sliderInputFormat,
14981
14988
  },
14982
14989
  domProps: { value: _vm.fromValue },
14983
14990
  on: {
@@ -15014,10 +15021,10 @@ var __vue_render__$N = function () {
15014
15021
  },
15015
15022
  ],
15016
15023
  attrs: {
15017
- type: "number",
15024
+ type: "text",
15018
15025
  max: _vm.facetMax,
15019
15026
  min: _vm.facetMin,
15020
- step: _vm.isPrice ? "0.01" : "1",
15027
+ pattern: _vm.sliderInputFormat,
15021
15028
  },
15022
15029
  domProps: { value: _vm.toValue },
15023
15030
  on: {
@@ -26,6 +26,8 @@ export default class TermFacet extends Vue {
26
26
  get facetMin(): number;
27
27
  get facetMax(): number;
28
28
  get statsSummary(): string;
29
+ get separator(): string;
30
+ get sliderInputFormat(): string | undefined;
29
31
  onMinValueChange(): void;
30
32
  onMaxValueChange(): void;
31
33
  handleInputChange(): void;
@@ -14802,7 +14802,7 @@ let TermFacet = class TermFacet extends Vue$1 {
14802
14802
  }
14803
14803
  get fromValue() {
14804
14804
  return this.isPrice
14805
- ? this.sliderRange[0].toFixed(2)
14805
+ ? this.sliderRange[0].toFixed(2).replace(".", this.separator)
14806
14806
  : `${this.sliderRange[0]}`;
14807
14807
  }
14808
14808
  set fromValue(stringValue) {
@@ -14818,7 +14818,7 @@ let TermFacet = class TermFacet extends Vue$1 {
14818
14818
  }
14819
14819
  get toValue() {
14820
14820
  return this.isPrice
14821
- ? this.sliderRange[1].toFixed(2)
14821
+ ? this.sliderRange[1].toFixed(2).replace(".", this.separator)
14822
14822
  : `${this.sliderRange[1]}`;
14823
14823
  }
14824
14824
  set toValue(stringValue) {
@@ -14877,9 +14877,16 @@ let TermFacet = class TermFacet extends Vue$1 {
14877
14877
  get statsSummary() {
14878
14878
  const [min, max] = this.sliderRange;
14879
14879
  return this.isPrice
14880
- ? formatPriceSummary([min, max], this.currency, this.searchResultOptions.labels.priceSeparator)
14880
+ ? formatPriceSummary([min, max], this.currency, this.separator)
14881
14881
  : formatRange({ gte: min, lte: max });
14882
14882
  }
14883
+ get separator() {
14884
+ var _a, _b, _c;
14885
+ return (_c = (_b = (_a = this.searchResultOptions) === null || _a === void 0 ? void 0 : _a.labels) === null || _b === void 0 ? void 0 : _b.priceSeparator) !== null && _c !== void 0 ? _c : ",";
14886
+ }
14887
+ get sliderInputFormat() {
14888
+ return this.isPrice ? `[0-9]+([${this.separator}][0-9]{1,2})?` : undefined;
14889
+ }
14883
14890
  onMinValueChange() {
14884
14891
  this.innerSliderRange = [];
14885
14892
  }
@@ -14970,10 +14977,10 @@ var __vue_render__$N = function () {
14970
14977
  },
14971
14978
  ],
14972
14979
  attrs: {
14973
- type: "number",
14980
+ type: "text",
14974
14981
  max: _vm.facetMax,
14975
14982
  min: _vm.facetMin,
14976
- step: _vm.isPrice ? "0.01" : "1",
14983
+ pattern: _vm.sliderInputFormat,
14977
14984
  },
14978
14985
  domProps: { value: _vm.fromValue },
14979
14986
  on: {
@@ -15010,10 +15017,10 @@ var __vue_render__$N = function () {
15010
15017
  },
15011
15018
  ],
15012
15019
  attrs: {
15013
- type: "number",
15020
+ type: "text",
15014
15021
  max: _vm.facetMax,
15015
15022
  min: _vm.facetMin,
15016
- step: _vm.isPrice ? "0.01" : "1",
15023
+ pattern: _vm.sliderInputFormat,
15017
15024
  },
15018
15025
  domProps: { value: _vm.toValue },
15019
15026
  on: {
@@ -26,6 +26,8 @@ export default class TermFacet extends Vue {
26
26
  get facetMin(): number;
27
27
  get facetMax(): number;
28
28
  get statsSummary(): string;
29
+ get separator(): string;
30
+ get sliderInputFormat(): string | undefined;
29
31
  onMinValueChange(): void;
30
32
  onMaxValueChange(): void;
31
33
  handleInputChange(): void;