@empathyco/x-components 6.0.0-alpha.5 → 6.0.0-alpha.51

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.
Files changed (761) hide show
  1. package/CHANGELOG.md +448 -0
  2. package/core/index.js +8 -1
  3. package/core/index.js.map +1 -1
  4. package/design-system/deprecated-full-theme.css +596 -596
  5. package/docs/API-reference/api/x-adapter-platform.md +12 -0
  6. package/docs/API-reference/api/x-adapter-platform.nextqueriesrelatedpromptsschema.md +11 -0
  7. package/docs/API-reference/api/x-adapter-platform.platformadapter.relatedprompts.md +11 -0
  8. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompt.md +23 -0
  9. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompt.nextqueries.md +11 -0
  10. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompt.suggestiontext.md +11 -0
  11. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompt.tagging.md +11 -0
  12. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompt.type.md +11 -0
  13. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptnextqueriestagging.md +22 -0
  14. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptnextqueriestagging.toolingdisplay.md +11 -0
  15. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptnextqueriestagging.toolingdisplayadd2cart.md +11 -0
  16. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptnextqueriestagging.toolingdisplayclick.md +11 -0
  17. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptsrequest.md +15 -0
  18. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptsresponse.data.md +13 -0
  19. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptsresponse.md +21 -0
  20. package/docs/API-reference/api/x-adapter-platform.platformrelatedpromptsresponse.status.md +11 -0
  21. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompttagging.md +22 -0
  22. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompttagging.nextqueries.md +11 -0
  23. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompttagging.toolingdisplay.md +11 -0
  24. package/docs/API-reference/api/x-adapter-platform.platformrelatedprompttagging.toolingdisplayclick.md +11 -0
  25. package/docs/API-reference/api/x-adapter-platform.platformsearchresponse.catalog.md +6 -0
  26. package/docs/API-reference/api/x-adapter-platform.platformsearchresponse.md +1 -1
  27. package/docs/API-reference/api/x-adapter-platform.relatedpromptschema.md +13 -0
  28. package/docs/API-reference/api/x-adapter-platform.relatedpromptsendpointadapter.md +13 -0
  29. package/docs/API-reference/api/x-adapter-platform.relatedpromptsrequestmapper.md +13 -0
  30. package/docs/API-reference/api/x-adapter-platform.relatedpromptsrequestschema.md +13 -0
  31. package/docs/API-reference/api/x-adapter-platform.relatedpromptsresponsemapper.md +13 -0
  32. package/docs/API-reference/api/x-adapter-platform.relatedpromptsresponseschema.md +13 -0
  33. package/docs/API-reference/api/x-components.animationprop.md +6 -1
  34. package/docs/API-reference/api/x-components.bannerslist.md +3 -3
  35. package/docs/API-reference/api/x-components.baseaddtocart.md +1 -0
  36. package/docs/API-reference/api/x-components.basedropdown.md +5 -5
  37. package/docs/API-reference/api/x-components.baseeventsmodal.md +2 -2
  38. package/docs/API-reference/api/x-components.basegrid.md +3 -3
  39. package/docs/API-reference/api/x-components.baseheadertogglepanel.md +5 -5
  40. package/docs/API-reference/api/x-components.baseidmodal.md +2 -2
  41. package/docs/API-reference/api/x-components.baseidtogglepanel.md +5 -5
  42. package/docs/API-reference/api/x-components.basemodal.md +10 -10
  43. package/docs/API-reference/api/x-components.baseresultimage.md +9 -9
  44. package/docs/API-reference/api/x-components.baseslider.md +70 -0
  45. package/docs/API-reference/api/x-components.basesuggestions.md +3 -3
  46. package/docs/API-reference/api/x-components.basetabspanel.md +8 -8
  47. package/docs/API-reference/api/x-components.basetogglepanel.md +3 -3
  48. package/docs/API-reference/api/x-components.basevariablecolumngrid.md +3 -3
  49. package/docs/API-reference/api/x-components.cancelfetchandsaverelatedprompts.md +13 -0
  50. package/docs/API-reference/api/x-components.configmutations.config.md +11 -0
  51. package/docs/API-reference/api/x-components.configmutations.md +29 -0
  52. package/docs/API-reference/api/x-components.configmutations.mergeconfig.md +24 -0
  53. package/docs/API-reference/api/x-components.configmutations.setconfig.md +24 -0
  54. package/docs/API-reference/api/x-components.createrelatedtagsquerygetter.md +26 -0
  55. package/docs/API-reference/api/x-components.createrelatedtagsquerygetteroptions.getrelatedtags.md +13 -0
  56. package/docs/API-reference/api/x-components.createrelatedtagsquerygetteroptions.md +20 -0
  57. package/docs/API-reference/api/x-components.createtrackrelatedprompttoolingdisplayclickwire.md +19 -0
  58. package/docs/API-reference/api/x-components.createtracktoolingadd2cartwire.md +19 -0
  59. package/docs/API-reference/api/x-components.createtracktoolingdisplaywire.md +19 -0
  60. package/docs/API-reference/api/{x-components.defaultpdpaddtocartservice._constructor_.md → x-components.defaultexternaltaggingservice._constructor_.md} +3 -3
  61. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.add_to_cart_id_key.md +13 -0
  62. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.instance.md +13 -0
  63. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.localstorageservice.md +11 -0
  64. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.md +43 -0
  65. package/docs/API-reference/api/{x-components.defaultpdpaddtocartservice.movetosessionstorage.md → x-components.defaultexternaltaggingservice.movetosessionstorage.md} +2 -2
  66. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.result_clicked_id_key.md +13 -0
  67. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.sessionstorageservice.md +11 -0
  68. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.storagekey.md +11 -0
  69. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.storagettlms.md +11 -0
  70. package/docs/API-reference/api/{x-components.defaultpdpaddtocartservice.store.md → x-components.defaultexternaltaggingservice.store.md} +2 -2
  71. package/docs/API-reference/api/x-components.defaultexternaltaggingservice.storeaddtocart.md +24 -0
  72. package/docs/API-reference/api/{x-components.defaultpdpaddtocartservice.storeresultclicked.md → x-components.defaultexternaltaggingservice.storeresultclicked.md} +3 -3
  73. package/docs/API-reference/api/{x-components.defaultpdpaddtocartservice.trackaddtocart.md → x-components.defaultexternaltaggingservice.trackaddtocart.md} +3 -3
  74. package/docs/API-reference/api/x-components.displayclickprovider.md +66 -0
  75. package/docs/API-reference/api/x-components.empathize.md +6 -6
  76. package/docs/API-reference/api/x-components.empathizemutations.md +1 -1
  77. package/docs/API-reference/api/x-components.externaltaggingservice.md +23 -0
  78. package/docs/API-reference/api/{x-components.pdpaddtocartservice.movetosessionstorage.md → x-components.externaltaggingservice.movetosessionstorage.md} +2 -2
  79. package/docs/API-reference/api/x-components.externaltaggingservice.storeaddtocart.md +24 -0
  80. package/docs/API-reference/api/{x-components.pdpaddtocartservice.storeresultclicked.md → x-components.externaltaggingservice.storeresultclicked.md} +3 -3
  81. package/docs/API-reference/api/{x-components.pdpaddtocartservice.trackaddtocart.md → x-components.externaltaggingservice.trackaddtocart.md} +3 -3
  82. package/docs/API-reference/api/x-components.facets.md +3 -3
  83. package/docs/API-reference/api/x-components.facetsmutations.md +1 -1
  84. package/docs/API-reference/api/x-components.featurelocation.md +1 -1
  85. package/docs/API-reference/api/x-components.fetchandsaverelatedprompts.md +13 -0
  86. package/docs/API-reference/api/x-components.fetchrelatedprompts.md +13 -0
  87. package/docs/API-reference/api/x-components.filterslist.md +3 -3
  88. package/docs/API-reference/api/x-components.globalxbus.md +12 -0
  89. package/docs/API-reference/api/x-components.hierarchicalfilter.md +8 -2
  90. package/docs/API-reference/api/x-components.historyqueriesmutations.md +1 -1
  91. package/docs/API-reference/api/x-components.historyqueriesstate.md +1 -1
  92. package/docs/API-reference/api/x-components.identifierresults.md +3 -3
  93. package/docs/API-reference/api/x-components.identifierresultsmutations.md +1 -1
  94. package/docs/API-reference/api/x-components.identifierresultsstate.md +1 -1
  95. package/docs/API-reference/api/x-components.installxoptions.domelement.md +1 -1
  96. package/docs/API-reference/api/x-components.installxoptions.installextraplugins.md +2 -2
  97. package/docs/API-reference/api/x-components.installxoptions.md +1 -1
  98. package/docs/API-reference/api/x-components.itemslist.md +3 -3
  99. package/docs/API-reference/api/x-components.mainmodal.md +2 -2
  100. package/docs/API-reference/api/x-components.md +38 -3
  101. package/docs/API-reference/api/x-components.mergeconfig.md +27 -0
  102. package/docs/API-reference/api/x-components.multicolumnmaxwidthlayout.md +5 -5
  103. package/docs/API-reference/api/x-components.myhistory.md +3 -3
  104. package/docs/API-reference/api/x-components.nextqueriesgroup.md +22 -0
  105. package/docs/API-reference/api/x-components.nextqueriesgroup.modelname.md +11 -0
  106. package/docs/API-reference/api/x-components.nextqueriesgroup.nextqueries.md +11 -0
  107. package/docs/API-reference/api/x-components.nextquerieslist.md +3 -3
  108. package/docs/API-reference/api/x-components.nextqueriesmutations.md +1 -1
  109. package/docs/API-reference/api/x-components.nextqueriesstate.md +1 -1
  110. package/docs/API-reference/api/x-components.pageselector.md +80 -0
  111. package/docs/API-reference/api/x-components.partialresultslist.md +3 -3
  112. package/docs/API-reference/api/x-components.popularsearchesmutations.md +1 -1
  113. package/docs/API-reference/api/x-components.promotedslist.md +3 -3
  114. package/docs/API-reference/api/x-components.queriespreviewmutations.md +1 -1
  115. package/docs/API-reference/api/x-components.queryfeature.md +1 -1
  116. package/docs/API-reference/api/x-components.querymutations.md +20 -0
  117. package/docs/API-reference/api/x-components.querymutations.setquery.md +24 -0
  118. package/docs/API-reference/api/x-components.querypreviewlist.md +3 -3
  119. package/docs/API-reference/api/x-components.querystate.md +20 -0
  120. package/docs/API-reference/api/x-components.querystate.query.md +13 -0
  121. package/docs/API-reference/api/x-components.querysuggestionsmutations.md +1 -1
  122. package/docs/API-reference/api/x-components.querysuggestionsstate.md +1 -1
  123. package/docs/API-reference/api/x-components.recommendations.md +3 -3
  124. package/docs/API-reference/api/x-components.recommendationsmutations.md +1 -1
  125. package/docs/API-reference/api/x-components.relatedprompt.md +33 -0
  126. package/docs/API-reference/api/x-components.relatedpromptrequest.md +13 -0
  127. package/docs/API-reference/api/x-components.relatedpromptsactioncontext.md +15 -0
  128. package/docs/API-reference/api/x-components.relatedpromptsactions.cancelfetchandsaverelatedprompts.md +17 -0
  129. package/docs/API-reference/api/x-components.relatedpromptsactions.fetchandsaverelatedprompts.md +24 -0
  130. package/docs/API-reference/api/x-components.relatedpromptsactions.fetchrelatedprompts.md +24 -0
  131. package/docs/API-reference/api/x-components.relatedpromptsactions.md +22 -0
  132. package/docs/API-reference/api/x-components.relatedpromptsgetters.md +20 -0
  133. package/docs/API-reference/api/x-components.relatedpromptsgetters.request.md +13 -0
  134. package/docs/API-reference/api/x-components.relatedpromptslist.md +72 -0
  135. package/docs/API-reference/api/x-components.relatedpromptsmutations.md +26 -0
  136. package/docs/API-reference/api/x-components.relatedpromptsmutations.resetrelatedpromptsstate.md +17 -0
  137. package/docs/API-reference/api/x-components.relatedpromptsmutations.resetselectedprompt.md +17 -0
  138. package/docs/API-reference/api/x-components.relatedpromptsmutations.setparams.md +24 -0
  139. package/docs/API-reference/api/x-components.relatedpromptsmutations.setrelatedpromptsproducts.md +24 -0
  140. package/docs/API-reference/api/x-components.relatedpromptsmutations.setselectedprompt.md +24 -0
  141. package/docs/API-reference/api/x-components.relatedpromptsmutations.setselectedquery.md +24 -0
  142. package/docs/API-reference/api/x-components.relatedpromptsstate.md +24 -0
  143. package/docs/API-reference/api/x-components.relatedpromptsstate.params.md +13 -0
  144. package/docs/API-reference/api/x-components.relatedpromptsstate.relatedprompts.md +13 -0
  145. package/docs/API-reference/api/x-components.relatedpromptsstate.selectedprompt.md +13 -0
  146. package/docs/API-reference/api/x-components.relatedpromptsstate.selectedquery.md +13 -0
  147. package/docs/API-reference/api/x-components.relatedpromptstaglist.md +73 -0
  148. package/docs/API-reference/api/x-components.relatedpromptsxevents.md +24 -0
  149. package/docs/API-reference/api/x-components.relatedpromptsxevents.relatedpromptsrequestupdated.md +13 -0
  150. package/docs/API-reference/api/x-components.relatedpromptsxevents.userclickedarelatedpromptadd2cart.md +13 -0
  151. package/docs/API-reference/api/x-components.relatedpromptsxevents.userclickedarelatedpromptresult.md +13 -0
  152. package/docs/API-reference/api/x-components.relatedpromptsxevents.userselectedarelatedprompt.md +13 -0
  153. package/docs/API-reference/api/x-components.relatedpromptsxevents.userselectedarelatedpromptquery.md +13 -0
  154. package/docs/API-reference/api/x-components.relatedpromptsxmodule.md +13 -0
  155. package/docs/API-reference/api/x-components.relatedpromptsxstoremodule.md +15 -0
  156. package/docs/API-reference/api/x-components.relatedtags.md +3 -3
  157. package/docs/API-reference/api/x-components.relatedtagsmutations.md +1 -1
  158. package/docs/API-reference/api/x-components.relatedtagsstate.md +1 -1
  159. package/docs/API-reference/api/x-components.resultslist.md +3 -3
  160. package/docs/API-reference/api/x-components.scrolltotop.md +5 -5
  161. package/docs/API-reference/api/x-components.searchboxmutations.md +1 -1
  162. package/docs/API-reference/api/x-components.searchboxstate.md +1 -1
  163. package/docs/API-reference/api/x-components.searchconfig.md +1 -0
  164. package/docs/API-reference/api/x-components.searchconfig.pagemode.md +11 -0
  165. package/docs/API-reference/api/x-components.searchinputplaceholder.md +3 -3
  166. package/docs/API-reference/api/x-components.searchmutations.md +2 -1
  167. package/docs/API-reference/api/x-components.searchmutations.setstats.md +24 -0
  168. package/docs/API-reference/api/x-components.searchstate.md +2 -1
  169. package/docs/API-reference/api/x-components.searchstate.stats.md +13 -0
  170. package/docs/API-reference/api/x-components.searchxevents.md +1 -0
  171. package/docs/API-reference/api/x-components.searchxevents.userselectedapage.md +13 -0
  172. package/docs/API-reference/api/x-components.selectedfilterslist.md +3 -3
  173. package/docs/API-reference/api/x-components.semanticqueriesmutations.md +1 -1
  174. package/docs/API-reference/api/x-components.semanticqueriesstate.md +1 -1
  175. package/docs/API-reference/api/x-components.setconfig.md +27 -0
  176. package/docs/API-reference/api/x-components.setquery.md +25 -0
  177. package/docs/API-reference/api/x-components.simplefilter.md +6 -0
  178. package/docs/API-reference/api/x-components.singlecolumnlayout.md +3 -3
  179. package/docs/API-reference/api/x-components.slidingpanel.md +13 -5
  180. package/docs/API-reference/api/x-components.snippetcallbacks.md +6 -0
  181. package/docs/API-reference/api/x-components.sortdropdown.md +1 -1
  182. package/docs/API-reference/api/x-components.tagging.md +6 -6
  183. package/docs/API-reference/api/x-components.taggingconfig.md +2 -2
  184. package/docs/API-reference/api/{x-components.taggingconfig.clickedresultstoragekey.md → x-components.taggingconfig.storagekey.md} +3 -3
  185. package/docs/API-reference/api/x-components.taggingconfig.storagettlms.md +13 -0
  186. package/docs/API-reference/api/x-components.taggingmutations.md +1 -1
  187. package/docs/API-reference/api/x-components.taggingxevents.md +1 -1
  188. package/docs/API-reference/api/x-components.taggingxevents.resulturltrackingenabled.md +1 -1
  189. package/docs/API-reference/api/x-components.trackrelatedprompttoolingdisplayclickwire.md +13 -0
  190. package/docs/API-reference/api/x-components.tracktoolingadd2cartwire.md +13 -0
  191. package/docs/API-reference/api/x-components.tracktoolingdisplayclickedwire.md +13 -0
  192. package/docs/API-reference/api/x-components.typing.md +13 -0
  193. package/docs/API-reference/api/x-components.typingoptions.md +22 -0
  194. package/docs/API-reference/api/x-components.typingoptions.speed.md +13 -0
  195. package/docs/API-reference/api/x-components.typingoptions.targetattr.md +18 -0
  196. package/docs/API-reference/api/x-components.typingoptions.text.md +13 -0
  197. package/docs/API-reference/api/x-components.urlmutations.md +1 -1
  198. package/docs/API-reference/api/x-components.urlstate.md +1 -1
  199. package/docs/API-reference/api/x-components.usealiasapi.md +1 -0
  200. package/docs/API-reference/api/x-components.usealiasapi.pricestats.md +16 -0
  201. package/docs/API-reference/api/x-components.xeventstypes.md +3 -3
  202. package/docs/API-reference/api/x-components.xmodulestree.md +1 -0
  203. package/docs/API-reference/api/x-components.xmodulestree.relatedprompts.md +11 -0
  204. package/docs/API-reference/api/x-types.md +5 -0
  205. package/docs/API-reference/api/x-types.relatedprompt.md +26 -0
  206. package/docs/API-reference/api/x-types.relatedprompt.nextqueries.md +13 -0
  207. package/docs/API-reference/api/x-types.relatedprompt.relatedpromptnextqueries.md +13 -0
  208. package/docs/API-reference/api/x-types.relatedprompt.suggestiontext.md +13 -0
  209. package/docs/API-reference/api/x-types.relatedprompt.tagging.md +17 -0
  210. package/docs/API-reference/api/x-types.relatedprompt.toolingdisplaytagging.md +13 -0
  211. package/docs/API-reference/api/x-types.relatedprompt.type.md +13 -0
  212. package/docs/API-reference/api/x-types.relatedpromptnextquery.md +23 -0
  213. package/docs/API-reference/api/x-types.relatedpromptnextquery.query.md +13 -0
  214. package/docs/API-reference/api/x-types.relatedpromptnextquery.toolingdisplayadd2carttagging.md +13 -0
  215. package/docs/API-reference/api/x-types.relatedpromptnextquery.toolingdisplayclicktagging.md +13 -0
  216. package/docs/API-reference/api/x-types.relatedpromptnextquery.toolingdisplaytagging.md +13 -0
  217. package/docs/API-reference/api/x-types.relatedpromptsrequest.md +15 -0
  218. package/docs/API-reference/api/x-types.relatedpromptsresponse.md +20 -0
  219. package/docs/API-reference/api/x-types.relatedpromptsresponse.relatedprompts.md +11 -0
  220. package/docs/API-reference/api/x-types.searchresponse.md +1 -0
  221. package/docs/API-reference/api/x-types.searchresponse.stats.md +11 -0
  222. package/docs/API-reference/api/x-types.stats.md +22 -0
  223. package/docs/API-reference/api/x-types.stats.price.md +14 -0
  224. package/docs/API-reference/api/x-types.xcomponentsadapter.md +1 -0
  225. package/docs/API-reference/api/x-types.xcomponentsadapter.relatedprompts.md +11 -0
  226. package/docs/API-reference/components/common/result/x-components.base-result-image.md +2 -2
  227. package/docs/API-reference/components/common/x-components.base-slider.md +189 -0
  228. package/docs/API-reference/components/common/x-components.display-click-provider.md +17 -0
  229. package/docs/API-reference/components/common/x-components.items-list.md +1 -1
  230. package/docs/API-reference/components/common/x-components.page-selector.md +136 -0
  231. package/docs/API-reference/components/common/x-components.sliding-panel.md +7 -7
  232. package/docs/API-reference/components/facets/x-components.facets/facets.md +1 -1
  233. package/docs/API-reference/components/facets/x-components.lists/selected-filters-list.md +1 -1
  234. package/docs/API-reference/components/related-prompts/x-components.related-prompt.md +22 -0
  235. package/docs/API-reference/components/related-prompts/x-components.related-prompts-list.md +196 -0
  236. package/docs/API-reference/components/related-prompts/x-components.related-prompts-tag-list.md +32 -0
  237. package/docs/API-reference/components/search/x-components.results-list.md +1 -1
  238. package/docs/API-reference/components/tagging/x-components.tagging.md +15 -16
  239. package/js/components/animations/fade-and-slide.vue.js +1 -2
  240. package/js/components/animations/fade-and-slide.vue.js.map +1 -1
  241. package/js/components/base-dropdown.vue.js +1 -3
  242. package/js/components/base-dropdown.vue.js.map +1 -1
  243. package/js/components/base-dropdown.vue2.js +1 -7
  244. package/js/components/base-dropdown.vue2.js.map +1 -1
  245. package/js/components/base-event-button.vue.js +1 -2
  246. package/js/components/base-event-button.vue.js.map +1 -1
  247. package/js/components/base-grid.vue.js +11 -18
  248. package/js/components/base-grid.vue.js.map +1 -1
  249. package/js/components/base-grid.vue2.js.map +1 -1
  250. package/js/components/base-grid.vue3.js +1 -1
  251. package/js/components/base-keyboard-navigation.vue.js +1 -2
  252. package/js/components/base-keyboard-navigation.vue.js.map +1 -1
  253. package/js/components/base-rating.vue.js +1 -3
  254. package/js/components/base-rating.vue.js.map +1 -1
  255. package/js/components/base-slider.vue.js +65 -0
  256. package/js/components/base-slider.vue.js.map +1 -0
  257. package/js/components/base-slider.vue2.js +109 -0
  258. package/js/components/base-slider.vue2.js.map +1 -0
  259. package/js/components/base-slider.vue3.js +7 -0
  260. package/js/components/base-slider.vue3.js.map +1 -0
  261. package/js/components/base-variable-column-grid.vue.js +1 -2
  262. package/js/components/base-variable-column-grid.vue.js.map +1 -1
  263. package/js/components/column-picker/base-column-picker-dropdown.vue.js +1 -3
  264. package/js/components/column-picker/base-column-picker-dropdown.vue.js.map +1 -1
  265. package/js/components/column-picker/base-column-picker-list.vue.js +1 -3
  266. package/js/components/column-picker/base-column-picker-list.vue.js.map +1 -1
  267. package/js/components/display-click-provider.vue.js +74 -0
  268. package/js/components/display-click-provider.vue.js.map +1 -0
  269. package/js/components/display-click-provider.vue2.js +6 -0
  270. package/js/components/display-click-provider.vue2.js.map +1 -0
  271. package/js/components/filters/labels/base-rating-filter-label.vue.js +1 -3
  272. package/js/components/filters/labels/base-rating-filter-label.vue.js.map +1 -1
  273. package/js/components/icons/cross-tiny.vue.js +2 -2
  274. package/js/components/icons/plus.vue.js +2 -2
  275. package/js/components/items-list.vue.js +1 -2
  276. package/js/components/items-list.vue.js.map +1 -1
  277. package/js/components/items-list.vue2.js +2 -2
  278. package/js/components/items-list.vue2.js.map +1 -1
  279. package/js/components/layouts/fixed-header-and-asides-layout.vue.js +1 -7
  280. package/js/components/layouts/fixed-header-and-asides-layout.vue.js.map +1 -1
  281. package/js/components/layouts/multi-column-max-width-layout.vue.js +1 -9
  282. package/js/components/layouts/multi-column-max-width-layout.vue.js.map +1 -1
  283. package/js/components/layouts/single-column-layout.vue.js +1 -9
  284. package/js/components/layouts/single-column-layout.vue.js.map +1 -1
  285. package/js/components/modals/base-events-modal-close.vue.js +1 -2
  286. package/js/components/modals/base-events-modal-close.vue.js.map +1 -1
  287. package/js/components/modals/base-events-modal-open.vue.js +1 -2
  288. package/js/components/modals/base-events-modal-open.vue.js.map +1 -1
  289. package/js/components/modals/base-id-modal-close.vue.js +1 -2
  290. package/js/components/modals/base-id-modal-close.vue.js.map +1 -1
  291. package/js/components/modals/base-id-modal-open.vue.js +1 -2
  292. package/js/components/modals/base-id-modal-open.vue.js.map +1 -1
  293. package/js/components/modals/base-modal.vue.js +1 -2
  294. package/js/components/modals/base-modal.vue.js.map +1 -1
  295. package/js/components/modals/base-modal.vue2.js +13 -6
  296. package/js/components/modals/base-modal.vue2.js.map +1 -1
  297. package/js/components/page-loader-button.vue.js +8 -10
  298. package/js/components/page-loader-button.vue.js.map +1 -1
  299. package/js/components/page-loader-button.vue2.js.map +1 -1
  300. package/js/components/page-loader-button.vue3.js +7 -0
  301. package/js/components/page-loader-button.vue3.js.map +1 -0
  302. package/js/components/page-selector.vue.js +78 -0
  303. package/js/components/page-selector.vue.js.map +1 -0
  304. package/js/components/page-selector.vue2.js +128 -0
  305. package/js/components/page-selector.vue2.js.map +1 -0
  306. package/js/components/page-selector.vue3.js +7 -0
  307. package/js/components/page-selector.vue3.js.map +1 -0
  308. package/js/components/panels/base-header-toggle-panel.vue.js +1 -5
  309. package/js/components/panels/base-header-toggle-panel.vue.js.map +1 -1
  310. package/js/components/panels/base-id-toggle-panel-button.vue.js +1 -2
  311. package/js/components/panels/base-id-toggle-panel-button.vue.js.map +1 -1
  312. package/js/components/panels/base-id-toggle-panel.vue.js +1 -2
  313. package/js/components/panels/base-id-toggle-panel.vue.js.map +1 -1
  314. package/js/components/panels/base-tabs-panel.vue.js +1 -4
  315. package/js/components/panels/base-tabs-panel.vue.js.map +1 -1
  316. package/js/components/panels/base-toggle-panel.vue.js +1 -2
  317. package/js/components/panels/base-toggle-panel.vue.js.map +1 -1
  318. package/js/components/result/base-result-add-to-cart.vue.js +3 -3
  319. package/js/components/result/base-result-add-to-cart.vue.js.map +1 -1
  320. package/js/components/result/base-result-add-to-cart.vue2.js +19 -5
  321. package/js/components/result/base-result-add-to-cart.vue2.js.map +1 -1
  322. package/js/components/result/base-result-current-price.vue.js +1 -2
  323. package/js/components/result/base-result-current-price.vue.js.map +1 -1
  324. package/js/components/result/base-result-image.vue.js +39 -59
  325. package/js/components/result/base-result-image.vue.js.map +1 -1
  326. package/js/components/result/base-result-image.vue2.js +5 -5
  327. package/js/components/result/base-result-image.vue2.js.map +1 -1
  328. package/js/components/result/base-result-link.vue.js +1 -2
  329. package/js/components/result/base-result-link.vue.js.map +1 -1
  330. package/js/components/result/base-result-previous-price.vue.js +1 -2
  331. package/js/components/result/base-result-previous-price.vue.js.map +1 -1
  332. package/js/components/result/base-result-rating.vue.js +1 -4
  333. package/js/components/result/base-result-rating.vue.js.map +1 -1
  334. package/js/components/result/result-variant-selector.vue.js +1 -3
  335. package/js/components/result/result-variant-selector.vue.js.map +1 -1
  336. package/js/components/sliding-panel.vue.js +3 -6
  337. package/js/components/sliding-panel.vue.js.map +1 -1
  338. package/js/components/sliding-panel.vue2.js +2 -2
  339. package/js/components/sliding-panel.vue2.js.map +1 -1
  340. package/js/components/suggestions/base-suggestion.vue.js +1 -2
  341. package/js/components/suggestions/base-suggestion.vue.js.map +1 -1
  342. package/js/components/suggestions/base-suggestions.vue.js +1 -2
  343. package/js/components/suggestions/base-suggestions.vue.js.map +1 -1
  344. package/js/composables/use-alias-api.js +4 -1
  345. package/js/composables/use-alias-api.js.map +1 -1
  346. package/js/composables/use-getter.js +1 -1
  347. package/js/composables/use-state.js +1 -1
  348. package/js/directives/typing.js +58 -0
  349. package/js/directives/typing.js.map +1 -0
  350. package/js/index.js +20 -3
  351. package/js/index.js.map +1 -1
  352. package/js/types/animation-prop.js +5 -0
  353. package/js/types/animation-prop.js.map +1 -1
  354. package/js/x-installer/x-installer/x-installer.js +3 -3
  355. package/js/x-installer/x-installer/x-installer.js.map +1 -1
  356. package/js/x-modules/device/store/emitters.js +1 -0
  357. package/js/x-modules/device/store/emitters.js.map +1 -1
  358. package/js/x-modules/empathize/components/empathize.vue.js +1 -2
  359. package/js/x-modules/empathize/components/empathize.vue.js.map +1 -1
  360. package/js/x-modules/empathize/components/empathize.vue2.js +8 -3
  361. package/js/x-modules/empathize/components/empathize.vue2.js.map +1 -1
  362. package/js/x-modules/empathize/store/emitters.js +1 -0
  363. package/js/x-modules/empathize/store/emitters.js.map +1 -1
  364. package/js/x-modules/experience-controls/store/emitters.js +1 -0
  365. package/js/x-modules/experience-controls/store/emitters.js.map +1 -1
  366. package/js/x-modules/extra-params/components/extra-params.vue.js +1 -1
  367. package/js/x-modules/extra-params/components/extra-params.vue.js.map +1 -1
  368. package/js/x-modules/extra-params/store/emitters.js +1 -0
  369. package/js/x-modules/extra-params/store/emitters.js.map +1 -1
  370. package/js/x-modules/facets/components/facets/facets.vue.js +20 -33
  371. package/js/x-modules/facets/components/facets/facets.vue.js.map +1 -1
  372. package/js/x-modules/facets/components/facets/facets.vue2.js +2 -2
  373. package/js/x-modules/facets/components/facets/facets.vue2.js.map +1 -1
  374. package/js/x-modules/facets/components/filters/all-filter.vue.js +1 -2
  375. package/js/x-modules/facets/components/filters/all-filter.vue.js.map +1 -1
  376. package/js/x-modules/facets/components/filters/editable-number-range-filter.vue.js +1 -6
  377. package/js/x-modules/facets/components/filters/editable-number-range-filter.vue.js.map +1 -1
  378. package/js/x-modules/facets/components/filters/hierarchical-filter.vue.js +1 -3
  379. package/js/x-modules/facets/components/filters/hierarchical-filter.vue.js.map +1 -1
  380. package/js/x-modules/facets/components/filters/number-range-filter.vue.js +1 -3
  381. package/js/x-modules/facets/components/filters/number-range-filter.vue.js.map +1 -1
  382. package/js/x-modules/facets/components/filters/simple-filter.vue.js +1 -3
  383. package/js/x-modules/facets/components/filters/simple-filter.vue.js.map +1 -1
  384. package/js/x-modules/facets/components/lists/filters-list.vue.js +1 -2
  385. package/js/x-modules/facets/components/lists/filters-list.vue.js.map +1 -1
  386. package/js/x-modules/facets/components/lists/filters-search.vue.js +1 -3
  387. package/js/x-modules/facets/components/lists/filters-search.vue.js.map +1 -1
  388. package/js/x-modules/facets/components/lists/selected-filters-list.vue.js +11 -18
  389. package/js/x-modules/facets/components/lists/selected-filters-list.vue.js.map +1 -1
  390. package/js/x-modules/facets/components/lists/selected-filters-list.vue2.js +2 -2
  391. package/js/x-modules/facets/components/lists/selected-filters-list.vue2.js.map +1 -1
  392. package/js/x-modules/facets/components/lists/sliced-filters.vue.js +1 -4
  393. package/js/x-modules/facets/components/lists/sliced-filters.vue.js.map +1 -1
  394. package/js/x-modules/history-queries/components/clear-history-queries.vue.js +1 -2
  395. package/js/x-modules/history-queries/components/clear-history-queries.vue.js.map +1 -1
  396. package/js/x-modules/history-queries/components/history-queries.vue.js +1 -10
  397. package/js/x-modules/history-queries/components/history-queries.vue.js.map +1 -1
  398. package/js/x-modules/history-queries/components/history-query.vue.js +1 -6
  399. package/js/x-modules/history-queries/components/history-query.vue.js.map +1 -1
  400. package/js/x-modules/history-queries/components/my-history.vue.js +1 -4
  401. package/js/x-modules/history-queries/components/my-history.vue.js.map +1 -1
  402. package/js/x-modules/history-queries/components/remove-history-query.vue.js +1 -2
  403. package/js/x-modules/history-queries/components/remove-history-query.vue.js.map +1 -1
  404. package/js/x-modules/history-queries/store/emitters.js +1 -0
  405. package/js/x-modules/history-queries/store/emitters.js.map +1 -1
  406. package/js/x-modules/identifier-results/components/identifier-results.vue.js +1 -2
  407. package/js/x-modules/identifier-results/components/identifier-results.vue.js.map +1 -1
  408. package/js/x-modules/identifier-results/store/emitters.js +1 -0
  409. package/js/x-modules/identifier-results/store/emitters.js.map +1 -1
  410. package/js/x-modules/next-queries/components/next-queries.vue.js +1 -7
  411. package/js/x-modules/next-queries/components/next-queries.vue.js.map +1 -1
  412. package/js/x-modules/next-queries/components/next-query-preview.vue.js +1 -3
  413. package/js/x-modules/next-queries/components/next-query-preview.vue.js.map +1 -1
  414. package/js/x-modules/next-queries/components/next-query.vue.js +1 -4
  415. package/js/x-modules/next-queries/components/next-query.vue.js.map +1 -1
  416. package/js/x-modules/next-queries/store/emitters.js +1 -0
  417. package/js/x-modules/next-queries/store/emitters.js.map +1 -1
  418. package/js/x-modules/popular-searches/components/popular-search.vue.js +1 -4
  419. package/js/x-modules/popular-searches/components/popular-search.vue.js.map +1 -1
  420. package/js/x-modules/popular-searches/components/popular-searches.vue.js +1 -7
  421. package/js/x-modules/popular-searches/components/popular-searches.vue.js.map +1 -1
  422. package/js/x-modules/queries-preview/components/query-preview-button.vue.js +1 -2
  423. package/js/x-modules/queries-preview/components/query-preview-button.vue.js.map +1 -1
  424. package/js/x-modules/queries-preview/components/query-preview-button.vue2.js +6 -0
  425. package/js/x-modules/queries-preview/components/query-preview-button.vue2.js.map +1 -1
  426. package/js/x-modules/queries-preview/components/query-preview-list.vue.js.map +1 -1
  427. package/js/x-modules/queries-preview/components/query-preview-list.vue2.js +15 -2
  428. package/js/x-modules/queries-preview/components/query-preview-list.vue2.js.map +1 -1
  429. package/js/x-modules/queries-preview/components/query-preview.vue.js +1 -2
  430. package/js/x-modules/queries-preview/components/query-preview.vue.js.map +1 -1
  431. package/js/x-modules/queries-preview/components/query-preview.vue2.js +7 -1
  432. package/js/x-modules/queries-preview/components/query-preview.vue2.js.map +1 -1
  433. package/js/x-modules/queries-preview/store/actions/fetch-and-save-query-preview.action.js +2 -1
  434. package/js/x-modules/queries-preview/store/actions/fetch-and-save-query-preview.action.js.map +1 -1
  435. package/js/x-modules/queries-preview/store/emitters.js +1 -0
  436. package/js/x-modules/queries-preview/store/emitters.js.map +1 -1
  437. package/js/x-modules/queries-preview/store/module.js +1 -1
  438. package/js/x-modules/queries-preview/store/module.js.map +1 -1
  439. package/js/x-modules/queries-preview/utils/get-hash-from-query-preview.js +6 -4
  440. package/js/x-modules/queries-preview/utils/get-hash-from-query-preview.js.map +1 -1
  441. package/js/x-modules/query-suggestions/components/query-suggestion.vue.js +1 -4
  442. package/js/x-modules/query-suggestions/components/query-suggestion.vue.js.map +1 -1
  443. package/js/x-modules/query-suggestions/components/query-suggestions.vue.js +1 -7
  444. package/js/x-modules/query-suggestions/components/query-suggestions.vue.js.map +1 -1
  445. package/js/x-modules/query-suggestions/store/emitters.js +1 -0
  446. package/js/x-modules/query-suggestions/store/emitters.js.map +1 -1
  447. package/js/x-modules/recommendations/components/recommendations.vue.js +1 -2
  448. package/js/x-modules/recommendations/components/recommendations.vue.js.map +1 -1
  449. package/js/x-modules/recommendations/store/emitters.js +1 -0
  450. package/js/x-modules/recommendations/store/emitters.js.map +1 -1
  451. package/js/x-modules/related-prompts/components/related-prompt.vue.js +26 -0
  452. package/js/x-modules/related-prompts/components/related-prompt.vue.js.map +1 -0
  453. package/js/x-modules/related-prompts/components/related-prompt.vue2.js +31 -0
  454. package/js/x-modules/related-prompts/components/related-prompt.vue2.js.map +1 -0
  455. package/js/x-modules/related-prompts/components/related-prompt.vue3.js +7 -0
  456. package/js/x-modules/related-prompts/components/related-prompt.vue3.js.map +1 -0
  457. package/js/x-modules/related-prompts/components/related-prompts-list.vue.js +154 -0
  458. package/js/x-modules/related-prompts/components/related-prompts-list.vue.js.map +1 -0
  459. package/js/x-modules/related-prompts/components/related-prompts-list.vue2.js +6 -0
  460. package/js/x-modules/related-prompts/components/related-prompts-list.vue2.js.map +1 -0
  461. package/js/x-modules/related-prompts/components/related-prompts-tag-list.vue.js +98 -0
  462. package/js/x-modules/related-prompts/components/related-prompts-tag-list.vue.js.map +1 -0
  463. package/js/x-modules/related-prompts/components/related-prompts-tag-list.vue2.js +226 -0
  464. package/js/x-modules/related-prompts/components/related-prompts-tag-list.vue2.js.map +1 -0
  465. package/js/x-modules/related-prompts/components/related-prompts-tag-list.vue3.js +7 -0
  466. package/js/x-modules/related-prompts/components/related-prompts-tag-list.vue3.js.map +1 -0
  467. package/js/x-modules/related-prompts/store/actions/fetch-and-save-related-prompts.action.js +29 -0
  468. package/js/x-modules/related-prompts/store/actions/fetch-and-save-related-prompts.action.js.map +1 -0
  469. package/js/x-modules/related-prompts/store/actions/fetch-related-prompts.action.js +20 -0
  470. package/js/x-modules/related-prompts/store/actions/fetch-related-prompts.action.js.map +1 -0
  471. package/js/x-modules/related-prompts/store/emitters.js +15 -0
  472. package/js/x-modules/related-prompts/store/emitters.js.map +1 -0
  473. package/js/x-modules/related-prompts/store/getters/request.getter.js +16 -0
  474. package/js/x-modules/related-prompts/store/getters/request.getter.js.map +1 -0
  475. package/js/x-modules/related-prompts/store/module.js +61 -0
  476. package/js/x-modules/related-prompts/store/module.js.map +1 -0
  477. package/js/x-modules/related-prompts/wiring.js +99 -0
  478. package/js/x-modules/related-prompts/wiring.js.map +1 -0
  479. package/js/x-modules/related-prompts/x-module.js +21 -0
  480. package/js/x-modules/related-prompts/x-module.js.map +1 -0
  481. package/js/x-modules/related-tags/components/related-tag.vue.js +1 -2
  482. package/js/x-modules/related-tags/components/related-tag.vue.js.map +1 -1
  483. package/js/x-modules/related-tags/components/related-tags.vue.js +1 -4
  484. package/js/x-modules/related-tags/components/related-tags.vue.js.map +1 -1
  485. package/js/x-modules/related-tags/store/emitters.js +1 -0
  486. package/js/x-modules/related-tags/store/emitters.js.map +1 -1
  487. package/js/x-modules/scroll/components/scroll-to-top.vue.js +1 -2
  488. package/js/x-modules/scroll/components/scroll-to-top.vue.js.map +1 -1
  489. package/js/x-modules/scroll/components/scroll-to-top.vue2.js +6 -0
  490. package/js/x-modules/scroll/components/scroll-to-top.vue2.js.map +1 -1
  491. package/js/x-modules/scroll/store/emitters.js +1 -0
  492. package/js/x-modules/scroll/store/emitters.js.map +1 -1
  493. package/js/x-modules/search/components/partial-results-list.vue.js +1 -2
  494. package/js/x-modules/search/components/partial-results-list.vue.js.map +1 -1
  495. package/js/x-modules/search/components/results-list.vue.js +2 -2
  496. package/js/x-modules/search/components/results-list.vue.js.map +1 -1
  497. package/js/x-modules/search/components/sort-dropdown.vue.js +1 -3
  498. package/js/x-modules/search/components/sort-dropdown.vue.js.map +1 -1
  499. package/js/x-modules/search/store/actions/fetch-and-save-search-response.action.js +10 -3
  500. package/js/x-modules/search/store/actions/fetch-and-save-search-response.action.js.map +1 -1
  501. package/js/x-modules/search/store/actions/save-search-response.action.js +3 -1
  502. package/js/x-modules/search/store/actions/save-search-response.action.js.map +1 -1
  503. package/js/x-modules/search/store/emitters.js +1 -0
  504. package/js/x-modules/search/store/emitters.js.map +1 -1
  505. package/js/x-modules/search/store/module.js +9 -3
  506. package/js/x-modules/search/store/module.js.map +1 -1
  507. package/js/x-modules/search/wiring.js +4 -0
  508. package/js/x-modules/search/wiring.js.map +1 -1
  509. package/js/x-modules/search-box/components/clear-search-input.vue.js +1 -2
  510. package/js/x-modules/search-box/components/clear-search-input.vue.js.map +1 -1
  511. package/js/x-modules/search-box/components/search-button.vue.js +1 -2
  512. package/js/x-modules/search-box/components/search-button.vue.js.map +1 -1
  513. package/js/x-modules/search-box/store/emitters.js +1 -0
  514. package/js/x-modules/search-box/store/emitters.js.map +1 -1
  515. package/js/x-modules/semantic-queries/components/semantic-queries.vue.js +1 -3
  516. package/js/x-modules/semantic-queries/components/semantic-queries.vue.js.map +1 -1
  517. package/js/x-modules/semantic-queries/components/semantic-query.vue.js +1 -4
  518. package/js/x-modules/semantic-queries/components/semantic-query.vue.js.map +1 -1
  519. package/js/x-modules/tagging/components/tagging.vue.js +8 -7
  520. package/js/x-modules/tagging/components/tagging.vue.js.map +1 -1
  521. package/js/x-modules/tagging/service/{pdp-add-to-cart.service.js → external-tagging.service.js} +56 -25
  522. package/js/x-modules/tagging/service/external-tagging.service.js.map +1 -0
  523. package/js/x-modules/tagging/store/emitters.js +1 -1
  524. package/js/x-modules/tagging/store/emitters.js.map +1 -1
  525. package/js/x-modules/tagging/store/module.js +7 -3
  526. package/js/x-modules/tagging/store/module.js.map +1 -1
  527. package/js/x-modules/tagging/wiring.js +105 -8
  528. package/js/x-modules/tagging/wiring.js.map +1 -1
  529. package/js/x-modules/url/components/url-handler.vue.js.map +1 -1
  530. package/js/x-modules/url/components/url-handler.vue2.js +2 -1
  531. package/js/x-modules/url/components/url-handler.vue2.js.map +1 -1
  532. package/js/x-modules/url/store/emitters.js +1 -0
  533. package/js/x-modules/url/store/emitters.js.map +1 -1
  534. package/package.json +50 -49
  535. package/related-prompts/index.d.ts +1 -0
  536. package/related-prompts/index.js +10 -0
  537. package/report/x-adapter-platform.api.json +936 -81
  538. package/report/x-components.api.json +16366 -17517
  539. package/report/x-components.api.md +806 -213
  540. package/report/x-types.api.json +577 -0
  541. package/tagging/index.js +2 -2
  542. package/types/adapter/e2e-adapter.d.ts.map +1 -1
  543. package/types/adapter/mocked-responses.d.ts +3 -0
  544. package/types/adapter/mocked-responses.d.ts.map +1 -1
  545. package/types/components/base-dropdown.vue.d.ts +5 -5
  546. package/types/components/base-dropdown.vue.d.ts.map +1 -1
  547. package/types/components/base-grid.vue.d.ts +3 -3
  548. package/types/components/base-slider.vue.d.ts +74 -0
  549. package/types/components/base-slider.vue.d.ts.map +1 -0
  550. package/types/components/base-variable-column-grid.vue.d.ts +3 -3
  551. package/types/components/display-click-provider.vue.d.ts +61 -0
  552. package/types/components/display-click-provider.vue.d.ts.map +1 -0
  553. package/types/components/global-x-bus.vue.d.ts +12 -0
  554. package/types/components/global-x-bus.vue.d.ts.map +1 -1
  555. package/types/components/index.d.ts +3 -0
  556. package/types/components/index.d.ts.map +1 -1
  557. package/types/components/items-list.vue.d.ts +3 -3
  558. package/types/components/layouts/multi-column-max-width-layout.vue.d.ts +5 -5
  559. package/types/components/layouts/single-column-layout.vue.d.ts +3 -3
  560. package/types/components/modals/base-events-modal.vue.d.ts +2 -2
  561. package/types/components/modals/base-id-modal.vue.d.ts +2 -2
  562. package/types/components/modals/base-modal.vue.d.ts +10 -10
  563. package/types/components/modals/base-modal.vue.d.ts.map +1 -1
  564. package/types/components/modals/main-modal.vue.d.ts +2 -2
  565. package/types/components/page-selector.vue.d.ts +125 -0
  566. package/types/components/page-selector.vue.d.ts.map +1 -0
  567. package/types/components/panels/base-header-toggle-panel.vue.d.ts +5 -5
  568. package/types/components/panels/base-id-toggle-panel.vue.d.ts +5 -5
  569. package/types/components/panels/base-tabs-panel.vue.d.ts +8 -8
  570. package/types/components/panels/base-toggle-panel.vue.d.ts +3 -3
  571. package/types/components/result/base-result-add-to-cart.vue.d.ts +2 -0
  572. package/types/components/result/base-result-add-to-cart.vue.d.ts.map +1 -1
  573. package/types/components/result/base-result-image.vue.d.ts +10 -10
  574. package/types/components/result/base-result-image.vue.d.ts.map +1 -1
  575. package/types/components/sliding-panel.vue.d.ts +15 -5
  576. package/types/components/sliding-panel.vue.d.ts.map +1 -1
  577. package/types/components/snippet-callbacks.vue.d.ts +6 -0
  578. package/types/components/snippet-callbacks.vue.d.ts.map +1 -1
  579. package/types/components/suggestions/base-suggestions.vue.d.ts +3 -3
  580. package/types/composables/use-alias-api.d.ts +5 -0
  581. package/types/composables/use-alias-api.d.ts.map +1 -1
  582. package/types/composables/use-store.d.ts +2 -2
  583. package/types/composables/use-store.d.ts.map +1 -1
  584. package/types/directives/index.d.ts +1 -0
  585. package/types/directives/index.d.ts.map +1 -1
  586. package/types/directives/typing.d.ts +35 -0
  587. package/types/directives/typing.d.ts.map +1 -0
  588. package/types/index.d.ts +1 -0
  589. package/types/index.d.ts.map +1 -1
  590. package/types/store/index.d.ts +4 -1
  591. package/types/store/index.d.ts.map +1 -1
  592. package/types/tailwind/plugin-options.d.ts +1 -2
  593. package/types/tailwind/plugin-options.d.ts.map +1 -1
  594. package/types/types/animation-prop.d.ts +6 -2
  595. package/types/types/animation-prop.d.ts.map +1 -1
  596. package/types/types/origin.d.ts +2 -2
  597. package/types/types/origin.d.ts.map +1 -1
  598. package/types/types/page-mode.d.ts +2 -0
  599. package/types/types/page-mode.d.ts.map +1 -0
  600. package/types/views/home/types.d.ts +3 -0
  601. package/types/views/home/types.d.ts.map +1 -1
  602. package/types/wiring/events.types.d.ts +3 -1
  603. package/types/wiring/events.types.d.ts.map +1 -1
  604. package/types/x-installer/x-installer/types.d.ts +2 -2
  605. package/types/x-installer/x-installer/types.d.ts.map +1 -1
  606. package/types/x-installer/x-installer/x-installer.d.ts +4 -4
  607. package/types/x-installer/x-installer/x-installer.d.ts.map +1 -1
  608. package/types/x-modules/empathize/components/empathize.vue.d.ts +6 -6
  609. package/types/x-modules/empathize/components/empathize.vue.d.ts.map +1 -1
  610. package/types/x-modules/facets/components/facets/facets.vue.d.ts +3 -3
  611. package/types/x-modules/facets/components/filters/hierarchical-filter.vue.d.ts +8 -2
  612. package/types/x-modules/facets/components/filters/hierarchical-filter.vue.d.ts.map +1 -1
  613. package/types/x-modules/facets/components/filters/simple-filter.vue.d.ts +6 -0
  614. package/types/x-modules/facets/components/filters/simple-filter.vue.d.ts.map +1 -1
  615. package/types/x-modules/facets/components/lists/filters-list.vue.d.ts +3 -3
  616. package/types/x-modules/facets/components/lists/selected-filters-list.vue.d.ts +3 -3
  617. package/types/x-modules/history-queries/components/my-history.vue.d.ts +3 -3
  618. package/types/x-modules/identifier-results/components/identifier-results.vue.d.ts +3 -3
  619. package/types/x-modules/next-queries/components/next-queries-list.vue.d.ts +3 -3
  620. package/types/x-modules/next-queries/index.d.ts +1 -0
  621. package/types/x-modules/next-queries/index.d.ts.map +1 -1
  622. package/types/x-modules/queries-preview/components/query-preview-list.vue.d.ts +3 -3
  623. package/types/x-modules/queries-preview/components/query-preview-list.vue.d.ts.map +1 -1
  624. package/types/x-modules/queries-preview/components/query-preview.vue.d.ts.map +1 -1
  625. package/types/x-modules/queries-preview/store/actions/fetch-and-save-query-preview.action.d.ts.map +1 -1
  626. package/types/x-modules/queries-preview/store/module.d.ts.map +1 -1
  627. package/types/x-modules/queries-preview/utils/get-hash-from-query-preview.d.ts +4 -2
  628. package/types/x-modules/queries-preview/utils/get-hash-from-query-preview.d.ts.map +1 -1
  629. package/types/x-modules/recommendations/components/recommendations.vue.d.ts +3 -3
  630. package/types/x-modules/related-prompts/components/index.d.ts +4 -0
  631. package/types/x-modules/related-prompts/components/index.d.ts.map +1 -0
  632. package/types/x-modules/related-prompts/components/related-prompt.vue.d.ts +28 -0
  633. package/types/x-modules/related-prompts/components/related-prompt.vue.d.ts.map +1 -0
  634. package/types/x-modules/related-prompts/components/related-prompts-list.vue.d.ts +106 -0
  635. package/types/x-modules/related-prompts/components/related-prompts-list.vue.d.ts.map +1 -0
  636. package/types/x-modules/related-prompts/components/related-prompts-tag-list.vue.d.ts +132 -0
  637. package/types/x-modules/related-prompts/components/related-prompts-tag-list.vue.d.ts.map +1 -0
  638. package/types/x-modules/related-prompts/events.types.d.ts +36 -0
  639. package/types/x-modules/related-prompts/events.types.d.ts.map +1 -0
  640. package/types/x-modules/related-prompts/index.d.ts +6 -0
  641. package/types/x-modules/related-prompts/index.d.ts.map +1 -0
  642. package/types/x-modules/related-prompts/store/actions/fetch-and-save-related-prompts.action.d.ts +17 -0
  643. package/types/x-modules/related-prompts/store/actions/fetch-and-save-related-prompts.action.d.ts.map +1 -0
  644. package/types/x-modules/related-prompts/store/actions/fetch-related-prompts.action.d.ts +13 -0
  645. package/types/x-modules/related-prompts/store/actions/fetch-related-prompts.action.d.ts.map +1 -0
  646. package/types/x-modules/related-prompts/store/emitters.d.ts +9 -0
  647. package/types/x-modules/related-prompts/store/emitters.d.ts.map +1 -0
  648. package/types/x-modules/related-prompts/store/getters/request.getter.d.ts +13 -0
  649. package/types/x-modules/related-prompts/store/getters/request.getter.d.ts.map +1 -0
  650. package/types/x-modules/related-prompts/store/index.d.ts +7 -0
  651. package/types/x-modules/related-prompts/store/index.d.ts.map +1 -0
  652. package/types/x-modules/related-prompts/store/module.d.ts +8 -0
  653. package/types/x-modules/related-prompts/store/module.d.ts.map +1 -0
  654. package/types/x-modules/related-prompts/store/types.d.ts +108 -0
  655. package/types/x-modules/related-prompts/store/types.d.ts.map +1 -0
  656. package/types/x-modules/related-prompts/types.d.ts +10 -0
  657. package/types/x-modules/related-prompts/types.d.ts.map +1 -0
  658. package/types/x-modules/related-prompts/wiring.d.ts +38 -0
  659. package/types/x-modules/related-prompts/wiring.d.ts.map +1 -0
  660. package/types/x-modules/related-prompts/x-module.d.ts +16 -0
  661. package/types/x-modules/related-prompts/x-module.d.ts.map +1 -0
  662. package/types/x-modules/related-tags/components/related-tags.vue.d.ts +3 -3
  663. package/types/x-modules/scroll/components/scroll-to-top.vue.d.ts +5 -5
  664. package/types/x-modules/search/components/banners-list.vue.d.ts +3 -3
  665. package/types/x-modules/search/components/partial-results-list.vue.d.ts +3 -3
  666. package/types/x-modules/search/components/promoteds-list.vue.d.ts +3 -3
  667. package/types/x-modules/search/components/results-list.vue.d.ts +3 -3
  668. package/types/x-modules/search/components/sort-dropdown.vue.d.ts +1 -1
  669. package/types/x-modules/search/config.types.d.ts +2 -0
  670. package/types/x-modules/search/config.types.d.ts.map +1 -1
  671. package/types/x-modules/search/events.types.d.ts +4 -0
  672. package/types/x-modules/search/events.types.d.ts.map +1 -1
  673. package/types/x-modules/search/store/actions/fetch-and-save-search-response.action.d.ts.map +1 -1
  674. package/types/x-modules/search/store/actions/save-search-response.action.d.ts.map +1 -1
  675. package/types/x-modules/search/store/module.d.ts +2 -0
  676. package/types/x-modules/search/store/module.d.ts.map +1 -1
  677. package/types/x-modules/search/store/types.d.ts +9 -1
  678. package/types/x-modules/search/store/types.d.ts.map +1 -1
  679. package/types/x-modules/search/wiring.d.ts +4 -0
  680. package/types/x-modules/search/wiring.d.ts.map +1 -1
  681. package/types/x-modules/search-box/components/search-input-placeholder.vue.d.ts +3 -3
  682. package/types/x-modules/tagging/components/tagging.vue.d.ts +14 -12
  683. package/types/x-modules/tagging/components/tagging.vue.d.ts.map +1 -1
  684. package/types/x-modules/tagging/config.types.d.ts +3 -3
  685. package/types/x-modules/tagging/config.types.d.ts.map +1 -1
  686. package/types/x-modules/tagging/events.types.d.ts +2 -2
  687. package/types/x-modules/tagging/service/{pdp-add-to-cart.service.d.ts → external-tagging.service.d.ts} +31 -13
  688. package/types/x-modules/tagging/service/external-tagging.service.d.ts.map +1 -0
  689. package/types/x-modules/tagging/service/index.d.ts +1 -1
  690. package/types/x-modules/tagging/service/index.d.ts.map +1 -1
  691. package/types/x-modules/tagging/service/types.d.ts +13 -4
  692. package/types/x-modules/tagging/service/types.d.ts.map +1 -1
  693. package/types/x-modules/tagging/store/module.d.ts.map +1 -1
  694. package/types/x-modules/tagging/wiring.d.ts +54 -2
  695. package/types/x-modules/tagging/wiring.d.ts.map +1 -1
  696. package/types/x-modules/url/components/url-handler.vue.d.ts.map +1 -1
  697. package/types/x-modules/x-modules.types.d.ts +2 -0
  698. package/types/x-modules/x-modules.types.d.ts.map +1 -1
  699. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.clickedresultstoragekey.md +0 -11
  700. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.clickedresultstoragettlms.md +0 -11
  701. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.instance.md +0 -13
  702. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.localstorageservice.md +0 -11
  703. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.md +0 -41
  704. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.result_clicked_id_key.md +0 -13
  705. package/docs/API-reference/api/x-components.defaultpdpaddtocartservice.sessionstorageservice.md +0 -11
  706. package/docs/API-reference/api/x-components.pdpaddtocartservice.md +0 -22
  707. package/docs/API-reference/api/x-components.taggingconfig.clickedresultstoragettlms.md +0 -13
  708. package/docs/API-reference/api/x-components.usestore.md +0 -19
  709. package/docs/assets/features/overview-my-history.svg +0 -279
  710. package/docs/assets/features/overview-product-results-card.svg +0 -128
  711. package/docs/assets/interface/build-search-ui.svg +0 -167
  712. package/docs/assets/interface/experience-search-intro.svg +0 -1
  713. package/docs/assets/interface/integration-guide.svg +0 -1
  714. package/docs/assets/interface/integration-video.png +0 -0
  715. package/docs/assets/interface/x-architecture.svg +0 -1
  716. package/docs/assets/interface/x-empathize.gif +0 -0
  717. package/docs/assets/interface/x-facets.gif +0 -0
  718. package/docs/assets/interface/x-facets.svg +0 -189
  719. package/docs/assets/interface/x-history-queries.gif +0 -0
  720. package/docs/assets/interface/x-id-results.gif +0 -0
  721. package/docs/assets/interface/x-next-queries.gif +0 -0
  722. package/docs/assets/interface/x-popular-searches.gif +0 -0
  723. package/docs/assets/interface/x-query-suggestions.gif +0 -0
  724. package/docs/assets/interface/x-recommendations.gif +0 -0
  725. package/docs/assets/interface/x-recommendations.svg +0 -472
  726. package/docs/assets/interface/x-related-tags.gif +0 -0
  727. package/docs/assets/interface/x-results-layout.svg +0 -259
  728. package/docs/assets/interface/x-search-box-elements.svg +0 -1
  729. package/docs/assets/interface/x-search-box.svg +0 -60
  730. package/docs/build-search-ui/README.md +0 -127
  731. package/docs/build-search-ui/sidebar.js +0 -7
  732. package/docs/build-search-ui/web-archetype-development-guide.md +0 -186
  733. package/docs/build-search-ui/web-archetype-integration-guide.md +0 -458
  734. package/docs/build-search-ui/web-how-to-use-x-components-guide.md +0 -200
  735. package/docs/build-search-ui/web-x-architecture.md +0 -83
  736. package/docs/build-search-ui/web-x-components-development-guide.md +0 -157
  737. package/docs/experience-search-and-discovery/README.md +0 -132
  738. package/docs/experience-search-and-discovery/empathize.md +0 -119
  739. package/docs/experience-search-and-discovery/facets-and-filters.md +0 -154
  740. package/docs/experience-search-and-discovery/history-queries.md +0 -70
  741. package/docs/experience-search-and-discovery/id-results.md +0 -49
  742. package/docs/experience-search-and-discovery/my-history.md +0 -60
  743. package/docs/experience-search-and-discovery/next-queries.md +0 -72
  744. package/docs/experience-search-and-discovery/popular-searches.md +0 -50
  745. package/docs/experience-search-and-discovery/product-results-ui.md +0 -82
  746. package/docs/experience-search-and-discovery/query-suggestions.md +0 -48
  747. package/docs/experience-search-and-discovery/recommendations.md +0 -134
  748. package/docs/experience-search-and-discovery/related-tags.md +0 -66
  749. package/docs/experience-search-and-discovery/search-box.md +0 -99
  750. package/docs/experience-search-and-discovery/serp-ui.md +0 -125
  751. package/docs/experience-search-and-discovery/sidebar.js +0 -17
  752. package/docs/experience-search-and-discovery/web-local-storage.md +0 -30
  753. package/docs/input-status-machine-state.png +0 -0
  754. package/js/composables/use-store.js +0 -15
  755. package/js/composables/use-store.js.map +0 -1
  756. package/js/utils/options-api.js +0 -4
  757. package/js/utils/options-api.js.map +0 -1
  758. package/js/x-modules/tagging/service/pdp-add-to-cart.service.js.map +0 -1
  759. package/types/utils/options-api.d.ts +0 -3
  760. package/types/utils/options-api.d.ts.map +0 -1
  761. package/types/x-modules/tagging/service/pdp-add-to-cart.service.d.ts.map +0 -1
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './my-history.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, resolveDynamicComponent, withCtx, createElementBlock, Fragment, renderList, renderSlot, createElementVNode, toDisplayString, createVNode, normalizeClass, createCommentVNode, mergeProps, createTextVNode } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, resolveDynamicComponent, withCtx, createElementBlock, Fragment, renderList, renderSlot, createElementVNode, toDisplayString, createVNode, normalizeClass, mergeProps, createTextVNode, createCommentVNode } from 'vue';
3
3
  import './my-history.vue3.js';
