@survicate/survicate-web-package 23.2.4-npm → 24.1.0-npm
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/package.json +1 -1
- package/survicate_widget.d.ts +12 -4
- package/survicate_widget.js +1 -1
package/package.json
CHANGED
package/survicate_widget.d.ts
CHANGED
|
@@ -10,6 +10,14 @@ interface VisitorAttributes {
|
|
|
10
10
|
|
|
11
11
|
export type CallbackTypes = CallbackType | QuestionAnsweredCallback;
|
|
12
12
|
|
|
13
|
+
export enum SurveyType {
|
|
14
|
+
WidgetSurvey = 'WidgetSurvey',
|
|
15
|
+
PageSurvey = 'PageSurvey',
|
|
16
|
+
MobileSurvey = 'MobileSurvey',
|
|
17
|
+
FeedbackButton = 'FeedbackButton',
|
|
18
|
+
IntercomSurvey = 'IntercomSurvey'
|
|
19
|
+
}
|
|
20
|
+
|
|
13
21
|
export interface ShowSurveyOptions {
|
|
14
22
|
forceDisplay?: true;
|
|
15
23
|
displayMethod?: AppearMethodApi;
|
|
@@ -44,8 +52,8 @@ export interface SurveyApi {
|
|
|
44
52
|
addEventListener: (event: ApiEvents, callback: CallbackTypes) => number | void;
|
|
45
53
|
destroyVisitor: (callback?: () => void) => void;
|
|
46
54
|
disableTargeting?: boolean;
|
|
47
|
-
getSurvey: () =>
|
|
48
|
-
getVisitorId: () => string;
|
|
55
|
+
getSurvey: () => Record<string, Record<string, string>>;
|
|
56
|
+
getVisitorId: (surveyType?: SurveyType) => string;
|
|
49
57
|
invokeEvent: (eventName: string, eventProperties?: Record<string, string>) => void;
|
|
50
58
|
removeEventListener: (eventId: number | ApiEvents) => void;
|
|
51
59
|
retarget: () => void;
|
|
@@ -60,8 +68,8 @@ declare const Survicate: {
|
|
|
60
68
|
addEventListener: (event: ApiEvents, callback: CallbackTypes) => number | void;
|
|
61
69
|
destroyVisitor: (callback?: () => void) => void;
|
|
62
70
|
disableTargeting?: boolean;
|
|
63
|
-
getSurvey: () =>
|
|
64
|
-
getVisitorId: () => string;
|
|
71
|
+
getSurvey: () => Record<string, Record<string, string>>;
|
|
72
|
+
getVisitorId: (surveyType?: SurveyType) => string;
|
|
65
73
|
init: (config: ConfigModel) => Promise<null | void>;
|
|
66
74
|
invokeEvent: (eventName: string, eventProperties?: Record<string, string>) => void;
|
|
67
75
|
removeEventListener: (eventId: number | ApiEvents) => void;
|