analytica.click 0.0.425 → 0.0.427
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/{components → analytica.click/src/components}/AnalyticaConfig/index.d.ts +1 -1
- package/dist/{helpers → analytica.click/src/helpers}/errorTrack.d.ts +1 -1
- package/dist/{helpers → analytica.click/src/helpers}/track.d.ts +1 -1
- package/dist/{helpers → analytica.click/src/helpers}/trackServer.d.ts +1 -1
- package/dist/analytica.click/src/index.d.ts +2 -0
- package/dist/common/src/api/apis/DefaultApi.d.ts +117 -0
- package/dist/common/src/api/apis/index.d.ts +1 -0
- package/dist/common/src/api/index.d.ts +3 -0
- package/dist/common/src/api/models/ApiKey.d.ts +45 -0
- package/dist/common/src/api/models/ArchiveErrors.d.ts +27 -0
- package/dist/common/src/api/models/BingIntegration.d.ts +33 -0
- package/dist/common/src/api/models/Browser.d.ts +57 -0
- package/dist/common/src/api/models/DeleteAccount.d.ts +27 -0
- package/dist/common/src/api/models/Event.d.ts +57 -0
- package/dist/common/src/api/models/GetAccount.d.ts +51 -0
- package/dist/common/src/api/models/GetAccounts.d.ts +52 -0
- package/dist/common/src/api/models/GoogleIntegration.d.ts +39 -0
- package/dist/common/src/api/models/Language.d.ts +57 -0
- package/dist/common/src/api/models/Location.d.ts +57 -0
- package/dist/common/src/api/models/ModelError.d.ts +99 -0
- package/dist/common/src/api/models/PostAccount.d.ts +27 -0
- package/dist/common/src/api/models/PostError.d.ts +34 -0
- package/dist/common/src/api/models/PostErrorData.d.ts +51 -0
- package/dist/common/src/api/models/PostSiteTrack.d.ts +34 -0
- package/dist/common/src/api/models/PostSiteTrackData.d.ts +57 -0
- package/dist/common/src/api/models/Query.d.ts +69 -0
- package/dist/common/src/api/models/Referrer.d.ts +57 -0
- package/dist/common/src/api/models/Resolution.d.ts +57 -0
- package/dist/common/src/api/models/Rollup.d.ts +94 -0
- package/dist/common/src/api/models/RollupTopBrowsers.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopErrors.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopEvents.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopLanguages.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopLocations.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopQueries.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopReferrers.d.ts +33 -0
- package/dist/common/src/api/models/RollupTopResolutions.d.ts +33 -0
- package/dist/common/src/api/models/SeoResult.d.ts +64 -0
- package/dist/common/src/api/models/SeoResultValues.d.ts +45 -0
- package/dist/common/src/api/models/SiteData.d.ts +94 -0
- package/dist/common/src/api/models/SiteDetails.d.ts +45 -0
- package/dist/common/src/api/models/index.d.ts +33 -0
- package/dist/common/src/helpers/logsend.d.ts +2 -0
- package/dist/common-ui/src/components/ErrorBoundary/index.d.ts +16 -0
- package/dist/common-ui/src/types/widgets.d.ts +17 -0
- package/dist/helpers/trackServer.js +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +2 -2
- package/package.json +2 -2
- /package/dist/{components → analytica.click/src/components}/ErrorBoundary/index.d.ts +0 -0
- /package/dist/{components → analytica.click/src/components}/index.d.ts +0 -0
- /package/dist/{helpers → analytica.click/src/helpers}/index.d.ts +0 -0
- /package/dist/{helpers → analytica.click/src/helpers}/log.d.ts +0 -0
- /package/dist/{helpers → analytica.click/src/helpers}/object.d.ts +0 -0
@@ -0,0 +1,33 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface RollupTopLanguages
|
16
|
+
*/
|
17
|
+
export interface RollupTopLanguages {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {string}
|
21
|
+
* @memberof RollupTopLanguages
|
22
|
+
*/
|
23
|
+
language: string;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {number}
|
27
|
+
* @memberof RollupTopLanguages
|
28
|
+
*/
|
29
|
+
count: number;
|
30
|
+
}
|
31
|
+
export declare function RollupTopLanguagesFromJSON(json: any): RollupTopLanguages;
|
32
|
+
export declare function RollupTopLanguagesFromJSONTyped(json: any, ignoreDiscriminator: boolean): RollupTopLanguages;
|
33
|
+
export declare function RollupTopLanguagesToJSON(value?: RollupTopLanguages | null): any;
|
@@ -0,0 +1,33 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface RollupTopLocations
|
16
|
+
*/
|
17
|
+
export interface RollupTopLocations {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {string}
|
21
|
+
* @memberof RollupTopLocations
|
22
|
+
*/
|
23
|
+
countryRegion: string;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {number}
|
27
|
+
* @memberof RollupTopLocations
|
28
|
+
*/
|
29
|
+
count: number;
|
30
|
+
}
|
31
|
+
export declare function RollupTopLocationsFromJSON(json: any): RollupTopLocations;
|
32
|
+
export declare function RollupTopLocationsFromJSONTyped(json: any, ignoreDiscriminator: boolean): RollupTopLocations;
|
33
|
+
export declare function RollupTopLocationsToJSON(value?: RollupTopLocations | null): any;
|
@@ -0,0 +1,33 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface RollupTopQueries
|
16
|
+
*/
|
17
|
+
export interface RollupTopQueries {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {string}
|
21
|
+
* @memberof RollupTopQueries
|
22
|
+
*/
|
23
|
+
pathName: string;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {number}
|
27
|
+
* @memberof RollupTopQueries
|
28
|
+
*/
|
29
|
+
count: number;
|
30
|
+
}
|
31
|
+
export declare function RollupTopQueriesFromJSON(json: any): RollupTopQueries;
|
32
|
+
export declare function RollupTopQueriesFromJSONTyped(json: any, ignoreDiscriminator: boolean): RollupTopQueries;
|
33
|
+
export declare function RollupTopQueriesToJSON(value?: RollupTopQueries | null): any;
|
@@ -0,0 +1,33 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface RollupTopReferrers
|
16
|
+
*/
|
17
|
+
export interface RollupTopReferrers {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {string}
|
21
|
+
* @memberof RollupTopReferrers
|
22
|
+
*/
|
23
|
+
referrer: string;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {number}
|
27
|
+
* @memberof RollupTopReferrers
|
28
|
+
*/
|
29
|
+
count: number;
|
30
|
+
}
|
31
|
+
export declare function RollupTopReferrersFromJSON(json: any): RollupTopReferrers;
|
32
|
+
export declare function RollupTopReferrersFromJSONTyped(json: any, ignoreDiscriminator: boolean): RollupTopReferrers;
|
33
|
+
export declare function RollupTopReferrersToJSON(value?: RollupTopReferrers | null): any;
|
@@ -0,0 +1,33 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface RollupTopResolutions
|
16
|
+
*/
|
17
|
+
export interface RollupTopResolutions {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {string}
|
21
|
+
* @memberof RollupTopResolutions
|
22
|
+
*/
|
23
|
+
resolution: string;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {number}
|
27
|
+
* @memberof RollupTopResolutions
|
28
|
+
*/
|
29
|
+
count: number;
|
30
|
+
}
|
31
|
+
export declare function RollupTopResolutionsFromJSON(json: any): RollupTopResolutions;
|
32
|
+
export declare function RollupTopResolutionsFromJSONTyped(json: any, ignoreDiscriminator: boolean): RollupTopResolutions;
|
33
|
+
export declare function RollupTopResolutionsToJSON(value?: RollupTopResolutions | null): any;
|
@@ -0,0 +1,64 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
import { SeoResultValues } from './';
|
13
|
+
/**
|
14
|
+
*
|
15
|
+
* @export
|
16
|
+
* @interface SeoResult
|
17
|
+
*/
|
18
|
+
export interface SeoResult {
|
19
|
+
/**
|
20
|
+
*
|
21
|
+
* @type {string}
|
22
|
+
* @memberof SeoResult
|
23
|
+
*/
|
24
|
+
account: string;
|
25
|
+
/**
|
26
|
+
*
|
27
|
+
* @type {string}
|
28
|
+
* @memberof SeoResult
|
29
|
+
*/
|
30
|
+
email: string;
|
31
|
+
/**
|
32
|
+
*
|
33
|
+
* @type {string}
|
34
|
+
* @memberof SeoResult
|
35
|
+
*/
|
36
|
+
site: string;
|
37
|
+
/**
|
38
|
+
*
|
39
|
+
* @type {number}
|
40
|
+
* @memberof SeoResult
|
41
|
+
*/
|
42
|
+
datetime: number;
|
43
|
+
/**
|
44
|
+
*
|
45
|
+
* @type {string}
|
46
|
+
* @memberof SeoResult
|
47
|
+
*/
|
48
|
+
category: string;
|
49
|
+
/**
|
50
|
+
*
|
51
|
+
* @type {SeoResultValues}
|
52
|
+
* @memberof SeoResult
|
53
|
+
*/
|
54
|
+
totals: SeoResultValues;
|
55
|
+
/**
|
56
|
+
*
|
57
|
+
* @type {Array<SeoResultValues>}
|
58
|
+
* @memberof SeoResult
|
59
|
+
*/
|
60
|
+
queries: Array<SeoResultValues>;
|
61
|
+
}
|
62
|
+
export declare function SeoResultFromJSON(json: any): SeoResult;
|
63
|
+
export declare function SeoResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): SeoResult;
|
64
|
+
export declare function SeoResultToJSON(value?: SeoResult | null): any;
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface SeoResultValues
|
16
|
+
*/
|
17
|
+
export interface SeoResultValues {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {number}
|
21
|
+
* @memberof SeoResultValues
|
22
|
+
*/
|
23
|
+
clicks: number;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {number}
|
27
|
+
* @memberof SeoResultValues
|
28
|
+
*/
|
29
|
+
impressions: number;
|
30
|
+
/**
|
31
|
+
*
|
32
|
+
* @type {number}
|
33
|
+
* @memberof SeoResultValues
|
34
|
+
*/
|
35
|
+
position: number;
|
36
|
+
/**
|
37
|
+
*
|
38
|
+
* @type {string}
|
39
|
+
* @memberof SeoResultValues
|
40
|
+
*/
|
41
|
+
query: string;
|
42
|
+
}
|
43
|
+
export declare function SeoResultValuesFromJSON(json: any): SeoResultValues;
|
44
|
+
export declare function SeoResultValuesFromJSONTyped(json: any, ignoreDiscriminator: boolean): SeoResultValues;
|
45
|
+
export declare function SeoResultValuesToJSON(value?: SeoResultValues | null): any;
|
@@ -0,0 +1,94 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
import { Browser, Event, GetAccount, Language, Location, ModelError, Query, Referrer, Resolution, Rollup, SeoResult } from './';
|
13
|
+
/**
|
14
|
+
*
|
15
|
+
* @export
|
16
|
+
* @interface SiteData
|
17
|
+
*/
|
18
|
+
export interface SiteData {
|
19
|
+
/**
|
20
|
+
*
|
21
|
+
* @type {GetAccount}
|
22
|
+
* @memberof SiteData
|
23
|
+
*/
|
24
|
+
details?: GetAccount;
|
25
|
+
/**
|
26
|
+
*
|
27
|
+
* @type {Array<Browser>}
|
28
|
+
* @memberof SiteData
|
29
|
+
*/
|
30
|
+
browsers?: Array<Browser>;
|
31
|
+
/**
|
32
|
+
*
|
33
|
+
* @type {Array<Event>}
|
34
|
+
* @memberof SiteData
|
35
|
+
*/
|
36
|
+
events?: Array<Event>;
|
37
|
+
/**
|
38
|
+
*
|
39
|
+
* @type {Array<Location>}
|
40
|
+
* @memberof SiteData
|
41
|
+
*/
|
42
|
+
locations?: Array<Location>;
|
43
|
+
/**
|
44
|
+
*
|
45
|
+
* @type {Array<Query>}
|
46
|
+
* @memberof SiteData
|
47
|
+
*/
|
48
|
+
queries?: Array<Query>;
|
49
|
+
/**
|
50
|
+
*
|
51
|
+
* @type {Array<Referrer>}
|
52
|
+
* @memberof SiteData
|
53
|
+
*/
|
54
|
+
referrers?: Array<Referrer>;
|
55
|
+
/**
|
56
|
+
*
|
57
|
+
* @type {Array<Resolution>}
|
58
|
+
* @memberof SiteData
|
59
|
+
*/
|
60
|
+
resolutions?: Array<Resolution>;
|
61
|
+
/**
|
62
|
+
*
|
63
|
+
* @type {Array<Language>}
|
64
|
+
* @memberof SiteData
|
65
|
+
*/
|
66
|
+
languages?: Array<Language>;
|
67
|
+
/**
|
68
|
+
*
|
69
|
+
* @type {Array<Rollup>}
|
70
|
+
* @memberof SiteData
|
71
|
+
*/
|
72
|
+
rollups?: Array<Rollup>;
|
73
|
+
/**
|
74
|
+
*
|
75
|
+
* @type {Array<ModelError>}
|
76
|
+
* @memberof SiteData
|
77
|
+
*/
|
78
|
+
errors?: Array<ModelError>;
|
79
|
+
/**
|
80
|
+
*
|
81
|
+
* @type {Array<SeoResult>}
|
82
|
+
* @memberof SiteData
|
83
|
+
*/
|
84
|
+
google?: Array<SeoResult>;
|
85
|
+
/**
|
86
|
+
*
|
87
|
+
* @type {Array<SeoResult>}
|
88
|
+
* @memberof SiteData
|
89
|
+
*/
|
90
|
+
bing?: Array<SeoResult>;
|
91
|
+
}
|
92
|
+
export declare function SiteDataFromJSON(json: any): SiteData;
|
93
|
+
export declare function SiteDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): SiteData;
|
94
|
+
export declare function SiteDataToJSON(value?: SiteData | null): any;
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/**
|
2
|
+
* analytica.click
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
4
|
+
*
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
6
|
+
* Contact: support@analytica.click
|
7
|
+
*
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
9
|
+
* https://openapi-generator.tech
|
10
|
+
* Do not edit the class manually.
|
11
|
+
*/
|
12
|
+
/**
|
13
|
+
*
|
14
|
+
* @export
|
15
|
+
* @interface SiteDetails
|
16
|
+
*/
|
17
|
+
export interface SiteDetails {
|
18
|
+
/**
|
19
|
+
*
|
20
|
+
* @type {string}
|
21
|
+
* @memberof SiteDetails
|
22
|
+
*/
|
23
|
+
site: string;
|
24
|
+
/**
|
25
|
+
*
|
26
|
+
* @type {string}
|
27
|
+
* @memberof SiteDetails
|
28
|
+
*/
|
29
|
+
account: string;
|
30
|
+
/**
|
31
|
+
*
|
32
|
+
* @type {string}
|
33
|
+
* @memberof SiteDetails
|
34
|
+
*/
|
35
|
+
favicon?: string;
|
36
|
+
/**
|
37
|
+
*
|
38
|
+
* @type {string}
|
39
|
+
* @memberof SiteDetails
|
40
|
+
*/
|
41
|
+
category: string;
|
42
|
+
}
|
43
|
+
export declare function SiteDetailsFromJSON(json: any): SiteDetails;
|
44
|
+
export declare function SiteDetailsFromJSONTyped(json: any, ignoreDiscriminator: boolean): SiteDetails;
|
45
|
+
export declare function SiteDetailsToJSON(value?: SiteDetails | null): any;
|
@@ -0,0 +1,33 @@
|
|
1
|
+
export * from './ApiKey';
|
2
|
+
export * from './ArchiveErrors';
|
3
|
+
export * from './BingIntegration';
|
4
|
+
export * from './Browser';
|
5
|
+
export * from './DeleteAccount';
|
6
|
+
export * from './Event';
|
7
|
+
export * from './GetAccount';
|
8
|
+
export * from './GetAccounts';
|
9
|
+
export * from './GoogleIntegration';
|
10
|
+
export * from './Language';
|
11
|
+
export * from './Location';
|
12
|
+
export * from './ModelError';
|
13
|
+
export * from './PostAccount';
|
14
|
+
export * from './PostError';
|
15
|
+
export * from './PostErrorData';
|
16
|
+
export * from './PostSiteTrack';
|
17
|
+
export * from './PostSiteTrackData';
|
18
|
+
export * from './Query';
|
19
|
+
export * from './Referrer';
|
20
|
+
export * from './Resolution';
|
21
|
+
export * from './Rollup';
|
22
|
+
export * from './RollupTopBrowsers';
|
23
|
+
export * from './RollupTopErrors';
|
24
|
+
export * from './RollupTopEvents';
|
25
|
+
export * from './RollupTopLanguages';
|
26
|
+
export * from './RollupTopLocations';
|
27
|
+
export * from './RollupTopQueries';
|
28
|
+
export * from './RollupTopReferrers';
|
29
|
+
export * from './RollupTopResolutions';
|
30
|
+
export * from './SeoResult';
|
31
|
+
export * from './SeoResultValues';
|
32
|
+
export * from './SiteData';
|
33
|
+
export * from './SiteDetails';
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import { Component } from 'react';
|
2
|
+
import type { TErrorMessage } from '../../types/widgets';
|
3
|
+
export interface IErrorBoundaryProps {
|
4
|
+
notify?: TErrorMessage;
|
5
|
+
children?: JSX.Element | JSX.Element[];
|
6
|
+
}
|
7
|
+
export declare class ErrorBoundary extends Component<IErrorBoundaryProps, {
|
8
|
+
hasError: Error | ErrorEvent | undefined;
|
9
|
+
}> {
|
10
|
+
seenError: boolean;
|
11
|
+
constructor(props: any);
|
12
|
+
static getDerivedStateFromError(errorV: any): {
|
13
|
+
hasError: any;
|
14
|
+
};
|
15
|
+
render(): import("react/jsx-runtime").JSX.Element | JSX.Element[] | undefined;
|
16
|
+
}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
export type TTrackNoEvent = (p: Omit<ITrack, 'eventName'>) => Promise<{
|
2
|
+
error?: string;
|
3
|
+
}>;
|
4
|
+
export type TTrack = (p: ITrack) => Promise<{
|
5
|
+
error?: string;
|
6
|
+
}>;
|
7
|
+
export interface ITrack {
|
8
|
+
analyticaToken: string;
|
9
|
+
overrideBaseUrl?: string;
|
10
|
+
eventName: string;
|
11
|
+
}
|
12
|
+
export type TErrorMessage = (m: Error | ErrorEvent) => Promise<void>;
|
13
|
+
export interface IAnalyticaConfig {
|
14
|
+
analyticaToken?: string;
|
15
|
+
overrideBaseUrl?: string;
|
16
|
+
devMode?: boolean;
|
17
|
+
}
|
@@ -1 +1 @@
|
|
1
|
-
var Yr=Object.create;var se=Object.defineProperty;var Zr=Object.getOwnPropertyDescriptor;var jr=Object.getOwnPropertyNames;var et=Object.getPrototypeOf,rt=Object.prototype.hasOwnProperty;var c=(e,r)=>()=>(r||e((r={exports:{}}).exports,r),r.exports),tt=(e,r)=>{for(var t in r)se(e,t,{get:r[t],enumerable:!0})},be=(e,r,t,n)=>{if(r&&typeof r=="object"||typeof r=="function")for(let i of jr(r))!rt.call(e,i)&&i!==t&&se(e,i,{get:()=>r[i],enumerable:!(n=Zr(r,i))||n.enumerable});return e};var nt=(e,r,t)=>(t=e!=null?Yr(et(e)):{},be(r||!e||!e.__esModule?se(t,"default",{value:e,enumerable:!0}):t,e)),it=e=>be(se({},"__esModule",{value:!0}),e);var m=c(s=>{"use strict";var oe=s&&s.__awaiter||function(e,r,t,n){function i(o){return o instanceof t?o:new t(function(l){l(o)})}return new(t||(t=Promise))(function(o,l){function ge(O){try{ne(n.next(O))}catch(ie){l(ie)}}function Oe(O){try{ne(n.throw(O))}catch(ie){l(ie)}}function ne(O){O.done?o(O.value):i(O.value).then(ge,Oe)}ne((n=n.apply(e,r||[])).next())})};Object.defineProperty(s,"__esModule",{value:!0});s.TextApiResponse=s.BlobApiResponse=s.VoidApiResponse=s.JSONApiResponse=s.canConsumeForm=s.mapValues=s.querystring=s.exists=s.Configuration=s.COLLECTION_FORMATS=s.RequiredError=s.BaseAPI=s.BASE_PATH=void 0;s.BASE_PATH="https://api.analytica.click".replace(/\/+$/,"");var ot=e=>typeof Blob<"u"&&e instanceof Blob,Se=class{constructor(r=new de){this.configuration=r,this.fetchApi=(t,n)=>oe(this,void 0,void 0,function*(){let i={url:t,init:n};for(let l of this.middleware)l.pre&&(i=(yield l.pre(Object.assign({fetch:this.fetchApi},i)))||i);let o=yield(this.configuration.fetchApi||fetch)(i.url,i.init);for(let l of this.middleware)l.post&&(o=(yield l.post({fetch:this.fetchApi,url:i.url,init:i.init,response:o.clone()}))||o);return o}),this.middleware=r.middleware||[]}withMiddleware(...r){let t=this.clone();return t.middleware=t.middleware.concat(...r),t}withPreMiddleware(...r){let t=r.map(n=>({pre:n}));return this.withMiddleware(...t)}withPostMiddleware(...r){let t=r.map(n=>({post:n}));return this.withMiddleware(...t)}request(r,t){return oe(this,void 0,void 0,function*(){let{url:n,init:i}=this.createFetchParams(r,t),o=yield this.fetchApi(n,i);if(o.status>=200&&o.status<300)return o;throw o})}createFetchParams(r,t){let n=this.configuration.basePath+r.path;r.query!==void 0&&Object.keys(r.query).length!==0&&(n+="?"+(this.configuration.queryParamsStringify||fe)(r.query));let i=typeof FormData<"u"&&r.body instanceof FormData||r.body instanceof URLSearchParams||ot(r.body)?r.body:JSON.stringify(r.body),o=Object.assign({},this.configuration.headers,r.headers),l=Object.assign({method:r.method,headers:o,body:i,credentials:this.configuration.credentials},t);return{url:n,init:l}}clone(){let r=this.constructor,t=new r(this.configuration);return t.middleware=this.middleware.slice(),t}};s.BaseAPI=Se;var ye=class extends Error{constructor(r,t){super(t),this.field=r,this.name="RequiredError"}};s.RequiredError=ye;s.COLLECTION_FORMATS={csv:",",ssv:" ",tsv:" ",pipes:"|"};var de=class{constructor(r={}){this.configuration=r}get basePath(){return this.configuration.basePath!=null?this.configuration.basePath:s.BASE_PATH}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||fe}get username(){return this.configuration.username}get password(){return this.configuration.password}get apiKey(){let r=this.configuration.apiKey;if(r)return typeof r=="function"?r:()=>r}get accessToken(){let r=this.configuration.accessToken;if(r)return typeof r=="function"?r:()=>oe(this,void 0,void 0,function*(){return r})}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}};s.Configuration=de;function ut(e,r){let t=e[r];return t!=null}s.exists=ut;function fe(e,r=""){return Object.keys(e).map(t=>{let n=r+(r.length?`[${t}]`:t),i=e[t];if(i instanceof Array){let o=i.map(l=>encodeURIComponent(String(l))).join(`&${encodeURIComponent(n)}=`);return`${encodeURIComponent(n)}=${o}`}return i instanceof Date?`${encodeURIComponent(n)}=${encodeURIComponent(i.toISOString())}`:i instanceof Object?fe(i,n):`${encodeURIComponent(n)}=${encodeURIComponent(String(i))}`}).filter(t=>t.length>0).join("&")}s.querystring=fe;function ct(e,r){return Object.keys(e).reduce((t,n)=>Object.assign(Object.assign({},t),{[n]:r(e[n])}),{})}s.mapValues=ct;function at(e){for(let r of e)if(r.contentType==="multipart/form-data")return!0;return!1}s.canConsumeForm=at;var Te=class{constructor(r,t=n=>n){this.raw=r,this.transformer=t}value(){return oe(this,void 0,void 0,function*(){return this.transformer(yield this.raw.json())})}};s.JSONApiResponse=Te;var Ne=class{constructor(r){this.raw=r}value(){return oe(this,void 0,void 0,function*(){})}};s.VoidApiResponse=Ne;var Je=class{constructor(r){this.raw=r}value(){return oe(this,void 0,void 0,function*(){return yield this.raw.blob()})}};s.BlobApiResponse=Je;var he=class{constructor(r){this.raw=r}value(){return oe(this,void 0,void 0,function*(){return yield this.raw.text()})}};s.TextApiResponse=he});var Ee=c(h=>{"use strict";Object.defineProperty(h,"__esModule",{value:!0});h.ApiKeyToJSON=h.ApiKeyFromJSONTyped=h.ApiKeyFromJSON=void 0;function st(e){return Pe(e,!1)}h.ApiKeyFromJSON=st;function Pe(e,r){return e==null?e:{key:e.key,adminKey:e.adminKey,site:e.site,account:e.account}}h.ApiKeyFromJSONTyped=Pe;function dt(e){if(e!==void 0)return e===null?null:{key:e.key,adminKey:e.adminKey,site:e.site,account:e.account}}h.ApiKeyToJSON=dt});var Ae=c(R=>{"use strict";Object.defineProperty(R,"__esModule",{value:!0});R.ArchiveErrorsToJSON=R.ArchiveErrorsFromJSONTyped=R.ArchiveErrorsFromJSON=void 0;function ft(e){return De(e,!1)}R.ArchiveErrorsFromJSON=ft;function De(e,r){return e==null?e:{PKsB64:e.PKsB64}}R.ArchiveErrorsFromJSONTyped=De;function lt(e){if(e!==void 0)return e===null?null:{PKsB64:e.PKsB64}}R.ArchiveErrorsToJSON=lt});var ke=c(F=>{"use strict";Object.defineProperty(F,"__esModule",{value:!0});F.BingIntegrationToJSON=F.BingIntegrationFromJSONTyped=F.BingIntegrationFromJSON=void 0;function pt(e){return qe(e,!1)}F.BingIntegrationFromJSON=pt;function qe(e,r){return e==null?e:{key:e.key,account:e.account}}F.BingIntegrationFromJSONTyped=qe;function mt(e){if(e!==void 0)return e===null?null:{key:e.key,account:e.account}}F.BingIntegrationToJSON=mt});var Be=c(w=>{"use strict";Object.defineProperty(w,"__esModule",{value:!0});w.BingResultToJSON=w.BingResultFromJSONTyped=w.BingResultFromJSON=void 0;function gt(e){return Le(e,!1)}w.BingResultFromJSON=gt;function Le(e,r){return e==null?e:{account:e.account,site:e.site,datetime:e.datetime,clicks:e.clicks,impressions:e.impressions,category:e.category}}w.BingResultFromJSONTyped=Le;function Ot(e){if(e!==void 0)return e===null?null:{account:e.account,site:e.site,datetime:e.datetime,clicks:e.clicks,impressions:e.impressions,category:e.category}}w.BingResultToJSON=Ot});var Ke=c(_=>{"use strict";Object.defineProperty(_,"__esModule",{value:!0});_.BrowserToJSON=_.BrowserFromJSONTyped=_.BrowserFromJSON=void 0;var St=m();function yt(e){return Me(e,!1)}_.BrowserFromJSON=yt;function Me(e,r){return e==null?e:{account:(0,St.exists)(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,browser:e.browser,count:e.count,category:e.category}}_.BrowserFromJSONTyped=Me;function Tt(e){if(e!==void 0)return e===null?null:{account:e.account,datetime:e.datetime,site:e.site,browser:e.browser,count:e.count,category:e.category}}_.BrowserToJSON=Tt});var Ie=c(b=>{"use strict";Object.defineProperty(b,"__esModule",{value:!0});b.DeleteAccountToJSON=b.DeleteAccountFromJSONTyped=b.DeleteAccountFromJSON=void 0;function Nt(e){return Ge(e,!1)}b.DeleteAccountFromJSON=Nt;function Ge(e,r){return e==null?e:{site:e.site}}b.DeleteAccountFromJSONTyped=Ge;function Jt(e){if(e!==void 0)return e===null?null:{site:e.site}}b.DeleteAccountToJSON=Jt});var ve=c(P=>{"use strict";Object.defineProperty(P,"__esModule",{value:!0});P.EventToJSON=P.EventFromJSONTyped=P.EventFromJSON=void 0;var ht=m();function Rt(e){return xe(e,!1)}P.EventFromJSON=Rt;function xe(e,r){return e==null?e:{account:(0,ht.exists)(e,"account")?e.account:void 0,site:e.site,eventName:e.eventName,datetime:e.datetime,count:e.count,category:e.category}}P.EventFromJSONTyped=xe;function Ft(e){if(e!==void 0)return e===null?null:{account:e.account,site:e.site,eventName:e.eventName,datetime:e.datetime,count:e.count,category:e.category}}P.EventToJSON=Ft});var Ce=c(E=>{"use strict";Object.defineProperty(E,"__esModule",{value:!0});E.GetAccountToJSON=E.GetAccountFromJSONTyped=E.GetAccountFromJSON=void 0;var wt=m();function _t(e){return Qe(e,!1)}E.GetAccountFromJSON=_t;function Qe(e,r){return e==null?e:{site:e.site,account:e.account,apiKey:e.apiKey,adminApiKey:e.adminApiKey,favicon:(0,wt.exists)(e,"favicon")?e.favicon:void 0}}E.GetAccountFromJSONTyped=Qe;function bt(e){if(e!==void 0)return e===null?null:{site:e.site,account:e.account,apiKey:e.apiKey,adminApiKey:e.adminApiKey,favicon:e.favicon}}E.GetAccountToJSON=bt});var Ve=c(D=>{"use strict";Object.defineProperty(D,"__esModule",{value:!0});D.GetAccountsToJSON=D.GetAccountsFromJSONTyped=D.GetAccountsFromJSON=void 0;var le=m(),ze=N();function Pt(e){return $e(e,!1)}D.GetAccountsFromJSON=Pt;function $e(e,r){return e==null?e:{accounts:e.accounts.map(ze.GetAccountFromJSON),googleEmail:(0,le.exists)(e,"googleEmail")?e.googleEmail:void 0,googleKey:(0,le.exists)(e,"googleKey")?e.googleKey:void 0,bingKey:(0,le.exists)(e,"bingKey")?e.bingKey:void 0,bingAccount:(0,le.exists)(e,"bingAccount")?e.bingAccount:void 0}}D.GetAccountsFromJSONTyped=$e;function Et(e){if(e!==void 0)return e===null?null:{accounts:e.accounts.map(ze.GetAccountToJSON),googleEmail:e.googleEmail,googleKey:e.googleKey,bingKey:e.bingKey,bingAccount:e.bingAccount}}D.GetAccountsToJSON=Et});var He=c(A=>{"use strict";Object.defineProperty(A,"__esModule",{value:!0});A.GoogleIntegrationToJSON=A.GoogleIntegrationFromJSONTyped=A.GoogleIntegrationFromJSON=void 0;function Dt(e){return Ue(e,!1)}A.GoogleIntegrationFromJSON=Dt;function Ue(e,r){return e==null?e:{email:e.email,key:e.key,account:e.account}}A.GoogleIntegrationFromJSONTyped=Ue;function At(e){if(e!==void 0)return e===null?null:{email:e.email,key:e.key,account:e.account}}A.GoogleIntegrationToJSON=At});var Xe=c(q=>{"use strict";Object.defineProperty(q,"__esModule",{value:!0});q.GoogleQueryToJSON=q.GoogleQueryFromJSONTyped=q.GoogleQueryFromJSON=void 0;function qt(e){return We(e,!1)}q.GoogleQueryFromJSON=qt;function We(e,r){return e==null?e:{clicks:e.clicks,ctr:e.ctr,impressions:e.impressions,keys:e.keys,position:e.position}}q.GoogleQueryFromJSONTyped=We;function kt(e){if(e!==void 0)return e===null?null:{clicks:e.clicks,ctr:e.ctr,impressions:e.impressions,keys:e.keys,position:e.position}}q.GoogleQueryToJSON=kt});var je=c(k=>{"use strict";Object.defineProperty(k,"__esModule",{value:!0});k.GoogleResultToJSON=k.GoogleResultFromJSONTyped=k.GoogleResultFromJSON=void 0;var Ye=N();function Lt(e){return Ze(e,!1)}k.GoogleResultFromJSON=Lt;function Ze(e,r){return e==null?e:{account:e.account,email:e.email,site:e.site,datetime:e.datetime,clicks:e.clicks,impressions:e.impressions,position:e.position,queries:e.queries.map(Ye.GoogleQueryFromJSON),category:e.category}}k.GoogleResultFromJSONTyped=Ze;function Bt(e){if(e!==void 0)return e===null?null:{account:e.account,email:e.email,site:e.site,datetime:e.datetime,clicks:e.clicks,impressions:e.impressions,position:e.position,queries:e.queries.map(Ye.GoogleQueryToJSON),category:e.category}}k.GoogleResultToJSON=Bt});var rr=c(L=>{"use strict";Object.defineProperty(L,"__esModule",{value:!0});L.LanguageToJSON=L.LanguageFromJSONTyped=L.LanguageFromJSON=void 0;var Mt=m();function Kt(e){return er(e,!1)}L.LanguageFromJSON=Kt;function er(e,r){return e==null?e:{account:(0,Mt.exists)(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,language:e.language,count:e.count,category:e.category}}L.LanguageFromJSONTyped=er;function Gt(e){if(e!==void 0)return e===null?null:{account:e.account,datetime:e.datetime,site:e.site,language:e.language,count:e.count,category:e.category}}L.LanguageToJSON=Gt});var nr=c(B=>{"use strict";Object.defineProperty(B,"__esModule",{value:!0});B.LocationToJSON=B.LocationFromJSONTyped=B.LocationFromJSON=void 0;var It=m();function xt(e){return tr(e,!1)}B.LocationFromJSON=xt;function tr(e,r){return e==null?e:{account:(0,It.exists)(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,countryRegion:e.countryRegion,category:e.category,count:e.count}}B.LocationFromJSONTyped=tr;function vt(e){if(e!==void 0)return e===null?null:{account:e.account,datetime:e.datetime,site:e.site,countryRegion:e.countryRegion,category:e.category,count:e.count}}B.LocationToJSON=vt});var or=c(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});M.ModelErrorToJSON=M.ModelErrorFromJSONTyped=M.ModelErrorFromJSON=void 0;var ce=m();function Qt(e){return ir(e,!1)}M.ModelErrorFromJSON=Qt;function ir(e,r){return e==null?e:{PK:e.PK,messageHash:(0,ce.exists)(e,"messageHash")?e.messageHash:void 0,site:e.site,account:e.account,message:(0,ce.exists)(e,"message")?e.message:void 0,name:(0,ce.exists)(e,"name")?e.name:void 0,stack:(0,ce.exists)(e,"stack")?e.stack:void 0,href:e.href,filename:(0,ce.exists)(e,"filename")?e.filename:void 0,datetime:e.datetime,archived:(0,ce.exists)(e,"archived")?e.archived:void 0,count:e.count,category:e.category}}M.ModelErrorFromJSONTyped=ir;function Ct(e){if(e!==void 0)return e===null?null:{PK:e.PK,messageHash:e.messageHash,site:e.site,account:e.account,message:e.message,name:e.name,stack:e.stack,href:e.href,filename:e.filename,datetime:e.datetime,archived:e.archived,count:e.count,category:e.category}}M.ModelErrorToJSON=Ct});var cr=c(K=>{"use strict";Object.defineProperty(K,"__esModule",{value:!0});K.PostAccountToJSON=K.PostAccountFromJSONTyped=K.PostAccountFromJSON=void 0;function zt(e){return ur(e,!1)}K.PostAccountFromJSON=zt;function ur(e,r){return e==null?e:{site:e.site}}K.PostAccountFromJSONTyped=ur;function $t(e){if(e!==void 0)return e===null?null:{site:e.site}}K.PostAccountToJSON=$t});var dr=c(G=>{"use strict";Object.defineProperty(G,"__esModule",{value:!0});G.PostErrorToJSON=G.PostErrorFromJSONTyped=G.PostErrorFromJSON=void 0;var ar=N();function Vt(e){return sr(e,!1)}G.PostErrorFromJSON=Vt;function sr(e,r){return e==null?e:{key:e.key,data:(0,ar.PostErrorDataFromJSON)(e.data)}}G.PostErrorFromJSONTyped=sr;function Ut(e){if(e!==void 0)return e===null?null:{key:e.key,data:(0,ar.PostErrorDataToJSON)(e.data)}}G.PostErrorToJSON=Ut});var lr=c(I=>{"use strict";Object.defineProperty(I,"__esModule",{value:!0});I.PostErrorDataToJSON=I.PostErrorDataFromJSONTyped=I.PostErrorDataFromJSON=void 0;var Re=m();function Ht(e){return fr(e,!1)}I.PostErrorDataFromJSON=Ht;function fr(e,r){return e==null?e:{message:e.message,name:(0,Re.exists)(e,"name")?e.name:void 0,stack:(0,Re.exists)(e,"stack")?e.stack:void 0,href:e.href,filename:(0,Re.exists)(e,"filename")?e.filename:void 0}}I.PostErrorDataFromJSONTyped=fr;function Wt(e){if(e!==void 0)return e===null?null:{message:e.message,name:e.name,stack:e.stack,href:e.href,filename:e.filename}}I.PostErrorDataToJSON=Wt});var gr=c(x=>{"use strict";Object.defineProperty(x,"__esModule",{value:!0});x.PostSiteTrackToJSON=x.PostSiteTrackFromJSONTyped=x.PostSiteTrackFromJSON=void 0;var pr=N();function Xt(e){return mr(e,!1)}x.PostSiteTrackFromJSON=Xt;function mr(e,r){return e==null?e:{key:e.key,data:(0,pr.PostSiteTrackDataFromJSON)(e.data)}}x.PostSiteTrackFromJSONTyped=mr;function Yt(e){if(e!==void 0)return e===null?null:{key:e.key,data:(0,pr.PostSiteTrackDataToJSON)(e.data)}}x.PostSiteTrackToJSON=Yt});var Sr=c(v=>{"use strict";Object.defineProperty(v,"__esModule",{value:!0});v.PostSiteTrackDataToJSON=v.PostSiteTrackDataFromJSONTyped=v.PostSiteTrackDataFromJSON=void 0;var ae=m();function Zt(e){return Or(e,!1)}v.PostSiteTrackDataFromJSON=Zt;function Or(e,r){return e==null?e:{eventName:e.eventName,pageLocation:(0,ae.exists)(e,"pageLocation")?e.pageLocation:void 0,pageReferrer:(0,ae.exists)(e,"pageReferrer")?e.pageReferrer:void 0,pageTitle:(0,ae.exists)(e,"pageTitle")?e.pageTitle:void 0,browserResolution:(0,ae.exists)(e,"browserResolution")?e.browserResolution:void 0,browserLanguage:(0,ae.exists)(e,"browserLanguage")?e.browserLanguage:void 0}}v.PostSiteTrackDataFromJSONTyped=Or;function jt(e){if(e!==void 0)return e===null?null:{eventName:e.eventName,pageLocation:e.pageLocation,pageReferrer:e.pageReferrer,pageTitle:e.pageTitle,browserResolution:e.browserResolution,browserLanguage:e.browserLanguage}}v.PostSiteTrackDataToJSON=jt});var Tr=c(Q=>{"use strict";Object.defineProperty(Q,"__esModule",{value:!0});Q.QueryToJSON=Q.QueryFromJSONTyped=Q.QueryFromJSON=void 0;var Fe=m();function en(e){return yr(e,!1)}Q.QueryFromJSON=en;function yr(e,r){return e==null?e:{account:(0,Fe.exists)(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,pathName:e.pathName,search:(0,Fe.exists)(e,"search")?e.search:void 0,hash:(0,Fe.exists)(e,"hash")?e.hash:void 0,count:e.count,category:e.category}}Q.QueryFromJSONTyped=yr;function rn(e){if(e!==void 0)return e===null?null:{account:e.account,datetime:e.datetime,site:e.site,pathName:e.pathName,search:e.search,hash:e.hash,count:e.count,category:e.category}}Q.QueryToJSON=rn});var Jr=c(C=>{"use strict";Object.defineProperty(C,"__esModule",{value:!0});C.ReferrerToJSON=C.ReferrerFromJSONTyped=C.ReferrerFromJSON=void 0;var tn=m();function nn(e){return Nr(e,!1)}C.ReferrerFromJSON=nn;function Nr(e,r){return e==null?e:{account:(0,tn.exists)(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,referrer:e.referrer,count:e.count,category:e.category}}C.ReferrerFromJSONTyped=Nr;function on(e){if(e!==void 0)return e===null?null:{account:e.account,datetime:e.datetime,site:e.site,referrer:e.referrer,count:e.count,category:e.category}}C.ReferrerToJSON=on});var Rr=c(z=>{"use strict";Object.defineProperty(z,"__esModule",{value:!0});z.ResolutionToJSON=z.ResolutionFromJSONTyped=z.ResolutionFromJSON=void 0;var un=m();function cn(e){return hr(e,!1)}z.ResolutionFromJSON=cn;function hr(e,r){return e==null?e:{account:(0,un.exists)(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,resolution:e.resolution,count:e.count,category:e.category}}z.ResolutionFromJSONTyped=hr;function an(e){if(e!==void 0)return e===null?null:{account:e.account,datetime:e.datetime,site:e.site,resolution:e.resolution,count:e.count,category:e.category}}z.ResolutionToJSON=an});var wr=c(V=>{"use strict";Object.defineProperty(V,"__esModule",{value:!0});V.RollupToJSON=V.RollupFromJSONTyped=V.RollupFromJSON=void 0;var $=m(),g=N();function sn(e){return Fr(e,!1)}V.RollupFromJSON=sn;function Fr(e,r){return e==null?e:{account:e.account,site:e.site,datetime:e.datetime,category:e.category,topReferrers:(0,$.exists)(e,"topReferrers")?e.topReferrers.map(g.RollupTopReferrersFromJSON):void 0,topResolutions:(0,$.exists)(e,"topResolutions")?e.topResolutions.map(g.RollupTopResolutionsFromJSON):void 0,topQueries:(0,$.exists)(e,"topQueries")?e.topQueries.map(g.RollupTopQueriesFromJSON):void 0,topLocations:(0,$.exists)(e,"topLocations")?e.topLocations.map(g.RollupTopLocationsFromJSON):void 0,topBrowsers:(0,$.exists)(e,"topBrowsers")?e.topBrowsers.map(g.RollupTopBrowsersFromJSON):void 0,topEvents:(0,$.exists)(e,"topEvents")?e.topEvents.map(g.RollupTopEventsFromJSON):void 0,topLanguages:(0,$.exists)(e,"topLanguages")?e.topLanguages.map(g.RollupTopLanguagesFromJSON):void 0,topErrors:(0,$.exists)(e,"topErrors")?e.topErrors.map(g.RollupTopErrorsFromJSON):void 0}}V.RollupFromJSONTyped=Fr;function dn(e){if(e!==void 0)return e===null?null:{account:e.account,site:e.site,datetime:e.datetime,category:e.category,topReferrers:e.topReferrers===void 0?void 0:e.topReferrers.map(g.RollupTopReferrersToJSON),topResolutions:e.topResolutions===void 0?void 0:e.topResolutions.map(g.RollupTopResolutionsToJSON),topQueries:e.topQueries===void 0?void 0:e.topQueries.map(g.RollupTopQueriesToJSON),topLocations:e.topLocations===void 0?void 0:e.topLocations.map(g.RollupTopLocationsToJSON),topBrowsers:e.topBrowsers===void 0?void 0:e.topBrowsers.map(g.RollupTopBrowsersToJSON),topEvents:e.topEvents===void 0?void 0:e.topEvents.map(g.RollupTopEventsToJSON),topLanguages:e.topLanguages===void 0?void 0:e.topLanguages.map(g.RollupTopLanguagesToJSON),topErrors:e.topErrors===void 0?void 0:e.topErrors.map(g.RollupTopErrorsToJSON)}}V.RollupToJSON=dn});var br=c(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});U.RollupTopBrowsersToJSON=U.RollupTopBrowsersFromJSONTyped=U.RollupTopBrowsersFromJSON=void 0;function fn(e){return _r(e,!1)}U.RollupTopBrowsersFromJSON=fn;function _r(e,r){return e==null?e:{browser:e.browser,count:e.count}}U.RollupTopBrowsersFromJSONTyped=_r;function ln(e){if(e!==void 0)return e===null?null:{browser:e.browser,count:e.count}}U.RollupTopBrowsersToJSON=ln});var Er=c(H=>{"use strict";Object.defineProperty(H,"__esModule",{value:!0});H.RollupTopErrorsToJSON=H.RollupTopErrorsFromJSONTyped=H.RollupTopErrorsFromJSON=void 0;function pn(e){return Pr(e,!1)}H.RollupTopErrorsFromJSON=pn;function Pr(e,r){return e==null?e:{href:e.href,count:e.count}}H.RollupTopErrorsFromJSONTyped=Pr;function mn(e){if(e!==void 0)return e===null?null:{href:e.href,count:e.count}}H.RollupTopErrorsToJSON=mn});var Ar=c(W=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0});W.RollupTopEventsToJSON=W.RollupTopEventsFromJSONTyped=W.RollupTopEventsFromJSON=void 0;function gn(e){return Dr(e,!1)}W.RollupTopEventsFromJSON=gn;function Dr(e,r){return e==null?e:{eventName:e.eventName,count:e.count}}W.RollupTopEventsFromJSONTyped=Dr;function On(e){if(e!==void 0)return e===null?null:{eventName:e.eventName,count:e.count}}W.RollupTopEventsToJSON=On});var kr=c(X=>{"use strict";Object.defineProperty(X,"__esModule",{value:!0});X.RollupTopLanguagesToJSON=X.RollupTopLanguagesFromJSONTyped=X.RollupTopLanguagesFromJSON=void 0;function Sn(e){return qr(e,!1)}X.RollupTopLanguagesFromJSON=Sn;function qr(e,r){return e==null?e:{language:e.language,count:e.count}}X.RollupTopLanguagesFromJSONTyped=qr;function yn(e){if(e!==void 0)return e===null?null:{language:e.language,count:e.count}}X.RollupTopLanguagesToJSON=yn});var Br=c(Y=>{"use strict";Object.defineProperty(Y,"__esModule",{value:!0});Y.RollupTopLocationsToJSON=Y.RollupTopLocationsFromJSONTyped=Y.RollupTopLocationsFromJSON=void 0;function Tn(e){return Lr(e,!1)}Y.RollupTopLocationsFromJSON=Tn;function Lr(e,r){return e==null?e:{countryRegion:e.countryRegion,count:e.count}}Y.RollupTopLocationsFromJSONTyped=Lr;function Nn(e){if(e!==void 0)return e===null?null:{countryRegion:e.countryRegion,count:e.count}}Y.RollupTopLocationsToJSON=Nn});var Kr=c(Z=>{"use strict";Object.defineProperty(Z,"__esModule",{value:!0});Z.RollupTopQueriesToJSON=Z.RollupTopQueriesFromJSONTyped=Z.RollupTopQueriesFromJSON=void 0;function Jn(e){return Mr(e,!1)}Z.RollupTopQueriesFromJSON=Jn;function Mr(e,r){return e==null?e:{pathName:e.pathName,count:e.count}}Z.RollupTopQueriesFromJSONTyped=Mr;function hn(e){if(e!==void 0)return e===null?null:{pathName:e.pathName,count:e.count}}Z.RollupTopQueriesToJSON=hn});var Ir=c(j=>{"use strict";Object.defineProperty(j,"__esModule",{value:!0});j.RollupTopReferrersToJSON=j.RollupTopReferrersFromJSONTyped=j.RollupTopReferrersFromJSON=void 0;function Rn(e){return Gr(e,!1)}j.RollupTopReferrersFromJSON=Rn;function Gr(e,r){return e==null?e:{referrer:e.referrer,count:e.count}}j.RollupTopReferrersFromJSONTyped=Gr;function Fn(e){if(e!==void 0)return e===null?null:{referrer:e.referrer,count:e.count}}j.RollupTopReferrersToJSON=Fn});var vr=c(ee=>{"use strict";Object.defineProperty(ee,"__esModule",{value:!0});ee.RollupTopResolutionsToJSON=ee.RollupTopResolutionsFromJSONTyped=ee.RollupTopResolutionsFromJSON=void 0;function wn(e){return xr(e,!1)}ee.RollupTopResolutionsFromJSON=wn;function xr(e,r){return e==null?e:{resolution:e.resolution,count:e.count}}ee.RollupTopResolutionsFromJSONTyped=xr;function _n(e){if(e!==void 0)return e===null?null:{resolution:e.resolution,count:e.count}}ee.RollupTopResolutionsToJSON=_n});var Cr=c(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.SiteDataToJSON=re.SiteDataFromJSONTyped=re.SiteDataFromJSON=void 0;var S=m(),f=N();function bn(e){return Qr(e,!1)}re.SiteDataFromJSON=bn;function Qr(e,r){return e==null?e:{details:(0,S.exists)(e,"details")?(0,f.GetAccountFromJSON)(e.details):void 0,browsers:(0,S.exists)(e,"browsers")?e.browsers.map(f.BrowserFromJSON):void 0,events:(0,S.exists)(e,"events")?e.events.map(f.EventFromJSON):void 0,locations:(0,S.exists)(e,"locations")?e.locations.map(f.LocationFromJSON):void 0,queries:(0,S.exists)(e,"queries")?e.queries.map(f.QueryFromJSON):void 0,referrers:(0,S.exists)(e,"referrers")?e.referrers.map(f.ReferrerFromJSON):void 0,resolutions:(0,S.exists)(e,"resolutions")?e.resolutions.map(f.ResolutionFromJSON):void 0,languages:(0,S.exists)(e,"languages")?e.languages.map(f.LanguageFromJSON):void 0,rollups:(0,S.exists)(e,"rollups")?e.rollups.map(f.RollupFromJSON):void 0,errors:(0,S.exists)(e,"errors")?e.errors.map(f.ModelErrorFromJSON):void 0,google:(0,S.exists)(e,"google")?e.google.map(f.GoogleResultFromJSON):void 0,bing:(0,S.exists)(e,"bing")?e.bing.map(f.BingResultFromJSON):void 0}}re.SiteDataFromJSONTyped=Qr;function Pn(e){if(e!==void 0)return e===null?null:{details:(0,f.GetAccountToJSON)(e.details),browsers:e.browsers===void 0?void 0:e.browsers.map(f.BrowserToJSON),events:e.events===void 0?void 0:e.events.map(f.EventToJSON),locations:e.locations===void 0?void 0:e.locations.map(f.LocationToJSON),queries:e.queries===void 0?void 0:e.queries.map(f.QueryToJSON),referrers:e.referrers===void 0?void 0:e.referrers.map(f.ReferrerToJSON),resolutions:e.resolutions===void 0?void 0:e.resolutions.map(f.ResolutionToJSON),languages:e.languages===void 0?void 0:e.languages.map(f.LanguageToJSON),rollups:e.rollups===void 0?void 0:e.rollups.map(f.RollupToJSON),errors:e.errors===void 0?void 0:e.errors.map(f.ModelErrorToJSON),google:e.google===void 0?void 0:e.google.map(f.GoogleResultToJSON),bing:e.bing===void 0?void 0:e.bing.map(f.BingResultToJSON)}}re.SiteDataToJSON=Pn});var $r=c(te=>{"use strict";Object.defineProperty(te,"__esModule",{value:!0});te.SiteDetailsToJSON=te.SiteDetailsFromJSONTyped=te.SiteDetailsFromJSON=void 0;var En=m();function Dn(e){return zr(e,!1)}te.SiteDetailsFromJSON=Dn;function zr(e,r){return e==null?e:{site:e.site,account:e.account,favicon:(0,En.exists)(e,"favicon")?e.favicon:void 0,category:e.category}}te.SiteDetailsFromJSONTyped=zr;function An(e){if(e!==void 0)return e===null?null:{site:e.site,account:e.account,favicon:e.favicon,category:e.category}}te.SiteDetailsToJSON=An});var N=c(u=>{"use strict";var qn=u&&u.__createBinding||(Object.create?function(e,r,t,n){n===void 0&&(n=t);var i=Object.getOwnPropertyDescriptor(r,t);(!i||("get"in i?!r.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,n,i)}:function(e,r,t,n){n===void 0&&(n=t),e[n]=r[t]}),a=u&&u.__exportStar||function(e,r){for(var t in e)t!=="default"&&!Object.prototype.hasOwnProperty.call(r,t)&&qn(r,e,t)};Object.defineProperty(u,"__esModule",{value:!0});a(Ee(),u);a(Ae(),u);a(ke(),u);a(Be(),u);a(Ke(),u);a(Ie(),u);a(ve(),u);a(Ce(),u);a(Ve(),u);a(He(),u);a(Xe(),u);a(je(),u);a(rr(),u);a(nr(),u);a(or(),u);a(cr(),u);a(dr(),u);a(lr(),u);a(gr(),u);a(Sr(),u);a(Tr(),u);a(Jr(),u);a(Rr(),u);a(wr(),u);a(br(),u);a(Er(),u);a(Ar(),u);a(kr(),u);a(Br(),u);a(Kr(),u);a(Ir(),u);a(vr(),u);a(Cr(),u);a($r(),u)});var Vr=c(y=>{"use strict";var kn=y&&y.__createBinding||(Object.create?function(e,r,t,n){n===void 0&&(n=t);var i=Object.getOwnPropertyDescriptor(r,t);(!i||("get"in i?!r.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,n,i)}:function(e,r,t,n){n===void 0&&(n=t),e[n]=r[t]}),Ln=y&&y.__setModuleDefault||(Object.create?function(e,r){Object.defineProperty(e,"default",{enumerable:!0,value:r})}:function(e,r){e.default=r}),Bn=y&&y.__importStar||function(e){if(e&&e.__esModule)return e;var r={};if(e!=null)for(var t in e)t!=="default"&&Object.prototype.hasOwnProperty.call(e,t)&&kn(r,e,t);return Ln(r,e),r},p=y&&y.__awaiter||function(e,r,t,n){function i(o){return o instanceof t?o:new t(function(l){l(o)})}return new(t||(t=Promise))(function(o,l){function ge(O){try{ne(n.next(O))}catch(ie){l(ie)}}function Oe(O){try{ne(n.throw(O))}catch(ie){l(ie)}}function ne(O){O.done?o(O.value):i(O.value).then(ge,Oe)}ne((n=n.apply(e,r||[])).next())})};Object.defineProperty(y,"__esModule",{value:!0});y.DefaultApi=void 0;var d=Bn(m()),T=N(),we=class extends d.BaseAPI{accountGetRaw(r){return p(this,void 0,void 0,function*(){let t={},n={};this.configuration&&this.configuration.apiKey&&(n.authorization=this.configuration.apiKey("authorization"));let i=yield this.request({path:"/account",method:"GET",headers:n,query:t},r);return new d.JSONApiResponse(i,o=>(0,T.GetAccountsFromJSON)(o))})}accountGet(r){return p(this,void 0,void 0,function*(){return yield(yield this.accountGetRaw(r)).value()})}archiveErrorRaw(r,t){return p(this,void 0,void 0,function*(){if(r.id===null||r.id===void 0)throw new d.RequiredError("id","Required parameter requestParameters.id was null or undefined when calling archiveError.");let n={},i={};this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/errors/{id}".replace("{id}",encodeURIComponent(String(r.id))),method:"DELETE",headers:i,query:n},t);return new d.VoidApiResponse(o)})}archiveError(r,t){return p(this,void 0,void 0,function*(){yield this.archiveErrorRaw(r,t)})}archiveErrorsRaw(r,t){return p(this,void 0,void 0,function*(){if(r.archiveErrors===null||r.archiveErrors===void 0)throw new d.RequiredError("archiveErrors","Required parameter requestParameters.archiveErrors was null or undefined when calling archiveErrors.");let n={},i={};i["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/errors",method:"DELETE",headers:i,query:n,body:(0,T.ArchiveErrorsToJSON)(r.archiveErrors)},t);return new d.VoidApiResponse(o)})}archiveErrors(r,t){return p(this,void 0,void 0,function*(){yield this.archiveErrorsRaw(r,t)})}bingIntegrationPostRaw(r,t){return p(this,void 0,void 0,function*(){if(r.bingIntegration===null||r.bingIntegration===void 0)throw new d.RequiredError("bingIntegration","Required parameter requestParameters.bingIntegration was null or undefined when calling bingIntegrationPost.");let n={},i={};i["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/account/integrations/bing",method:"POST",headers:i,query:n,body:(0,T.BingIntegrationToJSON)(r.bingIntegration)},t);return new d.VoidApiResponse(o)})}bingIntegrationPost(r,t){return p(this,void 0,void 0,function*(){yield this.bingIntegrationPostRaw(r,t)})}getTrackingAllSitesRaw(r,t){return p(this,void 0,void 0,function*(){if(r.minDate===null||r.minDate===void 0)throw new d.RequiredError("minDate","Required parameter requestParameters.minDate was null or undefined when calling getTrackingAllSites.");if(r.maxDate===null||r.maxDate===void 0)throw new d.RequiredError("maxDate","Required parameter requestParameters.maxDate was null or undefined when calling getTrackingAllSites.");let n={};r.minDate!==void 0&&(n.minDate=r.minDate),r.maxDate!==void 0&&(n.maxDate=r.maxDate);let i={};this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/site/tracking",method:"GET",headers:i,query:n},t);return new d.JSONApiResponse(o,l=>l.map(T.SiteDataFromJSON))})}getTrackingAllSites(r,t){return p(this,void 0,void 0,function*(){return yield(yield this.getTrackingAllSitesRaw(r,t)).value()})}getTrackingSiteRaw(r,t){return p(this,void 0,void 0,function*(){if(r.id===null||r.id===void 0)throw new d.RequiredError("id","Required parameter requestParameters.id was null or undefined when calling getTrackingSite.");if(r.minDate===null||r.minDate===void 0)throw new d.RequiredError("minDate","Required parameter requestParameters.minDate was null or undefined when calling getTrackingSite.");if(r.maxDate===null||r.maxDate===void 0)throw new d.RequiredError("maxDate","Required parameter requestParameters.maxDate was null or undefined when calling getTrackingSite.");let n={};r.minDate!==void 0&&(n.minDate=r.minDate),r.maxDate!==void 0&&(n.maxDate=r.maxDate);let i={};this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/site/tracking/{id}".replace("{id}",encodeURIComponent(String(r.id))),method:"GET",headers:i,query:n},t);return new d.JSONApiResponse(o,l=>(0,T.SiteDataFromJSON)(l))})}getTrackingSite(r,t){return p(this,void 0,void 0,function*(){return yield(yield this.getTrackingSiteRaw(r,t)).value()})}googleIntegrationPostRaw(r,t){return p(this,void 0,void 0,function*(){if(r.googleIntegration===null||r.googleIntegration===void 0)throw new d.RequiredError("googleIntegration","Required parameter requestParameters.googleIntegration was null or undefined when calling googleIntegrationPost.");let n={},i={};i["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/account/integrations/google",method:"POST",headers:i,query:n,body:(0,T.GoogleIntegrationToJSON)(r.googleIntegration)},t);return new d.VoidApiResponse(o)})}googleIntegrationPost(r,t){return p(this,void 0,void 0,function*(){yield this.googleIntegrationPostRaw(r,t)})}postErrorsRaw(r,t){return p(this,void 0,void 0,function*(){if(r.postError===null||r.postError===void 0)throw new d.RequiredError("postError","Required parameter requestParameters.postError was null or undefined when calling postErrors.");let n={},i={};i["Content-Type"]="application/json";let o=yield this.request({path:"/errors",method:"POST",headers:i,query:n,body:r.postError.map(T.PostErrorToJSON)},t);return new d.VoidApiResponse(o)})}postErrors(r,t){return p(this,void 0,void 0,function*(){yield this.postErrorsRaw(r,t)})}postPageTrackRaw(r,t){return p(this,void 0,void 0,function*(){if(r.postSiteTrack===null||r.postSiteTrack===void 0)throw new d.RequiredError("postSiteTrack","Required parameter requestParameters.postSiteTrack was null or undefined when calling postPageTrack.");let n={},i={};i["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/site",method:"POST",headers:i,query:n,body:(0,T.PostSiteTrackToJSON)(r.postSiteTrack)},t);return new d.VoidApiResponse(o)})}postPageTrack(r,t){return p(this,void 0,void 0,function*(){yield this.postPageTrackRaw(r,t)})}siteDeleteRaw(r,t){return p(this,void 0,void 0,function*(){if(r.deleteAccount===null||r.deleteAccount===void 0)throw new d.RequiredError("deleteAccount","Required parameter requestParameters.deleteAccount was null or undefined when calling siteDelete.");let n={},i={};i["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/account/site",method:"DELETE",headers:i,query:n,body:(0,T.DeleteAccountToJSON)(r.deleteAccount)},t);return new d.VoidApiResponse(o)})}siteDelete(r,t){return p(this,void 0,void 0,function*(){yield this.siteDeleteRaw(r,t)})}sitePostRaw(r,t){return p(this,void 0,void 0,function*(){if(r.postAccount===null||r.postAccount===void 0)throw new d.RequiredError("postAccount","Required parameter requestParameters.postAccount was null or undefined when calling sitePost.");let n={},i={};i["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(i.authorization=this.configuration.apiKey("authorization"));let o=yield this.request({path:"/account/site",method:"POST",headers:i,query:n,body:(0,T.PostAccountToJSON)(r.postAccount)},t);return new d.VoidApiResponse(o)})}sitePost(r,t){return p(this,void 0,void 0,function*(){yield this.sitePostRaw(r,t)})}};y.DefaultApi=we});var Ur=c(ue=>{"use strict";var Mn=ue&&ue.__createBinding||(Object.create?function(e,r,t,n){n===void 0&&(n=t);var i=Object.getOwnPropertyDescriptor(r,t);(!i||("get"in i?!r.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,n,i)}:function(e,r,t,n){n===void 0&&(n=t),e[n]=r[t]}),Kn=ue&&ue.__exportStar||function(e,r){for(var t in e)t!=="default"&&!Object.prototype.hasOwnProperty.call(r,t)&&Mn(r,e,t)};Object.defineProperty(ue,"__esModule",{value:!0});Kn(Vr(),ue)});var Hr=c(J=>{"use strict";var Gn=J&&J.__createBinding||(Object.create?function(e,r,t,n){n===void 0&&(n=t);var i=Object.getOwnPropertyDescriptor(r,t);(!i||("get"in i?!r.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,n,i)}:function(e,r,t,n){n===void 0&&(n=t),e[n]=r[t]}),_e=J&&J.__exportStar||function(e,r){for(var t in e)t!=="default"&&!Object.prototype.hasOwnProperty.call(r,t)&&Gn(r,e,t)};Object.defineProperty(J,"__esModule",{value:!0});_e(m(),J);_e(Ur(),J);_e(N(),J)});var vn={};tt(vn,{page:()=>xn,track:()=>Xr});module.exports=it(vn);var pe=require("ag-common/dist/common/helpers/log"),me=require("ag-common/dist/ui/helpers/callOpenApi"),Wr=nt(Hr());function In(e){return(0,me.callOpenApi)({...e,func:r=>(0,me.apiResponseToAxiosResponse)(()=>e.func(r)),newDefaultApi:r=>new Wr.DefaultApi(r),logout:()=>window.location.reload(),refreshToken:async()=>{}})}var Xr=async({analyticaToken:e,overrideBaseUrl:r="https://api.analytica.click",eventName:t})=>{let n={eventName:t};if(typeof window<"u"&&(n={...n,pageLocation:window.location.href,browserResolution:`${window?.screen?.width}:${window?.screen?.height}`}),typeof document<"u"&&(n={...n,pageReferrer:document.referrer,pageTitle:document.title}),typeof navigator<"u"&&(n={...n,browserLanguage:navigator.language}),typeof window<"u"&&window?.location?.hostname==="localhost")return(0,pe.debug)(`local page ignored: ${JSON.stringify(n)}, to ${r}`),{};let i=await In({apiUrl:r,headers:{authorization:""},func:o=>o.postPageTrackRaw({postSiteTrack:{key:e,data:n}})});return i.error?((0,pe.warn)("tracking error:"+JSON.stringify(i.error,null,2)),{error:JSON.stringify(i.error,null,2)}):{}},xn=async({analyticaToken:e,overrideBaseUrl:r="https://api.analytica.click"})=>Xr({analyticaToken:e,overrideBaseUrl:r,eventName:"PAGE"});0&&(module.exports={page,track});
|
1
|
+
"use strict";var y=Object.defineProperty;var Y=Object.getOwnPropertyDescriptor;var Z=Object.getOwnPropertyNames;var v=Object.prototype.hasOwnProperty;var j=(e,r)=>{for(var t in r)y(e,t,{get:r[t],enumerable:!0})},ee=(e,r,t,n)=>{if(r&&typeof r=="object"||typeof r=="function")for(let o of Z(r))!v.call(e,o)&&o!==t&&y(e,o,{get:()=>r[o],enumerable:!(n=Y(r,o))||n.enumerable});return e};var re=e=>ee(y({},"__esModule",{value:!0}),e);var De={};j(De,{page:()=>be,track:()=>X});module.exports=re(De);var m=require("ag-common/dist/common/helpers/log"),g=require("ag-common/dist/ui/helpers/callOpenApi");var te="https://api.analytica.click".replace(/\/+$/,""),ne=e=>typeof Blob<"u"&&e instanceof Blob,l=class{constructor(r=new T){this.configuration=r;this.fetchApi=async(r,t)=>{let n={url:r,init:t};for(let a of this.middleware)a.pre&&(n=await a.pre({fetch:this.fetchApi,...n})||n);let o=await(this.configuration.fetchApi||fetch)(n.url,n.init);for(let a of this.middleware)a.post&&(o=await a.post({fetch:this.fetchApi,url:n.url,init:n.init,response:o.clone()})||o);return o};this.middleware=r.middleware||[]}withMiddleware(...r){let t=this.clone();return t.middleware=t.middleware.concat(...r),t}withPreMiddleware(...r){let t=r.map(n=>({pre:n}));return this.withMiddleware(...t)}withPostMiddleware(...r){let t=r.map(n=>({post:n}));return this.withMiddleware(...t)}async request(r,t){let{url:n,init:o}=this.createFetchParams(r,t),a=await this.fetchApi(n,o);if(a.status>=200&&a.status<300)return a;throw a}createFetchParams(r,t){let n=this.configuration.basePath+r.path;r.query!==void 0&&Object.keys(r.query).length!==0&&(n+="?"+this.configuration.queryParamsStringify(r.query));let o=typeof FormData<"u"&&r.body instanceof FormData||r.body instanceof URLSearchParams||ne(r.body)?r.body:JSON.stringify(r.body),a=Object.assign({},this.configuration.headers,r.headers),c={method:r.method,headers:a,body:o,credentials:this.configuration.credentials,...t};return{url:n,init:c}}clone(){let r=this.constructor,t=new r(this.configuration);return t.middleware=this.middleware.slice(),t}},u=class extends Error{constructor(t,n){super(n);this.field=t;this.name="RequiredError"}};var T=class{constructor(r={}){this.configuration=r}get basePath(){return this.configuration.basePath!=null?this.configuration.basePath:te}get fetchApi(){return this.configuration.fetchApi}get middleware(){return this.configuration.middleware||[]}get queryParamsStringify(){return this.configuration.queryParamsStringify||x}get username(){return this.configuration.username}get password(){return this.configuration.password}get apiKey(){let r=this.configuration.apiKey;if(r)return typeof r=="function"?r:()=>r}get accessToken(){let r=this.configuration.accessToken;if(r)return typeof r=="function"?r:async()=>r}get headers(){return this.configuration.headers}get credentials(){return this.configuration.credentials}};function i(e,r){let t=e[r];return t!=null}function x(e,r=""){return Object.keys(e).map(t=>{let n=r+(r.length?`[${t}]`:t),o=e[t];if(o instanceof Array){let a=o.map(c=>encodeURIComponent(String(c))).join(`&${encodeURIComponent(n)}=`);return`${encodeURIComponent(n)}=${a}`}return o instanceof Date?`${encodeURIComponent(n)}=${encodeURIComponent(o.toISOString())}`:o instanceof Object?x(o,n):`${encodeURIComponent(n)}=${encodeURIComponent(String(o))}`}).filter(t=>t.length>0).join("&")}var p=class{constructor(r,t=n=>n){this.raw=r;this.transformer=t}async value(){return this.transformer(await this.raw.json())}},s=class{constructor(r){this.raw=r}async value(){}};function w(e){if(e!==void 0)return e===null?null:{PKsB64:e.PKsB64}}function A(e){if(e!==void 0)return e===null?null:{key:e.key,account:e.account}}function N(e){return ie(e,!1)}function ie(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,browser:e.browser,count:e.count,category:e.category}}function O(e){if(e!==void 0)return e===null?null:{site:e.site}}function P(e){return ae(e,!1)}function ae(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,site:e.site,eventName:e.eventName,datetime:e.datetime,count:e.count,category:e.category}}function d(e){return ue(e,!1)}function ue(e,r){return e==null?e:{site:e.site,account:e.account,apiKey:e.apiKey,adminApiKey:e.adminApiKey,favicon:i(e,"favicon")?e.favicon:void 0}}function J(e){return ce(e,!1)}function ce(e,r){return e==null?e:{accounts:e.accounts.map(d),googleEmail:i(e,"googleEmail")?e.googleEmail:void 0,googleKey:i(e,"googleKey")?e.googleKey:void 0,bingKey:i(e,"bingKey")?e.bingKey:void 0,bingAccount:i(e,"bingAccount")?e.bingAccount:void 0}}function E(e){if(e!==void 0)return e===null?null:{email:e.email,key:e.key,account:e.account}}function b(e){return pe(e,!1)}function pe(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,language:e.language,count:e.count,category:e.category}}function D(e){return le(e,!1)}function le(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,countryRegion:e.countryRegion,category:e.category,count:e.count}}function F(e){return de(e,!1)}function de(e,r){return e==null?e:{PK:e.PK,messageHash:i(e,"messageHash")?e.messageHash:void 0,site:e.site,account:e.account,message:i(e,"message")?e.message:void 0,name:i(e,"name")?e.name:void 0,stack:i(e,"stack")?e.stack:void 0,href:e.href,filename:i(e,"filename")?e.filename:void 0,datetime:e.datetime,archived:i(e,"archived")?e.archived:void 0,count:e.count,category:e.category}}function q(e){if(e!==void 0)return e===null?null:{site:e.site}}function k(e){if(e!==void 0)return e===null?null:{key:e.key,data:I(e.data)}}function I(e){if(e!==void 0)return e===null?null:{message:e.message,name:e.name,stack:e.stack,href:e.href,filename:e.filename}}function L(e){if(e!==void 0)return e===null?null:{key:e.key,data:K(e.data)}}function K(e){if(e!==void 0)return e===null?null:{eventName:e.eventName,pageLocation:e.pageLocation,pageReferrer:e.pageReferrer,pageTitle:e.pageTitle,browserResolution:e.browserResolution,browserLanguage:e.browserLanguage}}function B(e){return fe(e,!1)}function fe(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,pathName:e.pathName,search:i(e,"search")?e.search:void 0,hash:i(e,"hash")?e.hash:void 0,count:e.count,category:e.category}}function G(e){return me(e,!1)}function me(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,referrer:e.referrer,count:e.count,category:e.category}}function V(e){return ge(e,!1)}function ge(e,r){return e==null?e:{account:i(e,"account")?e.account:void 0,datetime:e.datetime,site:e.site,resolution:e.resolution,count:e.count,category:e.category}}function H(e){return ye(e,!1)}function ye(e,r){return e==null?e:{account:e.account,site:e.site,datetime:e.datetime,category:e.category,topReferrers:i(e,"topReferrers")?e.topReferrers.map(_):void 0,topResolutions:i(e,"topResolutions")?e.topResolutions.map(W):void 0,topQueries:i(e,"topQueries")?e.topQueries.map(U):void 0,topLocations:i(e,"topLocations")?e.topLocations.map($):void 0,topBrowsers:i(e,"topBrowsers")?e.topBrowsers.map(Q):void 0,topEvents:i(e,"topEvents")?e.topEvents.map(M):void 0,topLanguages:i(e,"topLanguages")?e.topLanguages.map(z):void 0,topErrors:i(e,"topErrors")?e.topErrors.map(C):void 0}}function Q(e){return Te(e,!1)}function Te(e,r){return e==null?e:{browser:e.browser,count:e.count}}function C(e){return Re(e,!1)}function Re(e,r){return e==null?e:{href:e.href,count:e.count}}function M(e){return he(e,!1)}function he(e,r){return e==null?e:{eventName:e.eventName,count:e.count}}function z(e){return Se(e,!1)}function Se(e,r){return e==null?e:{language:e.language,count:e.count}}function $(e){return xe(e,!1)}function xe(e,r){return e==null?e:{countryRegion:e.countryRegion,count:e.count}}function U(e){return we(e,!1)}function we(e,r){return e==null?e:{pathName:e.pathName,count:e.count}}function _(e){return Ae(e,!1)}function Ae(e,r){return e==null?e:{referrer:e.referrer,count:e.count}}function W(e){return Ne(e,!1)}function Ne(e,r){return e==null?e:{resolution:e.resolution,count:e.count}}function h(e){return Oe(e,!1)}function Oe(e,r){return e==null?e:{account:e.account,email:e.email,site:e.site,datetime:e.datetime,category:e.category,totals:R(e.totals),queries:e.queries.map(R)}}function R(e){return Pe(e,!1)}function Pe(e,r){return e==null?e:{clicks:e.clicks,impressions:e.impressions,position:e.position,query:e.query}}function S(e){return Je(e,!1)}function Je(e,r){return e==null?e:{details:i(e,"details")?d(e.details):void 0,browsers:i(e,"browsers")?e.browsers.map(N):void 0,events:i(e,"events")?e.events.map(P):void 0,locations:i(e,"locations")?e.locations.map(D):void 0,queries:i(e,"queries")?e.queries.map(B):void 0,referrers:i(e,"referrers")?e.referrers.map(G):void 0,resolutions:i(e,"resolutions")?e.resolutions.map(V):void 0,languages:i(e,"languages")?e.languages.map(b):void 0,rollups:i(e,"rollups")?e.rollups.map(H):void 0,errors:i(e,"errors")?e.errors.map(F):void 0,google:i(e,"google")?e.google.map(h):void 0,bing:i(e,"bing")?e.bing.map(h):void 0}}var f=class extends l{async accountGetRaw(r){let t={},n={};this.configuration&&this.configuration.apiKey&&(n.authorization=this.configuration.apiKey("authorization"));let o=await this.request({path:"/account",method:"GET",headers:n,query:t},r);return new p(o,a=>J(a))}async accountGet(r){return await(await this.accountGetRaw(r)).value()}async archiveErrorRaw(r,t){if(r.id===null||r.id===void 0)throw new u("id","Required parameter requestParameters.id was null or undefined when calling archiveError.");let n={},o={};this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/errors/{id}".replace("{id}",encodeURIComponent(String(r.id))),method:"DELETE",headers:o,query:n},t);return new s(a)}async archiveError(r,t){await this.archiveErrorRaw(r,t)}async archiveErrorsRaw(r,t){if(r.archiveErrors===null||r.archiveErrors===void 0)throw new u("archiveErrors","Required parameter requestParameters.archiveErrors was null or undefined when calling archiveErrors.");let n={},o={};o["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/errors",method:"DELETE",headers:o,query:n,body:w(r.archiveErrors)},t);return new s(a)}async archiveErrors(r,t){await this.archiveErrorsRaw(r,t)}async bingIntegrationPostRaw(r,t){if(r.bingIntegration===null||r.bingIntegration===void 0)throw new u("bingIntegration","Required parameter requestParameters.bingIntegration was null or undefined when calling bingIntegrationPost.");let n={},o={};o["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/account/integrations/bing",method:"POST",headers:o,query:n,body:A(r.bingIntegration)},t);return new s(a)}async bingIntegrationPost(r,t){await this.bingIntegrationPostRaw(r,t)}async getTrackingAllSitesRaw(r,t){if(r.minDate===null||r.minDate===void 0)throw new u("minDate","Required parameter requestParameters.minDate was null or undefined when calling getTrackingAllSites.");if(r.maxDate===null||r.maxDate===void 0)throw new u("maxDate","Required parameter requestParameters.maxDate was null or undefined when calling getTrackingAllSites.");let n={};r.minDate!==void 0&&(n.minDate=r.minDate),r.maxDate!==void 0&&(n.maxDate=r.maxDate);let o={};this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/site/tracking",method:"GET",headers:o,query:n},t);return new p(a,c=>c.map(S))}async getTrackingAllSites(r,t){return await(await this.getTrackingAllSitesRaw(r,t)).value()}async getTrackingSiteRaw(r,t){if(r.id===null||r.id===void 0)throw new u("id","Required parameter requestParameters.id was null or undefined when calling getTrackingSite.");if(r.minDate===null||r.minDate===void 0)throw new u("minDate","Required parameter requestParameters.minDate was null or undefined when calling getTrackingSite.");if(r.maxDate===null||r.maxDate===void 0)throw new u("maxDate","Required parameter requestParameters.maxDate was null or undefined when calling getTrackingSite.");let n={};r.minDate!==void 0&&(n.minDate=r.minDate),r.maxDate!==void 0&&(n.maxDate=r.maxDate);let o={};this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/site/tracking/{id}".replace("{id}",encodeURIComponent(String(r.id))),method:"GET",headers:o,query:n},t);return new p(a,c=>S(c))}async getTrackingSite(r,t){return await(await this.getTrackingSiteRaw(r,t)).value()}async googleIntegrationPostRaw(r,t){if(r.googleIntegration===null||r.googleIntegration===void 0)throw new u("googleIntegration","Required parameter requestParameters.googleIntegration was null or undefined when calling googleIntegrationPost.");let n={},o={};o["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/account/integrations/google",method:"POST",headers:o,query:n,body:E(r.googleIntegration)},t);return new s(a)}async googleIntegrationPost(r,t){await this.googleIntegrationPostRaw(r,t)}async postErrorsRaw(r,t){if(r.postError===null||r.postError===void 0)throw new u("postError","Required parameter requestParameters.postError was null or undefined when calling postErrors.");let n={},o={};o["Content-Type"]="application/json";let a=await this.request({path:"/errors",method:"POST",headers:o,query:n,body:r.postError.map(k)},t);return new s(a)}async postErrors(r,t){await this.postErrorsRaw(r,t)}async postPageTrackRaw(r,t){if(r.postSiteTrack===null||r.postSiteTrack===void 0)throw new u("postSiteTrack","Required parameter requestParameters.postSiteTrack was null or undefined when calling postPageTrack.");let n={},o={};o["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/site",method:"POST",headers:o,query:n,body:L(r.postSiteTrack)},t);return new s(a)}async postPageTrack(r,t){await this.postPageTrackRaw(r,t)}async siteDeleteRaw(r,t){if(r.deleteAccount===null||r.deleteAccount===void 0)throw new u("deleteAccount","Required parameter requestParameters.deleteAccount was null or undefined when calling siteDelete.");let n={},o={};o["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/account/site",method:"DELETE",headers:o,query:n,body:O(r.deleteAccount)},t);return new s(a)}async siteDelete(r,t){await this.siteDeleteRaw(r,t)}async sitePostRaw(r,t){if(r.postAccount===null||r.postAccount===void 0)throw new u("postAccount","Required parameter requestParameters.postAccount was null or undefined when calling sitePost.");let n={},o={};o["Content-Type"]="application/json",this.configuration&&this.configuration.apiKey&&(o.authorization=this.configuration.apiKey("authorization"));let a=await this.request({path:"/account/site",method:"POST",headers:o,query:n,body:q(r.postAccount)},t);return new s(a)}async sitePost(r,t){await this.sitePostRaw(r,t)}};function Ee(e){return(0,g.callOpenApi)({...e,func:r=>(0,g.apiResponseToAxiosResponse)(()=>e.func(r)),newDefaultApi:r=>new f(r),logout:()=>window.location.reload(),refreshToken:async()=>{}})}var X=async({analyticaToken:e,overrideBaseUrl:r="https://api.analytica.click",eventName:t})=>{let n={eventName:t};if(typeof window<"u"&&(n={...n,pageLocation:window.location.href,browserResolution:`${window?.screen?.width}:${window?.screen?.height}`}),typeof document<"u"&&(n={...n,pageReferrer:document.referrer,pageTitle:document.title}),typeof navigator<"u"&&(n={...n,browserLanguage:navigator.language}),typeof window<"u"&&window?.location?.hostname==="localhost")return(0,m.debug)(`local page ignored: ${JSON.stringify(n)}, to ${r}`),{};let o=await Ee({apiUrl:r,headers:{authorization:""},func:a=>a.postPageTrackRaw({postSiteTrack:{key:e,data:n}})});return o.error?((0,m.warn)("tracking error:"+JSON.stringify(o.error,null,2)),{error:JSON.stringify(o.error,null,2)}):{}},be=async({analyticaToken:e,overrideBaseUrl:r="https://api.analytica.click"})=>X({analyticaToken:e,overrideBaseUrl:r,eventName:"PAGE"});0&&(module.exports={page,track});
|