4
4
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
5
5
 
@@ -41,7 +41,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
41
41
  animation: _ctx.animation
42
42
  }, {
43
43
  default: withCtx(({ suggestion, index }) => [
44
- createCommentVNode("\n @slot History Query item\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n @binding {() => string} formatTime - Callback to format time to `hh:mm [PM/AM]`\n "),
45
44
  renderSlot(_ctx.$slots, "suggestion", mergeProps({ ref_for: true }, { suggestion, index, formatTime: _ctx.formatTime }), () => [
46
45
  createVNode(_component_HistoryQuery, {
47
46
  suggestion,
@@ -49,7 +48,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
49
48
  class: "x-history-queries__item x-suggestion"
50
49
  }, {
51
50
  default: withCtx(() => [
52
- createCommentVNode("\n @slot History Query content\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n @binding {() => string} formatTime - Callback to format time to `hh:mm [PM/AM]`\n "),
53
51
  renderSlot(_ctx.$slots, "suggestion-content", mergeProps({ ref_for: true }, { suggestion, index, formatTime: _ctx.formatTime }), () => [
54
52
  createTextVNode(
55
53
  toDisplayString(suggestion.query) + " - " + toDisplayString(_ctx.formatTime(suggestion.timestamp)),
@@ -59,7 +57,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
59
57
  ], true)
60
58
  ]),
61
59
  "remove-button-content": withCtx(() => [
62
- createCommentVNode("\n @slot History Query remove button content\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n "),
63
60
  renderSlot(_ctx.$slots, "suggestion-remove-content", mergeProps({ ref_for: true }, { suggestion, index }), void 0, true)
64
61
  ]),
65
62
  _: 2
@@ -1 +1 @@
1
- {"version":3,"file":"my-history.vue.js","sources":["../../../../../src/x-modules/history-queries/components/my-history.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" v-if=\"hasHistoryQueries\" class=\"x-my-history\" tag=\"ul\">\n <li\n v-for=\"(historyQueries, date) in groupByDate\"\n :key=\"date\"\n class=\"x-my-history-item\"\n data-test=\"my-history-item\"\n >\n <slot name=\"date\" :date=\"date\">\n <span class=\"x-my-history-item__date\" data-test=\"my-history-date\">{{ date }}</span>\n </slot>\n <BaseSuggestions\n :suggestions=\"historyQueries\"\n class=\"x-my-history-queries\"\n :class=\"queriesListClass\"\n data-test=\"my-history-queries\"\n :animation=\"animation\"\n >\n <template #default=\"{ suggestion, index }\">\n <!--\n @slot History Query item\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n @binding {() => string} formatTime - Callback to format time to `hh:mm [PM/AM]`\n -->\n <slot name=\"suggestion\" v-bind=\"{ suggestion, index, formatTime }\">\n <HistoryQuery\n :suggestion=\"suggestion\"\n data-test=\"history-query-item\"\n class=\"x-history-queries__item x-suggestion\"\n >\n <template #default>\n <!--\n @slot History Query content\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n @binding {() => string} formatTime - Callback to format time to `hh:mm [PM/AM]`\n -->\n <slot name=\"suggestion-content\" v-bind=\"{ suggestion, index, formatTime }\">\n {{ suggestion.query }} - {{ formatTime(suggestion.timestamp) }}\n </slot>\n </template>\n <template #remove-button-content>\n <!--\n @slot History Query remove button content\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n -->\n <slot name=\"suggestion-remove-content\" v-bind=\"{ suggestion, index }\" />\n </template>\n </HistoryQuery>\n </slot>\n </template>\n </BaseSuggestions>\n </li>\n </component>\n</template>\n\n<script lang=\"ts\">\n import { HistoryQuery as HistoryQueryType } from '@empathyco/x-types';\n import { Dictionary } from '@empathyco/x-utils';\n import { computed, defineComponent, inject } from 'vue';\n import BaseSuggestions from '../../../components/suggestions/base-suggestions.vue';\n import { groupItemsBy, isArrayEmpty } from '../../../utils/array';\n import { SnippetConfig } from '../../../x-installer/api/api.types';\n import { historyQueriesXModule } from '../x-module';\n import { AnimationProp } from '../../../types/index';\n import { useState } from '../../../composables/use-state';\n import HistoryQuery from './history-query.vue';\n\n /**\n * The component renders the full history of user searched queries grouped by the day\n * they were performed.\n *\n * @remarks\n *\n * Allows the user to select one of them, emitting the needed events.\n * A history query is just another type of suggestion that contains a query that the user has\n * made in the past.\n * @public\n */\n export default defineComponent({\n name: 'MyHistory',\n xModule: historyQueriesXModule.name,\n components: {\n HistoryQuery,\n BaseSuggestions\n },\n props: {\n /**\n * Animation component that will be used to animate the suggestions.\n *\n * @public\n */\n animation: {\n type: AnimationProp,\n default: 'ul'\n },\n /**\n * The current locale.\n *\n * @public\n */\n locale: {\n type: String,\n default: 'en'\n },\n /** Class inherited by content element. */\n queriesListClass: String\n },\n setup(props) {\n /**\n * The list of history queries.\n *\n * @internal\n */\n const { historyQueries } = useState('historyQueries', ['historyQueries']);\n\n /**\n * The provided {@link SnippetConfig}.\n *\n * @internal\n */\n const snippetConfig = inject<SnippetConfig | undefined>('snippetConfig');\n\n /**\n * The locale that it is going to be used. It can be the one send it by the snippet config or\n * the one pass it using the prop.\n *\n * @returns The locale to be used.\n * @internal\n */\n const usedLocale = computed(() => snippetConfig?.lang ?? props.locale);\n\n /**\n * Returns a record of history queries grouped by date.\n *\n * @example\n * ```typescript\n * const historyQueriesGrouped = {\n * 'Monday, January 10th, 2022' : [{\n * query: 'lego',\n * modelName: 'HistoryQuery',\n * timestamp: 121312312\n * }],\n * 'Tuesday, January 11th, 2022' : [{\n * query: 'barbie',\n * modelName: 'HistoryQuery',\n * timestamp: 15221212\n * }]\n * }\n * ```\n * @returns The history queries grouped by date.\n * @internal\n */\n const groupByDate = computed((): Dictionary<HistoryQueryType[]> => {\n return groupItemsBy(historyQueries.value as HistoryQueryType[], current => {\n return new Date(current.timestamp).toLocaleDateString(usedLocale.value, {\n day: 'numeric',\n weekday: 'long',\n month: 'long',\n year: 'numeric'\n });\n });\n });\n\n /**\n * Formats a timestamp into `hh:mm [PM/AM]` format.\n *\n * @example\n * ```typescript\n * // locale 'es'\n * console.log(formatTime(Date.now()) // '16:54'.\n *\n * // locale 'en'\n * console.log(formatTime(Date.now()) // '16:54 PM'.\n * ```\n * @param timestamp - The timestamp to format.\n * @returns The formatted time.\n * @internal\n */\n const formatTime = (timestamp: number) =>\n new Date(timestamp).toLocaleTimeString(usedLocale.value, {\n hour: '2-digit',\n minute: '2-digit'\n });\n\n /**\n * The `hasHistoryQueries` computed property is a flag representing if there are history queries\n * stored.\n *\n * @returns True if there are history queries; false otherwise.\n * @internal\n */\n const hasHistoryQueries = computed(\n () => !isArrayEmpty(historyQueries.value as HistoryQueryType[])\n );\n\n return {\n hasHistoryQueries,\n groupByDate,\n historyQueries,\n formatTime\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-my-history {\n display: flex;\n flex-flow: column nowrap;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Events\n\nThis component doesn't emit events.\n\n## See it in action\n\nHere you have a basic example of how the MyHistory is rendered.\n\n```vue\n<template>\n <MyHistory />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with props\n\nIn this example, the my history has been configured to use the 'es' locale.\n\n```vue\n<template>\n <MyHistory :locale=\"es\" />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with the animation\n\n```vue\n<template>\n <MyHistory :animation=\"fadeAndSlide\" />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n import { FadeAndSlide } from '@empathyco/x-components';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n },\n data() {\n return {\n fadeAndSlide: FadeAndSlide\n };\n }\n };\n</script>\n```\n\n### Play with suggestion slot\n\nIn this example, the [`HistoryQuery`](./x-components.history-query.md) component is passed in the\n`suggestion` slot (although any other component could potentially be passed).\n\n```vue\n<template>\n <MyHistory #suggestion=\"{ suggestion }\">\n <HistoryQuery :suggestion=\"suggestion\"></HistoryQuery>\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory, HistoryQuery } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory,\n HistoryQuery\n }\n };\n</script>\n```\n\n### Play with suggestion-content slot\n\nTo continue the previous example, the [`HistoryQuery`](./x-components.history-query.md) component is\npassed in the `suggestion-content` slot, but in addition, an HTML span tag for the text are also\npassed.\n\n```vue\n<template>\n <MyHistory #suggestion-content=\"{ suggestion }\">\n <span>{{ suggestion.query }}</span>\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with suggestion-content slot\n\nIn this example, an HTML span tag for the date are passed.\n\n```vue\n<template>\n <MyHistory #date=\"{ date }\">\n <span>{{ date }}</span>\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with suggestion-content-remove slot\n\nTo continue the previous example, the [`HistoryQuery`](./x-components.history-query.md) component is\npassed in the `suggestion-content` slot, but in addition, a cross icon is also passed to change the\nicon to remove the history query.\n\n```vue\n<template>\n <MyHistory #suggestion-content-remove=\"{ suggestion }\">\n <CrossIcon />\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n import { CrossIcon } from '@empathyco/x-components';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory,\n CrossIcon\n }\n };\n</script>\n```\n\n### Customizing the items with classes\n\nThe `queriesListClass` prop can be used to add classes to the suggestions list.\n\n```vue live\n<template>\n <MyHistory #date=\"{ date }\" queriesListClass=\"x-gap-16\" />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_renderList","_createElementVNode","_toDisplayString","_createVNode","animation","_withCtx","_createCommentVNode","_renderSlot","_mergeProps"],"mappings":";;;;;MAS8C,UAAU,GAAA;AAAA,EAAA,KAAA,EAAA,yBAAA;;;;;AARJ,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AADpD,EAAA,OAAA,IAAA,CAAA,iBAAA,IAAAC,SAAA,EAC0E,EAAAC,WAAA,CAAAC,uBAAA,CAAA,IAAA,CAAA,SAAA,CAAA,EAAA;AAAA,IAAC,GAAI,EAAA,CAAA;AAAA,IAAA,KAAA,EAAA,cAAA;AAD/E,IAAA,GAAA,EAAA,IAAA;AAAA,GAAA,EAAA;;iBAIY,IAAI,CAAA,EAAAC,kBAAA;AAAA,QAAAC,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAAA,IAAA,CAAA,WAAA,EAAA,CAAA,cAAA,EAAA,IAAA,KAAA;AACL,UAAA,OAAAL,SAAA,EAAoB,EAAAG,kBAAA,CAAA,IAAA,EAAA;AAAA,YACzB,GAAA,EAAA,IAAA;AAAA,YAAA,KAAA,EAAA,mBAAA;YAEA,WAEO,EAAA,iBAAA;AAAA,WAAA,EAAA;;AACP,cAAAG,kBAAA;AAAA,gBA0CkB,MAAA;AAAA,gBAAA,UAAA;AAAA,gBAAAC,eAAA,CAAA,IAAA,CAAA;AAAA,gBAAA,CAAA;AAAA;AAAA,eAAA;AAAA,aAzCf,EAAA,IAAA,CAAA;AAAA,YAAAC,WAAA,CAZT,0BAac,EAAA;AAAA,cAEN,WAAU,EAAA,cAAA;AAAA,cACT,sBAAWC,CAAS,sBAAA,EAAA,IAAA,CAAA,gBAAA,CAAA,CAAA;AAAA,cAAA,WAAA,EAAA,oBAAA;cAEV,SAAO,EAAA,IAAA,CAAA,SAAA;AAAA,aAAA,EAAA;AAOhB,cAAA,OAAA,EAAAC,OAAA,CA0BO,CA1BP,EAAA,UAAA,EAAA,KAAA,EAAA,KAAA;AAAA,gBAyBiBC,kBAAA,CAAA,6RAAA,CAAA;AAAA,gBAAAC,UAAA,CAvBZ,KAAY,MAAU,EAAA,YAAA,EAAAC,UAAA,CAAA,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAAA,UAAA,EAAA,KAAA,EAAA,UAAA,EAAA,IAAA,CAAA,UAAA,EAAA,CAAA,EAAA,MAAA;AAAA,kBAAAL,WAAA,CACd,uBAAqB,EAAA;AAAA,oBAC9B,UAAA;AAAA,oBAAA,WAAA,EAAA,oBAAA;oBAEW,KAAO,EAAA,sCAAA;AAAA,mBAAA,EAAA;6BAOhBE,OAEO,CAAA,MAAA;AAAA,sBAAAC,kBAAA,CAxCvB,8TAuC6E,CAAA;AAAA,sBAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,oBAAA,EAAAC,UAAA,CAAA,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAAA,UAAA,EAAA,KAAA,EAAA,UAAA,EAAA,IAAA,CAAA,UAAA,EAAA,CAAA,EAAA,MAAA;;;;;;AAGpD,uBAAA,EAAA,IAAA,CAAA;AAAA,qBAAA,CAAA;AAM+D,oBAAA,uBAAA,EAAAH,OAAA,CAAA,MAAA;AAAA,sBAAAC,kBAAA,CAAA,yOAAA,CAAA;AAhDxF,sBAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,2BAAA,EAAAC,UAAA,CAAA,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAAA,UAAA,EAAA,KAAA,EAAA,CAAA,EAAA,KAAA,CAAA,EAAA,IAAA,CAAA;AAAA,qBAAA,CAAA;;;;AAAA,iBAAA,EAAA,IAAA,CAAA;AAAA,eAAA,CAAA;;;;;AAAA,SAAA,CAAA;AAAA,QAAA,GAAA;AAAA;AAAA,OAAA;AAAA,KAAA,CAAA;AAAA,IAAA,CAAA,EAAA,CAAA;AAAA;AAAA,GAAA,CAAA,IAAAF,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA,CAAA;;;;;;"}
1
+ {"version":3,"file":"my-history.vue.js","sources":["../../../../../src/x-modules/history-queries/components/my-history.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" v-if=\"hasHistoryQueries\" class=\"x-my-history\" tag=\"ul\">\n <li\n v-for=\"(historyQueries, date) in groupByDate\"\n :key=\"date\"\n class=\"x-my-history-item\"\n data-test=\"my-history-item\"\n >\n <slot name=\"date\" :date=\"date\">\n <span class=\"x-my-history-item__date\" data-test=\"my-history-date\">{{ date }}</span>\n </slot>\n <BaseSuggestions\n :suggestions=\"historyQueries\"\n class=\"x-my-history-queries\"\n :class=\"queriesListClass\"\n data-test=\"my-history-queries\"\n :animation=\"animation\"\n >\n <template #default=\"{ suggestion, index }\">\n <!--\n @slot History Query item\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n @binding {() => string} formatTime - Callback to format time to `hh:mm [PM/AM]`\n -->\n <slot name=\"suggestion\" v-bind=\"{ suggestion, index, formatTime }\">\n <HistoryQuery\n :suggestion=\"suggestion\"\n data-test=\"history-query-item\"\n class=\"x-history-queries__item x-suggestion\"\n >\n <template #default>\n <!--\n @slot History Query content\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n @binding {() => string} formatTime - Callback to format time to `hh:mm [PM/AM]`\n -->\n <slot name=\"suggestion-content\" v-bind=\"{ suggestion, index, formatTime }\">\n {{ suggestion.query }} - {{ formatTime(suggestion.timestamp) }}\n </slot>\n </template>\n <template #remove-button-content>\n <!--\n @slot History Query remove button content\n @binding {Suggestion} suggestion - History Query suggestion data\n @binding {number} index - History Query suggestion index\n -->\n <slot name=\"suggestion-remove-content\" v-bind=\"{ suggestion, index }\" />\n </template>\n </HistoryQuery>\n </slot>\n </template>\n </BaseSuggestions>\n </li>\n </component>\n</template>\n\n<script lang=\"ts\">\n import { HistoryQuery as HistoryQueryType } from '@empathyco/x-types';\n import { Dictionary } from '@empathyco/x-utils';\n import { computed, defineComponent, inject } from 'vue';\n import BaseSuggestions from '../../../components/suggestions/base-suggestions.vue';\n import { groupItemsBy, isArrayEmpty } from '../../../utils/array';\n import { SnippetConfig } from '../../../x-installer/api/api.types';\n import { historyQueriesXModule } from '../x-module';\n import { AnimationProp } from '../../../types/index';\n import { useState } from '../../../composables/use-state';\n import HistoryQuery from './history-query.vue';\n\n /**\n * The component renders the full history of user searched queries grouped by the day\n * they were performed.\n *\n * @remarks\n *\n * Allows the user to select one of them, emitting the needed events.\n * A history query is just another type of suggestion that contains a query that the user has\n * made in the past.\n * @public\n */\n export default defineComponent({\n name: 'MyHistory',\n xModule: historyQueriesXModule.name,\n components: {\n HistoryQuery,\n BaseSuggestions\n },\n props: {\n /**\n * Animation component that will be used to animate the suggestions.\n *\n * @public\n */\n animation: {\n type: AnimationProp,\n default: 'ul'\n },\n /**\n * The current locale.\n *\n * @public\n */\n locale: {\n type: String,\n default: 'en'\n },\n /** Class inherited by content element. */\n queriesListClass: String\n },\n setup(props) {\n /**\n * The list of history queries.\n *\n * @internal\n */\n const { historyQueries } = useState('historyQueries', ['historyQueries']);\n\n /**\n * The provided {@link SnippetConfig}.\n *\n * @internal\n */\n const snippetConfig = inject<SnippetConfig | undefined>('snippetConfig');\n\n /**\n * The locale that it is going to be used. It can be the one send it by the snippet config or\n * the one pass it using the prop.\n *\n * @returns The locale to be used.\n * @internal\n */\n const usedLocale = computed(() => snippetConfig?.lang ?? props.locale);\n\n /**\n * Returns a record of history queries grouped by date.\n *\n * @example\n * ```typescript\n * const historyQueriesGrouped = {\n * 'Monday, January 10th, 2022' : [{\n * query: 'lego',\n * modelName: 'HistoryQuery',\n * timestamp: 121312312\n * }],\n * 'Tuesday, January 11th, 2022' : [{\n * query: 'barbie',\n * modelName: 'HistoryQuery',\n * timestamp: 15221212\n * }]\n * }\n * ```\n * @returns The history queries grouped by date.\n * @internal\n */\n const groupByDate = computed((): Dictionary<HistoryQueryType[]> => {\n return groupItemsBy(historyQueries.value as HistoryQueryType[], current => {\n return new Date(current.timestamp).toLocaleDateString(usedLocale.value, {\n day: 'numeric',\n weekday: 'long',\n month: 'long',\n year: 'numeric'\n });\n });\n });\n\n /**\n * Formats a timestamp into `hh:mm [PM/AM]` format.\n *\n * @example\n * ```typescript\n * // locale 'es'\n * console.log(formatTime(Date.now()) // '16:54'.\n *\n * // locale 'en'\n * console.log(formatTime(Date.now()) // '16:54 PM'.\n * ```\n * @param timestamp - The timestamp to format.\n * @returns The formatted time.\n * @internal\n */\n const formatTime = (timestamp: number) =>\n new Date(timestamp).toLocaleTimeString(usedLocale.value, {\n hour: '2-digit',\n minute: '2-digit'\n });\n\n /**\n * The `hasHistoryQueries` computed property is a flag representing if there are history queries\n * stored.\n *\n * @returns True if there are history queries; false otherwise.\n * @internal\n */\n const hasHistoryQueries = computed(\n () => !isArrayEmpty(historyQueries.value as HistoryQueryType[])\n );\n\n return {\n hasHistoryQueries,\n groupByDate,\n historyQueries,\n formatTime\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-my-history {\n display: flex;\n flex-flow: column nowrap;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Events\n\nThis component doesn't emit events.\n\n## See it in action\n\nHere you have a basic example of how the MyHistory is rendered.\n\n```vue\n<template>\n <MyHistory />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with props\n\nIn this example, the my history has been configured to use the 'es' locale.\n\n```vue\n<template>\n <MyHistory :locale=\"es\" />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with the animation\n\n```vue\n<template>\n <MyHistory :animation=\"fadeAndSlide\" />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n import { FadeAndSlide } from '@empathyco/x-components';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n },\n data() {\n return {\n fadeAndSlide: FadeAndSlide\n };\n }\n };\n</script>\n```\n\n### Play with suggestion slot\n\nIn this example, the [`HistoryQuery`](./x-components.history-query.md) component is passed in the\n`suggestion` slot (although any other component could potentially be passed).\n\n```vue\n<template>\n <MyHistory #suggestion=\"{ suggestion }\">\n <HistoryQuery :suggestion=\"suggestion\"></HistoryQuery>\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory, HistoryQuery } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory,\n HistoryQuery\n }\n };\n</script>\n```\n\n### Play with suggestion-content slot\n\nTo continue the previous example, the [`HistoryQuery`](./x-components.history-query.md) component is\npassed in the `suggestion-content` slot, but in addition, an HTML span tag for the text are also\npassed.\n\n```vue\n<template>\n <MyHistory #suggestion-content=\"{ suggestion }\">\n <span>{{ suggestion.query }}</span>\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with suggestion-content slot\n\nIn this example, an HTML span tag for the date are passed.\n\n```vue\n<template>\n <MyHistory #date=\"{ date }\">\n <span>{{ date }}</span>\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n\n### Play with suggestion-content-remove slot\n\nTo continue the previous example, the [`HistoryQuery`](./x-components.history-query.md) component is\npassed in the `suggestion-content` slot, but in addition, a cross icon is also passed to change the\nicon to remove the history query.\n\n```vue\n<template>\n <MyHistory #suggestion-content-remove=\"{ suggestion }\">\n <CrossIcon />\n </MyHistory>\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n import { CrossIcon } from '@empathyco/x-components';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory,\n CrossIcon\n }\n };\n</script>\n```\n\n### Customizing the items with classes\n\nThe `queriesListClass` prop can be used to add classes to the suggestions list.\n\n```vue live\n<template>\n <MyHistory #date=\"{ date }\" queriesListClass=\"x-gap-16\" />\n</template>\n\n<script>\n import { MyHistory } from '@empathyco/x-components/history-queries';\n\n export default {\n name: 'MyHistoryDemo',\n components: {\n MyHistory\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_renderList","_createElementVNode","_toDisplayString","_createVNode","animation","_withCtx","_renderSlot","_mergeProps","_createCommentVNode"],"mappings":";;;;;MAS8C,UAAU,GAAA;AAAA,EAAA,KAAA,EAAA,yBAAA;;;;;AARJ,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AADpD,EAAA,OAAA,IAAA,CAAA,iBAAA,IAAAC,SAAA,EAC0E,EAAAC,WAAA,CAAAC,uBAAA,CAAA,IAAA,CAAA,SAAA,CAAA,EAAA;AAAA,IAAC,GAAI,EAAA,CAAA;AAAA,IAAA,KAAA,EAAA,cAAA;AAD/E,IAAA,GAAA,EAAA,IAAA;AAAA,GAAA,EAAA;;iBAIY,IAAI,CAAA,EAAAC,kBAAA;AAAA,QAAAC,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAAA,IAAA,CAAA,WAAA,EAAA,CAAA,cAAA,EAAA,IAAA,KAAA;AACL,UAAA,OAAAL,SAAA,EAAoB,EAAAG,kBAAA,CAAA,IAAA,EAAA;AAAA,YACzB,GAAA,EAAA,IAAA;AAAA,YAAA,KAAA,EAAA,mBAAA;YAEA,WAEO,EAAA,iBAAA;AAAA,WAAA,EAAA;;AACP,cAAAG,kBAAA;AAAA,gBA0CkB,MAAA;AAAA,gBAAA,UAAA;AAAA,gBAAAC,eAAA,CAAA,IAAA,CAAA;AAAA,gBAAA,CAAA;AAAA;AAAA,eAAA;AAAA,aAzCf,EAAA,IAAA,CAAA;AAAA,YAAAC,WAAA,CAZT,0BAac,EAAA;AAAA,cAEN,WAAU,EAAA,cAAA;AAAA,cACT,sBAAWC,CAAS,sBAAA,EAAA,IAAA,CAAA,gBAAA,CAAA,CAAA;AAAA,cAAA,WAAA,EAAA,oBAAA;cAEV,SAAO,EAAA,IAAA,CAAA,SAAA;AAAA,aAAA,EAAA;uBAQdC,OAwBe,CAAA,CAAA,EAAA,UAAA,EAAA,KAAA,EAAA,KAAA;AAAA,gBAAAC,UAAA,CAvBZ,KAAY,MAAU,EAAA,YAAA,EAAAC,UAAA,CAAA,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAAA,UAAA,EAAA,KAAA,EAAA,UAAA,EAAA,IAAA,CAAA,UAAA,EAAA,CAAA,EAAA,MAAA;AAAA,kBAAAJ,WAAA,CACd,uBAAqB,EAAA;AAAA,oBAC9B,UAAA;AAAA,oBAAA,WAAA,EAAA,oBAAA;oBAEW,KAAO,EAAA,sCAAA;AAAA,mBAAA,EAAA;AA/BhC,oBAAA,OAAA,EAAAE,OAAA,CAAA,MAAA;AAAA,sBAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,oBAAA,EAAAC,UAAA,CAAA,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAAA,UAAA,EAAA,KAAA,EAAA,UAAA,EAAA,IAAA,CAAA,UAAA,EAAA,CAAA,EAAA,MAAA;;;;;;AA0CyB,uBAAA,EAAA,IAAA,CAAA;AAAA,qBAAA,CAAA;;AA1CzB,sBAAAD,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,2BAAA,EAAAC,UAAA,CAAA,EAAA,OAAA,EAAA,IAAA,EAAA,EAAA,EAAA,UAAA,EAAA,KAAA,EAAA,CAAA,EAAA,KAAA,CAAA,EAAA,IAAA,CAAA;AAAA,qBAAA,CAAA;;;;AAAA,iBAAA,EAAA,IAAA,CAAA;AAAA,eAAA,CAAA;;;;;AAAA,SAAA,CAAA;AAAA,QAAA,GAAA;AAAA;AAAA,OAAA;AAAA,KAAA,CAAA;AAAA,IAAA,CAAA,EAAA,CAAA;AAAA;AAAA,GAAA,CAAA,IAAAC,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA,CAAA;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './remove-history-query.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, withCtx, createCommentVNode, renderSlot } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, withCtx, renderSlot } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -10,7 +10,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
10
10
  "aria-label": "remove"
11
11
  }, {
12
12
  default: withCtx(() => [
13
- createCommentVNode(" @slot (Required) Button content with a text, an icon or both "),
14
13
  renderSlot(_ctx.$slots, "default")
15
14
  ]),
16
15
  _: 3
@@ -1 +1 @@
1
- {"version":3,"file":"remove-history-query.vue.js","sources":["../../../../../src/x-modules/history-queries/components/remove-history-query.vue"],"sourcesContent":["<template>\n <BaseEventButton\n class=\"x-remove-history-query\"\n :events=\"removeHistoryQueryEvent\"\n aria-label=\"remove\"\n >\n <!-- @slot (Required) Button content with a text, an icon or both -->\n <slot />\n </BaseEventButton>\n</template>\n\n<script lang=\"ts\">\n import { HistoryQuery } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseEventButton from '../../../components/base-event-button.vue';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { historyQueriesXModule } from '../x-module';\n\n /**\n * Button that when it is pressed emits the\n * {@link HistoryQueriesXEvents.UserPressedRemoveHistoryQuery} event, expressing the user\n * intention to remove a query in the history.\n *\n * @public\n */\n export default defineComponent({\n name: 'RemoveHistoryQuery',\n xModule: historyQueriesXModule.name,\n components: {\n BaseEventButton\n },\n props: {\n /**\n * The historyQuery that will be removed when clicking the clear button.\n *\n * @public\n */\n historyQuery: {\n type: Object as PropType<HistoryQuery>,\n required: true\n }\n },\n setup(props) {\n /**\n * The event handler that will be triggered when clicking on the clear history query button.\n *\n * @remarks\n * {@link HistoryQueriesXEvents.UserPressedRemoveHistoryQuery}: historyQuery\n *\n * @returns The {@link XEvent} to emit.\n * @public\n */\n const removeHistoryQueryEvent = computed(\n (): Partial<XEventsTypes> => ({ UserPressedRemoveHistoryQuery: props.historyQuery })\n );\n\n return {\n removeHistoryQueryEvent\n };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nA list of events that the component will emit:\n\n- [`UserPressedRemoveHistoryQuery`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n the event is emitted after the user clicks the button. The event payload is the history query\n data.\n\n## Examples\n\n### Basic Example\n\nYou can customize the content that this component renders. To do so, simply use the default slot.\n\n```vue\n<RemoveHistoryQuery :historyQuery=\"historyQuery\">\n <img class=\"x-history-query__icon\" src=\"./my-awesome-clear-icon.svg\"/>\n</RemoveHistoryQuery>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_createCommentVNode","_renderSlot"],"mappings":";;;;;AAQoB,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AALT,EAAA,OAAAC,SAAA,EAAyB,EAAAC,WAAA,CAAA,0BAAA,EAAA;AAAA,IAChC,KAAA,EAAA,wBAAA;AAAA,IAAA,MAAA,EAAA,IAAA,CAAA,uBAAA;AAJJ,IAAA,YAAA,EAAA,QAAA;AAAA,GAAA,EAAA;aAOIC,OAAQ,CAAA,MAAA;AAAA,MAAAC,kBAAA,CAAA,iEAAA,CAAA;AAPZ,MAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,SAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
1
+ {"version":3,"file":"remove-history-query.vue.js","sources":["../../../../../src/x-modules/history-queries/components/remove-history-query.vue"],"sourcesContent":["<template>\n <BaseEventButton\n class=\"x-remove-history-query\"\n :events=\"removeHistoryQueryEvent\"\n aria-label=\"remove\"\n >\n <!-- @slot (Required) Button content with a text, an icon or both -->\n <slot />\n </BaseEventButton>\n</template>\n\n<script lang=\"ts\">\n import { HistoryQuery } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseEventButton from '../../../components/base-event-button.vue';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { historyQueriesXModule } from '../x-module';\n\n /**\n * Button that when it is pressed emits the\n * {@link HistoryQueriesXEvents.UserPressedRemoveHistoryQuery} event, expressing the user\n * intention to remove a query in the history.\n *\n * @public\n */\n export default defineComponent({\n name: 'RemoveHistoryQuery',\n xModule: historyQueriesXModule.name,\n components: {\n BaseEventButton\n },\n props: {\n /**\n * The historyQuery that will be removed when clicking the clear button.\n *\n * @public\n */\n historyQuery: {\n type: Object as PropType<HistoryQuery>,\n required: true\n }\n },\n setup(props) {\n /**\n * The event handler that will be triggered when clicking on the clear history query button.\n *\n * @remarks\n * {@link HistoryQueriesXEvents.UserPressedRemoveHistoryQuery}: historyQuery\n *\n * @returns The {@link XEvent} to emit.\n * @public\n */\n const removeHistoryQueryEvent = computed(\n (): Partial<XEventsTypes> => ({ UserPressedRemoveHistoryQuery: props.historyQuery })\n );\n\n return {\n removeHistoryQueryEvent\n };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nA list of events that the component will emit:\n\n- [`UserPressedRemoveHistoryQuery`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n the event is emitted after the user clicks the button. The event payload is the history query\n data.\n\n## Examples\n\n### Basic Example\n\nYou can customize the content that this component renders. To do so, simply use the default slot.\n\n```vue\n<RemoveHistoryQuery :historyQuery=\"historyQuery\">\n <img class=\"x-history-query__icon\" src=\"./my-awesome-clear-icon.svg\"/>\n</RemoveHistoryQuery>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_renderSlot"],"mappings":";;;;;AAQoB,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AALT,EAAA,OAAAC,SAAA,EAAyB,EAAAC,WAAA,CAAA,0BAAA,EAAA;AAAA,IAChC,KAAA,EAAA,wBAAA;AAAA,IAAA,MAAA,EAAA,IAAA,CAAA,uBAAA;AAJJ,IAAA,YAAA,EAAA,QAAA;AAAA,GAAA,EAAA;;AAAA,MAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,SAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
@@ -1,3 +1,4 @@
1
+ import '@empathyco/x-utils';
1
2
  import { createStoreEmitters } from '../../../store/utils/store-emitters.utils.js';
2
3
  import { historyQueriesXStoreModule } from './module.js';
3
4
 
@@ -1 +1 @@
1
- {"version":3,"file":"emitters.js","sources":["../../../../../src/x-modules/history-queries/store/emitters.ts"],"sourcesContent":["import { createStoreEmitters } from '../../../store';\nimport { historyQueriesXStoreModule } from './module';\n\n/**\n * {@link StoreEmitters} For the history-queries module.\n *\n * @internal\n */\nexport const historyQueriesEmitters = createStoreEmitters(historyQueriesXStoreModule, {\n // Used for filtering next-queries with the session history queries\n SessionHistoryQueriesChanged: (_state, getters) => getters.sessionHistoryQueries,\n // Used for refreshing the session until it is extracted from the history queries module\n HistoryQueriesQueryChanged: { immediate: true, selector: state => state.query },\n // Used to load history-queries from the browser storage\n HistoryQueriesStorageKeyChanged: {\n immediate: true,\n selector: (_state, getters) => getters.storageKey\n }\n});\n"],"names":[],"mappings":";;;AAGA;;;;AAIG;AACU,MAAA,sBAAsB,GAAG,mBAAmB,CAAC,0BAA0B,EAAE;;IAEpF,4BAA4B,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,OAAO,CAAC,qBAAqB;;AAEhF,IAAA,0BAA0B,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,IAAI,KAAK,CAAC,KAAK,EAAE;;AAE/E,IAAA,+BAA+B,EAAE;AAC/B,QAAA,SAAS,EAAE,IAAI;QACf,QAAQ,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,OAAO,CAAC,UAAU;AAClD,KAAA;AACF,CAAA;;;;"}
1
+ {"version":3,"file":"emitters.js","sources":["../../../../../src/x-modules/history-queries/store/emitters.ts"],"sourcesContent":["import { createStoreEmitters } from '../../../store';\nimport { historyQueriesXStoreModule } from './module';\n\n/**\n * {@link StoreEmitters} For the history-queries module.\n *\n * @internal\n */\nexport const historyQueriesEmitters = createStoreEmitters(historyQueriesXStoreModule, {\n // Used for filtering next-queries with the session history queries\n SessionHistoryQueriesChanged: (_state, getters) => getters.sessionHistoryQueries,\n // Used for refreshing the session until it is extracted from the history queries module\n HistoryQueriesQueryChanged: { immediate: true, selector: state => state.query },\n // Used to load history-queries from the browser storage\n HistoryQueriesStorageKeyChanged: {\n immediate: true,\n selector: (_state, getters) => getters.storageKey\n }\n});\n"],"names":[],"mappings":";;;;AAGA;;;;AAIG;AACU,MAAA,sBAAsB,GAAG,mBAAmB,CAAC,0BAA0B,EAAE;;IAEpF,4BAA4B,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,OAAO,CAAC,qBAAqB;;AAEhF,IAAA,0BAA0B,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,IAAI,KAAK,CAAC,KAAK,EAAE;;AAE/E,IAAA,+BAA+B,EAAE;AAC/B,QAAA,SAAS,EAAE,IAAI;QACf,QAAQ,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,OAAO,CAAC,UAAU;AAClD,KAAA;AACF,CAAA;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './identifier-results.vue2.js';
2
- import { openBlock, createBlock, resolveDynamicComponent, withCtx, createElementBlock, Fragment, renderList, createCommentVNode, renderSlot } from 'vue';
2
+ import { openBlock, createBlock, resolveDynamicComponent, withCtx, createElementBlock, Fragment, renderList, renderSlot, createCommentVNode } from 'vue';
3
3
  import './identifier-results.vue3.js';
4
4
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
5
5
 
@@ -19,7 +19,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
19
19
  class: "x-identifier-results__item",
20
20
  "data-test": "identifier-results-item"
21
21
  }, [
22
- createCommentVNode("\n @slot (Required) Identifier results item content\n @binding {Result} identifierResult - Identifier Result data\n "),
23
22
  renderSlot(_ctx.$slots, "default", { identifierResult }, void 0, true)
24
23
  ]);
25
24
  }),
@@ -1 +1 @@
1
- {"version":3,"file":"identifier-results.vue.js","sources":["../../../../../src/x-modules/identifier-results/components/identifier-results.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" v-if=\"identifierResults.length\" tag=\"ul\" class=\"x-identifier-results\">\n <li\n v-for=\"identifierResult in identifierResultsToRender\"\n :key=\"identifierResult.id\"\n class=\"x-identifier-results__item\"\n data-test=\"identifier-results-item\"\n >\n <!--\n @slot (Required) Identifier results item content\n @binding {Result} identifierResult - Identifier Result data\n -->\n <slot :identifierResult=\"identifierResult\" />\n </li>\n </component>\n</template>\n\n<script lang=\"ts\">\n import { Result } from '@empathyco/x-types';\n import { computed, defineComponent, provide } from 'vue';\n import { PropsWithType } from '../../../utils/types';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { identifierResultsXModule } from '../x-module';\n import { AnimationProp } from '../../../types/animation-prop';\n import { useState } from '../../../composables/use-state';\n\n /**\n * Paints the list of identifier results stored in the state. Each identifier result should be\n * represented by a {@link IdentifierResult} component besides any\n * other component.\n *\n * @public\n */\n export default defineComponent({\n name: 'IdentifierResults',\n xModule: identifierResultsXModule.name,\n props: {\n /**\n * Animation component that will be used to animate the identifier results.\n *\n * @public\n */\n animation: {\n type: AnimationProp,\n default: 'ul'\n },\n /**\n * Number of identifier results to render.\n *\n * @public\n */\n maxItemsToRender: Number\n },\n setup: function (props) {\n /**\n * The module's list of identifier results.\n *\n * @public\n */\n const { identifierResults } = useState('identifierResults', ['identifierResults']);\n\n /**\n * The additional events to be emitted by the mandatory {@link BaseResultLink} component.\n *\n * @public\n */\n provide<PropsWithType<XEventsTypes, Result>[]>('resultClickExtraEvents', [\n 'UserClickedAIdentifierResult'\n ]);\n\n /**\n * Slices the identifier results from the state.\n *\n * @returns - The list of identifier results sliced by the number of items to render.\n *\n * @internal\n */\n const identifierResultsToRender = computed(() =>\n (identifierResults.value as Result[]).slice(0, props.maxItemsToRender)\n );\n\n return {\n identifierResults,\n identifierResultsToRender\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-identifier-results {\n display: flex;\n flex-flow: column nowrap;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Play with slot\n\nA IdentifierResult **must** be used inside the IdentifierResults component. In the example below the\nBaseResultLink is used as a wrapper and its default slot is filled with the IdentifierResult\ncomponent.\n\n```vue\n<IdentifierResults :animation=\"fadeAndSlide\">\n <template #default=\"{ identifierResult }\">\n <BaseResultLink :result=\"identifierResult\">\n <template #default=\"{ result }\">\n <IdentifierResult :result=\"result\"/>\n </template>\n </BaseResultLink>\n </template>\n</IdentifierResults>\n```\n\n### Play with props\n\nIn this example, the identifier results have been limited to render a maximum of 3 items.\n\n```vue\n<template>\n <IdentifierResults #default=\"{ identifierResult }\" :maxItemsToRender=\"3\">\n <IdentifierResult :result=\"identifierResult\" />\n </IdentifierResults>\n</template>\n\n<script>\n import { IdentifierResults, IdentifierResult } from '@empathyco/x-components';\n\n export default {\n name: 'IdentifierResultsDemo',\n components: {\n IdentifierResults,\n IdentifierResult\n }\n };\n</script>\n```\n</docs>\n"],"names":["animation","_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_renderList","_createCommentVNode"],"mappings":";;;;;AACE,SAAA,WAAA,CAAA,IAAA,EAAA,MAAA,EADF,MACkBA,EAAAA,MAAAA,EAAAA,KAAAA,EAAAA,QAAAA,EAAAA;SADlB,IACqE,CAAA,iBAAA,CAAA,MAAA,IAAAC,SAAA,EAAA,EAAAC,WAAA,CAAAC,uBAAA,CAAA,IAAA,CAAA,SAAA,CAAA,EAAA;AAAA,IAAC,GAAK,EAAA,CAAA;AAAA,IAAA,GAAA,EAAA,IAAA;AAD3E,IAAA,KAAA,EAAA,sBAAA;AAAA,GAAA,EAAA;;AAIY,OAAAF,SAAA,CAAA,IAAA,CAAA,EAAAG,kBAAA;AAAA,QAAmBC,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAAA,IAAA,CAAA,yBAAA,EAAA,CAAA,gBAAA,KAAA;AACpB,UAAA,OAAAL,SAAA,EAA6B,EAAAG,kBAAA,CAAA,IAAA,EAAA;AAAA,YAClC,GAAU,EAAA,gBAAA,CAAA,EAAA;AAAA,YAAA,KAAA,EAAA,4BAAA;AAEV,YAAA,WAAA,EAAA,yBAAA;AAAA,WAIA,EAAA;AAAA,YAAAG,kBAAA,CAAA,6IAAA,CAAA;;;AAZN,SAAA,CAAA;AAAA,QAAA,GAAA;AAAA;AAAA,OAAA;AAAA,KAAA,CAAA;AAAA,IAAA,CAAA,EAAA,CAAA;AAAA;AAAA,GAAA,CAAA,IAAAA,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA,CAAA;;;;;;"}
1
+ {"version":3,"file":"identifier-results.vue.js","sources":["../../../../../src/x-modules/identifier-results/components/identifier-results.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" v-if=\"identifierResults.length\" tag=\"ul\" class=\"x-identifier-results\">\n <li\n v-for=\"identifierResult in identifierResultsToRender\"\n :key=\"identifierResult.id\"\n class=\"x-identifier-results__item\"\n data-test=\"identifier-results-item\"\n >\n <!--\n @slot (Required) Identifier results item content\n @binding {Result} identifierResult - Identifier Result data\n -->\n <slot :identifierResult=\"identifierResult\" />\n </li>\n </component>\n</template>\n\n<script lang=\"ts\">\n import { Result } from '@empathyco/x-types';\n import { computed, defineComponent, provide } from 'vue';\n import { PropsWithType } from '../../../utils/types';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { identifierResultsXModule } from '../x-module';\n import { AnimationProp } from '../../../types/animation-prop';\n import { useState } from '../../../composables/use-state';\n\n /**\n * Paints the list of identifier results stored in the state. Each identifier result should be\n * represented by a {@link IdentifierResult} component besides any\n * other component.\n *\n * @public\n */\n export default defineComponent({\n name: 'IdentifierResults',\n xModule: identifierResultsXModule.name,\n props: {\n /**\n * Animation component that will be used to animate the identifier results.\n *\n * @public\n */\n animation: {\n type: AnimationProp,\n default: 'ul'\n },\n /**\n * Number of identifier results to render.\n *\n * @public\n */\n maxItemsToRender: Number\n },\n setup: function (props) {\n /**\n * The module's list of identifier results.\n *\n * @public\n */\n const { identifierResults } = useState('identifierResults', ['identifierResults']);\n\n /**\n * The additional events to be emitted by the mandatory {@link BaseResultLink} component.\n *\n * @public\n */\n provide<PropsWithType<XEventsTypes, Result>[]>('resultClickExtraEvents', [\n 'UserClickedAIdentifierResult'\n ]);\n\n /**\n * Slices the identifier results from the state.\n *\n * @returns - The list of identifier results sliced by the number of items to render.\n *\n * @internal\n */\n const identifierResultsToRender = computed(() =>\n (identifierResults.value as Result[]).slice(0, props.maxItemsToRender)\n );\n\n return {\n identifierResults,\n identifierResultsToRender\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-identifier-results {\n display: flex;\n flex-flow: column nowrap;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Play with slot\n\nA IdentifierResult **must** be used inside the IdentifierResults component. In the example below the\nBaseResultLink is used as a wrapper and its default slot is filled with the IdentifierResult\ncomponent.\n\n```vue\n<IdentifierResults :animation=\"fadeAndSlide\">\n <template #default=\"{ identifierResult }\">\n <BaseResultLink :result=\"identifierResult\">\n <template #default=\"{ result }\">\n <IdentifierResult :result=\"result\"/>\n </template>\n </BaseResultLink>\n </template>\n</IdentifierResults>\n```\n\n### Play with props\n\nIn this example, the identifier results have been limited to render a maximum of 3 items.\n\n```vue\n<template>\n <IdentifierResults #default=\"{ identifierResult }\" :maxItemsToRender=\"3\">\n <IdentifierResult :result=\"identifierResult\" />\n </IdentifierResults>\n</template>\n\n<script>\n import { IdentifierResults, IdentifierResult } from '@empathyco/x-components';\n\n export default {\n name: 'IdentifierResultsDemo',\n components: {\n IdentifierResults,\n IdentifierResult\n }\n };\n</script>\n```\n</docs>\n"],"names":["animation","_openBlock","_createBlock","_resolveDynamicComponent","_createElementBlock","_Fragment","_renderList","_createCommentVNode"],"mappings":";;;;;AACE,SAAA,WAAA,CAAA,IAAA,EAAA,MAAA,EADF,MACkBA,EAAAA,MAAAA,EAAAA,KAAAA,EAAAA,QAAAA,EAAAA;SADlB,IACqE,CAAA,iBAAA,CAAA,MAAA,IAAAC,SAAA,EAAA,EAAAC,WAAA,CAAAC,uBAAA,CAAA,IAAA,CAAA,SAAA,CAAA,EAAA;AAAA,IAAC,GAAK,EAAA,CAAA;AAAA,IAAA,GAAA,EAAA,IAAA;AAD3E,IAAA,KAAA,EAAA,sBAAA;AAAA,GAAA,EAAA;;AAIY,OAAAF,SAAA,CAAA,IAAA,CAAA,EAAAG,kBAAA;AAAA,QAAmBC,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAAA,IAAA,CAAA,yBAAA,EAAA,CAAA,gBAAA,KAAA;AACpB,UAAA,OAAAL,SAAA,EAA6B,EAAAG,kBAAA,CAAA,IAAA,EAAA;AAAA,YAClC,GAAU,EAAA,gBAAA,CAAA,EAAA;AAAA,YAAA,KAAA,EAAA,4BAAA;YAMV,WAA6C,EAAA,yBAAA;AAAA,WAAA,EAAA;;;AAZnD,SAAA,CAAA;AAAA,QAAA,GAAA;AAAA;AAAA,OAAA;AAAA,KAAA,CAAA;AAAA,IAAA,CAAA,EAAA,CAAA;AAAA;AAAA,GAAA,CAAA,IAAAG,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA,CAAA;;;;;;"}
@@ -1,3 +1,4 @@
1
+ import '@empathyco/x-utils';
1
2
  import { createStoreEmitters } from '../../../store/utils/store-emitters.utils.js';
2
3
  import { createEmitterArrayFilter } from '../../../utils/array.js';
3
4
  import { identifierResultsXStoreModule } from './module.js';
@@ -1 +1 @@
1
- {"version":3,"file":"emitters.js","sources":["../../../../../src/x-modules/identifier-results/store/emitters.ts"],"sourcesContent":["import { createStoreEmitters } from '../../../store';\nimport { createEmitterArrayFilter } from '../../../utils/array';\nimport { identifierResultsXStoreModule } from './module';\n\n/**\n * {@link StoreEmitters} For the identifier-results module.\n *\n * @internal\n */\nexport const identifierResultsEmitters = createStoreEmitters(identifierResultsXStoreModule, {\n IdentifierResultsChanged: {\n selector: state => state.identifierResults,\n filter: createEmitterArrayFilter('id')\n },\n IdentifierResultsRequestUpdated: (_, getters) => getters.identifierResultsRequest\n});\n"],"names":[],"mappings":";;;;AAIA;;;;AAIG;AACU,MAAA,yBAAyB,GAAG,mBAAmB,CAAC,6BAA6B,EAAE;AAC1F,IAAA,wBAAwB,EAAE;AACxB,QAAA,QAAQ,EAAE,KAAK,IAAI,KAAK,CAAC,iBAAiB;AAC1C,QAAA,MAAM,EAAE,wBAAwB,CAAC,IAAI,CAAC;AACvC,KAAA;IACD,+BAA+B,EAAE,CAAC,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,wBAAwB;AAClF,CAAA;;;;"}
1
+ {"version":3,"file":"emitters.js","sources":["../../../../../src/x-modules/identifier-results/store/emitters.ts"],"sourcesContent":["import { createStoreEmitters } from '../../../store';\nimport { createEmitterArrayFilter } from '../../../utils/array';\nimport { identifierResultsXStoreModule } from './module';\n\n/**\n * {@link StoreEmitters} For the identifier-results module.\n *\n * @internal\n */\nexport const identifierResultsEmitters = createStoreEmitters(identifierResultsXStoreModule, {\n IdentifierResultsChanged: {\n selector: state => state.identifierResults,\n filter: createEmitterArrayFilter('id')\n },\n IdentifierResultsRequestUpdated: (_, getters) => getters.identifierResultsRequest\n});\n"],"names":[],"mappings":";;;;;AAIA;;;;AAIG;AACU,MAAA,yBAAyB,GAAG,mBAAmB,CAAC,6BAA6B,EAAE;AAC1F,IAAA,wBAAwB,EAAE;AACxB,QAAA,QAAQ,EAAE,KAAK,IAAI,KAAK,CAAC,iBAAiB;AAC1C,QAAA,MAAM,EAAE,wBAAwB,CAAC,IAAI,CAAC;AACvC,KAAA;IACD,+BAA+B,EAAE,CAAC,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,wBAAwB;AAClF,CAAA;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './next-queries.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, withCtx, createCommentVNode, renderSlot, normalizeProps, guardReactiveProps, createVNode } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, withCtx, renderSlot, normalizeProps, guardReactiveProps, createVNode } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -11,9 +11,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
11
11
  class: "x-next-queries"
12
12
  }, {
13
13
  default: withCtx((baseScope) => [
14
- createCommentVNode(" eslint-disable max-len "),
15
- createCommentVNode("\n @slot Next Query item\n @binding {Object} v-bind - Next Query suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Next Query suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Next Query suggestion index\n @binding {boolean} highlightCurated - True if the curated NQs should be highlighted\n "),
16
- createCommentVNode(" eslint-enable max-len "),
17
14
  renderSlot(_ctx.$slots, "suggestion", normalizeProps(guardReactiveProps({ ...baseScope, highlightCurated: _ctx.highlightCurated })), () => [
18
15
  createVNode(_component_NextQuery, {
19
16
  suggestion: baseScope.suggestion,
@@ -21,9 +18,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
21
18
  class: "x-next-queries__suggestion x-suggestion"
22
19
  }, {
23
20
  default: withCtx((nextQueryScope) => [
24
- createCommentVNode(" eslint-disable max-len "),
25
- createCommentVNode("\n @slot Next Query content\n @binding {Object} v-bind - Next Query suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Next Query suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Next Query suggestion index\n @binding {boolean} shouldHighlightCurated - True if the curated NQ should be highlighted\n "),
26
- createCommentVNode(" eslint-enable max-len "),
27
21
  renderSlot(_ctx.$slots, "suggestion-content", normalizeProps(guardReactiveProps({ ...baseScope, ...nextQueryScope })))
28
22
  ]),
29
23
  _: 2
@@ -1 +1 @@
1
- {"version":3,"file":"next-queries.vue.js","sources":["../../../../../src/x-modules/next-queries/components/next-queries.vue"],"sourcesContent":["<template>\n <BaseSuggestions\n :suggestions=\"renderedNextQueries\"\n data-test=\"next-queries\"\n class=\"x-next-queries\"\n >\n <template #default=\"baseScope\">\n <!-- eslint-disable max-len -->\n <!--\n @slot Next Query item\n @binding {Object} v-bind - Next Query suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Next Query suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Next Query suggestion index\n @binding {boolean} highlightCurated - True if the curated NQs should be highlighted\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion\" v-bind=\"{ ...baseScope, highlightCurated }\">\n <NextQuery\n #default=\"nextQueryScope\"\n :suggestion=\"baseScope.suggestion\"\n :highlightCurated=\"highlightCurated\"\n class=\"x-next-queries__suggestion x-suggestion\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Next Query content\n @binding {Object} v-bind - Next Query suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Next Query suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Next Query suggestion index\n @binding {boolean} shouldHighlightCurated - True if the curated NQ should be highlighted\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion-content\" v-bind=\"{ ...baseScope, ...nextQueryScope }\" />\n </NextQuery>\n </slot>\n </template>\n </BaseSuggestions>\n</template>\n\n<script lang=\"ts\">\n import { NextQuery as NextQueryModel } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseSuggestions from '../../../components/suggestions/base-suggestions.vue';\n import { nextQueriesXModule } from '../x-module';\n import { useGetter } from '../../../composables/use-getter';\n import NextQuery from './next-query.vue';\n\n /**\n * Simple next-queries component that renders a list of\n * [`BaseSuggestions`](./x-components.base-suggestions.md),\n * allowing the user to select one of them, and emitting the needed events. A next query is a\n * suggestion for a new search, related to your previous query. I.e. If people normally search\n * for `shirts`, and then `trousers`, `trousers` would be a next query of `shirts`.\n *\n * @public\n */\n export default defineComponent({\n name: 'NextQueries',\n xModule: nextQueriesXModule.name,\n components: {\n NextQuery,\n BaseSuggestions\n },\n props: {\n /**\n * Flag to indicate if the curated next queries should be displayed different.\n *\n * @public\n */\n highlightCurated: {\n type: Boolean,\n default: false\n },\n /**\n * NextQueries list to be used instead of state NextQueries.\n *\n * @public\n */\n suggestions: Array as PropType<NextQueryModel[]>\n },\n setup(props) {\n /**\n * The list of next queries from the state.\n *\n * @internal\n */\n const stateNextQueries = useGetter('nextQueries', ['nextQueries']).nextQueries;\n\n /**.\n * The list of next queries finally rendered\n *\n * @internal\n */\n const renderedNextQueries = computed(() => props.suggestions ?? stateNextQueries.value);\n\n return { renderedNextQueries };\n }\n });\n</script>\n\n<!--eslint-disable max-len -->\n<docs lang=\"mdx\">\n## Inherited props\n\nThis component inherits the [`BaseSuggestions`](../base-components/x-components.base-suggestions.md)\nprops.\n\n| Name | Description | Type | Default |\n| ------------------ | ----------------------------------------------------------------- | -------- | ------- |\n| `animation` | Animation component that will be used to animate the suggestions. | `Vue` | `\"ul\"` |\n| `maxItemsToRender` | Number of popular searches to be rendered. | `number` | |\n\n## Examples\n\n### Basic example\n\nYou don't need to pass any props, or slots. Simply add the component, and when it has any next\nqueries it will show them\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries />\n </div>\n</template>\n\n<script>\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries\n }\n };\n</script>\n```\n\nThe component has three optional props. `animation` to render the component with an animation,\n`maxItemsToRender` to limit the number of next queries will be rendered (by default it is 5) and\n`highlightCurated` to indicate if the curated Next Queries inside the list should be highlighted.\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries :animation=\"'FadeAndSlide'\" :maxItemsToRender=\"10\" :highlightCurated=\"true\" />\n </div>\n</template>\n\n<script>\n import Vue from 'vue';\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries } from '@empathyco/x-components/next-queries';\n import { FadeAndSlide } from '@empathyco/x-components';\n\n // Registering the animation as a global component\n Vue.component('FadeAndSlide', FadeAndSlide);\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries\n }\n };\n</script>\n```\n\n### Overriding Next Queries' Content\n\nYou can use your custom implementation of the Next Query's content. In the example below, instead of\nusing the default Next Query's content, an icon is added, as well as a span with the query of the\nNext Query suggestion.\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries>\n <template #suggestion-content=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-next-query__query\">{{ suggestion.query }}</span>\n </template>\n </NextQueries>\n </div>\n</template>\n\n<script>\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries } from '@empathyco/x-components/next-queries';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries,\n TrendingIcon\n }\n };\n</script>\n```\n\n### Adding a custom next query component\n\nYou can use your custom implementation of a next query component. To work correctly, it should use\nthe `emitNextQuerySelected` function when the next query is selected. In the example below, instead\nof using the default `button` tag for a next query, an icon is added, and the text of the next query\nis wrapped in a `span`\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries>\n <template #suggestion=\"{ suggestion }\">\n <NextQuery :suggestion=\"suggestion\" class=\"x-next-queries__suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-next-query__query\">{{ suggestion.query }}</span>\n </template>\n </NextQuery>\n <button>Custom Behaviour</button>\n </template>\n </NextQueries>\n </div>\n</template>\n\n<script>\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries, NextQuery } from '@empathyco/x-components/next-queries';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries,\n NextQuery,\n TrendingIcon\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_createCommentVNode","_renderSlot","_normalizeProps","_guardReactiveProps","_createVNode","highlightCurated"],"mappings":";;;;;;AAgCoB,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AA7BhB,EAAA,OAAAC,SAAA,EAAwB,EAAAC,WAAA,CAAA,0BAAA,EAAA;AAAA,IACxB,WAAM,EAAA,IAAA,CAAA,mBAAA;AAAA,IAAA,WAAA,EAAA,cAAA;IAEK,KAAO,EAAA,gBAAA;AAAA,GAAA,EAAA;AAEhB,IAAA,OAAA,EAAAC,OAAA,CAAA,CAAA,SAAA,KAAA;AAAA,MAKAC,kBAA8B,CAAA,0BAAA,CAAA;AAAA,MAC9BA,kBAgBO,CAAA,0XAAA,CAAA;AAAA,MADOA,kBAAA,CAAA,yBAAA,CAAA;AAAA,MAZTC,UAAA,CAAA,IAAA,CAAY,QAAS,YAAW,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,gBAAA,EAAA,IAAA,CAAA,gBAAA,EAAA,CAAA,CAAA,EAAA,MAAA;AAAA,QAAAC,WAAA,CAChC,oBAAkBC,EAAAA;AAAAA,UACnB,UAAM,EAAA,SAAA,CAAA,UAAA;AAAA,UAAA,gBAAA,EAAA,IAAA,CAAA,gBAAA;UAHL,KAAO,EAAA,yCAAA;AAAA,SAAA,EAAA;AAMR,UAAA,OAAA,EAAAN,OAAA,CAAA,CAAA,cAAA,KAAA;AAAA,YAKAC,kBAA8B,CAAA,0BAAA,CAAA;AAAA,YAC9BA,mBAA+E,wZAAN,CAAA;AAAA,YAAAA,kBAAA,CAAA,yBAAA,CAAA;AA5BnF,YAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,oBAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,GAAA,cAAA,EAAA,CAAA,CAAA,CAAA;AAAA,WAAA,CAAA;;;;AAAA,OAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
1
+ {"version":3,"file":"next-queries.vue.js","sources":["../../../../../src/x-modules/next-queries/components/next-queries.vue"],"sourcesContent":["<template>\n <BaseSuggestions\n :suggestions=\"renderedNextQueries\"\n data-test=\"next-queries\"\n class=\"x-next-queries\"\n >\n <template #default=\"baseScope\">\n <!-- eslint-disable max-len -->\n <!--\n @slot Next Query item\n @binding {Object} v-bind - Next Query suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Next Query suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Next Query suggestion index\n @binding {boolean} highlightCurated - True if the curated NQs should be highlighted\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion\" v-bind=\"{ ...baseScope, highlightCurated }\">\n <NextQuery\n #default=\"nextQueryScope\"\n :suggestion=\"baseScope.suggestion\"\n :highlightCurated=\"highlightCurated\"\n class=\"x-next-queries__suggestion x-suggestion\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Next Query content\n @binding {Object} v-bind - Next Query suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Next Query suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Next Query suggestion index\n @binding {boolean} shouldHighlightCurated - True if the curated NQ should be highlighted\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion-content\" v-bind=\"{ ...baseScope, ...nextQueryScope }\" />\n </NextQuery>\n </slot>\n </template>\n </BaseSuggestions>\n</template>\n\n<script lang=\"ts\">\n import { NextQuery as NextQueryModel } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseSuggestions from '../../../components/suggestions/base-suggestions.vue';\n import { nextQueriesXModule } from '../x-module';\n import { useGetter } from '../../../composables/use-getter';\n import NextQuery from './next-query.vue';\n\n /**\n * Simple next-queries component that renders a list of\n * [`BaseSuggestions`](./x-components.base-suggestions.md),\n * allowing the user to select one of them, and emitting the needed events. A next query is a\n * suggestion for a new search, related to your previous query. I.e. If people normally search\n * for `shirts`, and then `trousers`, `trousers` would be a next query of `shirts`.\n *\n * @public\n */\n export default defineComponent({\n name: 'NextQueries',\n xModule: nextQueriesXModule.name,\n components: {\n NextQuery,\n BaseSuggestions\n },\n props: {\n /**\n * Flag to indicate if the curated next queries should be displayed different.\n *\n * @public\n */\n highlightCurated: {\n type: Boolean,\n default: false\n },\n /**\n * NextQueries list to be used instead of state NextQueries.\n *\n * @public\n */\n suggestions: Array as PropType<NextQueryModel[]>\n },\n setup(props) {\n /**\n * The list of next queries from the state.\n *\n * @internal\n */\n const stateNextQueries = useGetter('nextQueries', ['nextQueries']).nextQueries;\n\n /**.\n * The list of next queries finally rendered\n *\n * @internal\n */\n const renderedNextQueries = computed(() => props.suggestions ?? stateNextQueries.value);\n\n return { renderedNextQueries };\n }\n });\n</script>\n\n<!--eslint-disable max-len -->\n<docs lang=\"mdx\">\n## Inherited props\n\nThis component inherits the [`BaseSuggestions`](../base-components/x-components.base-suggestions.md)\nprops.\n\n| Name | Description | Type | Default |\n| ------------------ | ----------------------------------------------------------------- | -------- | ------- |\n| `animation` | Animation component that will be used to animate the suggestions. | `Vue` | `\"ul\"` |\n| `maxItemsToRender` | Number of popular searches to be rendered. | `number` | |\n\n## Examples\n\n### Basic example\n\nYou don't need to pass any props, or slots. Simply add the component, and when it has any next\nqueries it will show them\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries />\n </div>\n</template>\n\n<script>\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries\n }\n };\n</script>\n```\n\nThe component has three optional props. `animation` to render the component with an animation,\n`maxItemsToRender` to limit the number of next queries will be rendered (by default it is 5) and\n`highlightCurated` to indicate if the curated Next Queries inside the list should be highlighted.\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries :animation=\"'FadeAndSlide'\" :maxItemsToRender=\"10\" :highlightCurated=\"true\" />\n </div>\n</template>\n\n<script>\n import Vue from 'vue';\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries } from '@empathyco/x-components/next-queries';\n import { FadeAndSlide } from '@empathyco/x-components';\n\n // Registering the animation as a global component\n Vue.component('FadeAndSlide', FadeAndSlide);\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries\n }\n };\n</script>\n```\n\n### Overriding Next Queries' Content\n\nYou can use your custom implementation of the Next Query's content. In the example below, instead of\nusing the default Next Query's content, an icon is added, as well as a span with the query of the\nNext Query suggestion.\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries>\n <template #suggestion-content=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-next-query__query\">{{ suggestion.query }}</span>\n </template>\n </NextQueries>\n </div>\n</template>\n\n<script>\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries } from '@empathyco/x-components/next-queries';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries,\n TrendingIcon\n }\n };\n</script>\n```\n\n### Adding a custom next query component\n\nYou can use your custom implementation of a next query component. To work correctly, it should use\nthe `emitNextQuerySelected` function when the next query is selected. In the example below, instead\nof using the default `button` tag for a next query, an icon is added, and the text of the next query\nis wrapped in a `span`\n\n```vue live\n<template>\n <div>\n <SearchInput />\n <NextQueries>\n <template #suggestion=\"{ suggestion }\">\n <NextQuery :suggestion=\"suggestion\" class=\"x-next-queries__suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-next-query__query\">{{ suggestion.query }}</span>\n </template>\n </NextQuery>\n <button>Custom Behaviour</button>\n </template>\n </NextQueries>\n </div>\n</template>\n\n<script>\n import { SearchInput } from '@empathyco/x-components/search-box';\n import { NextQueries, NextQuery } from '@empathyco/x-components/next-queries';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueriesDemo',\n components: {\n SearchInput,\n NextQueries,\n NextQuery,\n TrendingIcon\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_renderSlot","_normalizeProps","_guardReactiveProps","_createVNode","highlightCurated"],"mappings":";;;;;;AAgCoB,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AA7BhB,EAAA,OAAAC,SAAA,EAAwB,EAAAC,WAAA,CAAA,0BAAA,EAAA;AAAA,IACxB,WAAM,EAAA,IAAA,CAAA,mBAAA;AAAA,IAAA,WAAA,EAAA,cAAA;IAEK,KAAO,EAAA,gBAAA;AAAA,GAAA,EAAA;aASdC,OAcY,CAAA,CAAA,SAAA,KAAA;AAAA,MAZTC,UAAA,CAAA,IAAA,CAAY,QAAS,YAAW,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,gBAAA,EAAA,IAAA,CAAA,gBAAA,EAAA,CAAA,CAAA,EAAA,MAAA;AAAA,QAAAC,WAAA,CAChC,oBAAkBC,EAAAA;AAAAA,UACnB,UAAM,EAAA,SAAA,CAAA,UAAA;AAAA,UAAA,gBAAA,EAAA,IAAA,CAAA,gBAAA;UAHL,KAAO,EAAA,yCAAA;AAAA,SAAA,EAAA;;AAhBlB,YAAAJ,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,oBAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,GAAA,cAAA,EAAA,CAAA,CAAA,CAAA;AAAA,WAAA,CAAA;;;;AAAA,OAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './next-query-preview.vue2.js';
2
- import { openBlock, createElementBlock, createCommentVNode, renderSlot, Fragment, renderList, createElementVNode, toDisplayString } from 'vue';
2
+ import { openBlock, createElementBlock, renderSlot, Fragment, renderList, createElementVNode, toDisplayString, createCommentVNode } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  const _hoisted_1 = {
@@ -10,7 +10,6 @@ const _hoisted_1 = {
10
10
  const _hoisted_2 = { "data-test": "result-name" };
11
11
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
12
12
  return _ctx.suggestionResults ? (openBlock(), createElementBlock("ul", _hoisted_1, [
13
- createCommentVNode("\n @slot Next Query Preview default slot.\n @binding {NextQuery} suggestion - Next Query suggestion data\n @binding {Result[]} results - The results preview of the next query\n @binding {number} totalResults - The total results of the search request\n "),
14
13
  renderSlot(_ctx.$slots, "default", {
15
14
  suggestion: _ctx.suggestion,
16
15
  results: _ctx.suggestionResults.items,
@@ -25,7 +24,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
25
24
  class: "x-next-query-preview__item",
26
25
  "data-test": "next-query-preview-item"
27
26
  }, [
28
- createCommentVNode("\n @slot Next Query Preview result slot.\n @binding {Result} result - A Next Query Preview result\n "),
29
27
  renderSlot(_ctx.$slots, "result", { result }, () => [
30
28
  createElementVNode(
31
29
  "span",
@@ -1 +1 @@
1
- {"version":3,"file":"next-query-preview.vue.js","sources":["../../../../../src/x-modules/next-queries/components/next-query-preview.vue"],"sourcesContent":["<template>\n <ul v-if=\"suggestionResults\" data-test=\"next-query-preview\" class=\"x-next-query-preview\">\n <!--\n @slot Next Query Preview default slot.\n @binding {NextQuery} suggestion - Next Query suggestion data\n @binding {Result[]} results - The results preview of the next query\n @binding {number} totalResults - The total results of the search request\n -->\n <slot\n :suggestion=\"suggestion\"\n :results=\"suggestionResults.items\"\n :totalResults=\"suggestionResults.totalResults\"\n >\n <li\n v-for=\"result in suggestionResults.items\"\n :key=\"result.id\"\n class=\"x-next-query-preview__item\"\n data-test=\"next-query-preview-item\"\n >\n <!--\n @slot Next Query Preview result slot.\n @binding {Result} result - A Next Query Preview result\n -->\n <slot name=\"result\" :result=\"result\">\n <span data-test=\"result-name\">{{ result.name }}</span>\n </slot>\n </li>\n </slot>\n </ul>\n</template>\n\n<script lang=\"ts\">\n import { computed, defineComponent, onMounted, PropType } from 'vue';\n import { NextQuery, PreviewResults } from '@empathyco/x-types';\n import { nextQueriesXModule } from '../x-module';\n import { use$x } from '../../../composables/use-$x';\n import { useState } from '../../../composables/use-state';\n\n /**\n * Retrieves a preview of the results of a next query and exposes them in the default slot,\n * along with the next query and the totalResults of the search request.\n * By default, it renders the names of the results.\n *\n * @public\n */\n export default defineComponent({\n name: 'NextQueryPreview',\n xModule: nextQueriesXModule.name,\n props: {\n /**\n * The next query to retrieve the results preview.\n *\n * @public\n */\n suggestion: {\n type: Object as PropType<NextQuery>,\n required: true\n },\n /**\n * Number of suggestion results to be rendered.\n *\n * @public\n */\n maxItemsToRender: Number\n },\n setup(props) {\n const $x = use$x();\n /**\n * The results preview of the next queries mounted.\n * It is a dictionary, indexed by the next query query.\n */\n const { resultsPreview } = useState('nextQueries', ['resultsPreview']);\n\n /**\n * The component emits the NextQueryPreviewMountedHook event to retrieve the results preview\n * of the next query.\n */\n onMounted(() => $x.emit('NextQueryPreviewMountedHook', props.suggestion.query));\n\n /**\n * Gets from the state the results preview of the next query.\n *\n * @returns The results preview of the actual next query.\n */\n const suggestionResults = computed((): PreviewResults | undefined => {\n const previewResults = resultsPreview.value[props.suggestion.query] as PreviewResults;\n\n return previewResults\n ? {\n ...previewResults,\n items: previewResults.items.slice(0, props.maxItemsToRender)\n }\n : undefined;\n });\n\n return { suggestionResults };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nThis component emits the\n[`NextQueryPreviewMountedHook`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts)\nwhen it is mounted.\n\n## See it in action\n\nHere you have a basic example of how the NextQueryPreview is rendered. Keep in mind that this\ncomponent is intended to be used overriding its default slot. By default it will only render the\nnames of the results.\n\n```vue live\n<template>\n <NextQueryPreview :suggestion=\"suggestion\" />\n</template>\n\n<script>\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryPreviewDemo',\n components: {\n NextQueryPreview\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Play with the default slot\n\nIn this example, the results will be rendered inside a sliding panel.\n\n```vue live\n<template>\n <NextQueryPreview :suggestion=\"suggestion\" #default=\"{ totalResults, results }\">\n <p>Total results: {{ totalResults }}</p>\n <SlidingPanel :resetOnContentChange=\"false\">\n <article\n v-for=\"result in results\"\n :key=\"result.id\"\n class=\"x-result\"\n style=\"max-width: 300px; overflow: hidden\"\n >\n <BaseResultLink :result=\"result\">\n <BaseResultImage :result=\"result\" class=\"x-result__picture\" />\n </BaseResultLink>\n <div class=\"x-result__description\">\n <BaseResultLink :result=\"result\">\n <h1 class=\"x-title3\">{{ result.name }}</h1>\n </BaseResultLink>\n </div>\n </article>\n </SlidingPanel>\n </NextQueryPreview>\n</template>\n\n<script>\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n import { SlidingPanel, BaseResultLink, BaseResultImage } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueryPreviewDemoOverridingSlot',\n components: {\n NextQueryPreview,\n SlidingPanel,\n BaseResultLink,\n BaseResultImage\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Play with the result slot\n\nThe component exposes a slot to override the result content, without modifying the list.\n\nIn this example, the ID of the results will be rendered along with the name.\n\n```vue\n<template>\n <NextQueryPreview :suggestion=\"suggestion\" #result=\"{ result }\">\n <span>{{ result.id }}</span>\n <span>{{ result.name }}</span>\n </NextQueryPreview>\n</template>\n\n<script>\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryPreviewDemoOverridingResultSlot',\n components: {\n NextQueryPreview\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Play with props\n\nIn this example, the suggestions has been limited to render a maximum of 4 items.\n\n```vue\n<template>\n <NextQueryPreview\n :maxItemsToRender=\"maxItemsToRender\"\n :suggestion=\"suggestion\"\n #default=\"{ results }\"\n >\n <BaseGrid #default=\"{ item }\" :items=\"results\">\n <BaseResultLink :result=\"item\">\n <BaseResultImage :result=\"item\" />\n </BaseResultLink>\n </BaseGrid>\n </NextQueryPreview>\n</template>\n\n<script>\n import { BaseGrid, BaseResultImage, BaseResultLink } from '@empathyco/x-components';\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryPreviewDemo',\n components: {\n BaseGrid,\n BaseResultImage,\n BaseResultLink,\n NextQueryPreview\n },\n data() {\n return {\n maxItemsToRender: 4,\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_createCommentVNode","suggestion","_renderSlot","suggestionResults","_Fragment","_renderList"],"mappings":";;;;MAC+B,UAAU,GAAA;AAAA,EAAqB,GAAK,EAAA,CAAA;AAAA,EAAA,WAAA,EAAA,oBAAA;;;;AAAjE,SAAA,WAAA,CAAA,IAAA,EAAA,MAAA,EAAA,MAAA,EA2BK,QA3BL,KA2BK,EAAA,QAAA,EAAA;AA1BH,EAAA,OAAA,IAAA,CAAA,iBAAA,IAAAA,SAAA,EAyBO,EAAAC,kBAAA,CAAA,IAAA,EAAA,UAAA,EAAA;AAAA,IAAAC,kBAAA,CAlBQC,iSAAU,CAAA;AAAA,IAAAC,UAAA,CACbC,IAAkB,CAAA,MAAA,EAAA,SAAA,EAAA;AAAA,MAC3B,YAAY,IAAEA,CAAAA,UAAAA;AAAAA,MAgBV,OAAA,EAAA,IAAA,CAAA,iBAAA,CAAA,KAAA;AAAA,MAdL,YAAA,EAAA,IAAA,CAAA,iBAAA,CAAA,YAAA;AAAA,KAAA,EAAA,MAAA;AAEQ,OAAAL,SAAA,CAAA,IAAO,CAAE,EAAAC,kBAAA;AAAA,QAAAK,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAAA,IAAA,CAAA,iBAAA,CAAA,KAAA,EAAA,CAAA,MAAA,KAAA;AACV,UAAA,OAAAP,SAAA,EAA6B,EAAAC,kBAAA,CAAA,IAAA,EAAA;AAAA,YAClC,GAAS,EAAA,MAAA,CAAA,EAAA;AAAA,YAAA,KAAA,EAAA,4BAAA;AAET,YAAA,WAAA,EAAA,yBAAA;AAAA,WAIA,EAAA;AAAA,YAAAC,kBAAA,CACE,mIAA4C,CAAA;AAAA,YAAAE,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,QAAA,EAAA,EAAA,MAAA,EAAA,EAAA,MAAA;;;;;;;;;;;;;;AAxBtD,KAAA,CAAA;AAAA,GAAA,CAAA,IAAAF,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA,CAAA;;;;;;"}
1
+ {"version":3,"file":"next-query-preview.vue.js","sources":["../../../../../src/x-modules/next-queries/components/next-query-preview.vue"],"sourcesContent":["<template>\n <ul v-if=\"suggestionResults\" data-test=\"next-query-preview\" class=\"x-next-query-preview\">\n <!--\n @slot Next Query Preview default slot.\n @binding {NextQuery} suggestion - Next Query suggestion data\n @binding {Result[]} results - The results preview of the next query\n @binding {number} totalResults - The total results of the search request\n -->\n <slot\n :suggestion=\"suggestion\"\n :results=\"suggestionResults.items\"\n :totalResults=\"suggestionResults.totalResults\"\n >\n <li\n v-for=\"result in suggestionResults.items\"\n :key=\"result.id\"\n class=\"x-next-query-preview__item\"\n data-test=\"next-query-preview-item\"\n >\n <!--\n @slot Next Query Preview result slot.\n @binding {Result} result - A Next Query Preview result\n -->\n <slot name=\"result\" :result=\"result\">\n <span data-test=\"result-name\">{{ result.name }}</span>\n </slot>\n </li>\n </slot>\n </ul>\n</template>\n\n<script lang=\"ts\">\n import { computed, defineComponent, onMounted, PropType } from 'vue';\n import { NextQuery, PreviewResults } from '@empathyco/x-types';\n import { nextQueriesXModule } from '../x-module';\n import { use$x } from '../../../composables/use-$x';\n import { useState } from '../../../composables/use-state';\n\n /**\n * Retrieves a preview of the results of a next query and exposes them in the default slot,\n * along with the next query and the totalResults of the search request.\n * By default, it renders the names of the results.\n *\n * @public\n */\n export default defineComponent({\n name: 'NextQueryPreview',\n xModule: nextQueriesXModule.name,\n props: {\n /**\n * The next query to retrieve the results preview.\n *\n * @public\n */\n suggestion: {\n type: Object as PropType<NextQuery>,\n required: true\n },\n /**\n * Number of suggestion results to be rendered.\n *\n * @public\n */\n maxItemsToRender: Number\n },\n setup(props) {\n const $x = use$x();\n /**\n * The results preview of the next queries mounted.\n * It is a dictionary, indexed by the next query query.\n */\n const { resultsPreview } = useState('nextQueries', ['resultsPreview']);\n\n /**\n * The component emits the NextQueryPreviewMountedHook event to retrieve the results preview\n * of the next query.\n */\n onMounted(() => $x.emit('NextQueryPreviewMountedHook', props.suggestion.query));\n\n /**\n * Gets from the state the results preview of the next query.\n *\n * @returns The results preview of the actual next query.\n */\n const suggestionResults = computed((): PreviewResults | undefined => {\n const previewResults = resultsPreview.value[props.suggestion.query] as PreviewResults;\n\n return previewResults\n ? {\n ...previewResults,\n items: previewResults.items.slice(0, props.maxItemsToRender)\n }\n : undefined;\n });\n\n return { suggestionResults };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nThis component emits the\n[`NextQueryPreviewMountedHook`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts)\nwhen it is mounted.\n\n## See it in action\n\nHere you have a basic example of how the NextQueryPreview is rendered. Keep in mind that this\ncomponent is intended to be used overriding its default slot. By default it will only render the\nnames of the results.\n\n```vue live\n<template>\n <NextQueryPreview :suggestion=\"suggestion\" />\n</template>\n\n<script>\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryPreviewDemo',\n components: {\n NextQueryPreview\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Play with the default slot\n\nIn this example, the results will be rendered inside a sliding panel.\n\n```vue live\n<template>\n <NextQueryPreview :suggestion=\"suggestion\" #default=\"{ totalResults, results }\">\n <p>Total results: {{ totalResults }}</p>\n <SlidingPanel :resetOnContentChange=\"false\">\n <article\n v-for=\"result in results\"\n :key=\"result.id\"\n class=\"x-result\"\n style=\"max-width: 300px; overflow: hidden\"\n >\n <BaseResultLink :result=\"result\">\n <BaseResultImage :result=\"result\" class=\"x-result__picture\" />\n </BaseResultLink>\n <div class=\"x-result__description\">\n <BaseResultLink :result=\"result\">\n <h1 class=\"x-title3\">{{ result.name }}</h1>\n </BaseResultLink>\n </div>\n </article>\n </SlidingPanel>\n </NextQueryPreview>\n</template>\n\n<script>\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n import { SlidingPanel, BaseResultLink, BaseResultImage } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueryPreviewDemoOverridingSlot',\n components: {\n NextQueryPreview,\n SlidingPanel,\n BaseResultLink,\n BaseResultImage\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Play with the result slot\n\nThe component exposes a slot to override the result content, without modifying the list.\n\nIn this example, the ID of the results will be rendered along with the name.\n\n```vue\n<template>\n <NextQueryPreview :suggestion=\"suggestion\" #result=\"{ result }\">\n <span>{{ result.id }}</span>\n <span>{{ result.name }}</span>\n </NextQueryPreview>\n</template>\n\n<script>\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryPreviewDemoOverridingResultSlot',\n components: {\n NextQueryPreview\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Play with props\n\nIn this example, the suggestions has been limited to render a maximum of 4 items.\n\n```vue\n<template>\n <NextQueryPreview\n :maxItemsToRender=\"maxItemsToRender\"\n :suggestion=\"suggestion\"\n #default=\"{ results }\"\n >\n <BaseGrid #default=\"{ item }\" :items=\"results\">\n <BaseResultLink :result=\"item\">\n <BaseResultImage :result=\"item\" />\n </BaseResultLink>\n </BaseGrid>\n </NextQueryPreview>\n</template>\n\n<script>\n import { BaseGrid, BaseResultImage, BaseResultLink } from '@empathyco/x-components';\n import { NextQueryPreview } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryPreviewDemo',\n components: {\n BaseGrid,\n BaseResultImage,\n BaseResultLink,\n NextQueryPreview\n },\n data() {\n return {\n maxItemsToRender: 4,\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["_openBlock","_createElementBlock","_renderSlot","suggestionResults","_Fragment","_renderList","_createCommentVNode"],"mappings":";;;;MAC+B,UAAU,GAAA;AAAA,EAAqB,GAAK,EAAA,CAAA;AAAA,EAAA,WAAA,EAAA,oBAAA;;;;AAAjE,SAAA,WAAA,CAAA,IAAA,EAAA,MAAA,EAAA,MAAA,EA2BK,QA3BL,KA2BK,EAAA,QAAA,EAAA;AApBH,EAAA,OAAA,IAAA,CAAA,iBAAA,IAAAA,SAAA,IACaC,kBAAY,CAAA,IAAA,EAAA,UAAA,EAAA;AAAA,IAAAC,UAAA,CACbC,IAAkB,CAAA,MAAA,EAAA,SAAA,EAAA;AAAA,MAC3B,YAAY,IAAEA,CAAAA,UAAAA;AAAAA,MAgBV,OAAA,EAAA,IAAA,CAAA,iBAAA,CAAA,KAAA;AAAA,MAdL,YAAA,EAAA,IAAA,CAAA,iBAAA,CAAA,YAAA;AAAA,KAAA,EAAA,MAAA;AAEQ,OAAAH,SAAA,CAAA,IAAO,CAAE,EAAAC,kBAAA;AAAA,QAAAG,QAAA;AAAA,QAAA,IAAA;AAAA,QAAAC,UAAA,CAAA,IAAA,CAAA,iBAAA,CAAA,KAAA,EAAA,CAAA,MAAA,KAAA;AACV,UAAA,OAAAL,SAAA,EAA6B,EAAAC,kBAAA,CAAA,IAAA,EAAA;AAAA,YAClC,GAAS,EAAA,MAAA,CAAA,EAAA;AAAA,YAAA,KAAA,EAAA,4BAAA;YAMT,WAEO,EAAA,yBAAA;AAAA,WAAA,EAAA;;;;;;;;;;;;;;;AAzBf,KAAA,CAAA;AAAA,GAAA,CAAA,IAAAK,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA,CAAA;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './next-query.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, normalizeClass, withCtx, createCommentVNode, renderSlot, normalizeProps, guardReactiveProps } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, normalizeClass, withCtx, renderSlot, normalizeProps, guardReactiveProps } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -12,9 +12,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
12
12
  feature: "next_query"
13
13
  }, {
14
14
  default: withCtx((baseScope) => [
15
- createCommentVNode(" eslint-disable max-len "),
16
- createCommentVNode("\n @slot Next Query content\n @binding {Object} v-bind - `BaseSuggestion` default slot scope: **suggestion** <code>Suggestion</code> - Suggestion data<br /> **query** <code>string</code> - The query that the suggestion belongs to<br /> **filter** <code>Filter \\| undefined</code> - Suggestion's filter\n @binding {boolean} shouldHighlightCurated - True if the curated NQ should be highlighted\n "),
17
- createCommentVNode(" eslint-enable max-len "),
18
15
  renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ ...baseScope, shouldHighlightCurated: _ctx.shouldHighlightCurated })))
19
16
  ]),
20
17
  _: 3
@@ -1 +1 @@
1
- {"version":3,"file":"next-query.vue.js","sources":["../../../../../src/x-modules/next-queries/components/next-query.vue"],"sourcesContent":["<template>\n <BaseSuggestion\n class=\"x-next-query\"\n :suggestion=\"suggestion\"\n :suggestionSelectedEvents=\"events\"\n data-test=\"next-query\"\n feature=\"next_query\"\n :class=\"{ 'x-next-query--is-curated': shouldHighlightCurated }\"\n #default=\"baseScope\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Next Query content\n @binding {Object} v-bind - `BaseSuggestion` default slot scope: **suggestion** <code>Suggestion</code> - Suggestion data<br /> **query** <code>string</code> - The query that the suggestion belongs to<br /> **filter** <code>Filter \\| undefined</code> - Suggestion's filter\n @binding {boolean} shouldHighlightCurated - True if the curated NQ should be highlighted\n -->\n <!-- eslint-enable max-len -->\n <slot v-bind=\"{ ...baseScope, shouldHighlightCurated }\" />\n </BaseSuggestion>\n</template>\n\n<script lang=\"ts\">\n import { NextQuery as NextQueryModel } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseSuggestion from '../../../components/suggestions/base-suggestion.vue';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { nextQueriesXModule } from '../x-module';\n\n /**\n * Renders a next query item which receives the suggestion that will be rendered as a prop. It\n * exposes a default slot to change the next query content. If the slot is not overridden,\n * it will render the suggestion query by default.\n *\n * @public\n */\n export default defineComponent({\n name: 'NextQuery',\n xModule: nextQueriesXModule.name,\n components: { BaseSuggestion },\n props: {\n /**\n * The suggestion to render and use in the default slot.\n *\n * @public\n */\n suggestion: {\n type: Object as PropType<NextQueryModel>,\n required: true\n },\n /**\n * Indicates if the curated next query should be highlighted.\n *\n * @public\n */\n highlightCurated: {\n type: Boolean,\n default: false\n }\n },\n setup(props) {\n /**\n * Events list which are going to be emitted when a next query is selected.\n *\n * @returns The {@link XEvent} to emit.\n * @public\n */\n const events = computed(\n (): Partial<XEventsTypes> => ({ UserSelectedANextQuery: props.suggestion })\n );\n\n /**\n * Checks if the next query is curated and if it should be highlighted.\n *\n * @returns True if the next query is curated and should be highlighted.\n *\n * @internal\n */\n const shouldHighlightCurated = computed(\n () => props.highlightCurated && (props.suggestion.isCurated ?? false)\n );\n\n return {\n events,\n shouldHighlightCurated\n };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Dynamic Classes\n\n`NextQuery` uses the following dynamic CSS classes so you can style it when is:\n\n- Curated: `x-next-query--is-curated`.\n\n## Events\n\nA list of events that the component will emit:\n\n- [`UserSelectedANextQuery`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n the event is emitted after the user clicks the button. The event payload is the next query data.\n\n## Examples\n\nThis components expects just a suggestion as a prop to be rendered. It has a slot to override the\ncontent. By default, it renders the suggestion query of the next query. It also has an optional\nprop, `highlightCurated`, to indicate if the curated Next Queries should be differentiated with a\nCSS class.\n\n### Basic Usage\n\nUsing default slot:\n\n```vue live\n<template>\n <NextQuery :suggestion=\"suggestion\" />\n</template>\n\n<script>\n import { NextQuery } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryDemo',\n components: {\n NextQuery\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Overriding default slot.\n\nThe default slot allows you to replace the content of the suggestion button.\n\n```vue live\n<template>\n <NextQuery :suggestion=\"suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-next-query__query\" :aria-label=\"suggestion.query\">{{ suggestion.query }}</span>\n </template>\n </NextQuery>\n</template>\n\n<script>\n import { NextQuery } from '@empathyco/x-components/next-queries';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueryDemo',\n components: {\n NextQuery,\n TrendingIcon\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_createCommentVNode","_renderSlot","_normalizeProps","_guardReactiveProps"],"mappings":";;;;;oCACEA,gBAiBiB,CAAA,gBAAA,CAAA,CAAA;AAfd,EAAA,OAAAC,SAAA,EAAsB,EAAAC,WAAA,CAAA,yBAAA,EAAA;AAAA,IACtB,uBAAwB,cAAQ,EAAA,EAAA,0BAAA,EAAA,IAAA,CAAA,sBAAA,EAAA,CAAA,CAAA;AAAA,IACjC,YAAS,IAAC,CAAA,UAAA;AAAA,IACV,wBAAoB,EAAA,IAAA,CAAA,MAAA;AAAA,IAAA,WAAA,EAAA,YAAA;IAEnB,OAAO,EAAA,YAAA;AAAA,GAAA,EAAA;AAGR,IAAA,OAAA,EAAAC,OAAA,CAAA,CAAA,SAAA,KAAA;AAAA,MAKAC,kBAA8B,CAAA,0BAAA,CAAA;AAAA,MAC9BA,mBAA0D,8aAAN,CAAA;AAAA,MAAAA,kBAAA,CAAA,yBAAA,CAAA;AAjBxD,MAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,SAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,sBAAA,EAAA,IAAA,CAAA,sBAAA,EAAA,CAAA,CAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
1
+ {"version":3,"file":"next-query.vue.js","sources":["../../../../../src/x-modules/next-queries/components/next-query.vue"],"sourcesContent":["<template>\n <BaseSuggestion\n class=\"x-next-query\"\n :suggestion=\"suggestion\"\n :suggestionSelectedEvents=\"events\"\n data-test=\"next-query\"\n feature=\"next_query\"\n :class=\"{ 'x-next-query--is-curated': shouldHighlightCurated }\"\n #default=\"baseScope\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Next Query content\n @binding {Object} v-bind - `BaseSuggestion` default slot scope: **suggestion** <code>Suggestion</code> - Suggestion data<br /> **query** <code>string</code> - The query that the suggestion belongs to<br /> **filter** <code>Filter \\| undefined</code> - Suggestion's filter\n @binding {boolean} shouldHighlightCurated - True if the curated NQ should be highlighted\n -->\n <!-- eslint-enable max-len -->\n <slot v-bind=\"{ ...baseScope, shouldHighlightCurated }\" />\n </BaseSuggestion>\n</template>\n\n<script lang=\"ts\">\n import { NextQuery as NextQueryModel } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseSuggestion from '../../../components/suggestions/base-suggestion.vue';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { nextQueriesXModule } from '../x-module';\n\n /**\n * Renders a next query item which receives the suggestion that will be rendered as a prop. It\n * exposes a default slot to change the next query content. If the slot is not overridden,\n * it will render the suggestion query by default.\n *\n * @public\n */\n export default defineComponent({\n name: 'NextQuery',\n xModule: nextQueriesXModule.name,\n components: { BaseSuggestion },\n props: {\n /**\n * The suggestion to render and use in the default slot.\n *\n * @public\n */\n suggestion: {\n type: Object as PropType<NextQueryModel>,\n required: true\n },\n /**\n * Indicates if the curated next query should be highlighted.\n *\n * @public\n */\n highlightCurated: {\n type: Boolean,\n default: false\n }\n },\n setup(props) {\n /**\n * Events list which are going to be emitted when a next query is selected.\n *\n * @returns The {@link XEvent} to emit.\n * @public\n */\n const events = computed(\n (): Partial<XEventsTypes> => ({ UserSelectedANextQuery: props.suggestion })\n );\n\n /**\n * Checks if the next query is curated and if it should be highlighted.\n *\n * @returns True if the next query is curated and should be highlighted.\n *\n * @internal\n */\n const shouldHighlightCurated = computed(\n () => props.highlightCurated && (props.suggestion.isCurated ?? false)\n );\n\n return {\n events,\n shouldHighlightCurated\n };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Dynamic Classes\n\n`NextQuery` uses the following dynamic CSS classes so you can style it when is:\n\n- Curated: `x-next-query--is-curated`.\n\n## Events\n\nA list of events that the component will emit:\n\n- [`UserSelectedANextQuery`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n the event is emitted after the user clicks the button. The event payload is the next query data.\n\n## Examples\n\nThis components expects just a suggestion as a prop to be rendered. It has a slot to override the\ncontent. By default, it renders the suggestion query of the next query. It also has an optional\nprop, `highlightCurated`, to indicate if the curated Next Queries should be differentiated with a\nCSS class.\n\n### Basic Usage\n\nUsing default slot:\n\n```vue live\n<template>\n <NextQuery :suggestion=\"suggestion\" />\n</template>\n\n<script>\n import { NextQuery } from '@empathyco/x-components/next-queries';\n\n export default {\n name: 'NextQueryDemo',\n components: {\n NextQuery\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Overriding default slot.\n\nThe default slot allows you to replace the content of the suggestion button.\n\n```vue live\n<template>\n <NextQuery :suggestion=\"suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-next-query__query\" :aria-label=\"suggestion.query\">{{ suggestion.query }}</span>\n </template>\n </NextQuery>\n</template>\n\n<script>\n import { NextQuery } from '@empathyco/x-components/next-queries';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'NextQueryDemo',\n components: {\n NextQuery,\n TrendingIcon\n },\n data() {\n return {\n suggestion: {\n modelName: 'NextQuery',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_renderSlot","_normalizeProps","_guardReactiveProps"],"mappings":";;;;;oCACEA,gBAiBiB,CAAA,gBAAA,CAAA,CAAA;AAfd,EAAA,OAAAC,SAAA,EAAsB,EAAAC,WAAA,CAAA,yBAAA,EAAA;AAAA,IACtB,uBAAwB,cAAQ,EAAA,EAAA,0BAAA,EAAA,IAAA,CAAA,sBAAA,EAAA,CAAA,CAAA;AAAA,IACjC,YAAS,IAAC,CAAA,UAAA;AAAA,IACV,wBAAoB,EAAA,IAAA,CAAA,MAAA;AAAA,IAAA,WAAA,EAAA,YAAA;IAEnB,OAAO,EAAA,YAAA;AAAA,GAAA,EAAA;;AARZ,MAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,SAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,sBAAA,EAAA,IAAA,CAAA,sBAAA,EAAA,CAAA,CAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
@@ -1,3 +1,4 @@
1
+ import '@empathyco/x-utils';
1
2
  import { createStoreEmitters } from '../../../store/utils/store-emitters.utils.js';
2
3
  import { createEmitterArrayFilter } from '../../../utils/array.js';
3
4
  import { nextQueriesXStoreModule } from './module.js';
@@ -1 +1 @@
1
- {"version":3,"file":"emitters.js","sources":["../../../../../src/x-modules/next-queries/store/emitters.ts"],"sourcesContent":["import { createStoreEmitters } from '../../../store';\nimport { createEmitterArrayFilter } from '../../../utils/array';\nimport { nextQueriesXStoreModule } from './module';\n\n/**\n * {@link StoreEmitters} For the next-queries module.\n *\n * @internal\n */\nexport const nextQueriesEmitters = createStoreEmitters(nextQueriesXStoreModule, {\n NextQueriesChanged: {\n selector: (_, getters) => getters.nextQueries,\n filter: createEmitterArrayFilter('query')\n },\n NextQueriesRequestUpdated: (_, getters) => getters.request\n});\n"],"names":[],"mappings":";;;;AAIA;;;;AAIG;AACU,MAAA,mBAAmB,GAAG,mBAAmB,CAAC,uBAAuB,EAAE;AAC9E,IAAA,kBAAkB,EAAE;QAClB,QAAQ,EAAE,CAAC,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,WAAW;AAC7C,QAAA,MAAM,EAAE,wBAAwB,CAAC,OAAO,CAAC;AAC1C,KAAA;IACD,yBAAyB,EAAE,CAAC,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,OAAO;AAC3D,CAAA;;;;"}
1
+ {"version":3,"file":"emitters.js","sources":["../../../../../src/x-modules/next-queries/store/emitters.ts"],"sourcesContent":["import { createStoreEmitters } from '../../../store';\nimport { createEmitterArrayFilter } from '../../../utils/array';\nimport { nextQueriesXStoreModule } from './module';\n\n/**\n * {@link StoreEmitters} For the next-queries module.\n *\n * @internal\n */\nexport const nextQueriesEmitters = createStoreEmitters(nextQueriesXStoreModule, {\n NextQueriesChanged: {\n selector: (_, getters) => getters.nextQueries,\n filter: createEmitterArrayFilter('query')\n },\n NextQueriesRequestUpdated: (_, getters) => getters.request\n});\n"],"names":[],"mappings":";;;;;AAIA;;;;AAIG;AACU,MAAA,mBAAmB,GAAG,mBAAmB,CAAC,uBAAuB,EAAE;AAC9E,IAAA,kBAAkB,EAAE;QAClB,QAAQ,EAAE,CAAC,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,WAAW;AAC7C,QAAA,MAAM,EAAE,wBAAwB,CAAC,OAAO,CAAC;AAC1C,KAAA;IACD,yBAAyB,EAAE,CAAC,CAAC,EAAE,OAAO,KAAK,OAAO,CAAC,OAAO;AAC3D,CAAA;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './popular-search.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, withCtx, createCommentVNode, renderSlot, normalizeProps, guardReactiveProps } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, withCtx, renderSlot, normalizeProps, guardReactiveProps } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -12,9 +12,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
12
12
  feature: "popular_search"
13
13
  }, {
14
14
  default: withCtx((baseScope) => [
15
- createCommentVNode(" eslint-disable max-len "),
16
- createCommentVNode("\n @slot Popular Search content\n @binding {Object} v-bind - `BaseSuggestion` default slot scope: **suggestion** <code>Suggestion</code> - Suggestion data<br /> **query** <code>string</code> - The query that the suggestion belongs to<br /> **filter** <code>Filter \\| undefined</code> - Suggestion's filter\n "),
17
- createCommentVNode(" eslint-enable max-len "),
18
15
  renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ ...baseScope })))
19
16
  ]),
20
17
  _: 3
@@ -1 +1 @@
1
- {"version":3,"file":"popular-search.vue.js","sources":["../../../../../src/x-modules/popular-searches/components/popular-search.vue"],"sourcesContent":["<template>\n <BaseSuggestion\n class=\"x-popular-search\"\n :suggestion=\"suggestion\"\n :suggestionSelectedEvents=\"events\"\n data-test=\"popular-search\"\n feature=\"popular_search\"\n #default=\"baseScope\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Popular Search content\n @binding {Object} v-bind - `BaseSuggestion` default slot scope: **suggestion** <code>Suggestion</code> - Suggestion data<br /> **query** <code>string</code> - The query that the suggestion belongs to<br /> **filter** <code>Filter \\| undefined</code> - Suggestion's filter\n -->\n <!-- eslint-enable max-len -->\n <slot v-bind=\"{ ...baseScope }\" />\n </BaseSuggestion>\n</template>\n\n<script lang=\"ts\">\n import { Suggestion } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseSuggestion from '../../../components/suggestions/base-suggestion.vue';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { popularSearchesXModule } from '../x-module';\n\n /**\n * Renders a popular search item which receives the suggestion that will be rendered as a prop. It\n * exposes a default slot to change the popular search content. If the slot is not overridden,\n * it will render the suggestion query by default.\n *\n * @public\n */\n export default defineComponent({\n name: 'PopularSearch',\n xModule: popularSearchesXModule.name,\n components: { BaseSuggestion },\n props: {\n /**\n * The suggestion to render and use in the default slot.\n *\n * @public\n */\n suggestion: {\n type: Object as PropType<Suggestion>,\n required: true\n }\n },\n setup(props) {\n /**\n * Events list which are going to be emitted when a popular search is selected.\n *\n * @returns The {@link XEvent} to emit.\n * @public\n */\n const events = computed(\n (): Partial<XEventsTypes> => ({ UserSelectedAPopularSearch: props.suggestion })\n );\n\n return { events };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nA list of events that the component will emit:\n\n- [`UserSelectedAPopularSearch`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n the event is emitted after the user clicks the button. The event payload is the popular search\n data.\n\n## Examples\n\nThis components expects just a suggestion as a prop to be rendered. It has a slot to override the\ncontent. By default, it renders the suggestion query of the popular search.\n\n### Basic Usage\n\n```vue live\n<template>\n <PopularSearch :suggestion=\"suggestion\" />\n</template>\n\n<script>\n import { PopularSearch } from '@empathyco/x-components/popular-searches';\n export default {\n name: 'PopularSearchDemo',\n components: {\n PopularSearch\n },\n data() {\n return {\n suggestion: {\n modelName: 'PopularSearch',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Custom Usage\n\n```vue live\n<template>\n <PopularSearch :suggestion=\"suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span :aria-label=\"suggestion.query\">{{ suggestion.query }}</span>\n </template>\n </PopularSearch>\n</template>\n\n<script>\n import { PopularSearch } from '@empathyco/x-components/popular-searches';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'PopularSearchDemo',\n components: {\n PopularSearch,\n TrendingIcon\n },\n data() {\n return {\n suggestion: {\n modelName: 'PopularSearch',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_createCommentVNode","_renderSlot","_normalizeProps","_guardReactiveProps"],"mappings":";;;;;oCACEA,gBAeiB,CAAA,gBAAA,CAAA,CAAA;AAbd,EAAA,OAAAC,SAAA,EAAsB,EAAAC,WAAA,CAAA,yBAAA,EAAA;AAAA,IACtB,KAAA,EAAA,kBAAA;AAAA,IACD,YAAS,IAAC,CAAA,UAAA;AAAA,IACV,wBAAwB,EAAA,IAAA,CAAA,MAAA;AAAA,IAAA,WAAA,EAAA,gBAAA;IACvB,OAAO,EAAA,gBAAA;AAAA,GAAA,EAAA;AAGR,IAAA,OAAA,EAAAC,OAAA,CAAA,CAAA,SAAA,KAAA;AAAA,MAIAC,kBAA8B,CAAA,0BAAA,CAAA;AAAA,MAC9BA,mBAAkC,0UAAN,CAAA;AAAA,MAAAA,kBAAA,CAAA,yBAAA,CAAA;AAfhC,MAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,SAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,CAAA,CAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
1
+ {"version":3,"file":"popular-search.vue.js","sources":["../../../../../src/x-modules/popular-searches/components/popular-search.vue"],"sourcesContent":["<template>\n <BaseSuggestion\n class=\"x-popular-search\"\n :suggestion=\"suggestion\"\n :suggestionSelectedEvents=\"events\"\n data-test=\"popular-search\"\n feature=\"popular_search\"\n #default=\"baseScope\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Popular Search content\n @binding {Object} v-bind - `BaseSuggestion` default slot scope: **suggestion** <code>Suggestion</code> - Suggestion data<br /> **query** <code>string</code> - The query that the suggestion belongs to<br /> **filter** <code>Filter \\| undefined</code> - Suggestion's filter\n -->\n <!-- eslint-enable max-len -->\n <slot v-bind=\"{ ...baseScope }\" />\n </BaseSuggestion>\n</template>\n\n<script lang=\"ts\">\n import { Suggestion } from '@empathyco/x-types';\n import { computed, defineComponent, PropType } from 'vue';\n import BaseSuggestion from '../../../components/suggestions/base-suggestion.vue';\n import { XEventsTypes } from '../../../wiring/events.types';\n import { popularSearchesXModule } from '../x-module';\n\n /**\n * Renders a popular search item which receives the suggestion that will be rendered as a prop. It\n * exposes a default slot to change the popular search content. If the slot is not overridden,\n * it will render the suggestion query by default.\n *\n * @public\n */\n export default defineComponent({\n name: 'PopularSearch',\n xModule: popularSearchesXModule.name,\n components: { BaseSuggestion },\n props: {\n /**\n * The suggestion to render and use in the default slot.\n *\n * @public\n */\n suggestion: {\n type: Object as PropType<Suggestion>,\n required: true\n }\n },\n setup(props) {\n /**\n * Events list which are going to be emitted when a popular search is selected.\n *\n * @returns The {@link XEvent} to emit.\n * @public\n */\n const events = computed(\n (): Partial<XEventsTypes> => ({ UserSelectedAPopularSearch: props.suggestion })\n );\n\n return { events };\n }\n });\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nA list of events that the component will emit:\n\n- [`UserSelectedAPopularSearch`](https://github.com/empathyco/x/blob/main/packages/x-components/src/wiring/events.types.ts):\n the event is emitted after the user clicks the button. The event payload is the popular search\n data.\n\n## Examples\n\nThis components expects just a suggestion as a prop to be rendered. It has a slot to override the\ncontent. By default, it renders the suggestion query of the popular search.\n\n### Basic Usage\n\n```vue live\n<template>\n <PopularSearch :suggestion=\"suggestion\" />\n</template>\n\n<script>\n import { PopularSearch } from '@empathyco/x-components/popular-searches';\n export default {\n name: 'PopularSearchDemo',\n components: {\n PopularSearch\n },\n data() {\n return {\n suggestion: {\n modelName: 'PopularSearch',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n\n### Custom Usage\n\n```vue live\n<template>\n <PopularSearch :suggestion=\"suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span :aria-label=\"suggestion.query\">{{ suggestion.query }}</span>\n </template>\n </PopularSearch>\n</template>\n\n<script>\n import { PopularSearch } from '@empathyco/x-components/popular-searches';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'PopularSearchDemo',\n components: {\n PopularSearch,\n TrendingIcon\n },\n data() {\n return {\n suggestion: {\n modelName: 'PopularSearch',\n query: 'tshirt',\n facets: []\n }\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_renderSlot","_normalizeProps","_guardReactiveProps"],"mappings":";;;;;oCACEA,gBAeiB,CAAA,gBAAA,CAAA,CAAA;AAbd,EAAA,OAAAC,SAAA,EAAsB,EAAAC,WAAA,CAAA,yBAAA,EAAA;AAAA,IACtB,KAAA,EAAA,kBAAA;AAAA,IACD,YAAS,IAAC,CAAA,UAAA;AAAA,IACV,wBAAwB,EAAA,IAAA,CAAA,MAAA;AAAA,IAAA,WAAA,EAAA,gBAAA;IACvB,OAAO,EAAA,gBAAA;AAAA,GAAA,EAAA;;AAPZ,MAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,SAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,CAAA,CAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './popular-searches.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, withCtx, createCommentVNode, renderSlot, normalizeProps, guardReactiveProps, createVNode } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, withCtx, renderSlot, normalizeProps, guardReactiveProps, createVNode } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -11,18 +11,12 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
11
11
  "data-test": "popular-searches"
12
12
  }, {
13
13
  default: withCtx((baseScope) => [
14
- createCommentVNode(" eslint-disable max-len "),
15
- createCommentVNode("\n @slot Popular Search item\n @binding {Object} v-bind - Popular Search suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Popular Search suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Popular Search suggestion index\n "),
16
- createCommentVNode(" eslint-enable max-len "),
17
14
  renderSlot(_ctx.$slots, "suggestion", normalizeProps(guardReactiveProps({ ...baseScope })), () => [
18
15
  createVNode(_component_PopularSearch, {
19
16
  suggestion: baseScope.suggestion,
20
17
  class: "x-popular-searches__suggestion x-suggestion"
21
18
  }, {
22
19
  default: withCtx((popularSearchScope) => [
23
- createCommentVNode(" eslint-disable max-len "),
24
- createCommentVNode("\n @slot Popular Search content\n @binding {Object} v-bind - Popular Search suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Popular Search suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Popular Search suggestion index\n "),
25
- createCommentVNode(" eslint-enable max-len "),
26
20
  renderSlot(_ctx.$slots, "suggestion-content", normalizeProps(guardReactiveProps({ ...baseScope, ...popularSearchScope })))
27
21
  ]),
28
22
  _: 2
@@ -1 +1 @@
1
- {"version":3,"file":"popular-searches.vue.js","sources":["../../../../../src/x-modules/popular-searches/components/popular-searches.vue"],"sourcesContent":["<template>\n <BaseSuggestions\n :suggestions=\"popularSearches\"\n class=\"x-popular-searches\"\n data-test=\"popular-searches\"\n >\n <template #default=\"baseScope\">\n <!-- eslint-disable max-len -->\n <!--\n @slot Popular Search item\n @binding {Object} v-bind - Popular Search suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Popular Search suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Popular Search suggestion index\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion\" v-bind=\"{ ...baseScope }\">\n <PopularSearch\n :suggestion=\"baseScope.suggestion\"\n class=\"x-popular-searches__suggestion x-suggestion\"\n #default=\"popularSearchScope\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Popular Search content\n @binding {Object} v-bind - Popular Search suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Popular Search suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Popular Search suggestion index\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion-content\" v-bind=\"{ ...baseScope, ...popularSearchScope }\" />\n </PopularSearch>\n </slot>\n </template>\n </BaseSuggestions>\n</template>\n\n<script lang=\"ts\">\n import { defineComponent } from 'vue';\n import BaseSuggestions from '../../../components/suggestions/base-suggestions.vue';\n import { popularSearchesXModule } from '../x-module';\n import { useGetter } from '../../../composables/use-getter';\n import PopularSearch from './popular-search.vue';\n\n /**\n * Simple popular-searches component that renders a list of suggestions, allowing the user to\n * select one of them, and emitting the needed events.\n * A popular search is just a query that has been searched a lot in a certain period and may\n * optionally have associated a set of filters.\n *\n * @public\n */\n export default defineComponent({\n name: 'PopularSearches',\n xModule: popularSearchesXModule.name,\n components: {\n PopularSearch,\n BaseSuggestions\n },\n setup() {\n /**\n * The list of popular searches.\n *\n * @internal\n */\n const { popularSearches } = useGetter('popularSearches', ['popularSearches']);\n\n return { popularSearches };\n }\n });\n</script>\n\n<!--eslint-disable max-len -->\n<docs lang=\"mdx\">\n## Inherited props\n\nThis component inherits the [`BaseSuggestions`](../base-components/x-components.base-suggestions.md)\nprops.\n\n| Name | Description | Type | Default |\n| ------------------ | ----------------------------------------------------------------- | -------- | ------- |\n| `animation` | Animation component that will be used to animate the suggestions. | `Vue` | `\"ul\"` |\n| `maxItemsToRender` | Number of popular searches to be rendered. | `number` | |\n\n## Examples\n\n### Default Usage\n\nYou don't need to pass any props, or slots. Simply add the component, and when it has any popular\nsearches it will show them.\n\n```vue live\n<template>\n <PopularSearches />\n</template>\n\n<script>\n import { PopularSearches } from '@empathyco/x-components/popular-searches';\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches\n }\n };\n</script>\n```\n\nThe component has two optional props. `animation` to render the component with an animation and\n`maxItemsToRender` to limit the number of popular searches will be rendered (by default it is 5).\n\n```vue live\n<template>\n <PopularSearches :animation=\"'FadeAndSlide'\" :maxItemsToRender=\"10\" />\n</template>\n\n<script>\n import Vue from 'vue';\n import { PopularSearches } from '@empathyco/x-components/popular-searches';\n import FadeAndSlide from '@empathyco/x-components';\n\n // Registering the animation as a global component\n Vue.component('FadeAndSlide', FadeAndSlide);\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches,\n FadeAndSlide\n }\n };\n</script>\n```\n\n### Overriding Popular Search's Content\n\nYou can use your custom implementation of the Popular Search's content. In the example below,\ninstead of using the default Popular Search's content, an icon is added, as well as a span with the\nquery of the Popular Search's suggestion.\n\n```vue live\n<template>\n <PopularSearches>\n <template #suggestion-content=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-popular-search__query\">{{ suggestion.query }}</span>\n </template>\n </PopularSearches>\n</template>\n\n<script>\n import { PopularSearches } from '@empathyco/x-components/popular-searches';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches,\n TrendingIcon\n }\n };\n</script>\n```\n\n### Adding a Custom Popular Search Item\n\nYou can use your custom implementation for the whole Popular Search item. In the example below, we\nchange the default implementation of the Popular Search in Popular Searches. A custom Popular Search\nimplementation is added, it has an image and a span as content (as in the previous example). Also, a\nbutton with a user customized behaviour is added at the same hierarchical level as the Popular\nSearch component.\n\n```vue live\n<template>\n <PopularSearches>\n <template #suggestion=\"{ suggestion }\">\n <PopularSearch :suggestion=\"suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-popular-search__query\">{{ suggestion.query }}</span>\n </template>\n </PopularSearch>\n <button>Custom Behaviour</button>\n </template>\n </PopularSearches>\n</template>\n\n<script>\n import { PopularSearches, PopularSearch } from '@empathyco/x-components/popular-searches';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches,\n PopularSearch,\n TrendingIcon\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_createCommentVNode","_renderSlot","_normalizeProps","_guardReactiveProps","_createVNode"],"mappings":";;;;;;AA6BoB,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AA1BX,EAAA,OAAAC,SAAA,EAAqB,EAAAC,WAAA,CAAA,0BAAA,EAAA;AAAA,IAC1B,WAAU,EAAA,IAAA,CAAA,eAAA;AAAA,IAAA,KAAA,EAAA,oBAAA;IAEC,WAAO,EAAA,kBAAA;AAAA,GAAA,EAAA;AAEhB,IAAA,OAAA,EAAAC,OAAA,CAAA,CAAA,SAAA,KAAA;AAAA,MAIAC,kBAA8B,CAAA,0BAAA,CAAA;AAAA,MAC9BA,kBAcO,CAAA,ySAAA,CAAA;AAAA,MADWA,kBAAA,CAAA,yBAAA,CAAA;AAAA,MAXbC,UAAA,CAAA,IAAA,CAAY,QAAS,YAAW,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,CAAA,CAAA,EAAA,MAAA;AAAA,QAC3BC,WAAA,CAAA,wBAAA,EAAA;AAAA,UAAA,UAAA,EAAA,SAAA,CAAA,UAAA;UACL,KAAO,EAAA,6CAAA;AAAA,SAAA,EAAA;AAGR,UAAA,OAAA,EAAAL,OAAA,CAAA,CAAA,kBAAA,KAAA;AAAA,YAIAC,kBAA8B,CAAA,0BAAA,CAAA;AAAA,YAC9BA,mBAAmF,wTAAN,CAAA;AAAA,YAAAA,kBAAA,CAAA,yBAAA,CAAA;AAzBvF,YAAAC,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,oBAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,GAAA,kBAAA,EAAA,CAAA,CAAA,CAAA;AAAA,WAAA,CAAA;;;;AAAA,OAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
1
+ {"version":3,"file":"popular-searches.vue.js","sources":["../../../../../src/x-modules/popular-searches/components/popular-searches.vue"],"sourcesContent":["<template>\n <BaseSuggestions\n :suggestions=\"popularSearches\"\n class=\"x-popular-searches\"\n data-test=\"popular-searches\"\n >\n <template #default=\"baseScope\">\n <!-- eslint-disable max-len -->\n <!--\n @slot Popular Search item\n @binding {Object} v-bind - Popular Search suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Popular Search suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Popular Search suggestion index\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion\" v-bind=\"{ ...baseScope }\">\n <PopularSearch\n :suggestion=\"baseScope.suggestion\"\n class=\"x-popular-searches__suggestion x-suggestion\"\n #default=\"popularSearchScope\"\n >\n <!-- eslint-disable max-len -->\n <!--\n @slot Popular Search content\n @binding {Object} v-bind - Popular Search suggestion attributes:<br />&nbsp;&nbsp;- **suggestion** <code>Suggestion</code> - Popular Search suggestion data<br />&nbsp;&nbsp;- **index** <code>number</code> - Popular Search suggestion index\n -->\n <!-- eslint-enable max-len -->\n <slot name=\"suggestion-content\" v-bind=\"{ ...baseScope, ...popularSearchScope }\" />\n </PopularSearch>\n </slot>\n </template>\n </BaseSuggestions>\n</template>\n\n<script lang=\"ts\">\n import { defineComponent } from 'vue';\n import BaseSuggestions from '../../../components/suggestions/base-suggestions.vue';\n import { popularSearchesXModule } from '../x-module';\n import { useGetter } from '../../../composables/use-getter';\n import PopularSearch from './popular-search.vue';\n\n /**\n * Simple popular-searches component that renders a list of suggestions, allowing the user to\n * select one of them, and emitting the needed events.\n * A popular search is just a query that has been searched a lot in a certain period and may\n * optionally have associated a set of filters.\n *\n * @public\n */\n export default defineComponent({\n name: 'PopularSearches',\n xModule: popularSearchesXModule.name,\n components: {\n PopularSearch,\n BaseSuggestions\n },\n setup() {\n /**\n * The list of popular searches.\n *\n * @internal\n */\n const { popularSearches } = useGetter('popularSearches', ['popularSearches']);\n\n return { popularSearches };\n }\n });\n</script>\n\n<!--eslint-disable max-len -->\n<docs lang=\"mdx\">\n## Inherited props\n\nThis component inherits the [`BaseSuggestions`](../base-components/x-components.base-suggestions.md)\nprops.\n\n| Name | Description | Type | Default |\n| ------------------ | ----------------------------------------------------------------- | -------- | ------- |\n| `animation` | Animation component that will be used to animate the suggestions. | `Vue` | `\"ul\"` |\n| `maxItemsToRender` | Number of popular searches to be rendered. | `number` | |\n\n## Examples\n\n### Default Usage\n\nYou don't need to pass any props, or slots. Simply add the component, and when it has any popular\nsearches it will show them.\n\n```vue live\n<template>\n <PopularSearches />\n</template>\n\n<script>\n import { PopularSearches } from '@empathyco/x-components/popular-searches';\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches\n }\n };\n</script>\n```\n\nThe component has two optional props. `animation` to render the component with an animation and\n`maxItemsToRender` to limit the number of popular searches will be rendered (by default it is 5).\n\n```vue live\n<template>\n <PopularSearches :animation=\"'FadeAndSlide'\" :maxItemsToRender=\"10\" />\n</template>\n\n<script>\n import Vue from 'vue';\n import { PopularSearches } from '@empathyco/x-components/popular-searches';\n import FadeAndSlide from '@empathyco/x-components';\n\n // Registering the animation as a global component\n Vue.component('FadeAndSlide', FadeAndSlide);\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches,\n FadeAndSlide\n }\n };\n</script>\n```\n\n### Overriding Popular Search's Content\n\nYou can use your custom implementation of the Popular Search's content. In the example below,\ninstead of using the default Popular Search's content, an icon is added, as well as a span with the\nquery of the Popular Search's suggestion.\n\n```vue live\n<template>\n <PopularSearches>\n <template #suggestion-content=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-popular-search__query\">{{ suggestion.query }}</span>\n </template>\n </PopularSearches>\n</template>\n\n<script>\n import { PopularSearches } from '@empathyco/x-components/popular-searches';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches,\n TrendingIcon\n }\n };\n</script>\n```\n\n### Adding a Custom Popular Search Item\n\nYou can use your custom implementation for the whole Popular Search item. In the example below, we\nchange the default implementation of the Popular Search in Popular Searches. A custom Popular Search\nimplementation is added, it has an image and a span as content (as in the previous example). Also, a\nbutton with a user customized behaviour is added at the same hierarchical level as the Popular\nSearch component.\n\n```vue live\n<template>\n <PopularSearches>\n <template #suggestion=\"{ suggestion }\">\n <PopularSearch :suggestion=\"suggestion\">\n <template #default=\"{ suggestion }\">\n <TrendingIcon />\n <span class=\"x-popular-search__query\">{{ suggestion.query }}</span>\n </template>\n </PopularSearch>\n <button>Custom Behaviour</button>\n </template>\n </PopularSearches>\n</template>\n\n<script>\n import { PopularSearches, PopularSearch } from '@empathyco/x-components/popular-searches';\n import { TrendingIcon } from '@empathyco/x-components';\n\n export default {\n name: 'PopularSearchesDemo',\n components: {\n PopularSearches,\n PopularSearch,\n TrendingIcon\n }\n };\n</script>\n```\n</docs>\n"],"names":["_resolveComponent","_openBlock","_createBlock","_withCtx","_renderSlot","_normalizeProps","_guardReactiveProps","_createVNode"],"mappings":";;;;;;AA6BoB,EAAA,MAAA,0BAAA,GAAAA,gBAAA,CAAA,iBAAA,CAAA,CAAA;AA1BX,EAAA,OAAAC,SAAA,EAAqB,EAAAC,WAAA,CAAA,0BAAA,EAAA;AAAA,IAC1B,WAAU,EAAA,IAAA,CAAA,eAAA;AAAA,IAAA,KAAA,EAAA,oBAAA;IAEC,WAAO,EAAA,kBAAA;AAAA,GAAA,EAAA;aAQdC,OAYgB,CAAA,CAAA,SAAA,KAAA;AAAA,MAXbC,UAAA,CAAA,IAAA,CAAY,QAAS,YAAW,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,CAAA,CAAA,EAAA,MAAA;AAAA,QAC3BC,WAAA,CAAA,wBAAA,EAAA;AAAA,UAAA,UAAA,EAAA,SAAA,CAAA,UAAA;UACL,KAAO,EAAA,6CAAA;AAAA,SAAA,EAAA;;AAjBlB,YAAAH,UAAA,CAAA,IAAA,CAAA,MAAA,EAAA,oBAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,EAAA,GAAA,SAAA,EAAA,GAAA,kBAAA,EAAA,CAAA,CAAA,CAAA;AAAA,WAAA,CAAA;;;;AAAA,OAAA,CAAA;AAAA,KAAA,CAAA;;;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import _sfc_main from './query-preview-button.vue2.js';
2
- import { resolveComponent, openBlock, createBlock, withCtx, createCommentVNode, renderSlot, createTextVNode, toDisplayString } from 'vue';
2
+ import { resolveComponent, openBlock, createBlock, withCtx, renderSlot, createTextVNode, toDisplayString } from 'vue';
3
3
  import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.js';
4
4
 
5
5
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -11,7 +11,6 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
11
11
  "data-test": "query-preview-button"
12
12
  }, {
13
13
  default: withCtx(() => [
14
- createCommentVNode(" @slot Button content with a text, an icon or both "),
15
14
  renderSlot(_ctx.$slots, "default", { queryPreviewInfo: _ctx.fullQueryPreviewInfo }, () => [
16
15
  createTextVNode(
17
16
  toDisplayString(_ctx.queryPreviewInfo.query),