@empathyco/x-components 7.5.0 → 8.0.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 +11 -0
- package/browse/index.js +0 -1
- package/core/index.js +3 -0
- package/core/index.js.map +1 -1
- package/docs/API-reference/api/x-components.md +0 -11
- package/docs/API-reference/api/x-components.sortdropdown.md +30 -4
- package/docs/API-reference/api/x-components.sortlist.md +32 -7
- package/docs/API-reference/api/x-components.sortpickerlist.md +32 -7
- package/docs/API-reference/api/x-components.usealiasapi.browseselectedsort.md +13 -0
- package/docs/API-reference/api/x-components.usealiasapi.md +21 -0
- package/docs/API-reference/components/{search → common/sort}/x-components.sort-dropdown.md +7 -4
- package/docs/API-reference/components/{search → common/sort}/x-components.sort-list.md +7 -4
- package/docs/API-reference/components/{search → common/sort}/x-components.sort-picker-list.md +8 -5
- package/js/{x-modules/search/components → components/sort}/sort-dropdown.vue.js +1 -1
- package/js/components/sort/sort-dropdown.vue.js.map +1 -0
- package/js/{x-modules/search/components → components/sort}/sort-dropdown.vue2.js +19 -12
- package/js/components/sort/sort-dropdown.vue2.js.map +1 -0
- package/js/{x-modules/search/components → components/sort}/sort-list.vue.js +2 -2
- package/js/components/sort/sort-list.vue.js.map +1 -0
- package/js/{x-modules/search/components → components/sort}/sort-list.vue2.js +22 -15
- package/js/components/sort/sort-list.vue2.js.map +1 -0
- package/js/components/sort/sort-list.vue3.js +7 -0
- package/js/{x-modules/search/components → components/sort}/sort-picker-list.vue.js +1 -1
- package/js/components/sort/sort-picker-list.vue.js.map +1 -0
- package/js/{x-modules/search/components → components/sort}/sort-picker-list.vue2.js +21 -14
- package/js/components/sort/sort-picker-list.vue2.js.map +1 -0
- package/js/composables/use-alias-api.js +3 -0
- package/js/composables/use-alias-api.js.map +1 -1
- package/js/index.js +3 -4
- package/js/index.js.map +1 -1
- package/js/x-modules/ai/components/ai-carousel.vue2.js +4 -0
- package/js/x-modules/ai/components/ai-carousel.vue2.js.map +1 -1
- package/js/x-modules/ai/components/ai-grouped-carousel.vue2.js +4 -0
- package/js/x-modules/ai/components/ai-grouped-carousel.vue2.js.map +1 -1
- package/js/x-modules/browse/store/actions/set-url-params.action.js +1 -1
- package/js/x-modules/browse/store/actions/set-url-params.action.js.map +1 -1
- package/js/x-modules/browse/wiring.js +6 -1
- package/js/x-modules/browse/wiring.js.map +1 -1
- package/js/x-modules/empathize/components/empathize.vue2.js +4 -0
- package/js/x-modules/empathize/components/empathize.vue2.js.map +1 -1
- package/js/x-modules/queries-preview/components/query-preview-button.vue2.js +4 -0
- package/js/x-modules/queries-preview/components/query-preview-button.vue2.js.map +1 -1
- package/js/x-modules/queries-preview/components/query-preview.vue2.js +4 -0
- package/js/x-modules/queries-preview/components/query-preview.vue2.js.map +1 -1
- package/js/x-modules/scroll/components/scroll-to-top.vue2.js +4 -0
- package/js/x-modules/scroll/components/scroll-to-top.vue2.js.map +1 -1
- package/js/x-modules/search/store/actions/set-url-params.action.js +1 -1
- package/js/x-modules/search/store/actions/set-url-params.action.js.map +1 -1
- package/js/x-modules/search/wiring.js +3 -0
- package/js/x-modules/search/wiring.js.map +1 -1
- package/package.json +2 -2
- package/report/x-components.api.json +515 -304
- package/report/x-components.api.md +106 -56
- package/search/index.js +0 -3
- package/types/src/components/index.d.ts +1 -0
- package/types/src/components/index.d.ts.map +1 -1
- package/types/src/components/sort/index.d.ts +4 -0
- package/types/src/components/sort/index.d.ts.map +1 -0
- package/types/src/{x-modules/search/components → components/sort}/sort-dropdown.vue.d.ts +33 -6
- package/types/src/components/sort/sort-dropdown.vue.d.ts.map +1 -0
- package/types/src/{x-modules/search/components → components/sort}/sort-list.vue.d.ts +35 -10
- package/types/src/components/sort/sort-list.vue.d.ts.map +1 -0
- package/types/src/{x-modules/search/components → components/sort}/sort-picker-list.vue.d.ts +45 -10
- package/types/src/components/sort/sort-picker-list.vue.d.ts.map +1 -0
- package/types/src/composables/use-alias-api.d.ts +2 -0
- package/types/src/composables/use-alias-api.d.ts.map +1 -1
- package/types/src/x-modules/browse/components/index.d.ts +0 -1
- package/types/src/x-modules/browse/components/index.d.ts.map +1 -1
- package/types/src/x-modules/browse/wiring.d.ts +6 -1
- package/types/src/x-modules/browse/wiring.d.ts.map +1 -1
- package/types/src/x-modules/search/components/index.d.ts +0 -3
- package/types/src/x-modules/search/components/index.d.ts.map +1 -1
- package/types/src/x-modules/search/wiring.d.ts +3 -0
- package/types/src/x-modules/search/wiring.d.ts.map +1 -1
- package/docs/API-reference/api/x-components.browsesortpickerlist.md +0 -45
- package/docs/API-reference/components/browse/x-components.browse-sort-picker-list.md +0 -24
- package/js/x-modules/browse/components/browse-sort-picker-list.vue.js +0 -73
- package/js/x-modules/browse/components/browse-sort-picker-list.vue.js.map +0 -1
- package/js/x-modules/browse/components/browse-sort-picker-list.vue2.js +0 -6
- package/js/x-modules/browse/components/browse-sort-picker-list.vue2.js.map +0 -1
- package/js/x-modules/search/components/sort-dropdown.vue.js.map +0 -1
- package/js/x-modules/search/components/sort-dropdown.vue2.js.map +0 -1
- package/js/x-modules/search/components/sort-list.vue.js.map +0 -1
- package/js/x-modules/search/components/sort-list.vue2.js.map +0 -1
- package/js/x-modules/search/components/sort-list.vue3.js +0 -7
- package/js/x-modules/search/components/sort-picker-list.vue.js.map +0 -1
- package/js/x-modules/search/components/sort-picker-list.vue2.js.map +0 -1
- package/types/src/x-modules/browse/components/browse-sort-picker-list.vue.d.ts +0 -50
- package/types/src/x-modules/browse/components/browse-sort-picker-list.vue.d.ts.map +0 -1
- package/types/src/x-modules/search/components/sort-dropdown.vue.d.ts.map +0 -1
- package/types/src/x-modules/search/components/sort-list.vue.d.ts.map +0 -1
- package/types/src/x-modules/search/components/sort-picker-list.types.d.ts +0 -12
- package/types/src/x-modules/search/components/sort-picker-list.types.d.ts.map +0 -1
- package/types/src/x-modules/search/components/sort-picker-list.vue.d.ts.map +0 -1
- /package/js/{x-modules/search/components → components/sort}/sort-list.vue3.js.map +0 -0
|
@@ -218,6 +218,9 @@ export declare const searchWiring: {
|
|
|
218
218
|
UserClickedOutOfMainModal: {
|
|
219
219
|
clearSearchQuery: import("../../wiring").AnyWire;
|
|
220
220
|
};
|
|
221
|
+
UserBrowsedToCategory: {
|
|
222
|
+
clearSearchQuery: import("../../wiring").AnyWire;
|
|
223
|
+
};
|
|
221
224
|
UserAcceptedAQueryPreview: {
|
|
222
225
|
setSearchQueryFromPreview: import("../../wiring").AnyWire;
|
|
223
226
|
setSearchExtraParamsFromPreview: import("../../wiring").AnyWire;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wiring.d.ts","sourceRoot":"","sources":["../../../../../src/x-modules/search/wiring.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAA;AA8CpD;;;;GAIG;AACH,eAAO,MAAM,oCAAoC,gCAEhD,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,cAAc,gCAAyD,CAAA;AAEpF;;;;GAIG;AACH,eAAO,MAAM,8BAA8B,2DAA6C,CAAA;AAExF;;;;GAIG;AACH,eAAO,MAAM,iCAAiC,oEAAgD,CAAA;AAE9F;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,gCAAkC,CAAA;AAEnE;;;;GAIG;AACH,eAAO,MAAM,cAAc,wEAA+B,CAAA;AAE1D;;;;GAIG;AACH,eAAO,MAAM,cAAc,qCAAyB,CAAA;AAEpD;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,gCAA6B,CAAA;AAE1D;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,oEAAmC,CAAA;AAElE;;;;GAIG;AACH,eAAO,MAAM,OAAO,qCAAwB,CAAA;AAE5C;;;;GAIG;AACH,eAAO,MAAM,YAAY,wDAA+B,CAAA;AAExD;;;;GAIG;AACH,eAAO,MAAM,aAAa,qCAAwB,CAAA;AAElD;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,+EAA0B,CAAA;AAE3D;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,gCAAkD,CAAA;AAEtF;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,gCAAsC,CAAA;AAEnE;;;;GAIG;AACH,eAAO,MAAM,6BAA6B,gCAAmD,CAAA;AAE7F;;;;GAIG;AACH,eAAO,MAAM,gCAAgC,gCAE5C,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,cAAc,gCAA0C,CAAA;AAErE;;;;;GAKG;AACH,eAAO,MAAM,4BAA4B,gCAMxC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,wCAAwC,2EAEpD,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,yBAAyB,2DAErC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,gCAGrC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,+BAA+B,gCAG3C,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,mCAAmC,gCAG/C,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,wCAAwC,gCAGpD,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,YAAY
|
|
1
|
+
{"version":3,"file":"wiring.d.ts","sourceRoot":"","sources":["../../../../../src/x-modules/search/wiring.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAA;AA8CpD;;;;GAIG;AACH,eAAO,MAAM,oCAAoC,gCAEhD,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,cAAc,gCAAyD,CAAA;AAEpF;;;;GAIG;AACH,eAAO,MAAM,8BAA8B,2DAA6C,CAAA;AAExF;;;;GAIG;AACH,eAAO,MAAM,iCAAiC,oEAAgD,CAAA;AAE9F;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,gCAAkC,CAAA;AAEnE;;;;GAIG;AACH,eAAO,MAAM,cAAc,wEAA+B,CAAA;AAE1D;;;;GAIG;AACH,eAAO,MAAM,cAAc,qCAAyB,CAAA;AAEpD;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,gCAA6B,CAAA;AAE1D;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,oEAAmC,CAAA;AAElE;;;;GAIG;AACH,eAAO,MAAM,OAAO,qCAAwB,CAAA;AAE5C;;;;GAIG;AACH,eAAO,MAAM,YAAY,wDAA+B,CAAA;AAExD;;;;GAIG;AACH,eAAO,MAAM,aAAa,qCAAwB,CAAA;AAElD;;;;GAIG;AACH,eAAO,MAAM,oBAAoB,+EAA0B,CAAA;AAE3D;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,gCAAkD,CAAA;AAEtF;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,gCAAsC,CAAA;AAEnE;;;;GAIG;AACH,eAAO,MAAM,6BAA6B,gCAAmD,CAAA;AAE7F;;;;GAIG;AACH,eAAO,MAAM,gCAAgC,gCAE5C,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,cAAc,gCAA0C,CAAA;AAErE;;;;;GAKG;AACH,eAAO,MAAM,4BAA4B,gCAMxC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,wCAAwC,2EAEpD,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,yBAAyB,2DAErC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,gCAGrC,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,+BAA+B,gCAG3C,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,mCAAmC,gCAG/C,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,wCAAwC,gCAGpD,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiFvB,CAAA"}
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
-
|
|
3
|
-
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [BrowseSortPickerList](./x-components.browsesortpickerlist.md)
|
|
4
|
-
|
|
5
|
-
## BrowseSortPickerList variable
|
|
6
|
-
|
|
7
|
-
The `SortPickerList` component allows user to select the browse results order. This component also allows to change the selected sort programmatically.
|
|
8
|
-
|
|
9
|
-
**Signature:**
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
_default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
13
|
-
animation: {
|
|
14
|
-
type: null;
|
|
15
|
-
required: false;
|
|
16
|
-
default: string;
|
|
17
|
-
};
|
|
18
|
-
items: {
|
|
19
|
-
type: ArrayConstructor;
|
|
20
|
-
required: true;
|
|
21
|
-
};
|
|
22
|
-
buttonClass: {
|
|
23
|
-
type: StringConstructor;
|
|
24
|
-
required: true;
|
|
25
|
-
};
|
|
26
|
-
}>, (_ctx: any, _cache: any) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
27
|
-
[key: string]: any;
|
|
28
|
-
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
29
|
-
animation: {
|
|
30
|
-
type: null;
|
|
31
|
-
required: false;
|
|
32
|
-
default: string;
|
|
33
|
-
};
|
|
34
|
-
items: {
|
|
35
|
-
type: ArrayConstructor;
|
|
36
|
-
required: true;
|
|
37
|
-
};
|
|
38
|
-
buttonClass: {
|
|
39
|
-
type: StringConstructor;
|
|
40
|
-
required: true;
|
|
41
|
-
};
|
|
42
|
-
}>> & Readonly<{}>, {
|
|
43
|
-
animation: any;
|
|
44
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>
|
|
45
|
-
```
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
|
|
3
|
-
title: BrowseSortPickerList
|
|
4
|
-
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# BrowseSortPickerList
|
|
8
|
-
|
|
9
|
-
The `SortPickerList` component allows user to select the browse results order. This component
|
|
10
|
-
also allows to change the selected sort programmatically.
|
|
11
|
-
|
|
12
|
-
## Props
|
|
13
|
-
|
|
14
|
-
| Name | Description | Type | Default |
|
|
15
|
-
| ------------------------ | ----------- | ------------------- | ----------------- |
|
|
16
|
-
| <code>animation</code> | | <code>union</code> | <code>'ul'</code> |
|
|
17
|
-
| <code>items</code> | | <code>Array</code> | <code></code> |
|
|
18
|
-
| <code>buttonClass</code> | | <code>string</code> | <code></code> |
|
|
19
|
-
|
|
20
|
-
## Slots
|
|
21
|
-
|
|
22
|
-
| Name | Description | Bindings<br />(name - type - description) |
|
|
23
|
-
| -------------------- | ----------- | ----------------------------------------- |
|
|
24
|
-
| <code>default</code> | | <br /> |
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { defineComponent, watch, computed, openBlock, createBlock, resolveDynamicComponent, withCtx, createElementBlock, Fragment, renderList, unref, normalizeClass, renderSlot, mergeProps, createTextVNode, toDisplayString } from 'vue';
|
|
2
|
-
import BaseEventButton from '../../../components/base-event-button.vue.js';
|
|
3
|
-
import { use$x } from '../../../composables/use-_x.js';
|
|
4
|
-
import { useState } from '../../../composables/use-state.js';
|
|
5
|
-
import { browseXModule } from '../x-module.js';
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* The `SortPickerList` component allows user to select the browse results order. This component
|
|
9
|
-
* also allows to change the selected sort programmatically.
|
|
10
|
-
*/
|
|
11
|
-
var _sfc_main = /*@__PURE__*/ defineComponent({
|
|
12
|
-
...{
|
|
13
|
-
xModule: browseXModule.name,
|
|
14
|
-
},
|
|
15
|
-
__name: 'browse-sort-picker-list',
|
|
16
|
-
props: {
|
|
17
|
-
animation: { type: null, required: false, default: 'ul' },
|
|
18
|
-
items: { type: Array, required: true },
|
|
19
|
-
buttonClass: { type: String, required: true }
|
|
20
|
-
},
|
|
21
|
-
setup(__props) {
|
|
22
|
-
const props = __props;
|
|
23
|
-
const $x = use$x();
|
|
24
|
-
const { sort: selectedSort } = useState('browse');
|
|
25
|
-
watch(selectedSort, (value) => $x.emit('SelectedBrowseSortProvided', value), {
|
|
26
|
-
immediate: true,
|
|
27
|
-
});
|
|
28
|
-
/**
|
|
29
|
-
* Sort list items.
|
|
30
|
-
*
|
|
31
|
-
* @returns A list of items with their css class and the event associate to it.
|
|
32
|
-
*/
|
|
33
|
-
const listItems = computed(() => props.items.map((item) => ({
|
|
34
|
-
item,
|
|
35
|
-
cssClasses: {
|
|
36
|
-
'xds:selected': item === selectedSort.value,
|
|
37
|
-
},
|
|
38
|
-
event: { UserClickedABrowseSort: item },
|
|
39
|
-
})));
|
|
40
|
-
return (_ctx, _cache) => {
|
|
41
|
-
return (openBlock(), createBlock(resolveDynamicComponent(__props.animation), {
|
|
42
|
-
tag: "div",
|
|
43
|
-
class: "x-sort-picker-list",
|
|
44
|
-
"data-test": "sort-picker",
|
|
45
|
-
role: "list"
|
|
46
|
-
}, {
|
|
47
|
-
default: withCtx(() => [
|
|
48
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(listItems.value, ({ item, cssClasses, event }) => {
|
|
49
|
-
return (openBlock(), createBlock(BaseEventButton, {
|
|
50
|
-
key: item,
|
|
51
|
-
class: normalizeClass([cssClasses, __props.buttonClass]),
|
|
52
|
-
"data-test": "sort-picker-button",
|
|
53
|
-
events: event,
|
|
54
|
-
"aria-pressed": item === unref(selectedSort) || null,
|
|
55
|
-
role: "listitem"
|
|
56
|
-
}, {
|
|
57
|
-
default: withCtx(() => [
|
|
58
|
-
renderSlot(_ctx.$slots, "default", mergeProps({ ref_for: true }, { item, isSelected: item === unref(selectedSort) }), () => [
|
|
59
|
-
createTextVNode(toDisplayString(item), 1 /* TEXT */)
|
|
60
|
-
])
|
|
61
|
-
]),
|
|
62
|
-
_: 2 /* DYNAMIC */
|
|
63
|
-
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "events", "aria-pressed"]));
|
|
64
|
-
}), 128 /* KEYED_FRAGMENT */))
|
|
65
|
-
]),
|
|
66
|
-
_: 3 /* FORWARDED */
|
|
67
|
-
}));
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
});
|
|
71
|
-
|
|
72
|
-
export { _sfc_main as default };
|
|
73
|
-
//# sourceMappingURL=browse-sort-picker-list.vue.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"browse-sort-picker-list.vue.js","sources":["../../../../../src/x-modules/browse/components/browse-sort-picker-list.vue"],"sourcesContent":["<template>\n <component\n :is=\"animation\"\n tag=\"div\"\n class=\"x-sort-picker-list\"\n data-test=\"sort-picker\"\n role=\"list\"\n >\n <BaseEventButton\n v-for=\"{ item, cssClasses, event } in listItems\"\n :key=\"item\"\n :class=\"[cssClasses, buttonClass]\"\n data-test=\"sort-picker-button\"\n :events=\"event\"\n :aria-pressed=\"item === selectedSort || null\"\n role=\"listitem\"\n >\n <slot v-bind=\"{ item, isSelected: item === selectedSort }\">\n {{ item }}\n </slot>\n </BaseEventButton>\n </component>\n</template>\n\n<script setup lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component } from 'vue'\nimport type { VueCSSClasses } from '../../../utils/types'\nimport type { XEventsTypes } from '../../../wiring/events.types'\nimport { computed, watch } from 'vue'\nimport BaseEventButton from '../../../components/base-event-button.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { browseXModule } from '../x-module'\n\n/**\n * Sort Picker item options.\n */\nexport interface SortPickerItem {\n item: Sort\n cssClasses: VueCSSClasses\n event: Partial<XEventsTypes>\n}\n\n/**\n * The `SortPickerList` component allows user to select the browse results order. This component\n * also allows to change the selected sort programmatically.\n */\n\ndefineOptions({\n xModule: browseXModule.name,\n})\n\nconst props = withDefaults(\n defineProps<{ animation?: string | Component; items: Sort[]; buttonClass: string }>(),\n { animation: 'ul' },\n)\n\nconst $x = use$x()\n\nconst { sort: selectedSort } = useState('browse')\n\nwatch(selectedSort, (value: Sort) => $x.emit('SelectedBrowseSortProvided', value), {\n immediate: true,\n})\n\n/**\n * Sort list items.\n *\n * @returns A list of items with their css class and the event associate to it.\n */\nconst listItems = computed<SortPickerItem[]>(() =>\n props.items.map((item: string) => ({\n item,\n cssClasses: {\n 'xds:selected': item === selectedSort.value,\n },\n event: { UserClickedABrowseSort: item },\n })),\n)\n</script>\n"],"names":["_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_normalizeClass","_unref","_renderSlot","_mergeProps"],"mappings":";;;;;;AA4CA;;;AAGE;;;;;;;;;;;;QAMF,MAAM,KAAK,GAAG,OAAA;AAKd,QAAA,MAAM,EAAE,GAAG,KAAK,EAAC;QAEjB,MAAM,EAAE,IAAI,EAAE,YAAY,EAAE,GAAG,QAAQ,CAAC,QAAQ,CAAA;AAEhD,QAAA,KAAK,CAAC,YAAY,EAAE,CAAC,KAAW,KAAK,EAAE,CAAC,IAAI,CAAC,4BAA4B,EAAE,KAAK,CAAC,EAAE;AACjF,YAAA,SAAS,EAAE,IAAI;AAChB,SAAA,CAAA;AAED;;;;AAIE;AACF,QAAA,MAAM,SAAS,GAAG,QAAQ,CAAmB,MAC3C,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,IAAY,MAAM;YACjC,IAAI;AACJ,YAAA,UAAU,EAAE;AACV,gBAAA,cAAc,EAAE,IAAI,KAAK,YAAY,CAAC,KAAK;AAC5C,aAAA;AACD,YAAA,KAAK,EAAE,EAAE,sBAAsB,EAAE,IAAI,EAAE;SACxC,CAAC,CAAC,CACL;;AA9EE,YAAA,QAAAA,SAAA,EAAA,EAAAC,WAAA,CAoBYC,wBAnBL,OAAA,CAAA,SAAS,CAAA,EAAA;AACd,gBAAA,GAAG,EAAC,KAAK;AACT,gBAAA,KAAK,EAAC,oBAAoB;AAC1B,gBAAA,WAAS,EAAC,aAAa;AACvB,gBAAA,IAAI,EAAC;;iCAGH,MAAgD;qBADlDF,SAAA,CAAA,IAAA,CAAA,EAAAG,kBAAA,CAYkBC,2BAXsB,SAAA,CAAA,KAAS,EAAA,CAAA,EAAtC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAA,KAAA;6CADlCH,WAAA,CAYkB,eAAA,EAAA;AAVf,4BAAA,GAAG,EAAE,IAAI;4BACT,KAAK,EAAAI,cAAA,CAAA,CAAG,UAAU,EAAE,OAAA,CAAA,WAAW,CAAA,CAAA;AAChC,4BAAA,WAAS,EAAC,oBAAoB;AAC7B,4BAAA,MAAM,EAAE,KAAK;4BACb,cAAY,EAAE,IAAI,KAAKC,KAAA,CAAA,YAAA,CAAY,IAAA,IAAA;AACpC,4BAAA,IAAI,EAAC;;6CAEL,MAEO;AAFP,gCAAAC,UAAA,CAEO,IAAA,CAAA,MAAA,EAAA,SAAA,EAFPC,WAEO,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAFS,IAAI,cAAc,IAAI,KAAKF,KAAA,CAAA,YAAA,CAAY,EAAA,CAAA,EAAvD,MAEO;oEADF,IAAI,CAAA,EAAA,CAAA;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"browse-sort-picker-list.vue2.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-dropdown.vue.js","sources":["../../../../../src/x-modules/search/components/sort-dropdown.vue"],"sourcesContent":["<template>\n <BaseDropdown\n ref=\"rootRef\"\n :items=\"items\"\n :model-value=\"selectedSort\"\n :animation=\"animation\"\n class=\"x-sort-dropdown\"\n data-test=\"sort-dropdown\"\n aria-label=\"Select sorting\"\n @update:model-value=\"emitUserClickedASort\"\n >\n <template #toggle=\"{ isOpen, item }\">\n <!--\n @slot Used to render the contents of the dropdown toggle button. If not provided, it uses\n the item slot as fallback.\n @binding {Sort} item - The sort data to render.\n @binding {boolean} isOpen - True if the dropdown is opened, and false if it is closed.\n -->\n <slot v-bind=\"{ isOpen, item }\" name=\"toggle\">{{ item }}</slot>\n </template>\n <template #item=\"{ item, isHighlighted, isSelected }\">\n <!--\n @slot (required) Used to render each one of the items content, and as fallback\n for the toggle button content slot if it is not provided.\n @binding {Sort} item - Sort to render\n @binding {boolean} isHighlighted - True when the item has the focus.\n @binding {boolean} isSelected - True when the item is selected.\n -->\n <slot v-bind=\"{ item, isHighlighted, isSelected }\" name=\"item\">{{ item }}</slot>\n </template>\n </BaseDropdown>\n</template>\n\n<script lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component, PropType } from 'vue'\nimport { defineComponent, ref, watch } from 'vue'\n\nimport BaseDropdown from '../../../components/base-dropdown.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { searchXModule } from '../x-module'\n\n/**\n * The `SortDropdown` component allows user to select the search results order. This component\n * also allows to change the selected sort programmatically.\n */\nexport default defineComponent({\n name: 'SortDropdown',\n xModule: searchXModule.name,\n components: { BaseDropdown },\n props: {\n /** The list of possible sort values. */\n items: {\n type: Array as PropType<Sort[]>,\n required: true,\n },\n /** The transition to use for opening and closing the dropdown. */\n animation: [String, Object] as PropType<string | Component>,\n },\n emits: ['change'],\n setup(_, { emit }) {\n const $x = use$x()\n\n const { sort: selectedSort } = useState('search')\n const rootRef = ref<typeof BaseDropdown>()\n\n watch(selectedSort, (value: Sort) => $x.emit('SelectedSortProvided', value), {\n immediate: true,\n })\n\n /**\n * Emits the events related to the selection of a sort value.\n *\n * @remarks `(rootRef.value as any)?.$el` because rollup-plugin-vue understands\n * `ref<typeof BaseDropdown>` as VueConstructor which doesn't contain $el.\n *\n * @param sort - The selected sort.\n */\n function emitUserClickedASort(sort: Sort) {\n $x.emit('UserClickedASort', sort, { target: (rootRef.value as any)?.$el })\n emit('change', sort)\n }\n\n return {\n emitUserClickedASort,\n rootRef,\n selectedSort,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Sort Dropdown\n\nThe `SortDropdown` component can be used to change the way the search results are ordered.\n\nTo do so, the list of valid sort values has to be provided using the `items` prop. These are the\nvalues that can be received then in the `SearchAdapter`.\n\nThe component also optionally accepts the selected sort, which can be set using the `v-model` prop.\nThis prop allows changing programmatically the selected sort, as it will be synced with the store\nimmediately. If this prop is not provided, the first item from the `items` prop will be the one\nselected by default.\n\nThis component also allows customizing both the toggle button and each one of the possible sort\nvalues. This can be done with the `toggle` and `item` slots.\n\n## Events\n\nThis component emits 2 different events:\n\n- [`SelectedSortProvided`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n To sync the selected sort with the store state value. This event is emitted as soon as the list of\n items is received, whenever this list changes if there is no provided value, and when the provided\n value changes.\n- [`UserClickedASort`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n As its name suggests, the event is emitted after the user clicks one of the sort options. This does\n not mean that the sort has changed, only that the user has clicked it.\n\n## Examples\n\n### Only providing the list of items\n\n```vue\n<template>\n <SortDropdown :items=\"sortValues\">\n <template #toggle=\"{ item, isOpen }\">{{ item }} {{ isOpen ? '🔼' : '🔽' }}</template>\n <template #item=\"{ item, isHighlighted, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n <span v-if=\"isHighlighted\">🟢</span>\n {{ item }}\n </template>\n </SortDropdown>\n</template>\n\n<script setup>\nimport { SortDropdown } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Providing also the selected value\n\n```vue\n<template>\n <SortDropdown v-model=\"selectedSort\" :items=\"sortValues\">\n <template #toggle=\"{ item, isOpen }\">{{ item }} {{ isOpen ? '🔼' : '🔽' }}</template>\n <template #item=\"{ item, isHighlighted, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n <span v-if=\"isHighlighted\">🟢</span>\n {{ item }}\n </template>\n </SortDropdown>\n</template>\n\n<script setup>\nimport { SortDropdown } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst selectedSort = ref('Price asc')\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n</docs>\n"],"names":["_createBlock","_withCtx","_renderSlot","_normalizeProps","_guardReactiveProps","_createTextVNode"],"mappings":";;;;;;sBACEA,WAAA,CA6Be,uBAAA,EAAA;AAAA,IA5Bb,GAAA,EAAI,SAAA;AAAA,IACH,KAAA,EAAO,IAAA,CAAA,KAAA;AAAA,IACP,aAAA,EAAa,IAAA,CAAA,YAAA;AAAA,IACb,SAAA,EAAW,IAAA,CAAA,SAAA;AAAA,IACZ,KAAA,EAAM,iBAAA;AAAA,IACN,WAAA,EAAU,eAAA;AAAA,IACV,YAAA,EAAW,gBAAA;AAAA,IACV,qBAAA,EAAoB,IAAA,CAAA;AAAA,GAAA,EAAA;AAEV,IAAA,MAAA,EAAMC,OAAA,CAOf,CAA+D,EAP5C,MAAA,EAAQ,IAAA,EAAI,KAAA;AAAA,MAO/BC,UAAA,CAA+D,IAAA,CAAA,MAAA,EAAA,QAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAA/C,MAAA,EAAQ,IAAA,MAAxB,MAA+D;AAAA,QAAAC,eAAA;0BAAd,IAAI,CAAA;AAAA,UAAA;AAAA;AAAA;AAAA,OAAA;;AAE5C,IAAA,IAAA,EAAIJ,OAAA,CAQb,CAAgF,EAR/D,IAAA,EAAM,eAAe,UAAA,EAAU,KAAA;AAAA,MAQhDC,WAAgF,IAAA,CAAA,MAAA,EAAA,MAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAhE,IAAA,EAAM,aAAA,EAAe,UAAA,MAArC,MAAgF;AAAA,QAAAC,eAAA;0BAAd,IAAI,CAAA;AAAA,UAAA;AAAA;AAAA;AAAA,OAAA;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-dropdown.vue2.js","sources":["../../../../../src/x-modules/search/components/sort-dropdown.vue"],"sourcesContent":["<template>\n <BaseDropdown\n ref=\"rootRef\"\n :items=\"items\"\n :model-value=\"selectedSort\"\n :animation=\"animation\"\n class=\"x-sort-dropdown\"\n data-test=\"sort-dropdown\"\n aria-label=\"Select sorting\"\n @update:model-value=\"emitUserClickedASort\"\n >\n <template #toggle=\"{ isOpen, item }\">\n <!--\n @slot Used to render the contents of the dropdown toggle button. If not provided, it uses\n the item slot as fallback.\n @binding {Sort} item - The sort data to render.\n @binding {boolean} isOpen - True if the dropdown is opened, and false if it is closed.\n -->\n <slot v-bind=\"{ isOpen, item }\" name=\"toggle\">{{ item }}</slot>\n </template>\n <template #item=\"{ item, isHighlighted, isSelected }\">\n <!--\n @slot (required) Used to render each one of the items content, and as fallback\n for the toggle button content slot if it is not provided.\n @binding {Sort} item - Sort to render\n @binding {boolean} isHighlighted - True when the item has the focus.\n @binding {boolean} isSelected - True when the item is selected.\n -->\n <slot v-bind=\"{ item, isHighlighted, isSelected }\" name=\"item\">{{ item }}</slot>\n </template>\n </BaseDropdown>\n</template>\n\n<script lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component, PropType } from 'vue'\nimport { defineComponent, ref, watch } from 'vue'\n\nimport BaseDropdown from '../../../components/base-dropdown.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { searchXModule } from '../x-module'\n\n/**\n * The `SortDropdown` component allows user to select the search results order. This component\n * also allows to change the selected sort programmatically.\n */\nexport default defineComponent({\n name: 'SortDropdown',\n xModule: searchXModule.name,\n components: { BaseDropdown },\n props: {\n /** The list of possible sort values. */\n items: {\n type: Array as PropType<Sort[]>,\n required: true,\n },\n /** The transition to use for opening and closing the dropdown. */\n animation: [String, Object] as PropType<string | Component>,\n },\n emits: ['change'],\n setup(_, { emit }) {\n const $x = use$x()\n\n const { sort: selectedSort } = useState('search')\n const rootRef = ref<typeof BaseDropdown>()\n\n watch(selectedSort, (value: Sort) => $x.emit('SelectedSortProvided', value), {\n immediate: true,\n })\n\n /**\n * Emits the events related to the selection of a sort value.\n *\n * @remarks `(rootRef.value as any)?.$el` because rollup-plugin-vue understands\n * `ref<typeof BaseDropdown>` as VueConstructor which doesn't contain $el.\n *\n * @param sort - The selected sort.\n */\n function emitUserClickedASort(sort: Sort) {\n $x.emit('UserClickedASort', sort, { target: (rootRef.value as any)?.$el })\n emit('change', sort)\n }\n\n return {\n emitUserClickedASort,\n rootRef,\n selectedSort,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Sort Dropdown\n\nThe `SortDropdown` component can be used to change the way the search results are ordered.\n\nTo do so, the list of valid sort values has to be provided using the `items` prop. These are the\nvalues that can be received then in the `SearchAdapter`.\n\nThe component also optionally accepts the selected sort, which can be set using the `v-model` prop.\nThis prop allows changing programmatically the selected sort, as it will be synced with the store\nimmediately. If this prop is not provided, the first item from the `items` prop will be the one\nselected by default.\n\nThis component also allows customizing both the toggle button and each one of the possible sort\nvalues. This can be done with the `toggle` and `item` slots.\n\n## Events\n\nThis component emits 2 different events:\n\n- [`SelectedSortProvided`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n To sync the selected sort with the store state value. This event is emitted as soon as the list of\n items is received, whenever this list changes if there is no provided value, and when the provided\n value changes.\n- [`UserClickedASort`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n As its name suggests, the event is emitted after the user clicks one of the sort options. This does\n not mean that the sort has changed, only that the user has clicked it.\n\n## Examples\n\n### Only providing the list of items\n\n```vue\n<template>\n <SortDropdown :items=\"sortValues\">\n <template #toggle=\"{ item, isOpen }\">{{ item }} {{ isOpen ? '🔼' : '🔽' }}</template>\n <template #item=\"{ item, isHighlighted, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n <span v-if=\"isHighlighted\">🟢</span>\n {{ item }}\n </template>\n </SortDropdown>\n</template>\n\n<script setup>\nimport { SortDropdown } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Providing also the selected value\n\n```vue\n<template>\n <SortDropdown v-model=\"selectedSort\" :items=\"sortValues\">\n <template #toggle=\"{ item, isOpen }\">{{ item }} {{ isOpen ? '🔼' : '🔽' }}</template>\n <template #item=\"{ item, isHighlighted, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n <span v-if=\"isHighlighted\">🟢</span>\n {{ item }}\n </template>\n </SortDropdown>\n</template>\n\n<script setup>\nimport { SortDropdown } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst selectedSort = ref('Price asc')\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;;;;AA2CA;;;AAGE;AACF,gBAAe,eAAe,CAAC;AAC7B,IAAA,IAAI,EAAE,cAAc;IACpB,OAAO,EAAE,aAAa,CAAC,IAAI;IAC3B,UAAU,EAAE,EAAE,YAAW,EAAG;AAC5B,IAAA,KAAK,EAAE;;AAEL,QAAA,KAAK,EAAE;AACL,YAAA,IAAI,EAAE,KAAyB;AAC/B,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;;AAED,QAAA,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,CAAiC;AAC5D,KAAA;IACD,KAAK,EAAE,CAAC,QAAQ,CAAC;AACjB,IAAA,KAAK,CAAC,CAAC,EAAE,EAAE,IAAG,EAAG,EAAA;AACf,QAAA,MAAM,EAAC,GAAI,KAAK,EAAC;QAEjB,MAAM,EAAE,IAAI,EAAE,YAAW,KAAM,QAAQ,CAAC,QAAQ,CAAA;AAChD,QAAA,MAAM,OAAM,GAAI,GAAG,EAAsB;AAEzC,QAAA,KAAK,CAAC,YAAY,EAAE,CAAC,KAAW,KAAK,EAAE,CAAC,IAAI,CAAC,sBAAsB,EAAE,KAAK,CAAC,EAAE;AAC3E,YAAA,SAAS,EAAE,IAAI;AAChB,SAAA,CAAA;AAED;;;;;;;AAOE;QACF,SAAS,oBAAoB,CAAC,IAAU,EAAA;AACtC,YAAA,EAAE,CAAC,IAAI,CAAC,kBAAkB,EAAE,IAAI,EAAE,EAAE,MAAM,EAAG,OAAO,CAAC,KAAa,EAAE,KAAK,CAAA;AACzE,YAAA,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAA;QACrB;QAEA,OAAO;YACL,oBAAoB;YACpB,OAAO;YACP,YAAY;SACd;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-list.vue.js","sources":["../../../../../src/x-modules/search/components/sort-list.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" tag=\"ul\" class=\"x-option-list x-sort-list\" data-test=\"sort-list\">\n <li\n v-for=\"{ item, cssClasses, event } in listItems\"\n :key=\"item\"\n :class=\"cssClasses\"\n class=\"x-option-list__item x-sort-list__item\"\n >\n <BaseEventButton\n class=\"x-sort-list__button xds:button\"\n data-test=\"x-sort-button\"\n :events=\"event\"\n >\n <slot v-bind=\"{ item, isSelected: item === selectedSort }\">\n {{ item }}\n </slot>\n </BaseEventButton>\n </li>\n </component>\n</template>\n\n<script lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component, PropType } from 'vue'\nimport type { VueCSSClasses } from '../../../utils/types'\nimport type { XEventsTypes } from '../../../wiring/events.types'\nimport { computed, defineComponent, watch } from 'vue'\nimport BaseEventButton from '../../../components/base-event-button.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { searchXModule } from '../x-module'\n\n/**\n * Sort list item options.\n */\ninterface SortListItem {\n item: Sort\n cssClasses: VueCSSClasses\n event: Partial<XEventsTypes>\n}\n\n/**\n * The `SortList` component allows user to select the search results order. This component\n * also allows to change the selected sort programmatically.\n */\nexport default defineComponent({\n name: 'SortList',\n xModule: searchXModule.name,\n components: { BaseEventButton },\n props: {\n /** The list of possible sort values. */\n items: {\n type: Array as PropType<Sort[]>,\n required: true,\n },\n /** The transition to use for rendering the list. */\n animation: {\n type: [String, Object] as PropType<string | Component>,\n default: () => 'ul',\n },\n },\n setup(props) {\n const $x = use$x()\n\n const { sort: selectedSort } = useState('search')\n\n watch(selectedSort, (value: Sort) => $x.emit('SelectedSortProvided', value), {\n immediate: true,\n })\n\n /**\n * Sort list items.\n *\n * @returns A list of items with their css class and the event associate to it.\n */\n const listItems = computed<SortListItem[]>(() =>\n props.items.map(item => ({\n item,\n cssClasses: {\n 'x-sort-list__item--is-selected': item === selectedSort.value,\n 'x-option-list__item--is-selected': item === selectedSort.value,\n },\n event: { UserClickedASort: item },\n })),\n )\n\n return {\n listItems,\n selectedSort,\n }\n },\n})\n</script>\n\n<style lang=\"css\" scoped>\n.x-sort-list {\n list-style-type: none;\n}\n</style>\n\n<docs lang=\"mdx\">\n## Sort List\n\nThe `SortList` component can be used to change the way the search results are ordered.\n\nTo do so, the list of valid sort values has to be provided using the `items` prop. These are the\nvalues that can then be received in the `SearchAdapter`.\n\nThe component also optionally accepts the selected sort, which can be set using the `v-model` prop.\nThis prop allows changing programmatically the selected sort, as it will be synced with the store\nimmediately. If this prop is not provided, the first item from the `items` prop will be the one\nselected by default.\n\nThis component also allows customizing each one of the possible sort values. This can be done with\nthe default slot.\n\n## Events\n\nThis component emits 2 different events:\n\n- [`SelectedSortProvided`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n To sync the selected sort with the store state value. This event is emitted as soon as the list of\n items is received, whenever this list changes if there is no provided value, and when the provided\n value changes.\n- [`UserClickedASort`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n As its name suggests, the event is emitted after the user clicks one of the sort options. This does\n not mean that the sort has changed, only that the user has clicked it.\n\n## Examples\n\n### Only providing the list of items\n\n```vue\n<template>\n <SortList :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">Item: {{ item }}</template>\n </SortList>\n</template>\n\n<script setup>\nimport { SortList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Providing also the selected value\n\n```vue\n<template>\n <SortList v-model=\"selectedSort\" :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n {{ item }}\n </template>\n </SortList>\n</template>\n\n<script setup>\nimport { SortList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst selectedSort = ref('Price asc')\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_renderList","_normalizeClass","_createVNode","_renderSlot","_mergeProps","_createTextVNode"],"mappings":";;;;;;;AACE,EAAA,OAAAA,SAAA,EAAA,EAAAC,WAAA,CAiBYC,wBAjBI,IAAA,CAAA,SAAS,CAAA,EAAA;AAAA,IAAE,GAAA,EAAI,IAAA;AAAA,IAAK,KAAA,EAAM,2BAAA;AAAA,IAA4B,WAAA,EAAU;AAAA,GAAA,EAAA;qBAE5E,MAAgD;AAAA,OAAAF,SAAA,CAAA,IAAA,CAAA,EADlDG,kBAAA;AAAA,QAeKC,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAdmC,IAAA,CAAA,SAAA,EAAS,CAAA,EAAtC,IAAA,EAAM,UAAA,EAAY,KAAA,EAAK,KAAA;AADlC,UAAA,OAAAL,SAAA,EAAA,EAAAG,kBAAA;AAAA,YAeK,IAAA;AAAA,YAAA;AAAA,cAbF,GAAA,EAAK,IAAA;AAAA,cACL,KAAA,EAAKG,cAAA,CAAA,CAAE,UAAA,EACF,uCAAuC,CAAA;AAAA,aAAA;;cAE7CC,WAAA,CAQkB,0BAAA,EAAA;AAAA,gBAPhB,KAAA,EAAM,gCAAA;AAAA,gBACN,WAAA,EAAU,eAAA;AAAA,gBACT,MAAA,EAAQ;AAAA,eAAA,EAAA;iCAET,MAEO;AAAA,kBAFPC,UAAA,CAEO,wBAFPC,UAAA,CAEO,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAFS,MAAI,UAAA,EAAc,IAAA,KAAS,IAAA,CAAA,YAAA,EAAY,CAAA,EAAvD,MAEO;AAAA,oBAAAC,eAAA;sCADF,IAAI,CAAA;AAAA,sBAAA;AAAA;AAAA;AAAA,mBAAA,EAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-list.vue2.js","sources":["../../../../../src/x-modules/search/components/sort-list.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" tag=\"ul\" class=\"x-option-list x-sort-list\" data-test=\"sort-list\">\n <li\n v-for=\"{ item, cssClasses, event } in listItems\"\n :key=\"item\"\n :class=\"cssClasses\"\n class=\"x-option-list__item x-sort-list__item\"\n >\n <BaseEventButton\n class=\"x-sort-list__button xds:button\"\n data-test=\"x-sort-button\"\n :events=\"event\"\n >\n <slot v-bind=\"{ item, isSelected: item === selectedSort }\">\n {{ item }}\n </slot>\n </BaseEventButton>\n </li>\n </component>\n</template>\n\n<script lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component, PropType } from 'vue'\nimport type { VueCSSClasses } from '../../../utils/types'\nimport type { XEventsTypes } from '../../../wiring/events.types'\nimport { computed, defineComponent, watch } from 'vue'\nimport BaseEventButton from '../../../components/base-event-button.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { searchXModule } from '../x-module'\n\n/**\n * Sort list item options.\n */\ninterface SortListItem {\n item: Sort\n cssClasses: VueCSSClasses\n event: Partial<XEventsTypes>\n}\n\n/**\n * The `SortList` component allows user to select the search results order. This component\n * also allows to change the selected sort programmatically.\n */\nexport default defineComponent({\n name: 'SortList',\n xModule: searchXModule.name,\n components: { BaseEventButton },\n props: {\n /** The list of possible sort values. */\n items: {\n type: Array as PropType<Sort[]>,\n required: true,\n },\n /** The transition to use for rendering the list. */\n animation: {\n type: [String, Object] as PropType<string | Component>,\n default: () => 'ul',\n },\n },\n setup(props) {\n const $x = use$x()\n\n const { sort: selectedSort } = useState('search')\n\n watch(selectedSort, (value: Sort) => $x.emit('SelectedSortProvided', value), {\n immediate: true,\n })\n\n /**\n * Sort list items.\n *\n * @returns A list of items with their css class and the event associate to it.\n */\n const listItems = computed<SortListItem[]>(() =>\n props.items.map(item => ({\n item,\n cssClasses: {\n 'x-sort-list__item--is-selected': item === selectedSort.value,\n 'x-option-list__item--is-selected': item === selectedSort.value,\n },\n event: { UserClickedASort: item },\n })),\n )\n\n return {\n listItems,\n selectedSort,\n }\n },\n})\n</script>\n\n<style lang=\"css\" scoped>\n.x-sort-list {\n list-style-type: none;\n}\n</style>\n\n<docs lang=\"mdx\">\n## Sort List\n\nThe `SortList` component can be used to change the way the search results are ordered.\n\nTo do so, the list of valid sort values has to be provided using the `items` prop. These are the\nvalues that can then be received in the `SearchAdapter`.\n\nThe component also optionally accepts the selected sort, which can be set using the `v-model` prop.\nThis prop allows changing programmatically the selected sort, as it will be synced with the store\nimmediately. If this prop is not provided, the first item from the `items` prop will be the one\nselected by default.\n\nThis component also allows customizing each one of the possible sort values. This can be done with\nthe default slot.\n\n## Events\n\nThis component emits 2 different events:\n\n- [`SelectedSortProvided`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n To sync the selected sort with the store state value. This event is emitted as soon as the list of\n items is received, whenever this list changes if there is no provided value, and when the provided\n value changes.\n- [`UserClickedASort`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n As its name suggests, the event is emitted after the user clicks one of the sort options. This does\n not mean that the sort has changed, only that the user has clicked it.\n\n## Examples\n\n### Only providing the list of items\n\n```vue\n<template>\n <SortList :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">Item: {{ item }}</template>\n </SortList>\n</template>\n\n<script setup>\nimport { SortList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Providing also the selected value\n\n```vue\n<template>\n <SortList v-model=\"selectedSort\" :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n {{ item }}\n </template>\n </SortList>\n</template>\n\n<script setup>\nimport { SortList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst selectedSort = ref('Price asc')\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;;;;AAyCA;;;AAGE;AACF,gBAAe,eAAe,CAAC;AAC7B,IAAA,IAAI,EAAE,UAAU;IAChB,OAAO,EAAE,aAAa,CAAC,IAAI;IAC3B,UAAU,EAAE,EAAE,eAAc,EAAG;AAC/B,IAAA,KAAK,EAAE;;AAEL,QAAA,KAAK,EAAE;AACL,YAAA,IAAI,EAAE,KAAyB;AAC/B,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;;AAED,QAAA,SAAS,EAAE;AACT,YAAA,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAiC;AACtD,YAAA,OAAO,EAAE,MAAM,IAAI;AACpB,SAAA;AACF,KAAA;AACD,IAAA,KAAK,CAAC,KAAK,EAAA;AACT,QAAA,MAAM,EAAC,GAAI,KAAK,EAAC;QAEjB,MAAM,EAAE,IAAI,EAAE,YAAW,KAAM,QAAQ,CAAC,QAAQ,CAAA;AAEhD,QAAA,KAAK,CAAC,YAAY,EAAE,CAAC,KAAW,KAAK,EAAE,CAAC,IAAI,CAAC,sBAAsB,EAAE,KAAK,CAAC,EAAE;AAC3E,YAAA,SAAS,EAAE,IAAI;AAChB,SAAA,CAAA;AAED;;;;AAIE;AACF,QAAA,MAAM,SAAQ,GAAI,QAAQ,CAAiB,MACzC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,IAAG,KAAM;YACvB,IAAI;AACJ,YAAA,UAAU,EAAE;AACV,gBAAA,gCAAgC,EAAE,IAAG,KAAM,YAAY,CAAC,KAAK;AAC7D,gBAAA,kCAAkC,EAAE,IAAG,KAAM,YAAY,CAAC,KAAK;AAChE,aAAA;AACD,YAAA,KAAK,EAAE,EAAE,gBAAgB,EAAE,IAAG,EAAG;SAClC,CAAC,CAAC,CACL;QAEA,OAAO;YACL,SAAS;YACT,YAAY;SACd;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-picker-list.vue.js","sources":["../../../../../src/x-modules/search/components/sort-picker-list.vue"],"sourcesContent":["<template>\n <component\n :is=\"animation\"\n tag=\"div\"\n class=\"x-sort-picker-list\"\n data-test=\"sort-picker\"\n role=\"list\"\n >\n <BaseEventButton\n v-for=\"{ item, cssClasses, event } in listItems\"\n :key=\"item\"\n :class=\"[cssClasses, buttonClass]\"\n data-test=\"sort-picker-button\"\n :events=\"event\"\n :aria-pressed=\"item === selectedSort || null\"\n role=\"listitem\"\n >\n <slot v-bind=\"{ item, isSelected: item === selectedSort }\">\n {{ item }}\n </slot>\n </BaseEventButton>\n </component>\n</template>\n\n<script lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component, PropType } from 'vue'\nimport type { SortPickerItem } from './sort-picker-list.types'\nimport { computed, defineComponent, watch } from 'vue'\nimport BaseEventButton from '../../../components/base-event-button.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { searchXModule } from '../x-module'\n\n/**\n * The `SortPickerList` component allows user to select the search results order. This component\n * also allows to change the selected sort programmatically.\n */\nexport default defineComponent({\n name: 'SortPickerList',\n xModule: searchXModule.name,\n components: { BaseEventButton },\n props: {\n /** The list of possible sort values. */\n items: {\n type: Array as PropType<Sort[]>,\n required: true,\n },\n /** The transition to use for rendering the list. */\n animation: {\n type: [String, Object] as PropType<string | Component>,\n default: () => 'div',\n },\n /** Class inherited by each sort button. */\n buttonClass: String,\n },\n setup(props) {\n const $x = use$x()\n\n const { sort: selectedSort } = useState('search')\n\n watch(selectedSort, (value: Sort) => $x.emit('SelectedSortProvided', value), {\n immediate: true,\n })\n\n /**\n * Sort list items.\n *\n * @returns A list of items with their css class and the event associate to it.\n */\n const listItems = computed<SortPickerItem[]>(() =>\n props.items.map(item => ({\n item,\n cssClasses: {\n 'xds:selected': item === selectedSort.value,\n },\n event: { UserClickedASort: item },\n })),\n )\n\n return {\n listItems,\n selectedSort,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Sort Picker List\n\nThe `SortPickerList` component can be used to change the way the search results are ordered.\n\nTo do so, the list of valid sort values has to be provided using the `items` prop. These are the\nvalues that can then be received in the `SearchAdapter`.\n\nThe component also optionally accepts the selected sort, which can be set using the `v-model` prop.\nThis prop allows changing programmatically the selected sort, as it will be synced with the store\nimmediately. If this prop is not provided, the first item from the `items` prop will be the one\nselected by default.\n\nThis component also allows customizing each one of the possible sort values. This can be done with\nthe default slot.\n\n## Events\n\nThis component emits 2 different events:\n\n- [`SelectedSortProvided`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n To sync the selected sort with the store state value. This event is emitted as soon as the list of\n items is received, whenever this list changes if there is no provided value, and when the provided\n value changes.\n- [`UserClickedASort`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n As its name suggests, the event is emitted after the user clicks one of the sort options. This does\n not mean that the sort has changed, only that the user has clicked it.\n\n## Examples\n\n### Only providing the list of items\n\n```vue\n<template>\n <SortPickerList :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">Item: {{ item }}</template>\n </SortPickerList>\n</template>\n\n<script setup>\nimport { SortPickerList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Providing also the selected value\n\n```vue\n<template>\n <SortPickerList v-model=\"selectedSort\" :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n {{ item }}\n </template>\n </SortPickerList>\n</template>\n\n<script setup>\nimport { SortPickerList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst selectedSort = ref('Price asc')\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Customizing the items with classes\n\nThe `buttonClass` prop can be used to add classes to the sort items.\n\n```vue\n<template>\n <SortPickerList :items=\"sortValues\" buttonClass=\"x-button-outlined\" />\n</template>\n\n<script setup>\nimport { SortPickerList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_renderList","_normalizeClass","_renderSlot","_mergeProps","_createTextVNode"],"mappings":";;;;;;AACE,EAAA,OAAAA,SAAA,EAAA,EAAAC,WAAA,CAoBYC,wBAnBL,IAAA,CAAA,SAAS,CAAA,EAAA;AAAA,IACd,GAAA,EAAI,KAAA;AAAA,IACJ,KAAA,EAAM,oBAAA;AAAA,IACN,WAAA,EAAU,aAAA;AAAA,IACV,IAAA,EAAK;AAAA,GAAA,EAAA;qBAGH,MAAgD;AAAA,OAAAF,SAAA,CAAA,IAAA,CAAA,EADlDG,kBAAA;AAAA,QAYkBC,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAXsB,IAAA,CAAA,SAAA,EAAS,CAAA,EAAtC,IAAA,EAAM,UAAA,EAAY,KAAA,EAAK,KAAA;8BADlCJ,WAAA,CAYkB,0BAAA,EAAA;AAAA,YAVf,GAAA,EAAK,IAAA;AAAA,YACL,KAAA,EAAKK,cAAA,CAAA,CAAG,UAAA,EAAY,IAAA,CAAA,WAAW,CAAA,CAAA;AAAA,YAChC,WAAA,EAAU,oBAAA;AAAA,YACT,MAAA,EAAQ,KAAA;AAAA,YACR,cAAA,EAAc,SAAS,IAAA,CAAA,YAAA,IAAY,IAAA;AAAA,YACpC,IAAA,EAAK;AAAA,WAAA,EAAA;6BAEL,MAEO;AAAA,cAFPC,UAAA,CAEO,wBAFPC,UAAA,CAEO,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAFS,MAAI,UAAA,EAAc,IAAA,KAAS,IAAA,CAAA,YAAA,EAAY,CAAA,EAAvD,MAEO;AAAA,gBAAAC,eAAA;kCADF,IAAI,CAAA;AAAA,kBAAA;AAAA;AAAA;AAAA,eAAA;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-picker-list.vue2.js","sources":["../../../../../src/x-modules/search/components/sort-picker-list.vue"],"sourcesContent":["<template>\n <component\n :is=\"animation\"\n tag=\"div\"\n class=\"x-sort-picker-list\"\n data-test=\"sort-picker\"\n role=\"list\"\n >\n <BaseEventButton\n v-for=\"{ item, cssClasses, event } in listItems\"\n :key=\"item\"\n :class=\"[cssClasses, buttonClass]\"\n data-test=\"sort-picker-button\"\n :events=\"event\"\n :aria-pressed=\"item === selectedSort || null\"\n role=\"listitem\"\n >\n <slot v-bind=\"{ item, isSelected: item === selectedSort }\">\n {{ item }}\n </slot>\n </BaseEventButton>\n </component>\n</template>\n\n<script lang=\"ts\">\nimport type { Sort } from '@empathyco/x-types'\nimport type { Component, PropType } from 'vue'\nimport type { SortPickerItem } from './sort-picker-list.types'\nimport { computed, defineComponent, watch } from 'vue'\nimport BaseEventButton from '../../../components/base-event-button.vue'\nimport { use$x } from '../../../composables/use-$x'\nimport { useState } from '../../../composables/use-state'\nimport { searchXModule } from '../x-module'\n\n/**\n * The `SortPickerList` component allows user to select the search results order. This component\n * also allows to change the selected sort programmatically.\n */\nexport default defineComponent({\n name: 'SortPickerList',\n xModule: searchXModule.name,\n components: { BaseEventButton },\n props: {\n /** The list of possible sort values. */\n items: {\n type: Array as PropType<Sort[]>,\n required: true,\n },\n /** The transition to use for rendering the list. */\n animation: {\n type: [String, Object] as PropType<string | Component>,\n default: () => 'div',\n },\n /** Class inherited by each sort button. */\n buttonClass: String,\n },\n setup(props) {\n const $x = use$x()\n\n const { sort: selectedSort } = useState('search')\n\n watch(selectedSort, (value: Sort) => $x.emit('SelectedSortProvided', value), {\n immediate: true,\n })\n\n /**\n * Sort list items.\n *\n * @returns A list of items with their css class and the event associate to it.\n */\n const listItems = computed<SortPickerItem[]>(() =>\n props.items.map(item => ({\n item,\n cssClasses: {\n 'xds:selected': item === selectedSort.value,\n },\n event: { UserClickedASort: item },\n })),\n )\n\n return {\n listItems,\n selectedSort,\n }\n },\n})\n</script>\n\n<docs lang=\"mdx\">\n## Sort Picker List\n\nThe `SortPickerList` component can be used to change the way the search results are ordered.\n\nTo do so, the list of valid sort values has to be provided using the `items` prop. These are the\nvalues that can then be received in the `SearchAdapter`.\n\nThe component also optionally accepts the selected sort, which can be set using the `v-model` prop.\nThis prop allows changing programmatically the selected sort, as it will be synced with the store\nimmediately. If this prop is not provided, the first item from the `items` prop will be the one\nselected by default.\n\nThis component also allows customizing each one of the possible sort values. This can be done with\nthe default slot.\n\n## Events\n\nThis component emits 2 different events:\n\n- [`SelectedSortProvided`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n To sync the selected sort with the store state value. This event is emitted as soon as the list of\n items is received, whenever this list changes if there is no provided value, and when the provided\n value changes.\n- [`UserClickedASort`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n As its name suggests, the event is emitted after the user clicks one of the sort options. This does\n not mean that the sort has changed, only that the user has clicked it.\n\n## Examples\n\n### Only providing the list of items\n\n```vue\n<template>\n <SortPickerList :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">Item: {{ item }}</template>\n </SortPickerList>\n</template>\n\n<script setup>\nimport { SortPickerList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Providing also the selected value\n\n```vue\n<template>\n <SortPickerList v-model=\"selectedSort\" :items=\"sortValues\">\n <template #default=\"{ item, isSelected }\">\n <span v-if=\"isSelected\">✅</span>\n {{ item }}\n </template>\n </SortPickerList>\n</template>\n\n<script setup>\nimport { SortPickerList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst selectedSort = ref('Price asc')\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n\n### Customizing the items with classes\n\nThe `buttonClass` prop can be used to add classes to the sort items.\n\n```vue\n<template>\n <SortPickerList :items=\"sortValues\" buttonClass=\"x-button-outlined\" />\n</template>\n\n<script setup>\nimport { SortPickerList } from '@empathyco/x-components/search'\nimport { ref } from 'vue'\n\nconst sortValues = ref(['Relevance', 'Price asc', 'Price desc'])\n</script>\n```\n</docs>\n"],"names":[],"mappings":";;;;;;AAkCA;;;AAGE;AACF,gBAAe,eAAe,CAAC;AAC7B,IAAA,IAAI,EAAE,gBAAgB;IACtB,OAAO,EAAE,aAAa,CAAC,IAAI;IAC3B,UAAU,EAAE,EAAE,eAAc,EAAG;AAC/B,IAAA,KAAK,EAAE;;AAEL,QAAA,KAAK,EAAE;AACL,YAAA,IAAI,EAAE,KAAyB;AAC/B,YAAA,QAAQ,EAAE,IAAI;AACf,SAAA;;AAED,QAAA,SAAS,EAAE;AACT,YAAA,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAiC;AACtD,YAAA,OAAO,EAAE,MAAM,KAAK;AACrB,SAAA;;AAED,QAAA,WAAW,EAAE,MAAM;AACpB,KAAA;AACD,IAAA,KAAK,CAAC,KAAK,EAAA;AACT,QAAA,MAAM,EAAC,GAAI,KAAK,EAAC;QAEjB,MAAM,EAAE,IAAI,EAAE,YAAW,KAAM,QAAQ,CAAC,QAAQ,CAAA;AAEhD,QAAA,KAAK,CAAC,YAAY,EAAE,CAAC,KAAW,KAAK,EAAE,CAAC,IAAI,CAAC,sBAAsB,EAAE,KAAK,CAAC,EAAE;AAC3E,YAAA,SAAS,EAAE,IAAI;AAChB,SAAA,CAAA;AAED;;;;AAIE;AACF,QAAA,MAAM,YAAY,QAAQ,CAAmB,MAC3C,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,IAAG,KAAM;YACvB,IAAI;AACJ,YAAA,UAAU,EAAE;AACV,gBAAA,cAAc,EAAE,IAAG,KAAM,YAAY,CAAC,KAAK;AAC5C,aAAA;AACD,YAAA,KAAK,EAAE,EAAE,gBAAgB,EAAE,IAAG,EAAG;SAClC,CAAC,CAAC,CACL;QAEA,OAAO;YACL,SAAS;YACT,YAAY;SACd;IACF,CAAC;AACF,CAAA,CAAA;;;;"}
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import type { Sort } from '@empathyco/x-types';
|
|
2
|
-
import type { VueCSSClasses } from '../../../utils/types';
|
|
3
|
-
import type { XEventsTypes } from '../../../wiring/events.types';
|
|
4
|
-
/**
|
|
5
|
-
* Sort Picker item options.
|
|
6
|
-
*/
|
|
7
|
-
export interface SortPickerItem {
|
|
8
|
-
item: Sort;
|
|
9
|
-
cssClasses: VueCSSClasses;
|
|
10
|
-
event: Partial<XEventsTypes>;
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
* The `SortPickerList` component allows user to select the browse results order. This component
|
|
14
|
-
* also allows to change the selected sort programmatically.
|
|
15
|
-
*/
|
|
16
|
-
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
17
|
-
animation: {
|
|
18
|
-
type: null;
|
|
19
|
-
required: false;
|
|
20
|
-
default: string;
|
|
21
|
-
};
|
|
22
|
-
items: {
|
|
23
|
-
type: ArrayConstructor;
|
|
24
|
-
required: true;
|
|
25
|
-
};
|
|
26
|
-
buttonClass: {
|
|
27
|
-
type: StringConstructor;
|
|
28
|
-
required: true;
|
|
29
|
-
};
|
|
30
|
-
}>, (_ctx: any, _cache: any) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
31
|
-
[key: string]: any;
|
|
32
|
-
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
33
|
-
animation: {
|
|
34
|
-
type: null;
|
|
35
|
-
required: false;
|
|
36
|
-
default: string;
|
|
37
|
-
};
|
|
38
|
-
items: {
|
|
39
|
-
type: ArrayConstructor;
|
|
40
|
-
required: true;
|
|
41
|
-
};
|
|
42
|
-
buttonClass: {
|
|
43
|
-
type: StringConstructor;
|
|
44
|
-
required: true;
|
|
45
|
-
};
|
|
46
|
-
}>> & Readonly<{}>, {
|
|
47
|
-
animation: any;
|
|
48
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
49
|
-
export default _default;
|
|
50
|
-
//# sourceMappingURL=browse-sort-picker-list.vue?vue&type=script&setup=true&lang.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"browse-sort-picker-list.vue?vue&type=script&setup=true&lang.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/browse/components/browse-sort-picker-list.vue?vue&type=script&setup=true&lang.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAE9C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AACzD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAOhE;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,IAAI,CAAA;IACV,UAAU,EAAE,aAAa,CAAA;IACzB,KAAK,EAAE,OAAO,CAAC,YAAY,CAAC,CAAA;CAC7B;AAED;;;GAGG;;;;;;;;;;;;;;;WA0CW,GAAG,UAAS,GAAG;;;;;;;;;;;;;;;;;;;AAvC7B,wBAsEE"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-dropdown.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/search/components/sort-dropdown.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAQ9C;;;GAGG;;IAMC,wCAAwC;;cAEvB,QAAQ,CAAC,IAAI,EAAE,CAAC;;;IAGjC,kEAAkE;eACnC,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC;;iCAqBvB,IAAI;;;;IA3BxC,wCAAwC;;cAEvB,QAAQ,CAAC,IAAI,EAAE,CAAC;;;IAGjC,kEAAkE;eACnC,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC;;;;;;AAX/D,wBA2CE"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-list.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/search/components/sort-list.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAC9C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AACzD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAOhE;;GAEG;AACH,UAAU,YAAY;IACpB,IAAI,EAAE,IAAI,CAAA;IACV,UAAU,EAAE,aAAa,CAAA;IACzB,KAAK,EAAE,OAAO,CAAC,YAAY,CAAC,CAAA;CAC7B;AAED;;;GAGG;;IAMC,wCAAwC;;cAEvB,QAAQ,CAAC,IAAI,EAAE,CAAC;;;IAGjC,oDAAoD;;cAExB,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC;;;;;;;IAPxD,wCAAwC;;cAEvB,QAAQ,CAAC,IAAI,EAAE,CAAC;;;IAGjC,oDAAoD;;cAExB,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC;;;;;;;;AAZ5D,wBA8CE"}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { Sort } from '@empathyco/x-types';
|
|
2
|
-
import type { VueCSSClasses } from '../../../utils/types';
|
|
3
|
-
import type { XEventsTypes } from '../../../wiring/events.types';
|
|
4
|
-
/**
|
|
5
|
-
* Sort Picker item options.
|
|
6
|
-
*/
|
|
7
|
-
export interface SortPickerItem {
|
|
8
|
-
item: Sort;
|
|
9
|
-
cssClasses: VueCSSClasses;
|
|
10
|
-
event: Partial<XEventsTypes>;
|
|
11
|
-
}
|
|
12
|
-
//# sourceMappingURL=sort-picker-list.types.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-picker-list.types.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/search/components/sort-picker-list.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AACzD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAEhE;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,IAAI,CAAA;IACV,UAAU,EAAE,aAAa,CAAA;IACzB,KAAK,EAAE,OAAO,CAAC,YAAY,CAAC,CAAA;CAC7B"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sort-picker-list.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../../../src/x-modules/search/components/sort-picker-list.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAC9C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AAO9D;;;GAGG;;IAMC,wCAAwC;;cAEvB,QAAQ,CAAC,IAAI,EAAE,CAAC;;;IAGjC,oDAAoD;;cAExB,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC;;;IAGxD,2CAA2C;;;;;;IAV3C,wCAAwC;;cAEvB,QAAQ,CAAC,IAAI,EAAE,CAAC;;;IAGjC,oDAAoD;;cAExB,QAAQ,CAAC,MAAM,GAAG,SAAS,CAAC;;;IAGxD,2CAA2C;;;;;;;AAf/C,wBA+CE"}
|
|
File without changes
|