@getlupa/client 0.10.1 → 0.10.3

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 (61) hide show
  1. package/dist/cjs/components/search-box/SearchBox.vue.d.ts +6 -1
  2. package/dist/cjs/components/search-box/SearchBoxInput.vue.d.ts +2 -0
  3. package/dist/cjs/components/search-box/products/SearchBoxProduct.vue.d.ts +1 -0
  4. package/dist/cjs/components/search-results/SearchResults.vue.d.ts +3 -0
  5. package/dist/cjs/components/search-results/SearchResultsTitle.vue.d.ts +2 -0
  6. package/dist/cjs/components/search-results/products/SearchResultsToolbar.vue.d.ts +1 -0
  7. package/dist/cjs/components/search-results/products/product-card/SearchResultsProductCard.vue.d.ts +1 -0
  8. package/dist/cjs/components/search-results/products/product-card/elements/SearchResultsProductCustom.vue.d.ts +2 -0
  9. package/dist/cjs/constants/development/searchBoxDev.example.const.d.ts +1 -0
  10. package/dist/cjs/constants/development/searchResultsDev.example.const.d.ts +1 -0
  11. package/dist/cjs/constants/global.const.d.ts +1 -0
  12. package/dist/cjs/index.min.js +366 -147
  13. package/dist/cjs/store/modules/tracking.d.ts +3 -1
  14. package/dist/cjs/types/AnalyticsOptions.d.ts +3 -2
  15. package/dist/cjs/types/search-box/Common.d.ts +1 -0
  16. package/dist/cjs/types/search-box/SearchBoxOptions.d.ts +1 -0
  17. package/dist/cjs/types/search-container/SearchContainerOptions.d.ts +1 -0
  18. package/dist/cjs/types/search-results/SearchResultsProductCardOptions.d.ts +1 -0
  19. package/dist/cjs/utils/shadowDom.utils.d.ts +5 -0
  20. package/dist/containerStyle.js +1 -0
  21. package/dist/es/components/search-box/SearchBox.vue.d.ts +6 -1
  22. package/dist/es/components/search-box/SearchBoxInput.vue.d.ts +2 -0
  23. package/dist/es/components/search-box/products/SearchBoxProduct.vue.d.ts +1 -0
  24. package/dist/es/components/search-results/SearchResults.vue.d.ts +3 -0
  25. package/dist/es/components/search-results/SearchResultsTitle.vue.d.ts +2 -0
  26. package/dist/es/components/search-results/products/SearchResultsToolbar.vue.d.ts +1 -0
  27. package/dist/es/components/search-results/products/product-card/SearchResultsProductCard.vue.d.ts +1 -0
  28. package/dist/es/components/search-results/products/product-card/elements/SearchResultsProductCustom.vue.d.ts +2 -0
  29. package/dist/es/constants/development/searchBoxDev.example.const.d.ts +1 -0
  30. package/dist/es/constants/development/searchResultsDev.example.const.d.ts +1 -0
  31. package/dist/es/constants/global.const.d.ts +1 -0
  32. package/dist/es/index.min.js +366 -147
  33. package/dist/es/store/modules/tracking.d.ts +3 -1
  34. package/dist/es/types/AnalyticsOptions.d.ts +3 -2
  35. package/dist/es/types/search-box/Common.d.ts +1 -0
  36. package/dist/es/types/search-box/SearchBoxOptions.d.ts +1 -0
  37. package/dist/es/types/search-container/SearchContainerOptions.d.ts +1 -0
  38. package/dist/es/types/search-results/SearchResultsProductCardOptions.d.ts +1 -0
  39. package/dist/es/utils/shadowDom.utils.d.ts +5 -0
  40. package/dist/iife/components/search-box/SearchBox.vue.d.ts +6 -1
  41. package/dist/iife/components/search-box/SearchBoxInput.vue.d.ts +2 -0
  42. package/dist/iife/components/search-box/products/SearchBoxProduct.vue.d.ts +1 -0
  43. package/dist/iife/components/search-results/SearchResults.vue.d.ts +3 -0
  44. package/dist/iife/components/search-results/SearchResultsTitle.vue.d.ts +2 -0
  45. package/dist/iife/components/search-results/products/SearchResultsToolbar.vue.d.ts +1 -0
  46. package/dist/iife/components/search-results/products/product-card/SearchResultsProductCard.vue.d.ts +1 -0
  47. package/dist/iife/components/search-results/products/product-card/elements/SearchResultsProductCustom.vue.d.ts +2 -0
  48. package/dist/iife/constants/development/searchBoxDev.example.const.d.ts +1 -0
  49. package/dist/iife/constants/development/searchResultsDev.example.const.d.ts +1 -0
  50. package/dist/iife/constants/global.const.d.ts +1 -0
  51. package/dist/iife/index.min.js +1 -1
  52. package/dist/iife/store/modules/tracking.d.ts +3 -1
  53. package/dist/iife/types/AnalyticsOptions.d.ts +3 -2
  54. package/dist/iife/types/search-box/Common.d.ts +1 -0
  55. package/dist/iife/types/search-box/SearchBoxOptions.d.ts +1 -0
  56. package/dist/iife/types/search-container/SearchContainerOptions.d.ts +1 -0
  57. package/dist/iife/types/search-results/SearchResultsProductCardOptions.d.ts +1 -0
  58. package/dist/iife/utils/shadowDom.utils.d.ts +5 -0
  59. package/dist/lupaContainerStyle.css +1 -0
  60. package/dist/style.css +1 -1
  61. package/package.json +3 -2
