@empathyco/x-components 9.3.2 → 9.4.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.
- package/CHANGELOG.md +7 -0
- package/docs/API-reference/api/x-components.basecurrency.md +2 -0
- package/docs/API-reference/api/x-components.basepricefilterlabel.md +2 -0
- package/docs/API-reference/api/x-components.baseresultcurrentprice.md +2 -0
- package/docs/API-reference/api/x-components.baseresultpreviousprice.md +2 -0
- package/docs/API-reference/components/common/currency/x-components.base-currency.md +19 -0
- package/docs/API-reference/components/common/filters/labels/x-components.base-price-filter-label.md +37 -0
- package/docs/API-reference/components/common/result/x-components.base-result-current-price.md +21 -0
- package/docs/API-reference/components/common/result/x-components.base-result-previous-price.md +22 -0
- package/js/components/currency/base-currency.vue.js.map +1 -1
- package/js/components/currency/base-currency.vue2.js +8 -1
- package/js/components/currency/base-currency.vue2.js.map +1 -1
- package/js/components/filters/labels/base-price-filter-label.vue.js +8 -0
- package/js/components/filters/labels/base-price-filter-label.vue.js.map +1 -1
- package/js/components/result/base-result-current-price.vue.js +3 -2
- package/js/components/result/base-result-current-price.vue.js.map +1 -1
- package/js/components/result/base-result-current-price.vue2.js +6 -0
- package/js/components/result/base-result-current-price.vue2.js.map +1 -1
- package/js/components/result/base-result-previous-price.vue.js +3 -2
- package/js/components/result/base-result-previous-price.vue.js.map +1 -1
- package/js/components/result/base-result-previous-price.vue2.js +6 -0
- package/js/components/result/base-result-previous-price.vue2.js.map +1 -1
- package/package.json +2 -2
- package/report/x-components.api.json +84 -12
- package/report/x-components.api.md +8 -0
- package/types/src/components/currency/base-currency.vue.d.ts +12 -0
- package/types/src/components/currency/base-currency.vue.d.ts.map +1 -1
- package/types/src/components/filters/labels/base-price-filter-label.vue.d.ts +12 -0
- package/types/src/components/filters/labels/base-price-filter-label.vue.d.ts.map +1 -1
- package/types/src/components/result/base-result-current-price.vue.d.ts +12 -0
- package/types/src/components/result/base-result-current-price.vue.d.ts.map +1 -1
- package/types/src/components/result/base-result-previous-price.vue.d.ts +12 -0
- package/types/src/components/result/base-result-previous-price.vue.d.ts.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,13 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [9.4.0](https://github.com/empathyco/x/compare/@empathyco/x-components@9.3.2...@empathyco/x-components@9.4.0) (2026-10-12)
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* add locale prop to currency components for customizable formatting (#2186)
|
|
11
|
+
|
|
12
|
+
|
|
6
13
|
## [9.3.2](https://github.com/empathyco/x/compare/@empathyco/x-components@9.3.1...@empathyco/x-components@9.3.2) (2026-10-09)
|
|
7
14
|
|
|
8
15
|
### Code Refactoring
|
|
@@ -17,6 +17,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
17
17
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
18
18
|
default: () => {};
|
|
19
19
|
};
|
|
20
|
+
locale: StringConstructor;
|
|
20
21
|
}>, {
|
|
21
22
|
currencyText: import("vue").ComputedRef<string>;
|
|
22
23
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
@@ -29,6 +30,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
29
30
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
30
31
|
default: () => {};
|
|
31
32
|
};
|
|
33
|
+
locale: StringConstructor;
|
|
32
34
|
}>> & Readonly<{}>, {
|
|
33
35
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
34
36
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>
|
|
@@ -18,6 +18,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
18
18
|
};
|
|
19
19
|
currency: StringConstructor;
|
|
20
20
|
format: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
21
|
+
locale: StringConstructor;
|
|
21
22
|
lessThan: {
|
|
22
23
|
type: StringConstructor;
|
|
23
24
|
required: true;
|
|
@@ -41,6 +42,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
41
42
|
};
|
|
42
43
|
currency: StringConstructor;
|
|
43
44
|
format: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
45
|
+
locale: StringConstructor;
|
|
44
46
|
lessThan: {
|
|
45
47
|
type: StringConstructor;
|
|
46
48
|
required: true;
|
|
@@ -19,6 +19,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
19
19
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
20
20
|
default: () => {};
|
|
21
21
|
};
|
|
22
|
+
locale: StringConstructor;
|
|
22
23
|
}>, {
|
|
23
24
|
dynamicClasses: import("vue").ComputedRef<VueCSSClasses>;
|
|
24
25
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
@@ -31,6 +32,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
31
32
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
32
33
|
default: () => {};
|
|
33
34
|
};
|
|
35
|
+
locale: StringConstructor;
|
|
34
36
|
}>> & Readonly<{}>, {
|
|
35
37
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
36
38
|
}, {}, {
|
|
@@ -19,6 +19,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
19
19
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
20
20
|
default: () => {};
|
|
21
21
|
};
|
|
22
|
+
locale: StringConstructor;
|
|
22
23
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
23
24
|
result: {
|
|
24
25
|
type: PropType<Result>;
|
|
@@ -29,6 +30,7 @@ _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
|
29
30
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
30
31
|
default: () => {};
|
|
31
32
|
};
|
|
33
|
+
locale: StringConstructor;
|
|
32
34
|
}>> & Readonly<{}>, {
|
|
33
35
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
34
36
|
}, {}, {
|
|
@@ -13,6 +13,7 @@ title: BaseCurrency
|
|
|
13
13
|
| <code>value</code> | Numeric value to be formatted. | <code>number</code> | <code></code> |
|
|
14
14
|
| <code>currency</code> | The ISO 4217 currency value. If not specified we use snippetConfig.currency | <code>string</code> | <code></code> |
|
|
15
15
|
| <code>format</code> | The currency format possibilities from Intl.NumberFormatOptions.<br />Allows customization of decimal places, grouping, etc.<br />Note: 'currency' and 'style' options are managed internally. | <code>Omit<Intl.NumberFormatOptions, 'currency' \| 'style'></code> | <code>() => ({})</code> |
|
|
16
|
+
| <code>locale</code> | Locale used to format the value. If not specified we use snippetConfig.uiLang | <code>string</code> | <code></code> |
|
|
16
17
|
|
|
17
18
|
## Example
|
|
18
19
|
|
|
@@ -110,3 +111,21 @@ internally):
|
|
|
110
111
|
import BaseCurrency from "@empathyco/x-components/js/components/currency/base-currency.vue";
|
|
111
112
|
</script>
|
|
112
113
|
```
|
|
114
|
+
|
|
115
|
+
### Using a different locale
|
|
116
|
+
|
|
117
|
+
By default the currency is formatted using the `uiLang` of the `snippetConfig`. You can format
|
|
118
|
+
the value in a different locale using the `locale` prop:
|
|
119
|
+
|
|
120
|
+
```vue
|
|
121
|
+
<template>
|
|
122
|
+
<!-- output: '€1,234.56' even if snippetConfig.uiLang is 'es-ES' -->
|
|
123
|
+
<BaseCurrency :value="1234.56" currency="EUR" locale="en-US" />
|
|
124
|
+
<!-- output: '1234,56 €' for snippetConfig.uiLang 'es-ES' -->
|
|
125
|
+
<BaseCurrency :value="1234.56" currency="EUR" />
|
|
126
|
+
</template>
|
|
127
|
+
|
|
128
|
+
<script setup>
|
|
129
|
+
import BaseCurrency from "@empathyco/x-components/js/components/currency/base-currency.vue";
|
|
130
|
+
</script>
|
|
131
|
+
```
|
package/docs/API-reference/components/common/filters/labels/x-components.base-price-filter-label.md
CHANGED
|
@@ -16,6 +16,7 @@ value of the filter.
|
|
|
16
16
|
| <code>filter</code> | The filter data for get min and max value. | <code>{ range: RangeValue }</code> | <code></code> |
|
|
17
17
|
| <code>currency</code> | An ISO 4217 currency value. | <code>string</code> | <code></code> |
|
|
18
18
|
| <code>format</code> | The currency format possibilities from Intl.NumberFormatOptions.<br />Allows customization of decimal places, grouping, etc. | <code>Omit<Intl.NumberFormatOptions, 'currency' \| 'style'></code> | <code></code> |
|
|
19
|
+
| <code>locale</code> | Locale used to format the currency. If not specified we use snippetConfig.uiLang | <code>string</code> | <code></code> |
|
|
19
20
|
| <code>lessThan</code> | Message shown when the filter hasn't got the min value defined. | <code>string</code> | <code></code> |
|
|
20
21
|
| <code>fromTo</code> | Message shown when the filter has both the min and max values defined. | <code>string</code> | <code></code> |
|
|
21
22
|
| <code>from</code> | Message shown when the filter hasn't got max value defined. | <code>string</code> | <code></code> |
|
|
@@ -99,3 +100,39 @@ import {
|
|
|
99
100
|
} from "@empathyco/x-components/facets";
|
|
100
101
|
</script>
|
|
101
102
|
```
|
|
103
|
+
|
|
104
|
+
### Using a different locale
|
|
105
|
+
|
|
106
|
+
By default the prices are formatted using the `uiLang` of the `snippetConfig`. If you want to
|
|
107
|
+
format them in a different locale, you can pass the `locale` prop:
|
|
108
|
+
|
|
109
|
+
```vue
|
|
110
|
+
<template>
|
|
111
|
+
<Facets>
|
|
112
|
+
<template #price="{ facet }">
|
|
113
|
+
<Filters v-slot="{ filter }" :filters="facet.filters">
|
|
114
|
+
<NumberRangeFilter :filter="filter" v-slot="{ filter }">
|
|
115
|
+
<!-- output: 'From $10.00 to $300.00' even if snippetConfig.uiLang is 'es-ES' -->
|
|
116
|
+
<BasePriceFilterLabel
|
|
117
|
+
:filter="filter"
|
|
118
|
+
currency="USD"
|
|
119
|
+
locale="en-US"
|
|
120
|
+
lessThan="Less than {max}"
|
|
121
|
+
fromTo="From {min} to {max}"
|
|
122
|
+
from="More than {min}"
|
|
123
|
+
/>
|
|
124
|
+
</NumberRangeFilter>
|
|
125
|
+
</Filters>
|
|
126
|
+
</template>
|
|
127
|
+
</Facets>
|
|
128
|
+
</template>
|
|
129
|
+
|
|
130
|
+
<script setup>
|
|
131
|
+
import BasePriceFilterLabel from "@empathyco/x-components/js/components/filters/labels/base-price-filter-label.vue";
|
|
132
|
+
import {
|
|
133
|
+
Filters,
|
|
134
|
+
Facets,
|
|
135
|
+
NumberRangeFilter,
|
|
136
|
+
} from "@empathyco/x-components/facets";
|
|
137
|
+
</script>
|
|
138
|
+
```
|
package/docs/API-reference/components/common/result/x-components.base-result-current-price.md
CHANGED
|
@@ -16,6 +16,7 @@ that may or may not be on sale.
|
|
|
16
16
|
| <code>result</code> | (Required) The @empathyco/x-types#Result information. | <code>Result</code> | <code></code> |
|
|
17
17
|
| <code>currency</code> | Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes. | <code>string</code> | <code></code> |
|
|
18
18
|
| <code>format</code> | The currency format possibilities from Intl.NumberFormatOptions.<br />Allows customization of decimal places, grouping, etc. | <code>Omit<Intl.NumberFormatOptions, 'currency' \| 'style'></code> | <code>() => ({})</code> |
|
|
19
|
+
| <code>locale</code> | Locale used to format the currency. If not specified we use snippetConfig.uiLang | <code>string</code> | <code></code> |
|
|
19
20
|
|
|
20
21
|
## Slots
|
|
21
22
|
|
|
@@ -66,6 +67,26 @@ const result = {
|
|
|
66
67
|
</script>
|
|
67
68
|
```
|
|
68
69
|
|
|
70
|
+
### Using a different locale
|
|
71
|
+
|
|
72
|
+
By default the price is formatted using the `uiLang` of the `snippetConfig`. If you want to
|
|
73
|
+
format the price in a different locale, you can pass the `locale` prop:
|
|
74
|
+
|
|
75
|
+
```vue
|
|
76
|
+
<template>
|
|
77
|
+
<!-- output: '$123.45' even if snippetConfig.uiLang is 'es-ES' -->
|
|
78
|
+
<BaseResultCurrentPrice :result="result" currency="USD" locale="en-US" />
|
|
79
|
+
</template>
|
|
80
|
+
|
|
81
|
+
<script setup>
|
|
82
|
+
import { BaseResultCurrentPrice } from "@empathyco/x-components";
|
|
83
|
+
const result = {
|
|
84
|
+
price: { value: 123.45, hasDiscount: false },
|
|
85
|
+
// ...other result properties
|
|
86
|
+
};
|
|
87
|
+
</script>
|
|
88
|
+
```
|
|
89
|
+
|
|
69
90
|
### Overriding default slot
|
|
70
91
|
|
|
71
92
|
```vue
|
package/docs/API-reference/components/common/result/x-components.base-result-previous-price.md
CHANGED
|
@@ -15,6 +15,7 @@ Component that renders the @empathyco/x-types#Result previous price.
|
|
|
15
15
|
| <code>result</code> | (Required) The @empathyco/x-types#Result information. | <code>Result</code> | <code></code> |
|
|
16
16
|
| <code>currency</code> | Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes. | <code>string</code> | <code></code> |
|
|
17
17
|
| <code>format</code> | The currency format possibilities from Intl.NumberFormatOptions.<br />Allows customization of decimal places, grouping, etc. | <code>Omit<Intl.NumberFormatOptions, 'currency' \| 'style'></code> | <code>() => ({})</code> |
|
|
18
|
+
| <code>locale</code> | Locale used to format the currency. If not specified we use snippetConfig.uiLang | <code>string</code> | <code></code> |
|
|
18
19
|
|
|
19
20
|
## Slots
|
|
20
21
|
|
|
@@ -67,6 +68,27 @@ const result = {
|
|
|
67
68
|
</script>
|
|
68
69
|
```
|
|
69
70
|
|
|
71
|
+
### Using a different locale
|
|
72
|
+
|
|
73
|
+
By default the price is formatted using the `uiLang` of the `snippetConfig`. If you want to
|
|
74
|
+
format the price in a different locale, you can pass the `locale` prop:
|
|
75
|
+
|
|
76
|
+
```vue
|
|
77
|
+
<template>
|
|
78
|
+
<!-- output: '$199.99' even if snippetConfig.uiLang is 'es-ES' -->
|
|
79
|
+
<BaseResultPreviousPrice :result="result" currency="USD" locale="en-US" />
|
|
80
|
+
</template>
|
|
81
|
+
|
|
82
|
+
<script setup>
|
|
83
|
+
import { BaseResultPreviousPrice } from "@empathyco/x-components";
|
|
84
|
+
|
|
85
|
+
const result = {
|
|
86
|
+
price: { originalValue: 199.99, hasDiscount: true },
|
|
87
|
+
// ...other result properties
|
|
88
|
+
};
|
|
89
|
+
</script>
|
|
90
|
+
```
|
|
91
|
+
|
|
70
92
|
### Overriding default slot
|
|
71
93
|
|
|
72
94
|
```vue
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-currency.vue.js","sources":["../../../../src/components/currency/base-currency.vue"],"sourcesContent":["<template>\n <span class=\"x-currency\">{{ currencyText }}</span>\n</template>\n\n<script lang=\"ts\">\nimport type { SnippetConfig } from '@x/x-installer'\nimport type { PropType } from 'vue'\nimport { computed, defineComponent, inject } from 'vue'\n\nexport default defineComponent({\n props: {\n /**\n * Numeric value to be formatted.\n *\n * @remarks Pass the value with 'v-bind:value' (or ':value' shortcut) instead of plain string.\n * @remarks Be careful using numbers under Number.MAX_SAFE_INTEGER to avoid unexpected errors.\n *\n * @public\n */\n value: {\n type: Number,\n required: true,\n },\n\n /**\n * The ISO 4217 currency value. If not specified we use snippetConfig.currency\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n * Note: 'currency' and 'style' options are managed internally.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n },\n\n setup(props) {\n const snippetConfig = inject<SnippetConfig>('snippetConfig')\n\n const currencyText = computed<string>(() => {\n const currency = props.currency ?? snippetConfig?.currency ?? 'EUR'\n return Intl.NumberFormat(
|
|
1
|
+
{"version":3,"file":"base-currency.vue.js","sources":["../../../../src/components/currency/base-currency.vue"],"sourcesContent":["<template>\n <span class=\"x-currency\">{{ currencyText }}</span>\n</template>\n\n<script lang=\"ts\">\nimport type { SnippetConfig } from '@x/x-installer'\nimport type { PropType } from 'vue'\nimport { computed, defineComponent, inject } from 'vue'\n\nexport default defineComponent({\n props: {\n /**\n * Numeric value to be formatted.\n *\n * @remarks Pass the value with 'v-bind:value' (or ':value' shortcut) instead of plain string.\n * @remarks Be careful using numbers under Number.MAX_SAFE_INTEGER to avoid unexpected errors.\n *\n * @public\n */\n value: {\n type: Number,\n required: true,\n },\n\n /**\n * The ISO 4217 currency value. If not specified we use snippetConfig.currency\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n * Note: 'currency' and 'style' options are managed internally.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n /**\n * Locale used to format the value. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n },\n\n setup(props) {\n const snippetConfig = inject<SnippetConfig>('snippetConfig')\n\n const currencyText = computed<string>(() => {\n const currency = props.currency ?? snippetConfig?.currency ?? 'EUR'\n const locale = props.locale ?? snippetConfig?.uiLang\n return Intl.NumberFormat(locale, {\n style: 'currency',\n ...props.format,\n currency,\n }).format(props.value)\n })\n\n return {\n currencyText,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Example\n\nRenders the value received as a property, which always must be a JavaScript number, formatted\nusing the Intl.NumberFormat API with ISO 4217 currency codes. The rendered tag is a span in order\nto render a default inline HTML element.\n\n### Basic usage\n\n```vue\n<template>\n <BaseCurrency :value=\"12345678.87654321\" currency=\"EUR\" />\n <!-- output depends on locale, e.g., '12.345.678,88 €' for es-ES -->\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Customizing decimal places\n\n```vue\n<template>\n <BaseCurrency\n :value=\"12345678.87654321\"\n currency=\"USD\"\n :format=\"{ minimumFractionDigits: 3, maximumFractionDigits: 3 }\"\n />\n <!-- output: '$12,345,678.877' for en-US locale -->\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### No decimal places\n\n```vue\n<template>\n <BaseCurrency\n :value=\"12345678.87\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 0, maximumFractionDigits: 0 }\"\n />\n <!-- output: '12.345.679 €' for es-ES locale (rounds up) -->\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Using different currencies\n\n```vue\n<template>\n <div>\n <BaseCurrency :value=\"1234.56\" currency=\"USD\" />\n <!-- output: '$1,234.56' for en-US -->\n <BaseCurrency :value=\"1234.56\" currency=\"EUR\" />\n <!-- output: '1.234,56 €' for es-ES -->\n <BaseCurrency :value=\"1234.56\" currency=\"GBP\" />\n <!-- output: '£1,234.56' for en-GB -->\n <BaseCurrency :value=\"1234.56\" currency=\"JPY\" />\n <!-- output: '¥1,235' for ja-JP -->\n </div>\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Advanced formatting options\n\nYou can pass any valid Intl.NumberFormatOptions (except 'currency' and 'style' which are managed\ninternally):\n\n```vue\n<template>\n <BaseCurrency\n :value=\"1234567.89\"\n currency=\"EUR\"\n :format=\"{\n minimumFractionDigits: 2,\n maximumFractionDigits: 4,\n useGrouping: true,\n }\"\n />\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Using a different locale\n\nBy default the currency is formatted using the `uiLang` of the `snippetConfig`. You can format\nthe value in a different locale using the `locale` prop:\n\n```vue\n<template>\n <!-- output: '€1,234.56' even if snippetConfig.uiLang is 'es-ES' -->\n <BaseCurrency :value=\"1234.56\" currency=\"EUR\" locale=\"en-US\" />\n <!-- output: '1234,56 €' for snippetConfig.uiLang 'es-ES' -->\n <BaseCurrency :value=\"1234.56\" currency=\"EUR\" />\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_toDisplayString"],"mappings":";;;;AACQ,MAAA,UAAA,GAAA,EAAA,KAAA,EAAM,YAAA,EAAY;;AAAxB,EAAA,OAAAA,SAAA,EAAA,EAAAC,kBAAA;AAAA,IAAkD,MAAA;AAAA,IAAlD,UAAA;AAAA,IAAkDC,gBAAtB,IAAA,CAAA,YAAY,CAAA;AAAA,IAAA;AAAA;AAAA,GAAA;;;;;;"}
|
|
@@ -31,12 +31,19 @@ var _sfc_main = defineComponent({
|
|
|
31
31
|
type: Object,
|
|
32
32
|
default: () => ({}),
|
|
33
33
|
},
|
|
34
|
+
/**
|
|
35
|
+
* Locale used to format the value. If not specified we use snippetConfig.uiLang
|
|
36
|
+
*
|
|
37
|
+
* @public
|
|
38
|
+
*/
|
|
39
|
+
locale: String,
|
|
34
40
|
},
|
|
35
41
|
setup(props) {
|
|
36
42
|
const snippetConfig = inject('snippetConfig');
|
|
37
43
|
const currencyText = computed(() => {
|
|
38
44
|
const currency = props.currency ?? snippetConfig?.currency ?? 'EUR';
|
|
39
|
-
|
|
45
|
+
const locale = props.locale ?? snippetConfig?.uiLang;
|
|
46
|
+
return Intl.NumberFormat(locale, {
|
|
40
47
|
style: 'currency',
|
|
41
48
|
...props.format,
|
|
42
49
|
currency,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-currency.vue2.js","sources":["../../../../src/components/currency/base-currency.vue"],"sourcesContent":["<template>\n <span class=\"x-currency\">{{ currencyText }}</span>\n</template>\n\n<script lang=\"ts\">\nimport type { SnippetConfig } from '@x/x-installer'\nimport type { PropType } from 'vue'\nimport { computed, defineComponent, inject } from 'vue'\n\nexport default defineComponent({\n props: {\n /**\n * Numeric value to be formatted.\n *\n * @remarks Pass the value with 'v-bind:value' (or ':value' shortcut) instead of plain string.\n * @remarks Be careful using numbers under Number.MAX_SAFE_INTEGER to avoid unexpected errors.\n *\n * @public\n */\n value: {\n type: Number,\n required: true,\n },\n\n /**\n * The ISO 4217 currency value. If not specified we use snippetConfig.currency\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n * Note: 'currency' and 'style' options are managed internally.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n },\n\n setup(props) {\n const snippetConfig = inject<SnippetConfig>('snippetConfig')\n\n const currencyText = computed<string>(() => {\n const currency = props.currency ?? snippetConfig?.currency ?? 'EUR'\n return Intl.NumberFormat(
|
|
1
|
+
{"version":3,"file":"base-currency.vue2.js","sources":["../../../../src/components/currency/base-currency.vue"],"sourcesContent":["<template>\n <span class=\"x-currency\">{{ currencyText }}</span>\n</template>\n\n<script lang=\"ts\">\nimport type { SnippetConfig } from '@x/x-installer'\nimport type { PropType } from 'vue'\nimport { computed, defineComponent, inject } from 'vue'\n\nexport default defineComponent({\n props: {\n /**\n * Numeric value to be formatted.\n *\n * @remarks Pass the value with 'v-bind:value' (or ':value' shortcut) instead of plain string.\n * @remarks Be careful using numbers under Number.MAX_SAFE_INTEGER to avoid unexpected errors.\n *\n * @public\n */\n value: {\n type: Number,\n required: true,\n },\n\n /**\n * The ISO 4217 currency value. If not specified we use snippetConfig.currency\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n * Note: 'currency' and 'style' options are managed internally.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n /**\n * Locale used to format the value. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n },\n\n setup(props) {\n const snippetConfig = inject<SnippetConfig>('snippetConfig')\n\n const currencyText = computed<string>(() => {\n const currency = props.currency ?? snippetConfig?.currency ?? 'EUR'\n const locale = props.locale ?? snippetConfig?.uiLang\n return Intl.NumberFormat(locale, {\n style: 'currency',\n ...props.format,\n currency,\n }).format(props.value)\n })\n\n return {\n currencyText,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Example\n\nRenders the value received as a property, which always must be a JavaScript number, formatted\nusing the Intl.NumberFormat API with ISO 4217 currency codes. The rendered tag is a span in order\nto render a default inline HTML element.\n\n### Basic usage\n\n```vue\n<template>\n <BaseCurrency :value=\"12345678.87654321\" currency=\"EUR\" />\n <!-- output depends on locale, e.g., '12.345.678,88 €' for es-ES -->\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Customizing decimal places\n\n```vue\n<template>\n <BaseCurrency\n :value=\"12345678.87654321\"\n currency=\"USD\"\n :format=\"{ minimumFractionDigits: 3, maximumFractionDigits: 3 }\"\n />\n <!-- output: '$12,345,678.877' for en-US locale -->\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### No decimal places\n\n```vue\n<template>\n <BaseCurrency\n :value=\"12345678.87\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 0, maximumFractionDigits: 0 }\"\n />\n <!-- output: '12.345.679 €' for es-ES locale (rounds up) -->\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Using different currencies\n\n```vue\n<template>\n <div>\n <BaseCurrency :value=\"1234.56\" currency=\"USD\" />\n <!-- output: '$1,234.56' for en-US -->\n <BaseCurrency :value=\"1234.56\" currency=\"EUR\" />\n <!-- output: '1.234,56 €' for es-ES -->\n <BaseCurrency :value=\"1234.56\" currency=\"GBP\" />\n <!-- output: '£1,234.56' for en-GB -->\n <BaseCurrency :value=\"1234.56\" currency=\"JPY\" />\n <!-- output: '¥1,235' for ja-JP -->\n </div>\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Advanced formatting options\n\nYou can pass any valid Intl.NumberFormatOptions (except 'currency' and 'style' which are managed\ninternally):\n\n```vue\n<template>\n <BaseCurrency\n :value=\"1234567.89\"\n currency=\"EUR\"\n :format=\"{\n minimumFractionDigits: 2,\n maximumFractionDigits: 4,\n useGrouping: true,\n }\"\n />\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n\n### Using a different locale\n\nBy default the currency is formatted using the `uiLang` of the `snippetConfig`. You can format\nthe value in a different locale using the `locale` prop:\n\n```vue\n<template>\n <!-- output: '€1,234.56' even if snippetConfig.uiLang is 'es-ES' -->\n <BaseCurrency :value=\"1234.56\" currency=\"EUR\" locale=\"en-US\" />\n <!-- output: '1234,56 €' for snippetConfig.uiLang 'es-ES' -->\n <BaseCurrency :value=\"1234.56\" currency=\"EUR\" />\n</template>\n\n<script setup>\nimport BaseCurrency from '@empathyco/x-components/js/components/currency/base-currency.vue'\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;AASA,gBAAe,eAAe,CAAC;AAC7B,IAAA,KAAK,EAAE;AACL;;;;;;;AAOE;AACF,QAAA,KAAK,EAAE;AACL,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AAED;;;;AAIE;AACF,QAAA,QAAQ,EAAE,MAAM;AAChB;;;;;;AAME;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAwE;AAC9E,YAAA,OAAO,EAAE,OAAO,EAAE,CAAC;AACpB,SAAA;AACD;;;;AAIE;AACF,QAAA,MAAM,EAAE,MAAM;AACf,KAAA;AAED,IAAA,KAAK,CAAC,KAAK,EAAA;AACT,QAAA,MAAM,aAAY,GAAI,MAAM,CAAgB,eAAe,CAAA;AAE3D,QAAA,MAAM,eAAe,QAAQ,CAAS,MAAI;YACxC,MAAM,QAAO,GAAI,KAAK,CAAC,QAAO,IAAK,aAAa,EAAE,QAAO,IAAK,KAAI;YAClE,MAAM,MAAK,GAAI,KAAK,CAAC,UAAU,aAAa,EAAE,MAAK;AACnD,YAAA,OAAO,IAAI,CAAC,YAAY,CAAC,MAAM,EAAE;AAC/B,gBAAA,KAAK,EAAE,UAAU;gBACjB,GAAG,KAAK,CAAC,MAAM;gBACf,QAAQ;AACT,aAAA,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,CAAA;AACvB,QAAA,CAAC,CAAA;QAED,OAAO;YACL,YAAY;SACd;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
@@ -28,6 +28,12 @@ var _sfc_main = defineComponent({
|
|
|
28
28
|
* @public
|
|
29
29
|
*/
|
|
30
30
|
format: Object,
|
|
31
|
+
/**
|
|
32
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
33
|
+
*
|
|
34
|
+
* @public
|
|
35
|
+
*/
|
|
36
|
+
locale: String,
|
|
31
37
|
/**
|
|
32
38
|
* Message shown when the filter hasn't got the min value defined.
|
|
33
39
|
*
|
|
@@ -78,6 +84,7 @@ var _sfc_main = defineComponent({
|
|
|
78
84
|
value: props.filter.range.min,
|
|
79
85
|
currency: props.currency,
|
|
80
86
|
format: props.format,
|
|
87
|
+
locale: props.locale,
|
|
81
88
|
});
|
|
82
89
|
}
|
|
83
90
|
else if (partMessage === '{max}') {
|
|
@@ -85,6 +92,7 @@ var _sfc_main = defineComponent({
|
|
|
85
92
|
value: props.filter.range.max,
|
|
86
93
|
currency: props.currency,
|
|
87
94
|
format: props.format,
|
|
95
|
+
locale: props.locale,
|
|
88
96
|
});
|
|
89
97
|
}
|
|
90
98
|
return partMessage;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-price-filter-label.vue.js","sources":["../../../../../src/components/filters/labels/base-price-filter-label.vue"],"sourcesContent":["<script lang=\"ts\">\nimport type { RangeValue } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport { computed, defineComponent, h } from 'vue'\nimport BaseCurrency from '../../currency/base-currency.vue'\n\n/**\n * Renders a label for a price filter, allowing to select different messages depending on the\n * value of the filter.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /** The filter data for get min and max value. */\n filter: {\n type: Object as PropType<{ range: RangeValue }>,\n required: true,\n },\n /**\n * An ISO 4217 currency value.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n /**\n * Message shown when the filter hasn't got the min value defined.\n *\n * @public\n */\n lessThan: {\n type: String,\n required: true,\n },\n /**\n * Message shown when the filter has both the min and max values defined.\n *\n * @public\n */\n fromTo: {\n type: String,\n required: true,\n },\n /**\n * Message shown when the filter hasn't got max value defined.\n *\n * @public\n */\n from: {\n type: String,\n required: true,\n },\n },\n setup(props) {\n /**\n * The active label, retrieved from the provided props.\n * It depends on the min and max values of the filter.\n *\n * @returns The active label to be formatted with the min and max values of the filter.\n */\n const label = computed<string>(() => {\n return props.filter.range.min === null\n ? props.lessThan\n : props.filter.range.max === null\n ? props.from\n : props.fromTo\n })\n\n return () => {\n const labelParts = label.value.split(/(\\{min\\}|\\{max\\})/)\n\n const children = labelParts.map(partMessage => {\n if (partMessage === '{min}') {\n return h(BaseCurrency, {\n value: props.filter.range.min as number,\n currency: props.currency,\n format: props.format,\n })\n } else if (partMessage === '{max}') {\n return h(BaseCurrency, {\n value: props.filter.range.max as number,\n currency: props.currency,\n format: props.format,\n })\n }\n return partMessage\n })\n\n return h('span', { class: 'x-price-filter-label' }, children)\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Example\n\nRenders a label for a price filter, allowing to select different messages depending on the value of\nthe filter.\n\n- When the `min` value property isn't defined in the filter, you can show a message like\n `Less than $10` by using the `lessThan` prop, combined with the `{max}` placeholder.\n- When the `max` value property isn't defined in the filter, you can show a message like\n `More than $300` by using the `from` prop, combined with the `{min}` placeholder.\n- If both the `min` and `max` values of the filter are defined, you can show a message like\n `$10 - $300` by using the `fromTo` prop.\n\nThis component uses internally the `BaseCurrency` one, so you can pass the same props to configure\nhow the price should look like.\n\n### Basic usage\n\n```vue\n<template>\n <Facets>\n <template #price=\"{ facet }\">\n <Filters v-slot=\"{ filter }\" :filters=\"facet.filters\">\n <NumberRangeFilter :filter=\"filter\" v-slot=\"{ filter }\">\n <BasePriceFilterLabel\n :filter=\"filter\"\n currency=\"USD\"\n lessThan=\"Less than {max}\"\n fromTo=\"From {min} to {max}\"\n from=\"More than {min}\"\n />\n </NumberRangeFilter>\n </Filters>\n </template>\n </Facets>\n</template>\n\n<script setup>\nimport BasePriceFilterLabel from '@empathyco/x-components/js/components/filters/labels/base-price-filter-label.vue'\nimport { Filters, Facets, NumberRangeFilter } from '@empathyco/x-components/facets'\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <Facets>\n <template #price=\"{ facet }\">\n <Filters v-slot=\"{ filter }\" :filters=\"facet.filters\">\n <NumberRangeFilter :filter=\"filter\" v-slot=\"{ filter }\">\n <BasePriceFilterLabel\n :filter=\"filter\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 0, maximumFractionDigits: 0 }\"\n lessThan=\"Less than {max}\"\n fromTo=\"From {min} to {max}\"\n from=\"More than {min}\"\n />\n </NumberRangeFilter>\n </Filters>\n </template>\n </Facets>\n</template>\n\n<script setup>\nimport BasePriceFilterLabel from '@empathyco/x-components/js/components/filters/labels/base-price-filter-label.vue'\nimport { Filters, Facets, NumberRangeFilter } from '@empathyco/x-components/facets'\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;AAMA;;;;;AAKE;AACF,gBAAe,eAAe,CAAC;IAC7B,UAAU,EAAE,EAAE,YAAW,EAAG;AAC5B,IAAA,KAAK,EAAE;;AAEL,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAyC;AAC/C,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,QAAQ,EAAE,MAAM;AAChB;;;;;AAKE;AACF,QAAA,MAAM,EAAE,MAAwE;AAChF;;;;AAIE;AACF,QAAA,QAAQ,EAAE;AACR,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,IAAI,EAAE;AACJ,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACF,KAAA;AACD,IAAA,KAAK,CAAC,KAAK,EAAA;AACT;;;;;AAKE;AACF,QAAA,MAAM,KAAI,GAAI,QAAQ,CAAS,MAAI;YACjC,OAAO,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAE,KAAM;kBAC9B,KAAK,CAAC;kBACN,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAE,KAAM;sBACzB,KAAK,CAAC;AACR,sBAAE,KAAK,CAAC,MAAK;AACnB,QAAA,CAAC,CAAA;AAED,QAAA,OAAO,MAAI;YACT,MAAM,UAAS,GAAI,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,mBAAmB,CAAA;YAExD,MAAM,WAAW,UAAU,CAAC,GAAG,CAAC,WAAU,IAAG;AAC3C,gBAAA,IAAI,WAAU,KAAM,OAAO,EAAE;oBAC3B,OAAO,CAAC,CAAC,YAAY,EAAE;AACrB,wBAAA,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAa;wBACvC,QAAQ,EAAE,KAAK,CAAC,QAAQ;wBACxB,MAAM,EAAE,KAAK,CAAC,MAAM;AACrB,qBAAA,CAAA;gBACH;AAAO,qBAAA,IAAI,WAAU,KAAM,OAAO,EAAE;oBAClC,OAAO,CAAC,CAAC,YAAY,EAAE;AACrB,wBAAA,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAa;wBACvC,QAAQ,EAAE,KAAK,CAAC,QAAQ;wBACxB,MAAM,EAAE,KAAK,CAAC,MAAM;AACrB,qBAAA,CAAA;gBACH;AACA,gBAAA,OAAO,WAAU;AACnB,YAAA,CAAC,CAAA;AAED,YAAA,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,sBAAqB,EAAG,EAAE,QAAQ,CAAA;AAC9D,QAAA,CAAA;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
1
|
+
{"version":3,"file":"base-price-filter-label.vue.js","sources":["../../../../../src/components/filters/labels/base-price-filter-label.vue"],"sourcesContent":["<script lang=\"ts\">\nimport type { RangeValue } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport { computed, defineComponent, h } from 'vue'\nimport BaseCurrency from '../../currency/base-currency.vue'\n\n/**\n * Renders a label for a price filter, allowing to select different messages depending on the\n * value of the filter.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /** The filter data for get min and max value. */\n filter: {\n type: Object as PropType<{ range: RangeValue }>,\n required: true,\n },\n /**\n * An ISO 4217 currency value.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n /**\n * Locale used to format the currency. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n /**\n * Message shown when the filter hasn't got the min value defined.\n *\n * @public\n */\n lessThan: {\n type: String,\n required: true,\n },\n /**\n * Message shown when the filter has both the min and max values defined.\n *\n * @public\n */\n fromTo: {\n type: String,\n required: true,\n },\n /**\n * Message shown when the filter hasn't got max value defined.\n *\n * @public\n */\n from: {\n type: String,\n required: true,\n },\n },\n setup(props) {\n /**\n * The active label, retrieved from the provided props.\n * It depends on the min and max values of the filter.\n *\n * @returns The active label to be formatted with the min and max values of the filter.\n */\n const label = computed<string>(() => {\n return props.filter.range.min === null\n ? props.lessThan\n : props.filter.range.max === null\n ? props.from\n : props.fromTo\n })\n\n return () => {\n const labelParts = label.value.split(/(\\{min\\}|\\{max\\})/)\n\n const children = labelParts.map(partMessage => {\n if (partMessage === '{min}') {\n return h(BaseCurrency, {\n value: props.filter.range.min as number,\n currency: props.currency,\n format: props.format,\n locale: props.locale,\n })\n } else if (partMessage === '{max}') {\n return h(BaseCurrency, {\n value: props.filter.range.max as number,\n currency: props.currency,\n format: props.format,\n locale: props.locale,\n })\n }\n return partMessage\n })\n\n return h('span', { class: 'x-price-filter-label' }, children)\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Example\n\nRenders a label for a price filter, allowing to select different messages depending on the value of\nthe filter.\n\n- When the `min` value property isn't defined in the filter, you can show a message like\n `Less than $10` by using the `lessThan` prop, combined with the `{max}` placeholder.\n- When the `max` value property isn't defined in the filter, you can show a message like\n `More than $300` by using the `from` prop, combined with the `{min}` placeholder.\n- If both the `min` and `max` values of the filter are defined, you can show a message like\n `$10 - $300` by using the `fromTo` prop.\n\nThis component uses internally the `BaseCurrency` one, so you can pass the same props to configure\nhow the price should look like.\n\n### Basic usage\n\n```vue\n<template>\n <Facets>\n <template #price=\"{ facet }\">\n <Filters v-slot=\"{ filter }\" :filters=\"facet.filters\">\n <NumberRangeFilter :filter=\"filter\" v-slot=\"{ filter }\">\n <BasePriceFilterLabel\n :filter=\"filter\"\n currency=\"USD\"\n lessThan=\"Less than {max}\"\n fromTo=\"From {min} to {max}\"\n from=\"More than {min}\"\n />\n </NumberRangeFilter>\n </Filters>\n </template>\n </Facets>\n</template>\n\n<script setup>\nimport BasePriceFilterLabel from '@empathyco/x-components/js/components/filters/labels/base-price-filter-label.vue'\nimport { Filters, Facets, NumberRangeFilter } from '@empathyco/x-components/facets'\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <Facets>\n <template #price=\"{ facet }\">\n <Filters v-slot=\"{ filter }\" :filters=\"facet.filters\">\n <NumberRangeFilter :filter=\"filter\" v-slot=\"{ filter }\">\n <BasePriceFilterLabel\n :filter=\"filter\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 0, maximumFractionDigits: 0 }\"\n lessThan=\"Less than {max}\"\n fromTo=\"From {min} to {max}\"\n from=\"More than {min}\"\n />\n </NumberRangeFilter>\n </Filters>\n </template>\n </Facets>\n</template>\n\n<script setup>\nimport BasePriceFilterLabel from '@empathyco/x-components/js/components/filters/labels/base-price-filter-label.vue'\nimport { Filters, Facets, NumberRangeFilter } from '@empathyco/x-components/facets'\n</script>\n```\n\n### Using a different locale\n\nBy default the prices are formatted using the `uiLang` of the `snippetConfig`. If you want to\nformat them in a different locale, you can pass the `locale` prop:\n\n```vue\n<template>\n <Facets>\n <template #price=\"{ facet }\">\n <Filters v-slot=\"{ filter }\" :filters=\"facet.filters\">\n <NumberRangeFilter :filter=\"filter\" v-slot=\"{ filter }\">\n <!-- output: 'From $10.00 to $300.00' even if snippetConfig.uiLang is 'es-ES' -->\n <BasePriceFilterLabel\n :filter=\"filter\"\n currency=\"USD\"\n locale=\"en-US\"\n lessThan=\"Less than {max}\"\n fromTo=\"From {min} to {max}\"\n from=\"More than {min}\"\n />\n </NumberRangeFilter>\n </Filters>\n </template>\n </Facets>\n</template>\n\n<script setup>\nimport BasePriceFilterLabel from '@empathyco/x-components/js/components/filters/labels/base-price-filter-label.vue'\nimport { Filters, Facets, NumberRangeFilter } from '@empathyco/x-components/facets'\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;AAMA;;;;;AAKE;AACF,gBAAe,eAAe,CAAC;IAC7B,UAAU,EAAE,EAAE,YAAW,EAAG;AAC5B,IAAA,KAAK,EAAE;;AAEL,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAyC;AAC/C,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,QAAQ,EAAE,MAAM;AAChB;;;;;AAKE;AACF,QAAA,MAAM,EAAE,MAAwE;AAChF;;;;AAIE;AACF,QAAA,MAAM,EAAE,MAAM;AACd;;;;AAIE;AACF,QAAA,QAAQ,EAAE;AACR,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,IAAI,EAAE;AACJ,YAAA,IAAI,EAAE,MAAM;AACZ,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACF,KAAA;AACD,IAAA,KAAK,CAAC,KAAK,EAAA;AACT;;;;;AAKE;AACF,QAAA,MAAM,KAAI,GAAI,QAAQ,CAAS,MAAI;YACjC,OAAO,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAE,KAAM;kBAC9B,KAAK,CAAC;kBACN,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAE,KAAM;sBACzB,KAAK,CAAC;AACR,sBAAE,KAAK,CAAC,MAAK;AACnB,QAAA,CAAC,CAAA;AAED,QAAA,OAAO,MAAI;YACT,MAAM,UAAS,GAAI,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,mBAAmB,CAAA;YAExD,MAAM,WAAW,UAAU,CAAC,GAAG,CAAC,WAAU,IAAG;AAC3C,gBAAA,IAAI,WAAU,KAAM,OAAO,EAAE;oBAC3B,OAAO,CAAC,CAAC,YAAY,EAAE;AACrB,wBAAA,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAa;wBACvC,QAAQ,EAAE,KAAK,CAAC,QAAQ;wBACxB,MAAM,EAAE,KAAK,CAAC,MAAM;wBACpB,MAAM,EAAE,KAAK,CAAC,MAAM;AACrB,qBAAA,CAAA;gBACH;AAAO,qBAAA,IAAI,WAAU,KAAM,OAAO,EAAE;oBAClC,OAAO,CAAC,CAAC,YAAY,EAAE;AACrB,wBAAA,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAAa;wBACvC,QAAQ,EAAE,KAAK,CAAC,QAAQ;wBACxB,MAAM,EAAE,KAAK,CAAC,MAAM;wBACpB,MAAM,EAAE,KAAK,CAAC,MAAM;AACrB,qBAAA,CAAA;gBACH;AACA,gBAAA,OAAO,WAAU;AACnB,YAAA,CAAC,CAAA;AAED,YAAA,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,sBAAqB,EAAG,EAAE,QAAQ,CAAA;AAC9D,QAAA,CAAA;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
@@ -16,8 +16,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
16
16
|
key: 0,
|
|
17
17
|
value: _ctx.result.price.value,
|
|
18
18
|
currency: _ctx.currency,
|
|
19
|
-
format: _ctx.format
|
|
20
|
-
|
|
19
|
+
format: _ctx.format,
|
|
20
|
+
locale: _ctx.locale
|
|
21
|
+
}, null, 8, ["value", "currency", "format", "locale"])) : createCommentVNode("v-if", true)
|
|
21
22
|
])
|
|
22
23
|
],
|
|
23
24
|
2
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-current-price.vue.js","sources":["../../../../src/components/result/base-result-current-price.vue"],"sourcesContent":["<template>\n <div :class=\"dynamicClasses\" class=\"x-result-current-price\" data-test=\"result-current-price\">\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.value\"\n :value=\"result.price.value\"\n :currency=\"currency\"\n :format=\"format\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport type { VueCSSClasses } from '../../utils/types'\nimport { computed, defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} current price\n * that may or may not be on sale.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n },\n setup(props) {\n /**\n * Dynamic CSS classes to add to the root element of this component.\n *\n * @returns A booleans dictionary where each key is the class name to add,\n * and the boolean value tells if it should be added or not.\n * @internal\n */\n const dynamicClasses = computed<VueCSSClasses>(() => ({\n 'x-result-current-price--on-sale': props.result.price?.hasDiscount ?? false,\n }))\n\n return {\n dynamicClasses,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the current price formatted. You can provide the `currency` and `format`\nproperties to customize the display.\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultCurrentPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.456, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\">\n <span class=\"custom-base-result-current-price\">{{ result.price.value }}</span>\n </BaseResultCurrentPrice>\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_normalizeClass","_renderSlot","_createBlock","_createCommentVNode"],"mappings":";;;;;;AACE,EAAA,OAAAA,SAAA,EAAA,EAAAC,kBAAA;AAAA,
|
|
1
|
+
{"version":3,"file":"base-result-current-price.vue.js","sources":["../../../../src/components/result/base-result-current-price.vue"],"sourcesContent":["<template>\n <div :class=\"dynamicClasses\" class=\"x-result-current-price\" data-test=\"result-current-price\">\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.value\"\n :value=\"result.price.value\"\n :currency=\"currency\"\n :format=\"format\"\n :locale=\"locale\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport type { VueCSSClasses } from '../../utils/types'\nimport { computed, defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} current price\n * that may or may not be on sale.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n /**\n * Locale used to format the currency. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n },\n setup(props) {\n /**\n * Dynamic CSS classes to add to the root element of this component.\n *\n * @returns A booleans dictionary where each key is the class name to add,\n * and the boolean value tells if it should be added or not.\n * @internal\n */\n const dynamicClasses = computed<VueCSSClasses>(() => ({\n 'x-result-current-price--on-sale': props.result.price?.hasDiscount ?? false,\n }))\n\n return {\n dynamicClasses,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the current price formatted. You can provide the `currency` and `format`\nproperties to customize the display.\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultCurrentPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.456, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Using a different locale\n\nBy default the price is formatted using the `uiLang` of the `snippetConfig`. If you want to\nformat the price in a different locale, you can pass the `locale` prop:\n\n```vue\n<template>\n <!-- output: '$123.45' even if snippetConfig.uiLang is 'es-ES' -->\n <BaseResultCurrentPrice :result=\"result\" currency=\"USD\" locale=\"en-US\" />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\">\n <span class=\"custom-base-result-current-price\">{{ result.price.value }}</span>\n </BaseResultCurrentPrice>\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_normalizeClass","_renderSlot","_createBlock","_createCommentVNode"],"mappings":";;;;;;AACE,EAAA,OAAAA,SAAA,EAAA,EAAAC,kBAAA;AAAA,IAcM,KAAA;AAAA,IAAA;AAAA,MAdA,KAAA,EAAKC,cAAA,CAAA,CAAE,IAAA,CAAA,cAAA,EAAsB,wBAAwB,CAAA,CAAA;AAAA,MAAC,WAAA,EAAU;AAAA,KAAA;;AAKpE,MAAAC,UAAA,CAQO,IAAA,CAAA,MAAA,EAAA,SAAA,EAAA,EARA,MAAA,EAAQ,IAAA,CAAA,MAAA,EAAM,EAArB,MAQO;AAAA,QANG,IAAA,CAAA,MAAA,CAAO,KAAA,EAAO,KAAA,IAAAH,SAAA,EAAA,EADtBI,WAAA,CAME,uBAAA,EAAA;AAAA,UAAA,GAAA,EAAA,CAAA;AAJC,UAAA,KAAA,EAAO,YAAO,KAAA,CAAM,KAAA;AAAA,UACpB,QAAA,EAAU,IAAA,CAAA,QAAA;AAAA,UACV,MAAA,EAAQ,IAAA,CAAA,MAAA;AAAA,UACR,MAAA,EAAQ,IAAA,CAAA;AAAA,SAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,OAAA,EAAA,UAAA,EAAA,QAAA,EAAA,QAAA,CAAA,CAAA,IAAAC,kBAAA,CAAA,MAAA,EAAA,IAAA;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-current-price.vue2.js","sources":["../../../../src/components/result/base-result-current-price.vue"],"sourcesContent":["<template>\n <div :class=\"dynamicClasses\" class=\"x-result-current-price\" data-test=\"result-current-price\">\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.value\"\n :value=\"result.price.value\"\n :currency=\"currency\"\n :format=\"format\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport type { VueCSSClasses } from '../../utils/types'\nimport { computed, defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} current price\n * that may or may not be on sale.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n },\n setup(props) {\n /**\n * Dynamic CSS classes to add to the root element of this component.\n *\n * @returns A booleans dictionary where each key is the class name to add,\n * and the boolean value tells if it should be added or not.\n * @internal\n */\n const dynamicClasses = computed<VueCSSClasses>(() => ({\n 'x-result-current-price--on-sale': props.result.price?.hasDiscount ?? false,\n }))\n\n return {\n dynamicClasses,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the current price formatted. You can provide the `currency` and `format`\nproperties to customize the display.\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultCurrentPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.456, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\">\n <span class=\"custom-base-result-current-price\">{{ result.price.value }}</span>\n </BaseResultCurrentPrice>\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"base-result-current-price.vue2.js","sources":["../../../../src/components/result/base-result-current-price.vue"],"sourcesContent":["<template>\n <div :class=\"dynamicClasses\" class=\"x-result-current-price\" data-test=\"result-current-price\">\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.value\"\n :value=\"result.price.value\"\n :currency=\"currency\"\n :format=\"format\"\n :locale=\"locale\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport type { VueCSSClasses } from '../../utils/types'\nimport { computed, defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} current price\n * that may or may not be on sale.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n /**\n * Locale used to format the currency. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n },\n setup(props) {\n /**\n * Dynamic CSS classes to add to the root element of this component.\n *\n * @returns A booleans dictionary where each key is the class name to add,\n * and the boolean value tells if it should be added or not.\n * @internal\n */\n const dynamicClasses = computed<VueCSSClasses>(() => ({\n 'x-result-current-price--on-sale': props.result.price?.hasDiscount ?? false,\n }))\n\n return {\n dynamicClasses,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the current price formatted. You can provide the `currency` and `format`\nproperties to customize the display.\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultCurrentPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.456, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Using a different locale\n\nBy default the price is formatted using the `uiLang` of the `snippetConfig`. If you want to\nformat the price in a different locale, you can pass the `locale` prop:\n\n```vue\n<template>\n <!-- output: '$123.45' even if snippetConfig.uiLang is 'es-ES' -->\n <BaseResultCurrentPrice :result=\"result\" currency=\"USD\" locale=\"en-US\" />\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultCurrentPrice :result=\"result\">\n <span class=\"custom-base-result-current-price\">{{ result.price.value }}</span>\n </BaseResultCurrentPrice>\n</template>\n\n<script setup>\nimport { BaseResultCurrentPrice } from '@empathyco/x-components'\nconst result = {\n price: { value: 123.45, hasDiscount: false },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;AAyBA;;;;;AAKE;AACF,gBAAe,eAAe,CAAC;IAC7B,UAAU,EAAE,EAAE,YAAW,EAAG;AAC5B,IAAA,KAAK,EAAE;AACL;;;;AAIE;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAA0B;AAChC,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,QAAQ,EAAE,MAAM;AAChB;;;;;AAKE;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAwE;AAC9E,YAAA,OAAO,EAAE,OAAO,EAAE,CAAC;AACpB,SAAA;AACD;;;;AAIE;AACF,QAAA,MAAM,EAAE,MAAM;AACf,KAAA;AACD,IAAA,KAAK,CAAC,KAAK,EAAA;AACT;;;;;;AAME;AACF,QAAA,MAAM,cAAa,GAAI,QAAQ,CAAgB,OAAO;YACpD,iCAAiC,EAAE,KAAK,CAAC,MAAM,CAAC,KAAK,EAAE,WAAU,IAAK,KAAK;AAC5E,SAAA,CAAC,CAAA;QAEF,OAAO;YACL,cAAc;SAChB;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
@@ -15,8 +15,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
15
15
|
key: 0,
|
|
16
16
|
value: _ctx.result.price.originalValue,
|
|
17
17
|
currency: _ctx.currency,
|
|
18
|
-
format: _ctx.format
|
|
19
|
-
|
|
18
|
+
format: _ctx.format,
|
|
19
|
+
locale: _ctx.locale
|
|
20
|
+
}, null, 8, ["value", "currency", "format", "locale"])) : createCommentVNode("v-if", true)
|
|
20
21
|
])
|
|
21
22
|
])) : createCommentVNode("v-if", true);
|
|
22
23
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-previous-price.vue.js","sources":["../../../../src/components/result/base-result-previous-price.vue"],"sourcesContent":["<template>\n <div\n v-if=\"result.price?.hasDiscount\"\n class=\"x-result-previous-price\"\n data-test=\"result-previous-price\"\n >\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.originalValue\"\n :value=\"result.price.originalValue\"\n :currency=\"currency\"\n :format=\"format\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport { defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} previous price.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the previous price formatted if it has discount. The component has optional\n`currency` and `format` props to customize the display.\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultPreviousPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\">\n <span class=\"custom-base-result-previous-price\">{{ result.price.originalValue }}</span>\n </BaseResultPreviousPrice>\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_renderSlot","_createBlock","_createCommentVNode"],"mappings":";;;;;;EAGI,KAAA,EAAM,yBAAA;AAAA,EACN,WAAA,EAAU;;;;AAFJ,EAAA,OAAA,IAAA,CAAA,MAAA,CAAO,KAAA,EAAO,WAAA,IAAAA,SAAA,EAAA,EADtBC,kBAAA,
|
|
1
|
+
{"version":3,"file":"base-result-previous-price.vue.js","sources":["../../../../src/components/result/base-result-previous-price.vue"],"sourcesContent":["<template>\n <div\n v-if=\"result.price?.hasDiscount\"\n class=\"x-result-previous-price\"\n data-test=\"result-previous-price\"\n >\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.originalValue\"\n :value=\"result.price.originalValue\"\n :currency=\"currency\"\n :format=\"format\"\n :locale=\"locale\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport { defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} previous price.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n /**\n * Locale used to format the currency. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the previous price formatted if it has discount. The component has optional\n`currency` and `format` props to customize the display.\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultPreviousPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Using a different locale\n\nBy default the price is formatted using the `uiLang` of the `snippetConfig`. If you want to\nformat the price in a different locale, you can pass the `locale` prop:\n\n```vue\n<template>\n <!-- output: '$199.99' even if snippetConfig.uiLang is 'es-ES' -->\n <BaseResultPreviousPrice :result=\"result\" currency=\"USD\" locale=\"en-US\" />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\">\n <span class=\"custom-base-result-previous-price\">{{ result.price.originalValue }}</span>\n </BaseResultPreviousPrice>\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_renderSlot","_createBlock","_createCommentVNode"],"mappings":";;;;;;EAGI,KAAA,EAAM,yBAAA;AAAA,EACN,WAAA,EAAU;;;;AAFJ,EAAA,OAAA,IAAA,CAAA,MAAA,CAAO,KAAA,EAAO,WAAA,IAAAA,SAAA,EAAA,EADtBC,kBAAA,CAkBM,KAAA,EAlBN,UAAA,EAkBM;AAAA,IATJC,UAAA,CAQO,IAAA,CAAA,MAAA,EAAA,SAAA,EAAA,EARA,MAAA,EAAQ,IAAA,CAAA,MAAA,IAAf,MAQO;AAAA,MANG,IAAA,CAAA,MAAA,CAAO,KAAA,EAAO,aAAA,IAAAF,SAAA,EAAA,EADtBG,WAAA,CAME,uBAAA,EAAA;AAAA,QAAA,GAAA,EAAA,CAAA;AAJC,QAAA,KAAA,EAAO,YAAO,KAAA,CAAM,aAAA;AAAA,QACpB,QAAA,EAAU,IAAA,CAAA,QAAA;AAAA,QACV,MAAA,EAAQ,IAAA,CAAA,MAAA;AAAA,QACR,MAAA,EAAQ,IAAA,CAAA;AAAA,OAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,OAAA,EAAA,UAAA,EAAA,QAAA,EAAA,QAAA,CAAA,CAAA,IAAAC,kBAAA,CAAA,MAAA,EAAA,IAAA;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-previous-price.vue2.js","sources":["../../../../src/components/result/base-result-previous-price.vue"],"sourcesContent":["<template>\n <div\n v-if=\"result.price?.hasDiscount\"\n class=\"x-result-previous-price\"\n data-test=\"result-previous-price\"\n >\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.originalValue\"\n :value=\"result.price.originalValue\"\n :currency=\"currency\"\n :format=\"format\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport { defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} previous price.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the previous price formatted if it has discount. The component has optional\n`currency` and `format` props to customize the display.\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultPreviousPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\">\n <span class=\"custom-base-result-previous-price\">{{ result.price.originalValue }}</span>\n </BaseResultPreviousPrice>\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"base-result-previous-price.vue2.js","sources":["../../../../src/components/result/base-result-previous-price.vue"],"sourcesContent":["<template>\n <div\n v-if=\"result.price?.hasDiscount\"\n class=\"x-result-previous-price\"\n data-test=\"result-previous-price\"\n >\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency\n v-if=\"result.price?.originalValue\"\n :value=\"result.price.originalValue\"\n :currency=\"currency\"\n :format=\"format\"\n :locale=\"locale\"\n />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\nimport type { Result } from '@empathyco/x-types'\nimport type { PropType } from 'vue'\nimport { defineComponent } from 'vue'\nimport BaseCurrency from '../currency/base-currency.vue'\n\n/**\n * Component that renders the {@link @empathyco/x-types#Result} previous price.\n *\n * @public\n */\nexport default defineComponent({\n components: { BaseCurrency },\n props: {\n /**\n * (Required) The {@link @empathyco/x-types#Result} information.\n *\n * @public\n */\n result: {\n type: Object as PropType<Result>,\n required: true,\n },\n /**\n * Optional value coming from https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes.\n *\n * @public\n */\n currency: String,\n /**\n * The currency format possibilities from Intl.NumberFormatOptions.\n * Allows customization of decimal places, grouping, etc.\n *\n * @public\n */\n format: {\n type: Object as PropType<Omit<Intl.NumberFormatOptions, 'currency' | 'style'>>,\n default: () => ({}),\n },\n /**\n * Locale used to format the currency. If not specified we use snippetConfig.uiLang\n *\n * @public\n */\n locale: String,\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the previous price formatted if it has discount. The component has optional\n`currency` and `format` props to customize the display.\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\" currency=\"USD\" />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Customizing format\n\nYou can customize the number formatting using the `format` prop with `Intl.NumberFormatOptions`:\n\n```vue\n<template>\n <BaseResultPreviousPrice\n :result=\"result\"\n currency=\"EUR\"\n :format=\"{ minimumFractionDigits: 2, maximumFractionDigits: 2 }\"\n />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Using a different locale\n\nBy default the price is formatted using the `uiLang` of the `snippetConfig`. If you want to\nformat the price in a different locale, you can pass the `locale` prop:\n\n```vue\n<template>\n <!-- output: '$199.99' even if snippetConfig.uiLang is 'es-ES' -->\n <BaseResultPreviousPrice :result=\"result\" currency=\"USD\" locale=\"en-US\" />\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n\n### Overriding default slot\n\n```vue\n<template>\n <BaseResultPreviousPrice :result=\"result\">\n <span class=\"custom-base-result-previous-price\">{{ result.price.originalValue }}</span>\n </BaseResultPreviousPrice>\n</template>\n\n<script setup>\nimport { BaseResultPreviousPrice } from '@empathyco/x-components'\n\nconst result = {\n price: { originalValue: 199.99, hasDiscount: true },\n // ...other result properties\n}\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;AA4BA;;;;AAIE;AACF,gBAAe,eAAe,CAAC;IAC7B,UAAU,EAAE,EAAE,YAAW,EAAG;AAC5B,IAAA,KAAK,EAAE;AACL;;;;AAIE;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAA0B;AAChC,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;AACD;;;;AAIE;AACF,QAAA,QAAQ,EAAE,MAAM;AAChB;;;;;AAKE;AACF,QAAA,MAAM,EAAE;AACN,YAAA,IAAI,EAAE,MAAwE;AAC9E,YAAA,OAAO,EAAE,OAAO,EAAE,CAAC;AACpB,SAAA;AACD;;;;AAIE;AACF,QAAA,MAAM,EAAE,MAAM;AACf,KAAA;AACF,CAAA,CAAA;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@empathyco/x-components",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.4.0",
|
|
4
4
|
"description": "Empathy X Components",
|
|
5
5
|
"author": "Empathy Systems Corporation S.L.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -117,5 +117,5 @@
|
|
|
117
117
|
"access": "public",
|
|
118
118
|
"directory": "dist"
|
|
119
119
|
},
|
|
120
|
-
"gitHead": "
|
|
120
|
+
"gitHead": "0336e5fc00a58996a081bd3dee4457f7fce1e73d"
|
|
121
121
|
}
|
|
@@ -6342,7 +6342,16 @@
|
|
|
6342
6342
|
},
|
|
6343
6343
|
{
|
|
6344
6344
|
"kind": "Content",
|
|
6345
|
-
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n
|
|
6345
|
+
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n locale: "
|
|
6346
|
+
},
|
|
6347
|
+
{
|
|
6348
|
+
"kind": "Reference",
|
|
6349
|
+
"text": "StringConstructor",
|
|
6350
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
6351
|
+
},
|
|
6352
|
+
{
|
|
6353
|
+
"kind": "Content",
|
|
6354
|
+
"text": ";\n}>, {\n currencyText: import(\"vue\")."
|
|
6346
6355
|
},
|
|
6347
6356
|
{
|
|
6348
6357
|
"kind": "Reference",
|
|
@@ -6441,7 +6450,16 @@
|
|
|
6441
6450
|
},
|
|
6442
6451
|
{
|
|
6443
6452
|
"kind": "Content",
|
|
6444
|
-
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n
|
|
6453
|
+
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n locale: "
|
|
6454
|
+
},
|
|
6455
|
+
{
|
|
6456
|
+
"kind": "Reference",
|
|
6457
|
+
"text": "StringConstructor",
|
|
6458
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
6459
|
+
},
|
|
6460
|
+
{
|
|
6461
|
+
"kind": "Content",
|
|
6462
|
+
"text": ";\n}>> & "
|
|
6445
6463
|
},
|
|
6446
6464
|
{
|
|
6447
6465
|
"kind": "Reference",
|
|
@@ -6486,7 +6504,7 @@
|
|
|
6486
6504
|
"name": "BaseCurrency",
|
|
6487
6505
|
"variableTypeTokenRange": {
|
|
6488
6506
|
"startIndex": 1,
|
|
6489
|
-
"endIndex":
|
|
6507
|
+
"endIndex": 50
|
|
6490
6508
|
}
|
|
6491
6509
|
},
|
|
6492
6510
|
{
|
|
@@ -10296,7 +10314,16 @@
|
|
|
10296
10314
|
},
|
|
10297
10315
|
{
|
|
10298
10316
|
"kind": "Content",
|
|
10299
|
-
"text": ", \"currency\" | \"style\">>;\n
|
|
10317
|
+
"text": ", \"currency\" | \"style\">>;\n locale: "
|
|
10318
|
+
},
|
|
10319
|
+
{
|
|
10320
|
+
"kind": "Reference",
|
|
10321
|
+
"text": "StringConstructor",
|
|
10322
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
10323
|
+
},
|
|
10324
|
+
{
|
|
10325
|
+
"kind": "Content",
|
|
10326
|
+
"text": ";\n lessThan: {\n type: "
|
|
10300
10327
|
},
|
|
10301
10328
|
{
|
|
10302
10329
|
"kind": "Reference",
|
|
@@ -10449,7 +10476,16 @@
|
|
|
10449
10476
|
},
|
|
10450
10477
|
{
|
|
10451
10478
|
"kind": "Content",
|
|
10452
|
-
"text": ", \"currency\" | \"style\">>;\n
|
|
10479
|
+
"text": ", \"currency\" | \"style\">>;\n locale: "
|
|
10480
|
+
},
|
|
10481
|
+
{
|
|
10482
|
+
"kind": "Reference",
|
|
10483
|
+
"text": "StringConstructor",
|
|
10484
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
10485
|
+
},
|
|
10486
|
+
{
|
|
10487
|
+
"kind": "Content",
|
|
10488
|
+
"text": ";\n lessThan: {\n type: "
|
|
10453
10489
|
},
|
|
10454
10490
|
{
|
|
10455
10491
|
"kind": "Reference",
|
|
@@ -10512,7 +10548,7 @@
|
|
|
10512
10548
|
"name": "BasePriceFilterLabel",
|
|
10513
10549
|
"variableTypeTokenRange": {
|
|
10514
10550
|
"startIndex": 1,
|
|
10515
|
-
"endIndex":
|
|
10551
|
+
"endIndex": 68
|
|
10516
10552
|
}
|
|
10517
10553
|
},
|
|
10518
10554
|
{
|
|
@@ -10941,7 +10977,16 @@
|
|
|
10941
10977
|
},
|
|
10942
10978
|
{
|
|
10943
10979
|
"kind": "Content",
|
|
10944
|
-
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n
|
|
10980
|
+
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n locale: "
|
|
10981
|
+
},
|
|
10982
|
+
{
|
|
10983
|
+
"kind": "Reference",
|
|
10984
|
+
"text": "StringConstructor",
|
|
10985
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
10986
|
+
},
|
|
10987
|
+
{
|
|
10988
|
+
"kind": "Content",
|
|
10989
|
+
"text": ";\n}>, {\n dynamicClasses: import(\"vue\")."
|
|
10945
10990
|
},
|
|
10946
10991
|
{
|
|
10947
10992
|
"kind": "Reference",
|
|
@@ -11058,7 +11103,16 @@
|
|
|
11058
11103
|
},
|
|
11059
11104
|
{
|
|
11060
11105
|
"kind": "Content",
|
|
11061
|
-
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n
|
|
11106
|
+
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n locale: "
|
|
11107
|
+
},
|
|
11108
|
+
{
|
|
11109
|
+
"kind": "Reference",
|
|
11110
|
+
"text": "StringConstructor",
|
|
11111
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
11112
|
+
},
|
|
11113
|
+
{
|
|
11114
|
+
"kind": "Content",
|
|
11115
|
+
"text": ";\n}>> & "
|
|
11062
11116
|
},
|
|
11063
11117
|
{
|
|
11064
11118
|
"kind": "Reference",
|
|
@@ -11112,7 +11166,7 @@
|
|
|
11112
11166
|
"name": "BaseResultCurrentPrice",
|
|
11113
11167
|
"variableTypeTokenRange": {
|
|
11114
11168
|
"startIndex": 1,
|
|
11115
|
-
"endIndex":
|
|
11169
|
+
"endIndex": 58
|
|
11116
11170
|
}
|
|
11117
11171
|
},
|
|
11118
11172
|
{
|
|
@@ -11784,7 +11838,16 @@
|
|
|
11784
11838
|
},
|
|
11785
11839
|
{
|
|
11786
11840
|
"kind": "Content",
|
|
11787
|
-
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n
|
|
11841
|
+
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n locale: "
|
|
11842
|
+
},
|
|
11843
|
+
{
|
|
11844
|
+
"kind": "Reference",
|
|
11845
|
+
"text": "StringConstructor",
|
|
11846
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
11847
|
+
},
|
|
11848
|
+
{
|
|
11849
|
+
"kind": "Content",
|
|
11850
|
+
"text": ";\n}>, {}, {}, {}, {}, import(\"vue\")."
|
|
11788
11851
|
},
|
|
11789
11852
|
{
|
|
11790
11853
|
"kind": "Reference",
|
|
@@ -11883,7 +11946,16 @@
|
|
|
11883
11946
|
},
|
|
11884
11947
|
{
|
|
11885
11948
|
"kind": "Content",
|
|
11886
|
-
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n
|
|
11949
|
+
"text": ", \"currency\" | \"style\">>;\n default: () => {};\n };\n locale: "
|
|
11950
|
+
},
|
|
11951
|
+
{
|
|
11952
|
+
"kind": "Reference",
|
|
11953
|
+
"text": "StringConstructor",
|
|
11954
|
+
"canonicalReference": "!StringConstructor:interface"
|
|
11955
|
+
},
|
|
11956
|
+
{
|
|
11957
|
+
"kind": "Content",
|
|
11958
|
+
"text": ";\n}>> & "
|
|
11887
11959
|
},
|
|
11888
11960
|
{
|
|
11889
11961
|
"kind": "Reference",
|
|
@@ -11937,7 +12009,7 @@
|
|
|
11937
12009
|
"name": "BaseResultPreviousPrice",
|
|
11938
12010
|
"variableTypeTokenRange": {
|
|
11939
12011
|
"startIndex": 1,
|
|
11940
|
-
"endIndex":
|
|
12012
|
+
"endIndex": 54
|
|
11941
12013
|
}
|
|
11942
12014
|
},
|
|
11943
12015
|
{
|
|
@@ -772,6 +772,7 @@ format: {
|
|
|
772
772
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
773
773
|
default: () => {};
|
|
774
774
|
};
|
|
775
|
+
locale: StringConstructor;
|
|
775
776
|
}>, {
|
|
776
777
|
currencyText: ComputedRef<string>;
|
|
777
778
|
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ExtractPropTypes< {
|
|
@@ -784,6 +785,7 @@ format: {
|
|
|
784
785
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
785
786
|
default: () => {};
|
|
786
787
|
};
|
|
788
|
+
locale: StringConstructor;
|
|
787
789
|
}>> & Readonly<{}>, {
|
|
788
790
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
789
791
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
@@ -1265,6 +1267,7 @@ required: true;
|
|
|
1265
1267
|
};
|
|
1266
1268
|
currency: StringConstructor;
|
|
1267
1269
|
format: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
1270
|
+
locale: StringConstructor;
|
|
1268
1271
|
lessThan: {
|
|
1269
1272
|
type: StringConstructor;
|
|
1270
1273
|
required: true;
|
|
@@ -1288,6 +1291,7 @@ required: true;
|
|
|
1288
1291
|
};
|
|
1289
1292
|
currency: StringConstructor;
|
|
1290
1293
|
format: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
1294
|
+
locale: StringConstructor;
|
|
1291
1295
|
lessThan: {
|
|
1292
1296
|
type: StringConstructor;
|
|
1293
1297
|
required: true;
|
|
@@ -1370,6 +1374,7 @@ format: {
|
|
|
1370
1374
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
1371
1375
|
default: () => {};
|
|
1372
1376
|
};
|
|
1377
|
+
locale: StringConstructor;
|
|
1373
1378
|
}>, {
|
|
1374
1379
|
dynamicClasses: ComputedRef<VueCSSClasses>;
|
|
1375
1380
|
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ExtractPropTypes< {
|
|
@@ -1382,6 +1387,7 @@ format: {
|
|
|
1382
1387
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
1383
1388
|
default: () => {};
|
|
1384
1389
|
};
|
|
1390
|
+
locale: StringConstructor;
|
|
1385
1391
|
}>> & Readonly<{}>, {
|
|
1386
1392
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
1387
1393
|
}, {}, {
|
|
@@ -1474,6 +1480,7 @@ format: {
|
|
|
1474
1480
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
1475
1481
|
default: () => {};
|
|
1476
1482
|
};
|
|
1483
|
+
locale: StringConstructor;
|
|
1477
1484
|
}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ExtractPropTypes< {
|
|
1478
1485
|
result: {
|
|
1479
1486
|
type: PropType<Result>;
|
|
@@ -1484,6 +1491,7 @@ format: {
|
|
|
1484
1491
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
1485
1492
|
default: () => {};
|
|
1486
1493
|
};
|
|
1494
|
+
locale: StringConstructor;
|
|
1487
1495
|
}>> & Readonly<{}>, {
|
|
1488
1496
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
1489
1497
|
}, {}, {
|
|
@@ -29,6 +29,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
29
29
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
30
30
|
default: () => {};
|
|
31
31
|
};
|
|
32
|
+
/**
|
|
33
|
+
* Locale used to format the value. If not specified we use snippetConfig.uiLang
|
|
34
|
+
*
|
|
35
|
+
* @public
|
|
36
|
+
*/
|
|
37
|
+
locale: StringConstructor;
|
|
32
38
|
}>, {
|
|
33
39
|
currencyText: import("vue").ComputedRef<string>;
|
|
34
40
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
@@ -61,6 +67,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
61
67
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
62
68
|
default: () => {};
|
|
63
69
|
};
|
|
70
|
+
/**
|
|
71
|
+
* Locale used to format the value. If not specified we use snippetConfig.uiLang
|
|
72
|
+
*
|
|
73
|
+
* @public
|
|
74
|
+
*/
|
|
75
|
+
locale: StringConstructor;
|
|
64
76
|
}>> & Readonly<{}>, {
|
|
65
77
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
66
78
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-currency.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../src/components/currency/base-currency.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;;IAK/B;;;;;;;OAOG;;;;;IAMH;;;;OAIG;;IAEH;;;;;;OAMG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC
|
|
1
|
+
{"version":3,"file":"base-currency.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../src/components/currency/base-currency.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;;IAK/B;;;;;;;OAOG;;;;;IAMH;;;;OAIG;;IAEH;;;;;;OAMG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;IAGhF;;;;OAIG;;;;;IAlCH;;;;;;;OAOG;;;;;IAMH;;;;OAIG;;IAEH;;;;;;OAMG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;IAGhF;;;;OAIG;;;;;AApCP,wBAyDE"}
|
|
@@ -27,6 +27,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
27
27
|
* @public
|
|
28
28
|
*/
|
|
29
29
|
format: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
30
|
+
/**
|
|
31
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
32
|
+
*
|
|
33
|
+
* @public
|
|
34
|
+
*/
|
|
35
|
+
locale: StringConstructor;
|
|
30
36
|
/**
|
|
31
37
|
* Message shown when the filter hasn't got the min value defined.
|
|
32
38
|
*
|
|
@@ -77,6 +83,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
77
83
|
* @public
|
|
78
84
|
*/
|
|
79
85
|
format: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
86
|
+
/**
|
|
87
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
88
|
+
*
|
|
89
|
+
* @public
|
|
90
|
+
*/
|
|
91
|
+
locale: StringConstructor;
|
|
80
92
|
/**
|
|
81
93
|
* Message shown when the filter hasn't got the min value defined.
|
|
82
94
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-price-filter-label.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../../src/components/filters/labels/base-price-filter-label.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAA;AACpD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAInC;;;;;GAKG;;IAIC,iDAAiD;;cAE/B,QAAQ,CAAC;YAAE,KAAK,EAAE,UAAU,CAAA;SAAE,CAAC;;;IAGjD;;;;OAIG;;IAEH;;;;;OAKG;YACe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;IAChF;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;;;;
|
|
1
|
+
{"version":3,"file":"base-price-filter-label.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../../src/components/filters/labels/base-price-filter-label.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAA;AACpD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAInC;;;;;GAKG;;IAIC,iDAAiD;;cAE/B,QAAQ,CAAC;YAAE,KAAK,EAAE,UAAU,CAAA;SAAE,CAAC;;;IAGjD;;;;OAIG;;IAEH;;;;;OAKG;YACe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;IAChF;;;;OAIG;;IAEH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;;;;IA9CH,iDAAiD;;cAE/B,QAAQ,CAAC;YAAE,KAAK,EAAE,UAAU,CAAA;SAAE,CAAC;;;IAGjD;;;;OAIG;;IAEH;;;;;OAKG;YACe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;IAChF;;;;OAIG;;IAEH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;IAKH;;;;OAIG;;;;;;;;AAjDP,wBA+FE"}
|
|
@@ -33,6 +33,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
33
33
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
34
34
|
default: () => {};
|
|
35
35
|
};
|
|
36
|
+
/**
|
|
37
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
38
|
+
*
|
|
39
|
+
* @public
|
|
40
|
+
*/
|
|
41
|
+
locale: StringConstructor;
|
|
36
42
|
}>, {
|
|
37
43
|
dynamicClasses: import("vue").ComputedRef<VueCSSClasses>;
|
|
38
44
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
@@ -61,6 +67,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
61
67
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
62
68
|
default: () => {};
|
|
63
69
|
};
|
|
70
|
+
/**
|
|
71
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
72
|
+
*
|
|
73
|
+
* @public
|
|
74
|
+
*/
|
|
75
|
+
locale: StringConstructor;
|
|
64
76
|
}>> & Readonly<{}>, {
|
|
65
77
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
66
78
|
}, {}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-current-price.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../src/components/result/base-result-current-price.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AACnC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAItD;;;;;GAKG;;IAIC;;;;OAIG;;cAEe,QAAQ,CAAC,MAAM,CAAC;;;IAGlC;;;;OAIG;;IAEH;;;;;OAKG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC
|
|
1
|
+
{"version":3,"file":"base-result-current-price.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../src/components/result/base-result-current-price.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AACnC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAItD;;;;;GAKG;;IAIC;;;;OAIG;;cAEe,QAAQ,CAAC,MAAM,CAAC;;;IAGlC;;;;OAIG;;IAEH;;;;;OAKG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;IAGhF;;;;OAIG;;;;;IA7BH;;;;OAIG;;cAEe,QAAQ,CAAC,MAAM,CAAC;;;IAGlC;;;;OAIG;;IAEH;;;;;OAKG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;IAGhF;;;;OAIG;;;;;;;AAhCP,wBAmDE"}
|
|
@@ -31,6 +31,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
31
31
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
32
32
|
default: () => {};
|
|
33
33
|
};
|
|
34
|
+
/**
|
|
35
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
36
|
+
*
|
|
37
|
+
* @public
|
|
38
|
+
*/
|
|
39
|
+
locale: StringConstructor;
|
|
34
40
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
35
41
|
/**
|
|
36
42
|
* (Required) The {@link @empathyco/x-types#Result} information.
|
|
@@ -57,6 +63,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
57
63
|
type: PropType<Omit<Intl.NumberFormatOptions, "currency" | "style">>;
|
|
58
64
|
default: () => {};
|
|
59
65
|
};
|
|
66
|
+
/**
|
|
67
|
+
* Locale used to format the currency. If not specified we use snippetConfig.uiLang
|
|
68
|
+
*
|
|
69
|
+
* @public
|
|
70
|
+
*/
|
|
71
|
+
locale: StringConstructor;
|
|
60
72
|
}>> & Readonly<{}>, {
|
|
61
73
|
format: Omit<Intl.NumberFormatOptions, "currency" | "style">;
|
|
62
74
|
}, {}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-previous-price.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../src/components/result/base-result-previous-price.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAInC;;;;GAIG;;IAIC;;;;OAIG;;cAEe,QAAQ,CAAC,MAAM,CAAC;;;IAGlC;;;;OAIG;;IAEH;;;;;OAKG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;;
|
|
1
|
+
{"version":3,"file":"base-result-previous-price.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../src/components/result/base-result-previous-price.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAInC;;;;GAIG;;IAIC;;;;OAIG;;cAEe,QAAQ,CAAC,MAAM,CAAC;;;IAGlC;;;;OAIG;;IAEH;;;;;OAKG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;IAGhF;;;;OAIG;;;IA7BH;;;;OAIG;;cAEe,QAAQ,CAAC,MAAM,CAAC;;;IAGlC;;;;OAIG;;IAEH;;;;;OAKG;;cAEe,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,mBAAmB,EAAE,UAAU,GAAG,OAAO,CAAC,CAAC;;;IAGhF;;;;OAIG;;;;;;;AAhCP,wBAmCE"}
|