@getlupa/client 0.14.3 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/search-results/SearchResults.vue.d.ts +6 -0
- package/dist/cjs/components/search-results/products/product-card/SearchResultsProductCard.vue.d.ts +2 -0
- package/dist/cjs/index.min.js +73 -12
- package/dist/cjs/store/modules/options.d.ts +5 -0
- package/dist/cjs/types/AnalyticsOptions.d.ts +2 -1
- package/dist/cjs/types/search-box/Common.d.ts +4 -0
- package/dist/es/components/search-results/SearchResults.vue.d.ts +6 -0
- package/dist/es/components/search-results/products/product-card/SearchResultsProductCard.vue.d.ts +2 -0
- package/dist/es/index.min.js +73 -12
- package/dist/es/store/modules/options.d.ts +5 -0
- package/dist/es/types/AnalyticsOptions.d.ts +2 -1
- package/dist/es/types/search-box/Common.d.ts +4 -0
- package/dist/iife/components/search-results/SearchResults.vue.d.ts +6 -0
- package/dist/iife/components/search-results/products/product-card/SearchResultsProductCard.vue.d.ts +2 -0
- package/dist/iife/index.min.js +1 -1
- package/dist/iife/store/modules/options.d.ts +5 -0
- package/dist/iife/types/AnalyticsOptions.d.ts +2 -1
- package/dist/iife/types/search-box/Common.d.ts +4 -0
- package/package.json +1 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { TrackingOptions } from "@/types/General";
|
|
1
2
|
import { SearchBoxOptions } from "@/types/search-box/SearchBoxOptions";
|
|
2
3
|
import { RoutingBehavior } from "@/types/search-results/RoutingBehavior";
|
|
3
4
|
import { SearchResultsOptions } from "@/types/search-results/SearchResultsOptions";
|
|
@@ -6,6 +7,7 @@ import { VuexModule } from "vuex-module-decorators";
|
|
|
6
7
|
export default class OptionsModule extends VuexModule {
|
|
7
8
|
searchBoxOptions: SearchBoxOptions;
|
|
8
9
|
searchResultOptions: SearchResultsOptions;
|
|
10
|
+
trackingOptions: TrackingOptions;
|
|
9
11
|
searchResultInitialFilters: FilterGroup;
|
|
10
12
|
get envOptions(): Options;
|
|
11
13
|
get classMap(): Record<string, string>;
|
|
@@ -17,6 +19,9 @@ export default class OptionsModule extends VuexModule {
|
|
|
17
19
|
setSearchBoxOptions({ options }: {
|
|
18
20
|
options: SearchBoxOptions;
|
|
19
21
|
}): void;
|
|
22
|
+
setTrackingOptions({ options }: {
|
|
23
|
+
options: TrackingOptions;
|
|
24
|
+
}): void;
|
|
20
25
|
setSearchResultOptions({ options }: {
|
|
21
26
|
options: SearchResultsOptions;
|
|
22
27
|
}): void;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
export declare const PARENT_EVENT_NAME = "GetLupa";
|
|
2
|
-
export declare type AnalyticsEventType = "search_query" | "search_form_submit" | "autocomplete_suggestion_click" | "autocomplete_product_click" | "search_product_click" | "search_zero_results" | "search_filters" | "search_add_to_cart";
|
|
2
|
+
export declare type AnalyticsEventType = "search_query" | "search_form_submit" | "autocomplete_suggestion_click" | "autocomplete_product_click" | "search_product_click" | "search_zero_results" | "search_filters" | "search_add_to_cart" | "view_item_list" | "select_item";
|
|
3
3
|
export declare type AnalyticsOptions = {
|
|
4
4
|
type: "ua" | "ga4" | "debug";
|
|
5
5
|
enabled: boolean;
|
|
6
6
|
parentEventName: string;
|
|
7
7
|
ignoreEvents?: AnalyticsEventType[];
|
|
8
|
+
itemMap?: (item: Record<string, unknown>) => Record<string, unknown>;
|
|
8
9
|
};
|
|
@@ -34,6 +34,10 @@ export declare type TrackableEventData = {
|
|
|
34
34
|
analytics?: {
|
|
35
35
|
type: AnalyticsEventType;
|
|
36
36
|
label: string;
|
|
37
|
+
items?: Record<string, unknown>[];
|
|
38
|
+
};
|
|
39
|
+
options?: {
|
|
40
|
+
allowEmptySearchQuery: boolean;
|
|
37
41
|
};
|
|
38
42
|
};
|
|
39
43
|
export declare type HighlightedDocInfo = {
|