@@ -1,7 +1,7 @@
1
1
  import { FetchedData, HighlightedDocInfo, InputSuggestion, InputSuggestionFacet, SelectedData, TrackableEventData } from "@/types/search-box/Common";
2
2
  import { SearchBoxInputOptions, SearchBoxOptions, SearchBoxPanelOptions } from "@/types/search-box/SearchBoxOptions";
3
3
  import { QueryParams } from "@/types/search-results/QueryParams";
4
- import { Document } from "@getlupa/client-sdk/Types";
4
+ import { Document, PublicQuery } from "@getlupa/client-sdk/Types";
5
5
  import Vue from "vue";
6
6
  declare const params: import("vuex-class/lib/bindings").BindingHelpers;
7
7
  export default class SearchBox extends Vue {
@@ -28,6 +28,10 @@ export default class SearchBox extends Vue {
28
28
  queryKey: string;
29
29
  data: TrackableEventData;
30
30
  }) => void;
31
+ trackSearch: ({ queryKey, query, }: {
32
+ queryKey: string;
33
+ query: PublicQuery;
34
+ }) => void;
31
35
  setSearchResultsLink: (searchResultsLink: string) => {
32
36
  searchResultsLink: string;
33
37
  };
@@ -63,6 +67,7 @@ export default class SearchBox extends Vue {
63
67
  query: string;
64
68
  }): void;
65
69
  trackDocumentClick(doc: HighlightedDocInfo): void;
70
+ trackSearchQuery(query?: string): void;
66
71
  trackSuggestionClick(suggestion?: string): void;
67
72
  resetValues(): void;
68
73
  handleProductClick(): void;
@@ -20,4 +20,6 @@ export default class SearchBoxInput extends Vue {
20
20
  handleQueryChange(): void;
21
21
  handleInput(evt?: InputEvent): void;
22
22
  handleFocus(): void;
23
+ clear(): void;
24
+ focus(): void;
23
25
  }
@@ -23,5 +23,6 @@ export default class SearchBoxProduct extends Vue {
23
23
  get imageElements(): DocumentElement[];
24
24
  get detailElements(): DocumentElement[];
25
25
  get id(): string;
26
+ get title(): string;
26
27
  handleClick(event?: Event): void;
27
28
  }
@@ -2,10 +2,12 @@ import { QueryParams } from "@/types/search-results/QueryParams";
2
2
  import { ProductGrid, SearchResultsDidYouMeanLabels, SearchResultsOptions, SearchResultsProductOptions } from "@/types/search-results/SearchResultsOptions";
3
3
  import { FilterGroup, PublicQuery, SearchQueryResult } from "@getlupa/client-sdk/Types";
4
4
  import Vue from "vue";
5
+ import { AnalyticsEventType } from "@/types/AnalyticsOptions";
5
6
  export default class SearchResults extends Vue {
6
7
  options: SearchResultsOptions;
7
8
  initialFilters: FilterGroup;
8
9
  isProductList: boolean;
10
+ isContainer: boolean;
9
11
  get productsOptions(): SearchResultsProductOptions;
10
12
  currentQueryText: string;
11
13
  hasResults: boolean;
@@ -16,6 +18,7 @@ export default class SearchResults extends Vue {
16
18
  trackSearch: ({ queryKey, query, }: {
17
19
  queryKey: string;
18
20
  query: PublicQuery;
21
+ type?: AnalyticsEventType;
19
22
  }) => void;
20
23
  trackResults: ({ queryKey, results, }: {
21
24
  queryKey: string;
@@ -3,6 +3,7 @@ import Vue from "vue";
3
3
  export default class SearchResultsTitle extends Vue {
4
4
  options: SearchResultsOptions;
5
5
  isProductList: boolean;
6
+ showSummary: boolean;
6
7
  currentQueryText: string;
7
8
  totalItems: number;
8
9
  suggestedSearchText: string;
@@ -10,5 +11,6 @@ export default class SearchResultsTitle extends Vue {
10
11
  get showProductCount(): boolean;
11
12
  get showSearchTitle(): boolean;
12
13
  get descriptionTop(): string | undefined;
14
+ get summaryLabel(): string;
13
15
  getLabel(label: string): string;
14
16
  }
@@ -21,6 +21,7 @@ export default class SearchResultsToolbar extends Vue {
21
21
  get displayPageSelect(): boolean;
22
22
  get searchSummaryLabel(): string;
23
23
  get showMobileFilterCount(): boolean;
24
+ get hasResults(): boolean;
24
25
  currentResolutionPageSizes: number[];
25
26
  removeAllFilters: () => {
26
27
  params: QueryParams;
@@ -30,6 +30,7 @@ export default class SearchResultsProductCard extends Vue {
30
30
  mounted(): void;
31
31
  checkIfIsInStock(): Promise<void>;
32
32
  get id(): string;
33
+ get title(): string;
33
34
  handleClick(): void;
34
35
  handleProductEvent(item: {
35
36
  type: ReportableEventType;
@@ -4,7 +4,9 @@ import { CustomDocumentElement } from "@/types/DocumentElement";
4
4
  export default class SearchResultsProductCustom extends Vue {
5
5
  item: Document;
6
6
  options: CustomDocumentElement;
7
+ get value(): unknown;
7
8
  get text(): string;
9
+ get isArray(): boolean;
8
10
  get className(): string;
9
11
  get label(): string | undefined;
10
12
  get isHtml(): boolean;
@@ -15,6 +15,7 @@ export declare const SEARCH_BOX_CONFIGURATION: {
15
15
  currency: string;
16
16
  priceSeparator: string;
17
17
  defaultFacetLabel: string;
18
+ close: string;
18
19
  };
19
20
  links: {
20
21
  searchResults: string;
@@ -100,6 +100,7 @@ export declare const SEARCH_RESULTS_CONFIGURATION: {
100
100
  details: string;
101
101
  };
102
102
  idKey: string;
103
+ titleKey: string;
103
104
  elements: DocumentElement[];
104
105
  breadcrumbs: ({
105
106
  label: string;
@@ -13,3 +13,4 @@ export declare const CURRENCY_KEY_INDICATOR = "price";
13
13
  export declare const DEFAULT_PAGE_SIZE = 12;
14
14
  export declare const DEFAULT_PAGE_SIZE_SELECTION: number[];
15
15
  export declare const LUPA_ROUTING_EVENT = "lupaRedirect";
16
+ export declare const DEFAULT_CONTAINER_STYLE = "containerStyle.css";