vc-error-handlers 0.1.98 → 0.2.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/esm2022/lib/configuration.mjs +7 -0
- package/{esm2020 → esm2022}/lib/featureFlag/feature-flag.directive.mjs +27 -27
- package/esm2022/lib/featureFlag/feature-flag.module.mjs +20 -0
- package/esm2022/lib/featureFlag/feature-flag.service.mjs +98 -0
- package/{esm2020 → esm2022}/lib/shared/components/chunk-unavailable/chunk-unavailable.component.mjs +35 -35
- package/esm2022/lib/shared/components/component-level-server-error/component-level-server-error.component.mjs +65 -0
- package/{esm2020 → esm2022}/lib/shared/components/error-modal/error-modal.component.mjs +45 -45
- package/esm2022/lib/shared/components/page-not-found/page-not-found.component.mjs +92 -0
- package/esm2022/lib/shared/components/server-error/server-error.component.mjs +83 -0
- package/{esm2020 → esm2022}/lib/shared/components/session-expired/session-expired.component.mjs +35 -35
- package/esm2022/lib/shared/components/unauthorized/unauthorized.component.mjs +103 -0
- package/{esm2020 → esm2022}/lib/shared/constants/api-config.constants.mjs +239 -239
- package/{esm2020 → esm2022}/lib/shared/constants/error-handling.constants.mjs +62 -62
- package/{esm2020 → esm2022}/lib/shared/errorhandler/chunk-error.handler.mjs +18 -18
- package/{esm2020 → esm2022}/lib/shared/errorhandler/sentry-error.handler.mjs +47 -47
- package/{esm2020 → esm2022}/lib/shared/interceptors/http.interceptor.mjs +35 -35
- package/{esm2020 → esm2022}/lib/shared/services/global-error.service.mjs +115 -115
- package/{esm2020 → esm2022}/lib/shared/services/router.service.mjs +19 -19
- package/{esm2020 → esm2022}/lib/shared/services/util.service.mjs +48 -48
- package/{esm2020 → esm2022}/lib/shared/types/global-error.types.mjs +15 -15
- package/{esm2020 → esm2022}/lib/ui-kit/dialog/dialog-config.mjs +2 -2
- package/esm2022/lib/ui-kit/dialog/dialog-injector.mjs +15 -0
- package/{esm2020 → esm2022}/lib/ui-kit/dialog/dialog-ref.mjs +12 -12
- package/{esm2020 → esm2022}/lib/ui-kit/dialog/dialog.component.mjs +85 -85
- package/esm2022/lib/ui-kit/dialog/dialog.module.mjs +21 -0
- package/{esm2020 → esm2022}/lib/ui-kit/dialog/dialog.service.mjs +52 -52
- package/{esm2020 → esm2022}/lib/ui-kit/dialog/insertion.directive.mjs +16 -16
- package/{esm2020 → esm2022}/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.mjs +50 -50
- package/esm2022/lib/ui-kit/snack-bar/snack-bar.module.mjs +18 -0
- package/{esm2020 → esm2022}/lib/ui-kit/snack-bar/snack-bar.service.mjs +32 -32
- package/{esm2020 → esm2022}/lib/vc-error-handlers.component.mjs +85 -85
- package/esm2022/lib/vc-error-handlers.module.mjs +84 -0
- package/{esm2020 → esm2022}/lib/vc-error-handlers.service.mjs +14 -14
- package/{esm2020 → esm2022}/public-api.mjs +16 -16
- package/{esm2020 → esm2022}/vc-error-handlers.mjs +4 -4
- package/{fesm2020 → fesm2022}/vc-error-handlers.mjs +1286 -1359
- package/fesm2022/vc-error-handlers.mjs.map +1 -0
- package/{vc-error-handlers.d.ts → index.d.ts} +5 -5
- package/lib/configuration.d.ts +5 -4
- package/lib/featureFlag/feature-flag.directive.d.ts +13 -13
- package/lib/featureFlag/feature-flag.module.d.ts +8 -8
- package/lib/featureFlag/feature-flag.service.d.ts +21 -19
- package/lib/shared/components/chunk-unavailable/chunk-unavailable.component.d.ts +20 -20
- package/lib/shared/components/component-level-server-error/component-level-server-error.component.d.ts +19 -19
- package/lib/shared/components/error-modal/error-modal.component.d.ts +21 -21
- package/lib/shared/components/page-not-found/page-not-found.component.d.ts +23 -23
- package/lib/shared/components/server-error/server-error.component.d.ts +19 -19
- package/lib/shared/components/session-expired/session-expired.component.d.ts +20 -20
- package/lib/shared/components/unauthorized/unauthorized.component.d.ts +23 -23
- package/lib/shared/constants/api-config.constants.d.ts +20 -20
- package/lib/shared/constants/error-handling.constants.d.ts +62 -62
- package/lib/shared/errorhandler/chunk-error.handler.d.ts +7 -7
- package/lib/shared/errorhandler/sentry-error.handler.d.ts +14 -14
- package/lib/shared/interceptors/http.interceptor.d.ts +13 -13
- package/lib/shared/services/global-error.service.d.ts +31 -31
- package/lib/shared/services/router.service.d.ts +6 -6
- package/lib/shared/services/util.service.d.ts +15 -15
- package/lib/shared/types/global-error.types.d.ts +27 -27
- package/lib/ui-kit/dialog/dialog-config.d.ts +6 -6
- package/lib/ui-kit/dialog/dialog-injector.d.ts +7 -7
- package/lib/ui-kit/dialog/dialog-ref.d.ts +7 -7
- package/lib/ui-kit/dialog/dialog.component.d.ts +33 -33
- package/lib/ui-kit/dialog/dialog.module.d.ts +9 -9
- package/lib/ui-kit/dialog/dialog.service.d.ts +17 -17
- package/lib/ui-kit/dialog/insertion.directive.d.ts +8 -8
- package/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.d.ts +20 -20
- package/lib/ui-kit/snack-bar/snack-bar.module.d.ts +8 -8
- package/lib/ui-kit/snack-bar/snack-bar.service.d.ts +11 -11
- package/lib/vc-error-handlers.component.d.ts +26 -26
- package/lib/vc-error-handlers.module.d.ts +26 -26
- package/lib/vc-error-handlers.service.d.ts +6 -6
- package/package.json +7 -13
- package/public-api.d.ts +13 -13
- package/environments/environment.d.ts +0 -39
- package/esm2020/environments/environment.mjs +0 -75
- package/esm2020/lib/configuration.mjs +0 -6
- package/esm2020/lib/featureFlag/feature-flag.module.mjs +0 -22
- package/esm2020/lib/featureFlag/feature-flag.service.mjs +0 -95
- package/esm2020/lib/shared/components/component-level-server-error/component-level-server-error.component.mjs +0 -64
- package/esm2020/lib/shared/components/page-not-found/page-not-found.component.mjs +0 -91
- package/esm2020/lib/shared/components/server-error/server-error.component.mjs +0 -82
- package/esm2020/lib/shared/components/unauthorized/unauthorized.component.mjs +0 -102
- package/esm2020/lib/ui-kit/dialog/dialog-injector.mjs +0 -15
- package/esm2020/lib/ui-kit/dialog/dialog.module.mjs +0 -21
- package/esm2020/lib/ui-kit/snack-bar/snack-bar.module.mjs +0 -18
- package/esm2020/lib/vc-error-handlers.module.mjs +0 -84
- package/fesm2015/vc-error-handlers.mjs +0 -1679
- package/fesm2015/vc-error-handlers.mjs.map +0 -1
- package/fesm2020/vc-error-handlers.mjs.map +0 -1
|
@@ -3,875 +3,607 @@ import { Injectable, Component, Input, Directive, ViewChild, NgModule, EventEmit
|
|
|
3
3
|
import { Subject, throwError } from 'rxjs';
|
|
4
4
|
import * as i3 from '@angular/router';
|
|
5
5
|
import { NavigationStart, NavigationEnd, NavigationError } from '@angular/router';
|
|
6
|
-
import * as
|
|
7
|
-
import { CommonModule } from '@angular/common';
|
|
8
|
-
import * as i1 from '@vcomply/authorizer';
|
|
9
|
-
import * as i1$
|
|
6
|
+
import * as i1 from '@angular/common';
|
|
7
|
+
import { CommonModule, NgOptimizedImage } from '@angular/common';
|
|
8
|
+
import * as i1$1 from '@vcomply/authorizer';
|
|
9
|
+
import * as i1$2 from '@angular/common/http';
|
|
10
10
|
import { HttpResponse, HTTP_INTERCEPTORS } from '@angular/common/http';
|
|
11
11
|
import { retry, timeout, tap, catchError } from 'rxjs/operators';
|
|
12
12
|
import * as Sentry from '@sentry/angular-ivy';
|
|
13
13
|
|
|
14
|
-
class VcErrorHandlersService {
|
|
15
|
-
constructor() { }
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
20
|
-
type: Injectable,
|
|
21
|
-
args: [{
|
|
22
|
-
providedIn: 'root'
|
|
23
|
-
}]
|
|
14
|
+
class VcErrorHandlersService {
|
|
15
|
+
constructor() { }
|
|
16
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
17
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersService, providedIn: 'root' }); }
|
|
18
|
+
}
|
|
19
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersService, decorators: [{
|
|
20
|
+
type: Injectable,
|
|
21
|
+
args: [{
|
|
22
|
+
providedIn: 'root'
|
|
23
|
+
}]
|
|
24
24
|
}], ctorParameters: function () { return []; } });
|
|
25
25
|
|
|
26
|
-
var ErrorStatusCode;
|
|
27
|
-
(function (ErrorStatusCode) {
|
|
28
|
-
ErrorStatusCode[ErrorStatusCode["URLNotFound"] = 404] = "URLNotFound";
|
|
29
|
-
ErrorStatusCode[ErrorStatusCode["UnauthorizedAccess"] = 403] = "UnauthorizedAccess";
|
|
30
|
-
ErrorStatusCode[ErrorStatusCode["Unauthenticated"] = 401] = "Unauthenticated";
|
|
31
|
-
// Server-side errors
|
|
32
|
-
ErrorStatusCode[ErrorStatusCode["InternalServerError"] = 500] = "InternalServerError";
|
|
33
|
-
ErrorStatusCode[ErrorStatusCode["ServiceUnavailable"] = 503] = "ServiceUnavailable";
|
|
34
|
-
ErrorStatusCode[ErrorStatusCode["BadGateway"] = 502] = "BadGateway";
|
|
35
|
-
ErrorStatusCode[ErrorStatusCode["RequestTimeout"] = 504] = "RequestTimeout";
|
|
36
|
-
// Network unavailability/offline case
|
|
37
|
-
ErrorStatusCode[ErrorStatusCode["NetworkUnavailable"] = 0] = "NetworkUnavailable";
|
|
38
|
-
// Application-specific errors
|
|
39
|
-
ErrorStatusCode[ErrorStatusCode["JSChunkUnavailable"] = 600] = "JSChunkUnavailable";
|
|
26
|
+
var ErrorStatusCode;
|
|
27
|
+
(function (ErrorStatusCode) {
|
|
28
|
+
ErrorStatusCode[ErrorStatusCode["URLNotFound"] = 404] = "URLNotFound";
|
|
29
|
+
ErrorStatusCode[ErrorStatusCode["UnauthorizedAccess"] = 403] = "UnauthorizedAccess";
|
|
30
|
+
ErrorStatusCode[ErrorStatusCode["Unauthenticated"] = 401] = "Unauthenticated";
|
|
31
|
+
// Server-side errors
|
|
32
|
+
ErrorStatusCode[ErrorStatusCode["InternalServerError"] = 500] = "InternalServerError";
|
|
33
|
+
ErrorStatusCode[ErrorStatusCode["ServiceUnavailable"] = 503] = "ServiceUnavailable";
|
|
34
|
+
ErrorStatusCode[ErrorStatusCode["BadGateway"] = 502] = "BadGateway";
|
|
35
|
+
ErrorStatusCode[ErrorStatusCode["RequestTimeout"] = 504] = "RequestTimeout";
|
|
36
|
+
// Network unavailability/offline case
|
|
37
|
+
ErrorStatusCode[ErrorStatusCode["NetworkUnavailable"] = 0] = "NetworkUnavailable";
|
|
38
|
+
// Application-specific errors
|
|
39
|
+
ErrorStatusCode[ErrorStatusCode["JSChunkUnavailable"] = 600] = "JSChunkUnavailable";
|
|
40
40
|
})(ErrorStatusCode || (ErrorStatusCode = {}));
|
|
41
41
|
|
|
42
|
-
const PAGE_LEVEL_API_CONFIG = [
|
|
43
|
-
{
|
|
44
|
-
method: '',
|
|
45
|
-
path: '',
|
|
46
|
-
query: null,
|
|
47
|
-
body: null,
|
|
48
|
-
pageCodes: [''],
|
|
49
|
-
},
|
|
50
|
-
];
|
|
51
|
-
const COMPONENT_LEVEL_API_CONFIG = [
|
|
52
|
-
{
|
|
53
|
-
method: 'GET',
|
|
54
|
-
path: '/organization/?mode=organisationUsersList',
|
|
55
|
-
query: { type: 'active' },
|
|
56
|
-
body: null,
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
method: 'GET',
|
|
60
|
-
path: '/organization/?mode=organisationUsersList',
|
|
61
|
-
query: { type: 'power_users' },
|
|
62
|
-
body: null,
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
method: 'GET',
|
|
66
|
-
path: '/organization/?mode=organisationUsersList',
|
|
67
|
-
query: { type: 'light_users' },
|
|
68
|
-
body: null,
|
|
69
|
-
},
|
|
70
|
-
{
|
|
71
|
-
method: 'GET',
|
|
72
|
-
path: '/organization/?mode=organisationUsersList',
|
|
73
|
-
query: { type: 'inactive' },
|
|
74
|
-
body: null,
|
|
75
|
-
},
|
|
76
|
-
{
|
|
77
|
-
method: 'GET',
|
|
78
|
-
path: '/organization/?mode=organisationUsersList',
|
|
79
|
-
query: { type: 'power_users_small' },
|
|
80
|
-
body: null,
|
|
81
|
-
},
|
|
82
|
-
{
|
|
83
|
-
method: 'GET',
|
|
84
|
-
path: '/Global-Dashboard/ManageDashboards',
|
|
85
|
-
query: null,
|
|
86
|
-
body: null,
|
|
87
|
-
},
|
|
88
|
-
{
|
|
89
|
-
method: 'GET',
|
|
90
|
-
path: '/Global-Dashboard/MyDashboard',
|
|
91
|
-
query: null,
|
|
92
|
-
body: null,
|
|
93
|
-
},
|
|
94
|
-
{
|
|
95
|
-
method: 'GET',
|
|
96
|
-
path: '/grc_object/?mode=grc/getGRCList',
|
|
97
|
-
query: null,
|
|
98
|
-
body: null,
|
|
99
|
-
},
|
|
100
|
-
{
|
|
101
|
-
method: 'GET',
|
|
102
|
-
path: '/compliance/?mode=responsibilityCenterTree',
|
|
103
|
-
query: null,
|
|
104
|
-
body: null,
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
method: 'GET',
|
|
108
|
-
path: '/organization/?mode=rcholidaylist',
|
|
109
|
-
query: null,
|
|
110
|
-
body: null,
|
|
111
|
-
},
|
|
112
|
-
{
|
|
113
|
-
method: 'GET',
|
|
114
|
-
path: '/organization/?mode=roles/getRoles',
|
|
115
|
-
query: null,
|
|
116
|
-
body: null,
|
|
117
|
-
},
|
|
118
|
-
{
|
|
119
|
-
method: 'GET',
|
|
120
|
-
path: '/organization/?mode=groupsList',
|
|
121
|
-
query: null,
|
|
122
|
-
body: null,
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
method: 'POST',
|
|
126
|
-
path: '/compliance_post/?mode=rcProfile',
|
|
127
|
-
query: null,
|
|
128
|
-
body: null,
|
|
129
|
-
},
|
|
130
|
-
{
|
|
131
|
-
method: 'POST',
|
|
132
|
-
path: '/organization_post/?mode=userProfile',
|
|
133
|
-
query: null,
|
|
134
|
-
body: null,
|
|
135
|
-
},
|
|
136
|
-
{
|
|
137
|
-
method: 'GET',
|
|
138
|
-
path: '/organization/?mode=roles/roleById',
|
|
139
|
-
query: null,
|
|
140
|
-
body: null,
|
|
141
|
-
},
|
|
142
|
-
{
|
|
143
|
-
method: 'GET',
|
|
144
|
-
path: '/organization/?mode=groupDetails',
|
|
145
|
-
query: null,
|
|
146
|
-
body: null,
|
|
147
|
-
},
|
|
148
|
-
{
|
|
149
|
-
method: 'POST',
|
|
150
|
-
path: '/compliance_post?mode=report/list',
|
|
151
|
-
query: null,
|
|
152
|
-
body: null,
|
|
153
|
-
},
|
|
154
|
-
{
|
|
155
|
-
method: 'GET',
|
|
156
|
-
path: '/organization/?mode=memberholidaylist',
|
|
157
|
-
query: null,
|
|
158
|
-
body: null,
|
|
159
|
-
},
|
|
160
|
-
{
|
|
161
|
-
method: 'GET',
|
|
162
|
-
path: '/grc_object/?mode=activity/activityLogList',
|
|
163
|
-
query: null,
|
|
164
|
-
body: null,
|
|
165
|
-
},
|
|
166
|
-
{
|
|
167
|
-
method: 'GET',
|
|
168
|
-
path: '/grc_object/?mode=activity/viewList',
|
|
169
|
-
query: null,
|
|
170
|
-
body: null,
|
|
171
|
-
},
|
|
172
|
-
{
|
|
173
|
-
method: 'GET',
|
|
174
|
-
path: '/program/categoriesList?owner_list=1',
|
|
175
|
-
query: null,
|
|
176
|
-
body: null,
|
|
177
|
-
},
|
|
178
|
-
{
|
|
179
|
-
method: 'POST',
|
|
180
|
-
path: '/risk/?mode=category/list',
|
|
181
|
-
query: null,
|
|
182
|
-
body: null,
|
|
183
|
-
},
|
|
184
|
-
{
|
|
185
|
-
method: 'POST',
|
|
186
|
-
path: 'memberDetailsbyIds',
|
|
187
|
-
query: null,
|
|
188
|
-
body: null,
|
|
189
|
-
},
|
|
190
|
-
{
|
|
191
|
-
method: 'GET',
|
|
192
|
-
path: '/organization?mode=signatureDetails',
|
|
193
|
-
query: null,
|
|
194
|
-
body: null,
|
|
195
|
-
},
|
|
196
|
-
{
|
|
197
|
-
method: 'GET',
|
|
198
|
-
path: '/program/responsibilityList',
|
|
199
|
-
query: null,
|
|
200
|
-
body: null,
|
|
201
|
-
},
|
|
202
|
-
{
|
|
203
|
-
method: 'GET',
|
|
204
|
-
path: '/program/getLinkedPolicies',
|
|
205
|
-
query: null,
|
|
206
|
-
body: null,
|
|
207
|
-
},
|
|
208
|
-
{
|
|
209
|
-
method: 'POST',
|
|
210
|
-
path: 'risk/list',
|
|
211
|
-
query: null,
|
|
212
|
-
body: null,
|
|
213
|
-
},
|
|
214
|
-
{
|
|
215
|
-
method: 'GET',
|
|
216
|
-
path: '/program/assignee',
|
|
217
|
-
query: null,
|
|
218
|
-
body: null,
|
|
219
|
-
},
|
|
220
|
-
{
|
|
221
|
-
method: 'GET',
|
|
222
|
-
path: '/program/evidence/getEvidences/b-cycle-header',
|
|
223
|
-
query: null,
|
|
224
|
-
body: null,
|
|
225
|
-
},
|
|
226
|
-
{
|
|
227
|
-
method: 'GET',
|
|
228
|
-
path: '/program/activity-logs',
|
|
229
|
-
query: null,
|
|
230
|
-
body: null,
|
|
231
|
-
},
|
|
232
|
-
{
|
|
233
|
-
method: 'GET',
|
|
234
|
-
path: '/program/activity-logs-views',
|
|
235
|
-
query: null,
|
|
236
|
-
body: null,
|
|
237
|
-
},
|
|
238
|
-
{
|
|
239
|
-
method: 'POST',
|
|
240
|
-
path: '/Assessment/?mode=category/list',
|
|
241
|
-
query: null,
|
|
242
|
-
body: null,
|
|
243
|
-
},
|
|
244
|
-
{
|
|
245
|
-
method: 'POST',
|
|
246
|
-
path: '/Assessment/?mode=assessment/list',
|
|
247
|
-
query: null,
|
|
248
|
-
body: null,
|
|
249
|
-
},
|
|
250
|
-
{
|
|
251
|
-
method: 'GET',
|
|
252
|
-
path: '/Assessment/?mode=assessment/fetchQuestionsByAssessmentId',
|
|
253
|
-
query: null,
|
|
254
|
-
body: null,
|
|
255
|
-
},
|
|
256
|
-
{
|
|
257
|
-
method: 'POST',
|
|
258
|
-
path: '/Assessment/?mode=assessment/responseSummary',
|
|
259
|
-
query: null,
|
|
260
|
-
body: null,
|
|
261
|
-
},
|
|
262
|
-
{
|
|
263
|
-
method: 'GET',
|
|
264
|
-
path: '/Assessment/?mode=assessment/logs',
|
|
265
|
-
query: null,
|
|
266
|
-
body: null,
|
|
267
|
-
},
|
|
268
|
-
{
|
|
269
|
-
method: 'GET',
|
|
270
|
-
path: '/program/subCategories',
|
|
271
|
-
query: null,
|
|
272
|
-
body: null,
|
|
273
|
-
},
|
|
274
|
-
{
|
|
275
|
-
method: 'POST',
|
|
276
|
-
path: '/Assessment/?mode=assessment/getAssessmentById',
|
|
277
|
-
query: null,
|
|
278
|
-
body: null,
|
|
279
|
-
},
|
|
42
|
+
const PAGE_LEVEL_API_CONFIG = [
|
|
43
|
+
{
|
|
44
|
+
method: '',
|
|
45
|
+
path: '',
|
|
46
|
+
query: null,
|
|
47
|
+
body: null,
|
|
48
|
+
pageCodes: [''],
|
|
49
|
+
},
|
|
50
|
+
];
|
|
51
|
+
const COMPONENT_LEVEL_API_CONFIG = [
|
|
52
|
+
{
|
|
53
|
+
method: 'GET',
|
|
54
|
+
path: '/organization/?mode=organisationUsersList',
|
|
55
|
+
query: { type: 'active' },
|
|
56
|
+
body: null,
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
method: 'GET',
|
|
60
|
+
path: '/organization/?mode=organisationUsersList',
|
|
61
|
+
query: { type: 'power_users' },
|
|
62
|
+
body: null,
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
method: 'GET',
|
|
66
|
+
path: '/organization/?mode=organisationUsersList',
|
|
67
|
+
query: { type: 'light_users' },
|
|
68
|
+
body: null,
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
method: 'GET',
|
|
72
|
+
path: '/organization/?mode=organisationUsersList',
|
|
73
|
+
query: { type: 'inactive' },
|
|
74
|
+
body: null,
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
method: 'GET',
|
|
78
|
+
path: '/organization/?mode=organisationUsersList',
|
|
79
|
+
query: { type: 'power_users_small' },
|
|
80
|
+
body: null,
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
method: 'GET',
|
|
84
|
+
path: '/Global-Dashboard/ManageDashboards',
|
|
85
|
+
query: null,
|
|
86
|
+
body: null,
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
method: 'GET',
|
|
90
|
+
path: '/Global-Dashboard/MyDashboard',
|
|
91
|
+
query: null,
|
|
92
|
+
body: null,
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
method: 'GET',
|
|
96
|
+
path: '/grc_object/?mode=grc/getGRCList',
|
|
97
|
+
query: null,
|
|
98
|
+
body: null,
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
method: 'GET',
|
|
102
|
+
path: '/compliance/?mode=responsibilityCenterTree',
|
|
103
|
+
query: null,
|
|
104
|
+
body: null,
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
method: 'GET',
|
|
108
|
+
path: '/organization/?mode=rcholidaylist',
|
|
109
|
+
query: null,
|
|
110
|
+
body: null,
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
method: 'GET',
|
|
114
|
+
path: '/organization/?mode=roles/getRoles',
|
|
115
|
+
query: null,
|
|
116
|
+
body: null,
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
method: 'GET',
|
|
120
|
+
path: '/organization/?mode=groupsList',
|
|
121
|
+
query: null,
|
|
122
|
+
body: null,
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
method: 'POST',
|
|
126
|
+
path: '/compliance_post/?mode=rcProfile',
|
|
127
|
+
query: null,
|
|
128
|
+
body: null,
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
method: 'POST',
|
|
132
|
+
path: '/organization_post/?mode=userProfile',
|
|
133
|
+
query: null,
|
|
134
|
+
body: null,
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
method: 'GET',
|
|
138
|
+
path: '/organization/?mode=roles/roleById',
|
|
139
|
+
query: null,
|
|
140
|
+
body: null,
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
method: 'GET',
|
|
144
|
+
path: '/organization/?mode=groupDetails',
|
|
145
|
+
query: null,
|
|
146
|
+
body: null,
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
method: 'POST',
|
|
150
|
+
path: '/compliance_post?mode=report/list',
|
|
151
|
+
query: null,
|
|
152
|
+
body: null,
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
method: 'GET',
|
|
156
|
+
path: '/organization/?mode=memberholidaylist',
|
|
157
|
+
query: null,
|
|
158
|
+
body: null,
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
method: 'GET',
|
|
162
|
+
path: '/grc_object/?mode=activity/activityLogList',
|
|
163
|
+
query: null,
|
|
164
|
+
body: null,
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
method: 'GET',
|
|
168
|
+
path: '/grc_object/?mode=activity/viewList',
|
|
169
|
+
query: null,
|
|
170
|
+
body: null,
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
method: 'GET',
|
|
174
|
+
path: '/program/categoriesList?owner_list=1',
|
|
175
|
+
query: null,
|
|
176
|
+
body: null,
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
method: 'POST',
|
|
180
|
+
path: '/risk/?mode=category/list',
|
|
181
|
+
query: null,
|
|
182
|
+
body: null,
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
method: 'POST',
|
|
186
|
+
path: 'memberDetailsbyIds',
|
|
187
|
+
query: null,
|
|
188
|
+
body: null,
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
method: 'GET',
|
|
192
|
+
path: '/organization?mode=signatureDetails',
|
|
193
|
+
query: null,
|
|
194
|
+
body: null,
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
method: 'GET',
|
|
198
|
+
path: '/program/responsibilityList',
|
|
199
|
+
query: null,
|
|
200
|
+
body: null,
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
method: 'GET',
|
|
204
|
+
path: '/program/getLinkedPolicies',
|
|
205
|
+
query: null,
|
|
206
|
+
body: null,
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
method: 'POST',
|
|
210
|
+
path: 'risk/list',
|
|
211
|
+
query: null,
|
|
212
|
+
body: null,
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
method: 'GET',
|
|
216
|
+
path: '/program/assignee',
|
|
217
|
+
query: null,
|
|
218
|
+
body: null,
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
method: 'GET',
|
|
222
|
+
path: '/program/evidence/getEvidences/b-cycle-header',
|
|
223
|
+
query: null,
|
|
224
|
+
body: null,
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
method: 'GET',
|
|
228
|
+
path: '/program/activity-logs',
|
|
229
|
+
query: null,
|
|
230
|
+
body: null,
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
method: 'GET',
|
|
234
|
+
path: '/program/activity-logs-views',
|
|
235
|
+
query: null,
|
|
236
|
+
body: null,
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
method: 'POST',
|
|
240
|
+
path: '/Assessment/?mode=category/list',
|
|
241
|
+
query: null,
|
|
242
|
+
body: null,
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
method: 'POST',
|
|
246
|
+
path: '/Assessment/?mode=assessment/list',
|
|
247
|
+
query: null,
|
|
248
|
+
body: null,
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
method: 'GET',
|
|
252
|
+
path: '/Assessment/?mode=assessment/fetchQuestionsByAssessmentId',
|
|
253
|
+
query: null,
|
|
254
|
+
body: null,
|
|
255
|
+
},
|
|
256
|
+
{
|
|
257
|
+
method: 'POST',
|
|
258
|
+
path: '/Assessment/?mode=assessment/responseSummary',
|
|
259
|
+
query: null,
|
|
260
|
+
body: null,
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
method: 'GET',
|
|
264
|
+
path: '/Assessment/?mode=assessment/logs',
|
|
265
|
+
query: null,
|
|
266
|
+
body: null,
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
method: 'GET',
|
|
270
|
+
path: '/program/subCategories',
|
|
271
|
+
query: null,
|
|
272
|
+
body: null,
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
method: 'POST',
|
|
276
|
+
path: '/Assessment/?mode=assessment/getAssessmentById',
|
|
277
|
+
query: null,
|
|
278
|
+
body: null,
|
|
279
|
+
},
|
|
280
280
|
];
|
|
281
281
|
|
|
282
|
-
class SnackBarService {
|
|
283
|
-
constructor() {
|
|
284
|
-
this.snackbarSubject = new Subject();
|
|
285
|
-
this.snackbarState = this.snackbarSubject.asObservable();
|
|
286
|
-
}
|
|
287
|
-
show(message, type) {
|
|
288
|
-
this.snackbarSubject.next({
|
|
289
|
-
show: true,
|
|
290
|
-
message,
|
|
291
|
-
icon: type,
|
|
292
|
-
});
|
|
293
|
-
}
|
|
294
|
-
hide() {
|
|
295
|
-
this.snackbarSubject.next({
|
|
296
|
-
show: false,
|
|
297
|
-
message: '',
|
|
298
|
-
icon: '',
|
|
299
|
-
});
|
|
300
|
-
}
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
305
|
-
type: Injectable,
|
|
306
|
-
args: [{
|
|
307
|
-
providedIn: 'root',
|
|
308
|
-
}]
|
|
282
|
+
class SnackBarService {
|
|
283
|
+
constructor() {
|
|
284
|
+
this.snackbarSubject = new Subject();
|
|
285
|
+
this.snackbarState = this.snackbarSubject.asObservable();
|
|
286
|
+
}
|
|
287
|
+
show(message, type) {
|
|
288
|
+
this.snackbarSubject.next({
|
|
289
|
+
show: true,
|
|
290
|
+
message,
|
|
291
|
+
icon: type,
|
|
292
|
+
});
|
|
293
|
+
}
|
|
294
|
+
hide() {
|
|
295
|
+
this.snackbarSubject.next({
|
|
296
|
+
show: false,
|
|
297
|
+
message: '',
|
|
298
|
+
icon: '',
|
|
299
|
+
});
|
|
300
|
+
}
|
|
301
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
302
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarService, providedIn: 'root' }); }
|
|
303
|
+
}
|
|
304
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarService, decorators: [{
|
|
305
|
+
type: Injectable,
|
|
306
|
+
args: [{
|
|
307
|
+
providedIn: 'root',
|
|
308
|
+
}]
|
|
309
309
|
}], ctorParameters: function () { return []; } });
|
|
310
310
|
|
|
311
|
-
class UtilsService {
|
|
312
|
-
isJsonSubset(parentJson, subsetJson) {
|
|
313
|
-
for (let key in subsetJson) {
|
|
314
|
-
if (!parentJson.hasOwnProperty(key) ||
|
|
315
|
-
parentJson[key] !== subsetJson[key]) {
|
|
316
|
-
return false;
|
|
317
|
-
}
|
|
318
|
-
}
|
|
319
|
-
return true;
|
|
320
|
-
}
|
|
321
|
-
extractQueryParams(params) {
|
|
322
|
-
const query = {};
|
|
323
|
-
params.keys().forEach((key) => {
|
|
324
|
-
query[key] = params.get(key);
|
|
325
|
-
});
|
|
326
|
-
return query;
|
|
327
|
-
}
|
|
328
|
-
isStringEqual(apiMethod, requestMethod) {
|
|
329
|
-
return apiMethod === requestMethod;
|
|
330
|
-
}
|
|
331
|
-
isSubstringInString(apiPath, requestPath) {
|
|
332
|
-
return requestPath.includes(apiPath);
|
|
333
|
-
}
|
|
334
|
-
isSubsetOfObject(apiQuery, requestQuery) {
|
|
335
|
-
if (!apiQuery)
|
|
336
|
-
return true;
|
|
337
|
-
return this.isJsonSubset(requestQuery, apiQuery);
|
|
338
|
-
}
|
|
339
|
-
isSubsetOfArray(apiBody, requestBody) {
|
|
340
|
-
if (!apiBody)
|
|
341
|
-
return true;
|
|
342
|
-
return this.isJsonSubset(apiBody, requestBody);
|
|
343
|
-
}
|
|
344
|
-
isValueInArray(apiPageCodes, pageCode) {
|
|
345
|
-
return apiPageCodes.includes(pageCode);
|
|
346
|
-
}
|
|
347
|
-
}
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
351
|
-
type: Injectable,
|
|
352
|
-
args: [{
|
|
353
|
-
providedIn: 'root',
|
|
354
|
-
}]
|
|
311
|
+
class UtilsService {
|
|
312
|
+
isJsonSubset(parentJson, subsetJson) {
|
|
313
|
+
for (let key in subsetJson) {
|
|
314
|
+
if (!parentJson.hasOwnProperty(key) ||
|
|
315
|
+
parentJson[key] !== subsetJson[key]) {
|
|
316
|
+
return false;
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
return true;
|
|
320
|
+
}
|
|
321
|
+
extractQueryParams(params) {
|
|
322
|
+
const query = {};
|
|
323
|
+
params.keys().forEach((key) => {
|
|
324
|
+
query[key] = params.get(key);
|
|
325
|
+
});
|
|
326
|
+
return query;
|
|
327
|
+
}
|
|
328
|
+
isStringEqual(apiMethod, requestMethod) {
|
|
329
|
+
return apiMethod === requestMethod;
|
|
330
|
+
}
|
|
331
|
+
isSubstringInString(apiPath, requestPath) {
|
|
332
|
+
return requestPath.includes(apiPath);
|
|
333
|
+
}
|
|
334
|
+
isSubsetOfObject(apiQuery, requestQuery) {
|
|
335
|
+
if (!apiQuery)
|
|
336
|
+
return true;
|
|
337
|
+
return this.isJsonSubset(requestQuery, apiQuery);
|
|
338
|
+
}
|
|
339
|
+
isSubsetOfArray(apiBody, requestBody) {
|
|
340
|
+
if (!apiBody)
|
|
341
|
+
return true;
|
|
342
|
+
return this.isJsonSubset(apiBody, requestBody);
|
|
343
|
+
}
|
|
344
|
+
isValueInArray(apiPageCodes, pageCode) {
|
|
345
|
+
return apiPageCodes.includes(pageCode);
|
|
346
|
+
}
|
|
347
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UtilsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
348
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UtilsService, providedIn: 'root' }); }
|
|
349
|
+
}
|
|
350
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UtilsService, decorators: [{
|
|
351
|
+
type: Injectable,
|
|
352
|
+
args: [{
|
|
353
|
+
providedIn: 'root',
|
|
354
|
+
}]
|
|
355
355
|
}] });
|
|
356
356
|
|
|
357
|
-
class GlobalErrorService {
|
|
358
|
-
constructor(snackBarService, utilService, router) {
|
|
359
|
-
this.snackBarService = snackBarService;
|
|
360
|
-
this.utilService = utilService;
|
|
361
|
-
this.router = router;
|
|
362
|
-
this.globalError$ = new Subject();
|
|
363
|
-
this.localError$ = new Subject();
|
|
364
|
-
this.pageLevelApiConfig = PAGE_LEVEL_API_CONFIG;
|
|
365
|
-
this.componentLevelApiConfig = COMPONENT_LEVEL_API_CONFIG;
|
|
366
|
-
}
|
|
367
|
-
handleSoftErrors(event) {
|
|
368
|
-
const xData = event.headers.get('X-Data');
|
|
369
|
-
if (xData) {
|
|
370
|
-
const parsedData = JSON.parse(xData);
|
|
371
|
-
const statusCode = parsedData.statusCode;
|
|
372
|
-
const statusMessage = parsedData.message;
|
|
373
|
-
if (statusCode && statusCode !== 0) {
|
|
374
|
-
this.snackBarService.show(statusMessage || 'Error occurred', 'error');
|
|
375
|
-
}
|
|
376
|
-
}
|
|
377
|
-
}
|
|
378
|
-
handleError(error, request) {
|
|
379
|
-
if (this.isUnauthenticated(error) ||
|
|
380
|
-
this.isUnauthorizedAccess(error) ||
|
|
381
|
-
this.isNetworkUnavailable(error)) {
|
|
382
|
-
this.publishGlobalError(error);
|
|
383
|
-
}
|
|
384
|
-
else if (this.isServerError(error)) {
|
|
385
|
-
this.handleServerError(error, request);
|
|
386
|
-
}
|
|
387
|
-
else {
|
|
388
|
-
this.handleSoftErrors(error);
|
|
389
|
-
}
|
|
390
|
-
}
|
|
391
|
-
isServerError(error) {
|
|
392
|
-
const serverErrorCodes = [
|
|
393
|
-
ErrorStatusCode.InternalServerError,
|
|
394
|
-
ErrorStatusCode.ServiceUnavailable,
|
|
395
|
-
ErrorStatusCode.BadGateway,
|
|
396
|
-
ErrorStatusCode.RequestTimeout,
|
|
397
|
-
];
|
|
398
|
-
return serverErrorCodes.includes(error.status);
|
|
399
|
-
}
|
|
400
|
-
isUnauthenticated(error) {
|
|
401
|
-
return error.status === ErrorStatusCode.Unauthenticated;
|
|
402
|
-
}
|
|
403
|
-
isUnauthorizedAccess(error) {
|
|
404
|
-
return error.status === ErrorStatusCode.UnauthorizedAccess;
|
|
405
|
-
}
|
|
406
|
-
isNetworkUnavailable(error) {
|
|
407
|
-
return error.status === ErrorStatusCode.NetworkUnavailable;
|
|
408
|
-
}
|
|
409
|
-
handleServerError(error, request) {
|
|
410
|
-
if (this.isPageLevelError(error, request)) {
|
|
411
|
-
this.publishGlobalError(error);
|
|
412
|
-
}
|
|
413
|
-
else if (this.isComponentLevelError(error, request)) {
|
|
414
|
-
this.publishLocalError(error, request);
|
|
415
|
-
}
|
|
416
|
-
}
|
|
417
|
-
publishGlobalError(error) {
|
|
418
|
-
this.globalError$.next(error);
|
|
419
|
-
}
|
|
420
|
-
publishLocalError(error, request) {
|
|
421
|
-
this.localError$.next({ error, request });
|
|
422
|
-
}
|
|
423
|
-
isPageLevelError(error, request) {
|
|
424
|
-
const requestDetails = {
|
|
425
|
-
method: request.method,
|
|
426
|
-
path: request.url,
|
|
427
|
-
query: this.utilService.extractQueryParams(request.params),
|
|
428
|
-
body: request.body,
|
|
429
|
-
pageCode: this.getPageCode(),
|
|
430
|
-
};
|
|
431
|
-
return this.pageLevelApiConfig.some((apiConfig) => this.isApiConfigMatching(apiConfig, requestDetails));
|
|
432
|
-
}
|
|
433
|
-
isComponentLevelError(error, request) {
|
|
434
|
-
const requestDetails = {
|
|
435
|
-
method: request.method,
|
|
436
|
-
path: request.url,
|
|
437
|
-
query: this.utilService.extractQueryParams(request.params),
|
|
438
|
-
body: request.body,
|
|
439
|
-
};
|
|
440
|
-
return this.componentLevelApiConfig.some((apiConfig) => this.isApiConfigMatching(apiConfig, requestDetails));
|
|
441
|
-
}
|
|
442
|
-
getPageCode() {
|
|
443
|
-
const currentRoute = this.router.routerState.snapshot.root.firstChild;
|
|
444
|
-
return currentRoute?.data?.pageCode;
|
|
445
|
-
}
|
|
446
|
-
isApiConfigMatching(apiConfig, requestDetails) {
|
|
447
|
-
return (this.utilService.isStringEqual(apiConfig.method, requestDetails.method) &&
|
|
448
|
-
this.utilService.isSubstringInString(apiConfig.path, requestDetails.path) &&
|
|
449
|
-
this.utilService.isSubsetOfObject(apiConfig.query, requestDetails.query) &&
|
|
450
|
-
this.utilService.isSubsetOfArray(apiConfig.body, requestDetails.body) &&
|
|
451
|
-
(!apiConfig.pageCodes ||
|
|
452
|
-
this.utilService.isValueInArray(apiConfig.pageCodes, requestDetails.pageCode || '')));
|
|
453
|
-
}
|
|
454
|
-
}
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
458
|
-
type: Injectable,
|
|
459
|
-
args: [{
|
|
460
|
-
providedIn: 'root',
|
|
461
|
-
}]
|
|
357
|
+
class GlobalErrorService {
|
|
358
|
+
constructor(snackBarService, utilService, router) {
|
|
359
|
+
this.snackBarService = snackBarService;
|
|
360
|
+
this.utilService = utilService;
|
|
361
|
+
this.router = router;
|
|
362
|
+
this.globalError$ = new Subject();
|
|
363
|
+
this.localError$ = new Subject();
|
|
364
|
+
this.pageLevelApiConfig = PAGE_LEVEL_API_CONFIG;
|
|
365
|
+
this.componentLevelApiConfig = COMPONENT_LEVEL_API_CONFIG;
|
|
366
|
+
}
|
|
367
|
+
handleSoftErrors(event) {
|
|
368
|
+
const xData = event.headers.get('X-Data');
|
|
369
|
+
if (xData) {
|
|
370
|
+
const parsedData = JSON.parse(xData);
|
|
371
|
+
const statusCode = parsedData.statusCode;
|
|
372
|
+
const statusMessage = parsedData.message;
|
|
373
|
+
if (statusCode && statusCode !== 0) {
|
|
374
|
+
this.snackBarService.show(statusMessage || 'Error occurred', 'error');
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
handleError(error, request) {
|
|
379
|
+
if (this.isUnauthenticated(error) ||
|
|
380
|
+
this.isUnauthorizedAccess(error) ||
|
|
381
|
+
this.isNetworkUnavailable(error)) {
|
|
382
|
+
this.publishGlobalError(error);
|
|
383
|
+
}
|
|
384
|
+
else if (this.isServerError(error)) {
|
|
385
|
+
this.handleServerError(error, request);
|
|
386
|
+
}
|
|
387
|
+
else {
|
|
388
|
+
this.handleSoftErrors(error);
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
isServerError(error) {
|
|
392
|
+
const serverErrorCodes = [
|
|
393
|
+
ErrorStatusCode.InternalServerError,
|
|
394
|
+
ErrorStatusCode.ServiceUnavailable,
|
|
395
|
+
ErrorStatusCode.BadGateway,
|
|
396
|
+
ErrorStatusCode.RequestTimeout,
|
|
397
|
+
];
|
|
398
|
+
return serverErrorCodes.includes(error.status);
|
|
399
|
+
}
|
|
400
|
+
isUnauthenticated(error) {
|
|
401
|
+
return error.status === ErrorStatusCode.Unauthenticated;
|
|
402
|
+
}
|
|
403
|
+
isUnauthorizedAccess(error) {
|
|
404
|
+
return error.status === ErrorStatusCode.UnauthorizedAccess;
|
|
405
|
+
}
|
|
406
|
+
isNetworkUnavailable(error) {
|
|
407
|
+
return error.status === ErrorStatusCode.NetworkUnavailable;
|
|
408
|
+
}
|
|
409
|
+
handleServerError(error, request) {
|
|
410
|
+
if (this.isPageLevelError(error, request)) {
|
|
411
|
+
this.publishGlobalError(error);
|
|
412
|
+
}
|
|
413
|
+
else if (this.isComponentLevelError(error, request)) {
|
|
414
|
+
this.publishLocalError(error, request);
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
publishGlobalError(error) {
|
|
418
|
+
this.globalError$.next(error);
|
|
419
|
+
}
|
|
420
|
+
publishLocalError(error, request) {
|
|
421
|
+
this.localError$.next({ error, request });
|
|
422
|
+
}
|
|
423
|
+
isPageLevelError(error, request) {
|
|
424
|
+
const requestDetails = {
|
|
425
|
+
method: request.method,
|
|
426
|
+
path: request.url,
|
|
427
|
+
query: this.utilService.extractQueryParams(request.params),
|
|
428
|
+
body: request.body,
|
|
429
|
+
pageCode: this.getPageCode(),
|
|
430
|
+
};
|
|
431
|
+
return this.pageLevelApiConfig.some((apiConfig) => this.isApiConfigMatching(apiConfig, requestDetails));
|
|
432
|
+
}
|
|
433
|
+
isComponentLevelError(error, request) {
|
|
434
|
+
const requestDetails = {
|
|
435
|
+
method: request.method,
|
|
436
|
+
path: request.url,
|
|
437
|
+
query: this.utilService.extractQueryParams(request.params),
|
|
438
|
+
body: request.body,
|
|
439
|
+
};
|
|
440
|
+
return this.componentLevelApiConfig.some((apiConfig) => this.isApiConfigMatching(apiConfig, requestDetails));
|
|
441
|
+
}
|
|
442
|
+
getPageCode() {
|
|
443
|
+
const currentRoute = this.router.routerState.snapshot.root.firstChild;
|
|
444
|
+
return currentRoute?.data?.pageCode;
|
|
445
|
+
}
|
|
446
|
+
isApiConfigMatching(apiConfig, requestDetails) {
|
|
447
|
+
return (this.utilService.isStringEqual(apiConfig.method, requestDetails.method) &&
|
|
448
|
+
this.utilService.isSubstringInString(apiConfig.path, requestDetails.path) &&
|
|
449
|
+
this.utilService.isSubsetOfObject(apiConfig.query, requestDetails.query) &&
|
|
450
|
+
this.utilService.isSubsetOfArray(apiConfig.body, requestDetails.body) &&
|
|
451
|
+
(!apiConfig.pageCodes ||
|
|
452
|
+
this.utilService.isValueInArray(apiConfig.pageCodes, requestDetails.pageCode || '')));
|
|
453
|
+
}
|
|
454
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalErrorService, deps: [{ token: SnackBarService }, { token: UtilsService }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
455
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalErrorService, providedIn: 'root' }); }
|
|
456
|
+
}
|
|
457
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GlobalErrorService, decorators: [{
|
|
458
|
+
type: Injectable,
|
|
459
|
+
args: [{
|
|
460
|
+
providedIn: 'root',
|
|
461
|
+
}]
|
|
462
462
|
}], ctorParameters: function () { return [{ type: SnackBarService }, { type: UtilsService }, { type: i3.Router }]; } });
|
|
463
463
|
|
|
464
|
-
class RouterService {
|
|
465
|
-
redirectToLogin() {
|
|
466
|
-
window.location.href =
|
|
467
|
-
`https://${window.location.host}/` +
|
|
468
|
-
'signin?redirectURL=' +
|
|
469
|
-
encodeURIComponent(window.location.href);
|
|
470
|
-
}
|
|
471
|
-
}
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
475
|
-
type: Injectable,
|
|
476
|
-
args: [{
|
|
477
|
-
providedIn: 'root',
|
|
478
|
-
}]
|
|
464
|
+
class RouterService {
|
|
465
|
+
redirectToLogin() {
|
|
466
|
+
window.location.href =
|
|
467
|
+
`https://${window.location.host}/` +
|
|
468
|
+
'signin?redirectURL=' +
|
|
469
|
+
encodeURIComponent(window.location.href);
|
|
470
|
+
}
|
|
471
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: RouterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
472
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: RouterService, providedIn: 'root' }); }
|
|
473
|
+
}
|
|
474
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: RouterService, decorators: [{
|
|
475
|
+
type: Injectable,
|
|
476
|
+
args: [{
|
|
477
|
+
providedIn: 'root',
|
|
478
|
+
}]
|
|
479
479
|
}] });
|
|
480
480
|
|
|
481
|
-
const VCOMPLY_LOGO_URL = 'https://cdn.v-comply.com/logo/prod/v-logo.svg';
|
|
482
|
-
const API_TIMEOUT_TIME = 1000 * 15;
|
|
483
|
-
const ORGANISATION_NAME = 'VCOMPLY TECHNOLOGIES, INC.';
|
|
484
|
-
const ERROR_FEATURE_FLAG = 'ff_error_handling';
|
|
485
|
-
const ERROR_CONFIG = {
|
|
486
|
-
PAGE_NOT_FOUND: {
|
|
487
|
-
imageUrl: 'https://cdn.v-comply.com/application/images/Error-page-illustration.svg',
|
|
488
|
-
title: 'Oops!',
|
|
489
|
-
description: "The page you're looking for doesn't exist.",
|
|
490
|
-
details: 'Please check the URL or return to the homepage.',
|
|
491
|
-
buttonText: 'GO TO DASHBOARD',
|
|
492
|
-
},
|
|
493
|
-
UNAUTHORIZED: {
|
|
494
|
-
imageUrl: 'https://cdn.v-comply.com/application/images/Error-page-illustration.svg',
|
|
495
|
-
title: 'Oops!',
|
|
496
|
-
description: "You don't have permission to access this page.",
|
|
497
|
-
details: 'If you believe this is an error, please contact',
|
|
498
|
-
email: 'help@v-comply.com',
|
|
499
|
-
support: 'for support',
|
|
500
|
-
buttonText: 'CONTACT SUPPORT',
|
|
501
|
-
mail: 'mailto:help@v-comply.com',
|
|
502
|
-
},
|
|
503
|
-
SESSION_EXPIRED: {
|
|
504
|
-
heading: 'Session Expired!',
|
|
505
|
-
description: 'Your session has expired. Please log in again to continue using the app.',
|
|
506
|
-
buttonText: 'LOGIN',
|
|
507
|
-
},
|
|
508
|
-
CHUNK_UNAVAILABLE: {
|
|
509
|
-
heading: 'Oops!',
|
|
510
|
-
description: 'Something went wrong. Please refresh the page or try again later.',
|
|
511
|
-
buttonText: 'REFRESH',
|
|
512
|
-
},
|
|
513
|
-
SERVER_ERROR: {
|
|
514
|
-
imageUrl: 'https://cdn.v-comply.com/application/images/Error-page-illustration.svg',
|
|
515
|
-
title: 'Oops!',
|
|
516
|
-
description: 'We are unable to load the data.',
|
|
517
|
-
details: 'Please refresh this page or try again later.',
|
|
518
|
-
buttonText: 'REFRESH',
|
|
519
|
-
snackBarMessage: `Oops! Something went wrong. Please try again later.`,
|
|
520
|
-
},
|
|
521
|
-
COMPONENT_LEVEL_SERVER_ERROR: {
|
|
522
|
-
imageUrl: 'https://cdn.v-comply.com/application/images/sad-emoji-icon.svg',
|
|
523
|
-
title: 'Oops!',
|
|
524
|
-
description: 'We are unable to load the data.',
|
|
525
|
-
details: 'Please refresh this section or try again later.',
|
|
526
|
-
buttonText: 'RETRY',
|
|
527
|
-
},
|
|
528
|
-
NETWORK_UNAVAILABLE: {
|
|
529
|
-
offlineMessage: "You're currently offline. Please check your internet connection and try again.",
|
|
530
|
-
},
|
|
531
|
-
};
|
|
532
|
-
const REDIRECTION_URL = {
|
|
533
|
-
compliance_dashboard: '/global-dashboard/compliance_dashboard',
|
|
534
|
-
};
|
|
535
|
-
const MODAL_ERROR_TYPES = {
|
|
536
|
-
CHUNK_NOT_FOUND: 'chunk_not_found',
|
|
537
|
-
SESSION_EXPIRED: 'session_expired',
|
|
538
|
-
};
|
|
539
|
-
const ALT_IMAGE_TEXT = {
|
|
540
|
-
ERROR_IMAGE: 'Error Image',
|
|
541
|
-
VCOMPLY_LOGO: 'VComply',
|
|
481
|
+
const VCOMPLY_LOGO_URL = 'https://cdn.v-comply.com/logo/prod/v-logo.svg';
|
|
482
|
+
const API_TIMEOUT_TIME = 1000 * 15;
|
|
483
|
+
const ORGANISATION_NAME = 'VCOMPLY TECHNOLOGIES, INC.';
|
|
484
|
+
const ERROR_FEATURE_FLAG = 'ff_error_handling';
|
|
485
|
+
const ERROR_CONFIG = {
|
|
486
|
+
PAGE_NOT_FOUND: {
|
|
487
|
+
imageUrl: 'https://cdn.v-comply.com/application/images/Error-page-illustration.svg',
|
|
488
|
+
title: 'Oops!',
|
|
489
|
+
description: "The page you're looking for doesn't exist.",
|
|
490
|
+
details: 'Please check the URL or return to the homepage.',
|
|
491
|
+
buttonText: 'GO TO DASHBOARD',
|
|
492
|
+
},
|
|
493
|
+
UNAUTHORIZED: {
|
|
494
|
+
imageUrl: 'https://cdn.v-comply.com/application/images/Error-page-illustration.svg',
|
|
495
|
+
title: 'Oops!',
|
|
496
|
+
description: "You don't have permission to access this page.",
|
|
497
|
+
details: 'If you believe this is an error, please contact',
|
|
498
|
+
email: 'help@v-comply.com',
|
|
499
|
+
support: 'for support',
|
|
500
|
+
buttonText: 'CONTACT SUPPORT',
|
|
501
|
+
mail: 'mailto:help@v-comply.com',
|
|
502
|
+
},
|
|
503
|
+
SESSION_EXPIRED: {
|
|
504
|
+
heading: 'Session Expired!',
|
|
505
|
+
description: 'Your session has expired. Please log in again to continue using the app.',
|
|
506
|
+
buttonText: 'LOGIN',
|
|
507
|
+
},
|
|
508
|
+
CHUNK_UNAVAILABLE: {
|
|
509
|
+
heading: 'Oops!',
|
|
510
|
+
description: 'Something went wrong. Please refresh the page or try again later.',
|
|
511
|
+
buttonText: 'REFRESH',
|
|
512
|
+
},
|
|
513
|
+
SERVER_ERROR: {
|
|
514
|
+
imageUrl: 'https://cdn.v-comply.com/application/images/Error-page-illustration.svg',
|
|
515
|
+
title: 'Oops!',
|
|
516
|
+
description: 'We are unable to load the data.',
|
|
517
|
+
details: 'Please refresh this page or try again later.',
|
|
518
|
+
buttonText: 'REFRESH',
|
|
519
|
+
snackBarMessage: `Oops! Something went wrong. Please try again later.`,
|
|
520
|
+
},
|
|
521
|
+
COMPONENT_LEVEL_SERVER_ERROR: {
|
|
522
|
+
imageUrl: 'https://cdn.v-comply.com/application/images/sad-emoji-icon.svg',
|
|
523
|
+
title: 'Oops!',
|
|
524
|
+
description: 'We are unable to load the data.',
|
|
525
|
+
details: 'Please refresh this section or try again later.',
|
|
526
|
+
buttonText: 'RETRY',
|
|
527
|
+
},
|
|
528
|
+
NETWORK_UNAVAILABLE: {
|
|
529
|
+
offlineMessage: "You're currently offline. Please check your internet connection and try again.",
|
|
530
|
+
},
|
|
531
|
+
};
|
|
532
|
+
const REDIRECTION_URL = {
|
|
533
|
+
compliance_dashboard: '/global-dashboard/compliance_dashboard',
|
|
534
|
+
};
|
|
535
|
+
const MODAL_ERROR_TYPES = {
|
|
536
|
+
CHUNK_NOT_FOUND: 'chunk_not_found',
|
|
537
|
+
SESSION_EXPIRED: 'session_expired',
|
|
538
|
+
};
|
|
539
|
+
const ALT_IMAGE_TEXT = {
|
|
540
|
+
ERROR_IMAGE: 'Error Image',
|
|
541
|
+
VCOMPLY_LOGO: 'VComply',
|
|
542
542
|
};
|
|
543
543
|
|
|
544
|
-
class SnackBarComponent {
|
|
545
|
-
constructor(snackbarService) {
|
|
546
|
-
this.snackbarService = snackbarService;
|
|
547
|
-
this.show = false;
|
|
548
|
-
this.message = '--';
|
|
549
|
-
this.icon = '';
|
|
550
|
-
this.type = 'alert';
|
|
551
|
-
this.icons = {
|
|
552
|
-
success: '',
|
|
553
|
-
warning: '',
|
|
554
|
-
info: '',
|
|
555
|
-
alert: '',
|
|
556
|
-
error: '',
|
|
557
|
-
};
|
|
558
|
-
}
|
|
559
|
-
ngOnInit() {
|
|
560
|
-
this.snackbarSubscription = this.snackbarService.snackbarState.subscribe((state) => {
|
|
561
|
-
if (state.icon && Object.keys(this.icons).includes(state?.icon)) {
|
|
562
|
-
this.icon = this.icons[state.icon];
|
|
563
|
-
this.type = state?.icon;
|
|
564
|
-
}
|
|
565
|
-
this.message = state.message;
|
|
566
|
-
this.show = state.show;
|
|
567
|
-
});
|
|
568
|
-
}
|
|
569
|
-
setAutoClose() {
|
|
570
|
-
setTimeout(() => {
|
|
571
|
-
this.show = false;
|
|
572
|
-
this.close();
|
|
573
|
-
}, 3000);
|
|
574
|
-
}
|
|
575
|
-
close() {
|
|
576
|
-
this.show = false;
|
|
577
|
-
this.snackbarService.hide();
|
|
578
|
-
}
|
|
579
|
-
ngOnDestroy() {
|
|
580
|
-
this.snackbarSubscription.unsubscribe();
|
|
581
|
-
}
|
|
582
|
-
}
|
|
583
|
-
|
|
584
|
-
SnackBarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: SnackBarComponent, selector: "app-snack-bar", ngImport: i0, template: "<div class=\"workflow-snackbar\" *ngIf=\"show\">\r\n <div class=\"workflow-snackbar-inner\">\r\n <div class=\"workflow-snackbarText\">\r\n <!--  -->\r\n <i class=\"icons\" [class]=\"type\" [innerHTML]=\"icon\"></i> <span [innerHTML]=\"message\">{{ message }}</span>\r\n </div>\r\n <button (click)=\"close()\">[ <span>Close</span> ]</button>\r\n </div>\r\n </div>", styles: ["::ng-deep .workflow-snackbar{position:fixed;top:20px;left:0;right:0;display:flex;align-items:center;justify-content:center;z-index:2147483647!important;pointer-events:none;animation:slide-top .3s cubic-bezier(.25,.46,.45,.94) both}::ng-deep .workflow-snackbar.white{background-color:#fff;color:#000;z-index:20}::ng-deep .workflow-snackbar.white button{color:#f6882f;font-size:11px;font-weight:400;pointer-events:all}::ng-deep .workflow-snackbar .workflow-snackbar-inner{display:flex;max-width:500px;min-width:450px;align-items:center;justify-content:space-between;padding:10px;background:#ffffff;border-radius:3px;box-shadow:0 0 10px #0003;min-height:55px;pointer-events:auto}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText{color:#161b2f;font-size:13px;display:flex;align-items:center;width:calc(100% - 70px)}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i{background:#f1f1f1;color:#d93b41;border-radius:50px;font-size:16px;width:30px;height:30px;text-align:center;line-height:28px;margin-right:10px;min-width:30px}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.success{color:#34aa44}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.warning{color:#f0b819}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.info{color:#1e5dd3}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.alert,::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.error{color:#d93b41}::ng-deep .workflow-snackbar .workflow-snackbar-inner button{background:transparent;border:none;font-size:11px;padding:0;position:relative;color:#747576;width:65px;text-align:right;cursor:pointer;text-transform:uppercase}::ng-deep .workflow-snackbar .workflow-snackbar-inner button span{color:#1e5dd3;font-weight:500}::ng-deep .workflow-snackbar .workflow-snackbar-inner button:focus{outline:none}@keyframes slide-top{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}\n"], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
585
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: SnackBarComponent, decorators: [{
|
|
586
|
-
type: Component,
|
|
587
|
-
args: [{ selector: 'app-snack-bar', template: "<div class=\"workflow-snackbar\" *ngIf=\"show\">\r\n <div class=\"workflow-snackbar-inner\">\r\n <div class=\"workflow-snackbarText\">\r\n <!--  -->\r\n <i class=\"icons\" [class]=\"type\" [innerHTML]=\"icon\"></i> <span [innerHTML]=\"message\">{{ message }}</span>\r\n </div>\r\n <button (click)=\"close()\">[ <span>Close</span> ]</button>\r\n </div>\r\n </div>", styles: ["::ng-deep .workflow-snackbar{position:fixed;top:20px;left:0;right:0;display:flex;align-items:center;justify-content:center;z-index:2147483647!important;pointer-events:none;animation:slide-top .3s cubic-bezier(.25,.46,.45,.94) both}::ng-deep .workflow-snackbar.white{background-color:#fff;color:#000;z-index:20}::ng-deep .workflow-snackbar.white button{color:#f6882f;font-size:11px;font-weight:400;pointer-events:all}::ng-deep .workflow-snackbar .workflow-snackbar-inner{display:flex;max-width:500px;min-width:450px;align-items:center;justify-content:space-between;padding:10px;background:#ffffff;border-radius:3px;box-shadow:0 0 10px #0003;min-height:55px;pointer-events:auto}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText{color:#161b2f;font-size:13px;display:flex;align-items:center;width:calc(100% - 70px)}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i{background:#f1f1f1;color:#d93b41;border-radius:50px;font-size:16px;width:30px;height:30px;text-align:center;line-height:28px;margin-right:10px;min-width:30px}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.success{color:#34aa44}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.warning{color:#f0b819}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.info{color:#1e5dd3}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.alert,::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.error{color:#d93b41}::ng-deep .workflow-snackbar .workflow-snackbar-inner button{background:transparent;border:none;font-size:11px;padding:0;position:relative;color:#747576;width:65px;text-align:right;cursor:pointer;text-transform:uppercase}::ng-deep .workflow-snackbar .workflow-snackbar-inner button span{color:#1e5dd3;font-weight:500}::ng-deep .workflow-snackbar .workflow-snackbar-inner button:focus{outline:none}@keyframes slide-top{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}\n"] }]
|
|
588
|
-
}], ctorParameters: function () { return [{ type: SnackBarService }]; } });
|
|
589
|
-
|
|
590
|
-
class DialogConfig {
|
|
591
|
-
}
|
|
592
|
-
|
|
593
|
-
class ErrorModalComponent {
|
|
594
|
-
constructor(authService, dialogConfig, routerService) {
|
|
595
|
-
this.authService = authService;
|
|
596
|
-
this.dialogConfig = dialogConfig;
|
|
597
|
-
this.routerService = routerService;
|
|
598
|
-
this.errorTypes = MODAL_ERROR_TYPES;
|
|
599
|
-
this.data = {
|
|
600
|
-
heading: 'Message',
|
|
601
|
-
description: 'Description',
|
|
602
|
-
buttonText: 'Click Action',
|
|
603
|
-
};
|
|
604
|
-
this.setDataConfig();
|
|
605
|
-
}
|
|
606
|
-
setDataConfig() {
|
|
607
|
-
this.data = this.dialogConfig.data?.errorConfig;
|
|
608
|
-
this.errorType = this.dialogConfig.data?.errorType;
|
|
609
|
-
}
|
|
610
|
-
onContinueAction() {
|
|
611
|
-
switch (this.errorType) {
|
|
612
|
-
case this.errorTypes.SESSION_EXPIRED:
|
|
613
|
-
this.authService.logout();
|
|
614
|
-
this.routerService.redirectToLogin();
|
|
615
|
-
break;
|
|
616
|
-
case this.errorTypes.CHUNK_NOT_FOUND:
|
|
617
|
-
window.location.reload();
|
|
618
|
-
break;
|
|
619
|
-
}
|
|
620
|
-
}
|
|
621
|
-
}
|
|
622
|
-
ErrorModalComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: ErrorModalComponent, deps: [{ token: i1.AuthorizerService }, { token: DialogConfig }, { token: RouterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
623
|
-
ErrorModalComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: ErrorModalComponent, selector: "lib-vc-error-modal", inputs: { errorType: "errorType" }, ngImport: i0, template: ` <div class="error-dialog-box">
|
|
624
|
-
<div class="error-dialog-box-top">{{ data.heading }}</div>
|
|
625
|
-
<div class="error-dialog-box-mid">
|
|
626
|
-
{{ data.description }}
|
|
627
|
-
</div>
|
|
628
|
-
<div class="error-dialog-box-bottom">
|
|
629
|
-
<button (click)="onContinueAction()" class="logIn-btn">
|
|
630
|
-
{{ data.buttonText }}
|
|
631
|
-
</button>
|
|
632
|
-
</div>
|
|
633
|
-
</div>`, isInline: true, styles: [".error-dialog-box{background:#fff;border-radius:.75rem;box-shadow:0 1px 10px #0003;width:27rem}.error-dialog-box-top{color:#000;font-size:16px;font-weight:500;border-radius:.75rem .75rem 0 0;display:flex;align-items:center;height:3.375rem;padding:0 1rem;margin-bottom:1rem}.error-dialog-box-mid{color:#565a6f;font-size:13px;min-height:5.5rem;padding:0 1rem}.error-dialog-box-bottom{display:flex;justify-content:end;padding:1rem}.error-dialog-box-bottom button.logIn-btn{background:#1e5dd3;border-radius:.125rem;border:none;color:#fff;cursor:pointer;font-size:11px;height:2rem;padding:.5rem .75rem}\n"] });
|
|
634
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: ErrorModalComponent, decorators: [{
|
|
635
|
-
type: Component,
|
|
636
|
-
args: [{ selector: 'lib-vc-error-modal', template: ` <div class="error-dialog-box">
|
|
637
|
-
<div class="error-dialog-box-top">{{ data.heading }}</div>
|
|
638
|
-
<div class="error-dialog-box-mid">
|
|
639
|
-
{{ data.description }}
|
|
640
|
-
</div>
|
|
641
|
-
<div class="error-dialog-box-bottom">
|
|
642
|
-
<button (click)="onContinueAction()" class="logIn-btn">
|
|
643
|
-
{{ data.buttonText }}
|
|
644
|
-
</button>
|
|
645
|
-
</div>
|
|
646
|
-
</div>`, styles: [".error-dialog-box{background:#fff;border-radius:.75rem;box-shadow:0 1px 10px #0003;width:27rem}.error-dialog-box-top{color:#000;font-size:16px;font-weight:500;border-radius:.75rem .75rem 0 0;display:flex;align-items:center;height:3.375rem;padding:0 1rem;margin-bottom:1rem}.error-dialog-box-mid{color:#565a6f;font-size:13px;min-height:5.5rem;padding:0 1rem}.error-dialog-box-bottom{display:flex;justify-content:end;padding:1rem}.error-dialog-box-bottom button.logIn-btn{background:#1e5dd3;border-radius:.125rem;border:none;color:#fff;cursor:pointer;font-size:11px;height:2rem;padding:.5rem .75rem}\n"] }]
|
|
647
|
-
}], ctorParameters: function () { return [{ type: i1.AuthorizerService }, { type: DialogConfig }, { type: RouterService }]; }, propDecorators: { errorType: [{
|
|
648
|
-
type: Input
|
|
649
|
-
}] } });
|
|
650
|
-
|
|
651
|
-
class InsertionDirective {
|
|
652
|
-
constructor(viewContainerRef) {
|
|
653
|
-
this.viewContainerRef = viewContainerRef;
|
|
654
|
-
}
|
|
655
|
-
}
|
|
656
|
-
InsertionDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: InsertionDirective, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
657
|
-
InsertionDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.0.1", type: InsertionDirective, selector: "[appInsertion]", ngImport: i0 });
|
|
658
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: InsertionDirective, decorators: [{
|
|
659
|
-
type: Directive,
|
|
660
|
-
args: [{
|
|
661
|
-
selector: '[appInsertion]',
|
|
662
|
-
}]
|
|
663
|
-
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; } });
|
|
664
|
-
|
|
665
|
-
class DialogRef {
|
|
666
|
-
constructor() {
|
|
667
|
-
this.afterDialogClosed = new Subject();
|
|
668
|
-
this.afterClosed = this.afterDialogClosed.asObservable();
|
|
669
|
-
}
|
|
670
|
-
close(result) {
|
|
671
|
-
// debugger
|
|
672
|
-
this.afterDialogClosed.next(result);
|
|
673
|
-
document.body.style.overflow = 'auto';
|
|
674
|
-
}
|
|
675
|
-
}
|
|
676
|
-
|
|
677
|
-
class DialogComponent {
|
|
678
|
-
constructor(componentFactoryResolver, cd, dialogRef, config, router) {
|
|
679
|
-
this.componentFactoryResolver = componentFactoryResolver;
|
|
680
|
-
this.cd = cd;
|
|
681
|
-
this.dialogRef = dialogRef;
|
|
682
|
-
this.config = config;
|
|
683
|
-
this.router = router;
|
|
684
|
-
this.animation = true;
|
|
685
|
-
this.onDialogClose = new Subject();
|
|
686
|
-
this.onClose = this.onDialogClose.asObservable();
|
|
687
|
-
// this.componentRef = this.componentRef;
|
|
688
|
-
// this.animate = this.animate;
|
|
689
|
-
// this.insertionPoint = this.insertionPoint;
|
|
690
|
-
// this.childComponentType = this.childComponentType;
|
|
691
|
-
}
|
|
692
|
-
ngOnInit() {
|
|
693
|
-
this.position = this.config.position;
|
|
694
|
-
this.background = this.config.background;
|
|
695
|
-
document.body.style.overflow = 'hidden';
|
|
696
|
-
setTimeout(() => {
|
|
697
|
-
this.animation = false;
|
|
698
|
-
}, 200);
|
|
699
|
-
this.routeAction();
|
|
700
|
-
}
|
|
701
|
-
routeAction() {
|
|
702
|
-
this.router.events.subscribe((event) => {
|
|
703
|
-
if (event instanceof NavigationStart) {
|
|
704
|
-
// Show loading indicator
|
|
705
|
-
}
|
|
706
|
-
if (event instanceof NavigationEnd) {
|
|
707
|
-
// Hide loading indicator
|
|
708
|
-
this.dialogRef.close();
|
|
709
|
-
}
|
|
710
|
-
if (event instanceof NavigationError) {
|
|
711
|
-
// Hide loading indicator
|
|
712
|
-
// Present error to user
|
|
713
|
-
}
|
|
714
|
-
});
|
|
715
|
-
}
|
|
716
|
-
ngAfterViewInit() {
|
|
717
|
-
this.loadChildComponent(this.childComponentType);
|
|
718
|
-
this.cd.detectChanges();
|
|
719
|
-
}
|
|
720
|
-
onOverlayClicked(evt) {
|
|
721
|
-
// this.dialogRef.close();
|
|
722
|
-
}
|
|
723
|
-
onDialogClicked(evt) {
|
|
724
|
-
evt.stopPropagation();
|
|
725
|
-
}
|
|
726
|
-
loadChildComponent(componentType) {
|
|
727
|
-
const componentFactory = this.componentFactoryResolver.resolveComponentFactory(componentType);
|
|
728
|
-
const viewContainerRef = this.insertionPoint.viewContainerRef;
|
|
729
|
-
viewContainerRef.clear();
|
|
730
|
-
this.componentRef = viewContainerRef.createComponent(componentFactory);
|
|
731
|
-
}
|
|
732
|
-
ngOnDestroy() {
|
|
733
|
-
if (this.componentRef) {
|
|
734
|
-
this.componentRef.destroy();
|
|
735
|
-
}
|
|
736
|
-
}
|
|
737
|
-
close(data) {
|
|
738
|
-
this.onDialogClose.next(data);
|
|
739
|
-
document.body.style.overflow = 'auto';
|
|
740
|
-
}
|
|
741
|
-
}
|
|
742
|
-
DialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogComponent, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ChangeDetectorRef }, { token: DialogRef }, { token: DialogConfig }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Component });
|
|
743
|
-
DialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: DialogComponent, selector: "app-dialog", viewQueries: [{ propertyName: "insertionPoint", first: true, predicate: InsertionDirective, descendants: true, static: true }], ngImport: i0, template: "<div\r\n class=\"overlay\"\r\n (click)=\"onOverlayClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER',\r\n black: background === 'black',\r\n whiteBlur: background === 'whiteBlur'\r\n }\" [class.pointer-none]=\"pointer === 'none'\"\r\n>\r\n <div\r\n class=\"dialog\"\r\n [class.animate]=\"animation\"\r\n (click)=\"onDialogClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER'\r\n }\"\r\n >\r\n <ng-template appInsertion></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".overlay{display:flex;position:fixed;top:0;bottom:0;left:0;right:0;align-items:center;justify-content:center;z-index:2147483009!important}.overlay.low{z-index:1}.overlay.black{background:#161b2fcc}.overlay.whiteBlur{-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.overlay.top{align-items:flex-start}.overlay.right{justify-content:flex-end}.overlay.bottom{align-items:flex-end}.overlay.left{justify-content:flex-start}.dialog{position:relative}.dialog.animate.top{animation:animate-top .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-top{0%{transform:translateY(-100px)}to{transform:translateY(0)}}.dialog.animate.right{animation:animate-right .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-right{0%{transform:translate(100%)}to{transform:translate(0)}}.pointer-none{pointer-events:none}\n"], directives: [{ type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: InsertionDirective, selector: "[appInsertion]" }] });
|
|
744
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogComponent, decorators: [{
|
|
745
|
-
type: Component,
|
|
746
|
-
args: [{ selector: 'app-dialog', template: "<div\r\n class=\"overlay\"\r\n (click)=\"onOverlayClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER',\r\n black: background === 'black',\r\n whiteBlur: background === 'whiteBlur'\r\n }\" [class.pointer-none]=\"pointer === 'none'\"\r\n>\r\n <div\r\n class=\"dialog\"\r\n [class.animate]=\"animation\"\r\n (click)=\"onDialogClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER'\r\n }\"\r\n >\r\n <ng-template appInsertion></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".overlay{display:flex;position:fixed;top:0;bottom:0;left:0;right:0;align-items:center;justify-content:center;z-index:2147483009!important}.overlay.low{z-index:1}.overlay.black{background:#161b2fcc}.overlay.whiteBlur{-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.overlay.top{align-items:flex-start}.overlay.right{justify-content:flex-end}.overlay.bottom{align-items:flex-end}.overlay.left{justify-content:flex-start}.dialog{position:relative}.dialog.animate.top{animation:animate-top .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-top{0%{transform:translateY(-100px)}to{transform:translateY(0)}}.dialog.animate.right{animation:animate-right .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-right{0%{transform:translate(100%)}to{transform:translate(0)}}.pointer-none{pointer-events:none}\n"] }]
|
|
747
|
-
}], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ChangeDetectorRef }, { type: DialogRef }, { type: DialogConfig }, { type: i3.Router }]; }, propDecorators: { insertionPoint: [{
|
|
748
|
-
type: ViewChild,
|
|
749
|
-
args: [InsertionDirective, { static: true }]
|
|
750
|
-
}] } });
|
|
751
|
-
|
|
752
|
-
class DialogModule {
|
|
753
|
-
}
|
|
754
|
-
DialogModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
755
|
-
DialogModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogModule, declarations: [DialogComponent, InsertionDirective], imports: [CommonModule], exports: [DialogComponent] });
|
|
756
|
-
DialogModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogModule, providers: [DialogRef], imports: [[CommonModule]] });
|
|
757
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogModule, decorators: [{
|
|
758
|
-
type: NgModule,
|
|
759
|
-
args: [{
|
|
760
|
-
imports: [CommonModule],
|
|
761
|
-
declarations: [DialogComponent, InsertionDirective],
|
|
762
|
-
providers: [DialogRef],
|
|
763
|
-
exports: [DialogComponent]
|
|
764
|
-
}]
|
|
765
|
-
}] });
|
|
766
|
-
|
|
767
|
-
class DialogInjector {
|
|
768
|
-
constructor(parentDialogInjector, dialogAdditionalTokens) {
|
|
769
|
-
this.parentDialogInjector = parentDialogInjector;
|
|
770
|
-
this.dialogAdditionalTokens = dialogAdditionalTokens;
|
|
771
|
-
}
|
|
772
|
-
// get(token: any, notFoundValue?: any){return; }
|
|
773
|
-
get(token, notFoundValue, flags) {
|
|
774
|
-
const value = this.dialogAdditionalTokens.get(token);
|
|
775
|
-
if (value) {
|
|
776
|
-
return value;
|
|
777
|
-
}
|
|
778
|
-
return this.parentDialogInjector.get(token, notFoundValue);
|
|
779
|
-
}
|
|
544
|
+
class SnackBarComponent {
|
|
545
|
+
constructor(snackbarService) {
|
|
546
|
+
this.snackbarService = snackbarService;
|
|
547
|
+
this.show = false;
|
|
548
|
+
this.message = '--';
|
|
549
|
+
this.icon = '';
|
|
550
|
+
this.type = 'alert';
|
|
551
|
+
this.icons = {
|
|
552
|
+
success: '',
|
|
553
|
+
warning: '',
|
|
554
|
+
info: '',
|
|
555
|
+
alert: '',
|
|
556
|
+
error: '',
|
|
557
|
+
};
|
|
558
|
+
}
|
|
559
|
+
ngOnInit() {
|
|
560
|
+
this.snackbarSubscription = this.snackbarService.snackbarState.subscribe((state) => {
|
|
561
|
+
if (state.icon && Object.keys(this.icons).includes(state?.icon)) {
|
|
562
|
+
this.icon = this.icons[state.icon];
|
|
563
|
+
this.type = state?.icon;
|
|
564
|
+
}
|
|
565
|
+
this.message = state.message;
|
|
566
|
+
this.show = state.show;
|
|
567
|
+
});
|
|
568
|
+
}
|
|
569
|
+
setAutoClose() {
|
|
570
|
+
setTimeout(() => {
|
|
571
|
+
this.show = false;
|
|
572
|
+
this.close();
|
|
573
|
+
}, 3000);
|
|
574
|
+
}
|
|
575
|
+
close() {
|
|
576
|
+
this.show = false;
|
|
577
|
+
this.snackbarService.hide();
|
|
578
|
+
}
|
|
579
|
+
ngOnDestroy() {
|
|
580
|
+
this.snackbarSubscription.unsubscribe();
|
|
581
|
+
}
|
|
582
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarComponent, deps: [{ token: SnackBarService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
583
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: SnackBarComponent, selector: "app-snack-bar", ngImport: i0, template: "<div class=\"workflow-snackbar\" *ngIf=\"show\">\r\n <div class=\"workflow-snackbar-inner\">\r\n <div class=\"workflow-snackbarText\">\r\n <!--  -->\r\n <i class=\"icons\" [class]=\"type\" [innerHTML]=\"icon\"></i> <span [innerHTML]=\"message\">{{ message }}</span>\r\n </div>\r\n <button (click)=\"close()\">[ <span>Close</span> ]</button>\r\n </div>\r\n </div>", styles: ["::ng-deep .workflow-snackbar{position:fixed;top:20px;left:0;right:0;display:flex;align-items:center;justify-content:center;z-index:2147483647!important;pointer-events:none;animation:slide-top .3s cubic-bezier(.25,.46,.45,.94) both}::ng-deep .workflow-snackbar.white{background-color:#fff;color:#000;z-index:20}::ng-deep .workflow-snackbar.white button{color:#f6882f;font-size:11px;font-weight:400;pointer-events:all}::ng-deep .workflow-snackbar .workflow-snackbar-inner{display:flex;max-width:500px;min-width:450px;align-items:center;justify-content:space-between;padding:10px;background:#fff;border-radius:3px;box-shadow:0 0 10px #0003;min-height:55px;pointer-events:auto}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText{color:#161b2f;font-size:13px;display:flex;align-items:center;width:calc(100% - 70px)}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i{background:#f1f1f1;color:#d93b41;border-radius:50px;font-size:16px;width:30px;height:30px;text-align:center;line-height:28px;margin-right:10px;min-width:30px}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.success{color:#34aa44}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.warning{color:#f0b819}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.info{color:#1e5dd3}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.alert{color:#d93b41}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.error{color:#d93b41}::ng-deep .workflow-snackbar .workflow-snackbar-inner button{background:transparent;border:none;font-size:11px;padding:0;position:relative;color:#747576;width:65px;text-align:right;cursor:pointer;text-transform:uppercase}::ng-deep .workflow-snackbar .workflow-snackbar-inner button span{color:#1e5dd3;font-weight:500}::ng-deep .workflow-snackbar .workflow-snackbar-inner button:focus{outline:none}@keyframes slide-top{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] }); }
|
|
780
584
|
}
|
|
585
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarComponent, decorators: [{
|
|
586
|
+
type: Component,
|
|
587
|
+
args: [{ selector: 'app-snack-bar', template: "<div class=\"workflow-snackbar\" *ngIf=\"show\">\r\n <div class=\"workflow-snackbar-inner\">\r\n <div class=\"workflow-snackbarText\">\r\n <!--  -->\r\n <i class=\"icons\" [class]=\"type\" [innerHTML]=\"icon\"></i> <span [innerHTML]=\"message\">{{ message }}</span>\r\n </div>\r\n <button (click)=\"close()\">[ <span>Close</span> ]</button>\r\n </div>\r\n </div>", styles: ["::ng-deep .workflow-snackbar{position:fixed;top:20px;left:0;right:0;display:flex;align-items:center;justify-content:center;z-index:2147483647!important;pointer-events:none;animation:slide-top .3s cubic-bezier(.25,.46,.45,.94) both}::ng-deep .workflow-snackbar.white{background-color:#fff;color:#000;z-index:20}::ng-deep .workflow-snackbar.white button{color:#f6882f;font-size:11px;font-weight:400;pointer-events:all}::ng-deep .workflow-snackbar .workflow-snackbar-inner{display:flex;max-width:500px;min-width:450px;align-items:center;justify-content:space-between;padding:10px;background:#fff;border-radius:3px;box-shadow:0 0 10px #0003;min-height:55px;pointer-events:auto}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText{color:#161b2f;font-size:13px;display:flex;align-items:center;width:calc(100% - 70px)}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i{background:#f1f1f1;color:#d93b41;border-radius:50px;font-size:16px;width:30px;height:30px;text-align:center;line-height:28px;margin-right:10px;min-width:30px}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.success{color:#34aa44}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.warning{color:#f0b819}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.info{color:#1e5dd3}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.alert{color:#d93b41}::ng-deep .workflow-snackbar .workflow-snackbar-inner .workflow-snackbarText i.error{color:#d93b41}::ng-deep .workflow-snackbar .workflow-snackbar-inner button{background:transparent;border:none;font-size:11px;padding:0;position:relative;color:#747576;width:65px;text-align:right;cursor:pointer;text-transform:uppercase}::ng-deep .workflow-snackbar .workflow-snackbar-inner button span{color:#1e5dd3;font-weight:500}::ng-deep .workflow-snackbar .workflow-snackbar-inner button:focus{outline:none}@keyframes slide-top{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}\n"] }]
|
|
588
|
+
}], ctorParameters: function () { return [{ type: SnackBarService }]; } });
|
|
781
589
|
|
|
782
|
-
class
|
|
783
|
-
constructor(
|
|
784
|
-
this.
|
|
785
|
-
this.
|
|
786
|
-
this.
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
}
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
map.set(DialogConfig, config);
|
|
796
|
-
const dialogRef = new DialogRef();
|
|
797
|
-
map.set(DialogRef, dialogRef);
|
|
798
|
-
const sub = dialogRef.afterClosed.subscribe(() => {
|
|
799
|
-
this.removeDialogComponentFromBody();
|
|
800
|
-
sub.unsubscribe();
|
|
801
|
-
});
|
|
802
|
-
const componentFactory = this.componentFactoryResolver.resolveComponentFactory(DialogComponent);
|
|
803
|
-
const componentRef = componentFactory.create(new DialogInjector(this.injector, map));
|
|
804
|
-
this.appRef.attachView(componentRef.hostView);
|
|
805
|
-
const domElem = componentRef.hostView.rootNodes[0];
|
|
806
|
-
document.body.appendChild(domElem);
|
|
807
|
-
this.dialogComponentRef = componentRef;
|
|
808
|
-
this.dialogComponentRef.instance.onClose.subscribe(() => {
|
|
809
|
-
this.removeDialogComponentFromBody();
|
|
810
|
-
});
|
|
811
|
-
return dialogRef;
|
|
812
|
-
}
|
|
813
|
-
removeDialogComponentFromBody() {
|
|
814
|
-
this.appRef.detachView(this.dialogComponentRef.hostView);
|
|
815
|
-
this.dialogComponentRef.destroy();
|
|
816
|
-
}
|
|
817
|
-
}
|
|
818
|
-
DialogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogService, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ApplicationRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
819
|
-
DialogService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogService, providedIn: DialogModule });
|
|
820
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: DialogService, decorators: [{
|
|
821
|
-
type: Injectable,
|
|
822
|
-
args: [{
|
|
823
|
-
providedIn: DialogModule,
|
|
824
|
-
}]
|
|
825
|
-
}], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ApplicationRef }, { type: i0.Injector }]; } });
|
|
826
|
-
|
|
827
|
-
class SessionExpiredComponent {
|
|
828
|
-
constructor(dialogService) {
|
|
829
|
-
this.dialogService = dialogService;
|
|
830
|
-
this.errorConfig = ERROR_CONFIG.SESSION_EXPIRED;
|
|
831
|
-
this.errorTypes = MODAL_ERROR_TYPES;
|
|
832
|
-
}
|
|
833
|
-
ngOnInit() {
|
|
834
|
-
this.openSessionExpiredModal();
|
|
835
|
-
}
|
|
836
|
-
openSessionExpiredModal() {
|
|
837
|
-
this.dialogService.open(ErrorModalComponent, {
|
|
838
|
-
data: {
|
|
839
|
-
errorType: this.errorTypes.SESSION_EXPIRED,
|
|
840
|
-
errorConfig: this.errorConfig,
|
|
841
|
-
},
|
|
842
|
-
position: 'center',
|
|
843
|
-
background: 'whiteBlur',
|
|
844
|
-
});
|
|
845
|
-
}
|
|
846
|
-
}
|
|
847
|
-
SessionExpiredComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: SessionExpiredComponent, deps: [{ token: DialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
848
|
-
SessionExpiredComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: SessionExpiredComponent, selector: "lib-vc-error-session-expired", ngImport: i0, template: ``, isInline: true });
|
|
849
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: SessionExpiredComponent, decorators: [{
|
|
850
|
-
type: Component,
|
|
851
|
-
args: [{
|
|
852
|
-
selector: 'lib-vc-error-session-expired',
|
|
853
|
-
template: ``,
|
|
854
|
-
}]
|
|
855
|
-
}], ctorParameters: function () { return [{ type: DialogService }]; } });
|
|
856
|
-
|
|
857
|
-
class UnauthorizedComponent {
|
|
858
|
-
constructor() {
|
|
859
|
-
this.currentYear = new Date().getFullYear();
|
|
860
|
-
this.errorConfig = ERROR_CONFIG.UNAUTHORIZED;
|
|
861
|
-
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
862
|
-
this.altImageText = ALT_IMAGE_TEXT;
|
|
863
|
-
this.organisationName = ORGANISATION_NAME;
|
|
864
|
-
}
|
|
865
|
-
redirectToSupport() {
|
|
866
|
-
window.location.href = this.errorConfig.mail;
|
|
867
|
-
}
|
|
868
|
-
}
|
|
869
|
-
UnauthorizedComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: UnauthorizedComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
870
|
-
UnauthorizedComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: UnauthorizedComponent, selector: "lib-vc-error-unauthorized", ngImport: i0, template: `
|
|
590
|
+
class UnauthorizedComponent {
|
|
591
|
+
constructor() {
|
|
592
|
+
this.currentYear = new Date().getFullYear();
|
|
593
|
+
this.errorConfig = ERROR_CONFIG.UNAUTHORIZED;
|
|
594
|
+
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
595
|
+
this.altImageText = ALT_IMAGE_TEXT;
|
|
596
|
+
this.organisationName = ORGANISATION_NAME;
|
|
597
|
+
}
|
|
598
|
+
redirectToSupport() {
|
|
599
|
+
window.location.href = this.errorConfig.mail;
|
|
600
|
+
}
|
|
601
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UnauthorizedComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
602
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: UnauthorizedComponent, selector: "lib-vc-error-unauthorized", ngImport: i0, template: `
|
|
871
603
|
<div class="errorPage">
|
|
872
604
|
<div class="errorPage-top">
|
|
873
605
|
<img
|
|
874
|
-
[
|
|
606
|
+
[ngSrc]="VcomplyLogo"
|
|
875
607
|
[alt]="altImageText.VCOMPLY_LOGO"
|
|
876
608
|
width="24"
|
|
877
609
|
height="24"
|
|
@@ -881,7 +613,7 @@ UnauthorizedComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
881
613
|
<div class="errorPage-inner">
|
|
882
614
|
<div class="errorPage-inner-image">
|
|
883
615
|
<img
|
|
884
|
-
[
|
|
616
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
885
617
|
[alt]="altImageText.ERROR_IMAGE"
|
|
886
618
|
width="246"
|
|
887
619
|
height="178"
|
|
@@ -907,14 +639,15 @@ UnauthorizedComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
907
639
|
</div>
|
|
908
640
|
</div>
|
|
909
641
|
</div>
|
|
910
|
-
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:
|
|
911
|
-
|
|
912
|
-
|
|
642
|
+
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:700;line-height:110px;margin-bottom:1.5rem}.errorPage-inner-right .errorPage-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.errorPage-inner-right .errorPage-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:1.75rem}.errorPage-inner-right .errorPage-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.errorPage-inner-right .errorPage-btn i{font-size:14px;margin-left:.25rem}.errorPage-copyright{font-size:11px;color:#787a8c;font-weight:500;position:absolute;bottom:8px;right:16px;line-height:16px}\n"], dependencies: [{ kind: "directive", type: i1.NgOptimizedImage, selector: "img[ngSrc]", inputs: ["ngSrc", "ngSrcset", "sizes", "width", "height", "loading", "priority", "loaderParams", "disableOptimizedSrcset", "fill", "src", "srcset"] }] }); }
|
|
643
|
+
}
|
|
644
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: UnauthorizedComponent, decorators: [{
|
|
645
|
+
type: Component,
|
|
913
646
|
args: [{ selector: 'lib-vc-error-unauthorized', template: `
|
|
914
647
|
<div class="errorPage">
|
|
915
648
|
<div class="errorPage-top">
|
|
916
649
|
<img
|
|
917
|
-
[
|
|
650
|
+
[ngSrc]="VcomplyLogo"
|
|
918
651
|
[alt]="altImageText.VCOMPLY_LOGO"
|
|
919
652
|
width="24"
|
|
920
653
|
height="24"
|
|
@@ -924,7 +657,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
924
657
|
<div class="errorPage-inner">
|
|
925
658
|
<div class="errorPage-inner-image">
|
|
926
659
|
<img
|
|
927
|
-
[
|
|
660
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
928
661
|
[alt]="altImageText.ERROR_IMAGE"
|
|
929
662
|
width="246"
|
|
930
663
|
height="178"
|
|
@@ -950,55 +683,321 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
950
683
|
</div>
|
|
951
684
|
</div>
|
|
952
685
|
</div>
|
|
953
|
-
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:
|
|
686
|
+
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:700;line-height:110px;margin-bottom:1.5rem}.errorPage-inner-right .errorPage-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.errorPage-inner-right .errorPage-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:1.75rem}.errorPage-inner-right .errorPage-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.errorPage-inner-right .errorPage-btn i{font-size:14px;margin-left:.25rem}.errorPage-copyright{font-size:11px;color:#787a8c;font-weight:500;position:absolute;bottom:8px;right:16px;line-height:16px}\n"] }]
|
|
954
687
|
}] });
|
|
955
688
|
|
|
956
|
-
class
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
this.
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
}
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
689
|
+
class DialogConfig {
|
|
690
|
+
}
|
|
691
|
+
|
|
692
|
+
class ErrorModalComponent {
|
|
693
|
+
constructor(authService, dialogConfig, routerService) {
|
|
694
|
+
this.authService = authService;
|
|
695
|
+
this.dialogConfig = dialogConfig;
|
|
696
|
+
this.routerService = routerService;
|
|
697
|
+
this.errorTypes = MODAL_ERROR_TYPES;
|
|
698
|
+
this.data = {
|
|
699
|
+
heading: 'Message',
|
|
700
|
+
description: 'Description',
|
|
701
|
+
buttonText: 'Click Action',
|
|
702
|
+
};
|
|
703
|
+
this.setDataConfig();
|
|
704
|
+
}
|
|
705
|
+
setDataConfig() {
|
|
706
|
+
this.data = this.dialogConfig.data?.errorConfig;
|
|
707
|
+
this.errorType = this.dialogConfig.data?.errorType;
|
|
708
|
+
}
|
|
709
|
+
onContinueAction() {
|
|
710
|
+
switch (this.errorType) {
|
|
711
|
+
case this.errorTypes.SESSION_EXPIRED:
|
|
712
|
+
this.authService.logout();
|
|
713
|
+
this.routerService.redirectToLogin();
|
|
714
|
+
break;
|
|
715
|
+
case this.errorTypes.CHUNK_NOT_FOUND:
|
|
716
|
+
window.location.reload();
|
|
717
|
+
break;
|
|
718
|
+
}
|
|
719
|
+
}
|
|
720
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ErrorModalComponent, deps: [{ token: i1$1.AuthorizerService }, { token: DialogConfig }, { token: RouterService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
721
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ErrorModalComponent, selector: "lib-vc-error-modal", inputs: { errorType: "errorType" }, ngImport: i0, template: ` <div class="error-dialog-box">
|
|
722
|
+
<div class="error-dialog-box-top">{{ data.heading }}</div>
|
|
723
|
+
<div class="error-dialog-box-mid">
|
|
724
|
+
{{ data.description }}
|
|
725
|
+
</div>
|
|
726
|
+
<div class="error-dialog-box-bottom">
|
|
727
|
+
<button (click)="onContinueAction()" class="logIn-btn">
|
|
728
|
+
{{ data.buttonText }}
|
|
729
|
+
</button>
|
|
730
|
+
</div>
|
|
731
|
+
</div>`, isInline: true, styles: [".error-dialog-box{background:#fff;border-radius:.75rem;box-shadow:0 1px 10px #0003;width:27rem}.error-dialog-box-top{color:#000;font-size:16px;font-weight:500;border-radius:.75rem .75rem 0 0;display:flex;align-items:center;height:3.375rem;padding:0 1rem;margin-bottom:1rem}.error-dialog-box-mid{color:#565a6f;font-size:13px;min-height:5.5rem;padding:0 1rem}.error-dialog-box-bottom{display:flex;justify-content:end;padding:1rem}.error-dialog-box-bottom button.logIn-btn{background:#1e5dd3;border-radius:.125rem;border:none;color:#fff;cursor:pointer;font-size:11px;height:2rem;padding:.5rem .75rem}\n"] }); }
|
|
732
|
+
}
|
|
733
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ErrorModalComponent, decorators: [{
|
|
734
|
+
type: Component,
|
|
735
|
+
args: [{ selector: 'lib-vc-error-modal', template: ` <div class="error-dialog-box">
|
|
736
|
+
<div class="error-dialog-box-top">{{ data.heading }}</div>
|
|
737
|
+
<div class="error-dialog-box-mid">
|
|
738
|
+
{{ data.description }}
|
|
739
|
+
</div>
|
|
740
|
+
<div class="error-dialog-box-bottom">
|
|
741
|
+
<button (click)="onContinueAction()" class="logIn-btn">
|
|
742
|
+
{{ data.buttonText }}
|
|
743
|
+
</button>
|
|
744
|
+
</div>
|
|
745
|
+
</div>`, styles: [".error-dialog-box{background:#fff;border-radius:.75rem;box-shadow:0 1px 10px #0003;width:27rem}.error-dialog-box-top{color:#000;font-size:16px;font-weight:500;border-radius:.75rem .75rem 0 0;display:flex;align-items:center;height:3.375rem;padding:0 1rem;margin-bottom:1rem}.error-dialog-box-mid{color:#565a6f;font-size:13px;min-height:5.5rem;padding:0 1rem}.error-dialog-box-bottom{display:flex;justify-content:end;padding:1rem}.error-dialog-box-bottom button.logIn-btn{background:#1e5dd3;border-radius:.125rem;border:none;color:#fff;cursor:pointer;font-size:11px;height:2rem;padding:.5rem .75rem}\n"] }]
|
|
746
|
+
}], ctorParameters: function () { return [{ type: i1$1.AuthorizerService }, { type: DialogConfig }, { type: RouterService }]; }, propDecorators: { errorType: [{
|
|
747
|
+
type: Input
|
|
748
|
+
}] } });
|
|
749
|
+
|
|
750
|
+
class InsertionDirective {
|
|
751
|
+
constructor(viewContainerRef) {
|
|
752
|
+
this.viewContainerRef = viewContainerRef;
|
|
753
|
+
}
|
|
754
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: InsertionDirective, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
755
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: InsertionDirective, selector: "[appInsertion]", ngImport: i0 }); }
|
|
756
|
+
}
|
|
757
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: InsertionDirective, decorators: [{
|
|
758
|
+
type: Directive,
|
|
759
|
+
args: [{
|
|
760
|
+
selector: '[appInsertion]',
|
|
761
|
+
}]
|
|
762
|
+
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; } });
|
|
763
|
+
|
|
764
|
+
class DialogRef {
|
|
765
|
+
constructor() {
|
|
766
|
+
this.afterDialogClosed = new Subject();
|
|
767
|
+
this.afterClosed = this.afterDialogClosed.asObservable();
|
|
768
|
+
}
|
|
769
|
+
close(result) {
|
|
770
|
+
// debugger
|
|
771
|
+
this.afterDialogClosed.next(result);
|
|
772
|
+
document.body.style.overflow = 'auto';
|
|
773
|
+
}
|
|
774
|
+
}
|
|
775
|
+
|
|
776
|
+
class DialogComponent {
|
|
777
|
+
constructor(componentFactoryResolver, cd, dialogRef, config, router) {
|
|
778
|
+
this.componentFactoryResolver = componentFactoryResolver;
|
|
779
|
+
this.cd = cd;
|
|
780
|
+
this.dialogRef = dialogRef;
|
|
781
|
+
this.config = config;
|
|
782
|
+
this.router = router;
|
|
783
|
+
this.animation = true;
|
|
784
|
+
this.onDialogClose = new Subject();
|
|
785
|
+
this.onClose = this.onDialogClose.asObservable();
|
|
786
|
+
// this.componentRef = this.componentRef;
|
|
787
|
+
// this.animate = this.animate;
|
|
788
|
+
// this.insertionPoint = this.insertionPoint;
|
|
789
|
+
// this.childComponentType = this.childComponentType;
|
|
790
|
+
}
|
|
791
|
+
ngOnInit() {
|
|
792
|
+
this.position = this.config.position;
|
|
793
|
+
this.background = this.config.background;
|
|
794
|
+
document.body.style.overflow = 'hidden';
|
|
795
|
+
setTimeout(() => {
|
|
796
|
+
this.animation = false;
|
|
797
|
+
}, 200);
|
|
798
|
+
this.routeAction();
|
|
799
|
+
}
|
|
800
|
+
routeAction() {
|
|
801
|
+
this.router.events.subscribe((event) => {
|
|
802
|
+
if (event instanceof NavigationStart) {
|
|
803
|
+
// Show loading indicator
|
|
804
|
+
}
|
|
805
|
+
if (event instanceof NavigationEnd) {
|
|
806
|
+
// Hide loading indicator
|
|
807
|
+
this.dialogRef.close();
|
|
808
|
+
}
|
|
809
|
+
if (event instanceof NavigationError) {
|
|
810
|
+
// Hide loading indicator
|
|
811
|
+
// Present error to user
|
|
812
|
+
}
|
|
813
|
+
});
|
|
814
|
+
}
|
|
815
|
+
ngAfterViewInit() {
|
|
816
|
+
this.loadChildComponent(this.childComponentType);
|
|
817
|
+
this.cd.detectChanges();
|
|
818
|
+
}
|
|
819
|
+
onOverlayClicked(evt) {
|
|
820
|
+
// this.dialogRef.close();
|
|
821
|
+
}
|
|
822
|
+
onDialogClicked(evt) {
|
|
823
|
+
evt.stopPropagation();
|
|
824
|
+
}
|
|
825
|
+
loadChildComponent(componentType) {
|
|
826
|
+
const componentFactory = this.componentFactoryResolver.resolveComponentFactory(componentType);
|
|
827
|
+
const viewContainerRef = this.insertionPoint.viewContainerRef;
|
|
828
|
+
viewContainerRef.clear();
|
|
829
|
+
this.componentRef = viewContainerRef.createComponent(componentFactory);
|
|
830
|
+
}
|
|
831
|
+
ngOnDestroy() {
|
|
832
|
+
if (this.componentRef) {
|
|
833
|
+
this.componentRef.destroy();
|
|
834
|
+
}
|
|
835
|
+
}
|
|
836
|
+
close(data) {
|
|
837
|
+
this.onDialogClose.next(data);
|
|
838
|
+
document.body.style.overflow = 'auto';
|
|
839
|
+
}
|
|
840
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogComponent, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ChangeDetectorRef }, { token: DialogRef }, { token: DialogConfig }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
841
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DialogComponent, selector: "app-dialog", viewQueries: [{ propertyName: "insertionPoint", first: true, predicate: InsertionDirective, descendants: true, static: true }], ngImport: i0, template: "<div\r\n class=\"overlay\"\r\n (click)=\"onOverlayClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER',\r\n black: background === 'black',\r\n whiteBlur: background === 'whiteBlur'\r\n }\" [class.pointer-none]=\"pointer === 'none'\"\r\n>\r\n <div\r\n class=\"dialog\"\r\n [class.animate]=\"animation\"\r\n (click)=\"onDialogClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER'\r\n }\"\r\n >\r\n <ng-template appInsertion></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".overlay{display:flex;position:fixed;inset:0;align-items:center;justify-content:center;z-index:2147483009!important}.overlay.low{z-index:1}.overlay.black{background:#161b2fcc}.overlay.whiteBlur{-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.overlay.top{align-items:flex-start}.overlay.right{justify-content:flex-end}.overlay.bottom{align-items:flex-end}.overlay.left{justify-content:flex-start}.dialog{position:relative}.dialog.animate.top{animation:animate-top .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-top{0%{transform:translateY(-100px)}to{transform:translateY(0)}}.dialog.animate.right{animation:animate-right .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-right{0%{transform:translate(100%)}to{transform:translate(0)}}.pointer-none{pointer-events:none}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: InsertionDirective, selector: "[appInsertion]" }] }); }
|
|
842
|
+
}
|
|
843
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogComponent, decorators: [{
|
|
844
|
+
type: Component,
|
|
845
|
+
args: [{ selector: 'app-dialog', template: "<div\r\n class=\"overlay\"\r\n (click)=\"onOverlayClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER',\r\n black: background === 'black',\r\n whiteBlur: background === 'whiteBlur'\r\n }\" [class.pointer-none]=\"pointer === 'none'\"\r\n>\r\n <div\r\n class=\"dialog\"\r\n [class.animate]=\"animation\"\r\n (click)=\"onDialogClicked($event)\"\r\n [ngClass]=\"{\r\n top: position === 'TOP',\r\n right: position === 'RIGHT',\r\n bottom: position === 'BOTTOM',\r\n left: position === 'LEFT',\r\n center: position === 'CENTER'\r\n }\"\r\n >\r\n <ng-template appInsertion></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".overlay{display:flex;position:fixed;inset:0;align-items:center;justify-content:center;z-index:2147483009!important}.overlay.low{z-index:1}.overlay.black{background:#161b2fcc}.overlay.whiteBlur{-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.overlay.top{align-items:flex-start}.overlay.right{justify-content:flex-end}.overlay.bottom{align-items:flex-end}.overlay.left{justify-content:flex-start}.dialog{position:relative}.dialog.animate.top{animation:animate-top .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-top{0%{transform:translateY(-100px)}to{transform:translateY(0)}}.dialog.animate.right{animation:animate-right .2s cubic-bezier(.25,.46,.45,.94) both}@keyframes animate-right{0%{transform:translate(100%)}to{transform:translate(0)}}.pointer-none{pointer-events:none}\n"] }]
|
|
846
|
+
}], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ChangeDetectorRef }, { type: DialogRef }, { type: DialogConfig }, { type: i3.Router }]; }, propDecorators: { insertionPoint: [{
|
|
847
|
+
type: ViewChild,
|
|
848
|
+
args: [InsertionDirective, { static: true }]
|
|
849
|
+
}] } });
|
|
850
|
+
|
|
851
|
+
class DialogModule {
|
|
852
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
853
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DialogModule, declarations: [DialogComponent, InsertionDirective], imports: [CommonModule], exports: [DialogComponent] }); }
|
|
854
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogModule, providers: [DialogRef], imports: [CommonModule] }); }
|
|
855
|
+
}
|
|
856
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogModule, decorators: [{
|
|
857
|
+
type: NgModule,
|
|
858
|
+
args: [{
|
|
859
|
+
imports: [CommonModule],
|
|
860
|
+
declarations: [DialogComponent, InsertionDirective],
|
|
861
|
+
providers: [DialogRef],
|
|
862
|
+
exports: [DialogComponent]
|
|
863
|
+
}]
|
|
864
|
+
}] });
|
|
865
|
+
|
|
866
|
+
class DialogInjector {
|
|
867
|
+
constructor(parentDialogInjector, dialogAdditionalTokens) {
|
|
868
|
+
this.parentDialogInjector = parentDialogInjector;
|
|
869
|
+
this.dialogAdditionalTokens = dialogAdditionalTokens;
|
|
870
|
+
}
|
|
871
|
+
// get(token: any, notFoundValue?: any){return; }
|
|
872
|
+
get(token, notFoundValue) {
|
|
873
|
+
const value = this.dialogAdditionalTokens.get(token);
|
|
874
|
+
if (value) {
|
|
875
|
+
return value;
|
|
876
|
+
}
|
|
877
|
+
return this.parentDialogInjector.get(token, notFoundValue);
|
|
878
|
+
}
|
|
879
|
+
}
|
|
880
|
+
|
|
881
|
+
class DialogService {
|
|
882
|
+
constructor(componentFactoryResolver, appRef, injector) {
|
|
883
|
+
this.componentFactoryResolver = componentFactoryResolver;
|
|
884
|
+
this.appRef = appRef;
|
|
885
|
+
this.injector = injector;
|
|
886
|
+
}
|
|
887
|
+
open(componentType, config) {
|
|
888
|
+
const dialogRef = this.appendDialogComponentToBody(config);
|
|
889
|
+
this.dialogComponentRef.instance.childComponentType = componentType;
|
|
890
|
+
return dialogRef;
|
|
891
|
+
}
|
|
892
|
+
appendDialogComponentToBody(config) {
|
|
893
|
+
const map = new WeakMap();
|
|
894
|
+
map.set(DialogConfig, config);
|
|
895
|
+
const dialogRef = new DialogRef();
|
|
896
|
+
map.set(DialogRef, dialogRef);
|
|
897
|
+
const sub = dialogRef.afterClosed.subscribe(() => {
|
|
898
|
+
this.removeDialogComponentFromBody();
|
|
899
|
+
sub.unsubscribe();
|
|
900
|
+
});
|
|
901
|
+
const componentFactory = this.componentFactoryResolver.resolveComponentFactory(DialogComponent);
|
|
902
|
+
const componentRef = componentFactory.create(new DialogInjector(this.injector, map));
|
|
903
|
+
this.appRef.attachView(componentRef.hostView);
|
|
904
|
+
const domElem = componentRef.hostView.rootNodes[0];
|
|
905
|
+
document.body.appendChild(domElem);
|
|
906
|
+
this.dialogComponentRef = componentRef;
|
|
907
|
+
this.dialogComponentRef.instance.onClose.subscribe(() => {
|
|
908
|
+
this.removeDialogComponentFromBody();
|
|
909
|
+
});
|
|
910
|
+
return dialogRef;
|
|
911
|
+
}
|
|
912
|
+
removeDialogComponentFromBody() {
|
|
913
|
+
this.appRef.detachView(this.dialogComponentRef.hostView);
|
|
914
|
+
this.dialogComponentRef.destroy();
|
|
915
|
+
}
|
|
916
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogService, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ApplicationRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
917
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogService, providedIn: DialogModule }); }
|
|
918
|
+
}
|
|
919
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DialogService, decorators: [{
|
|
920
|
+
type: Injectable,
|
|
921
|
+
args: [{
|
|
922
|
+
providedIn: DialogModule,
|
|
923
|
+
}]
|
|
924
|
+
}], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ApplicationRef }, { type: i0.Injector }]; } });
|
|
925
|
+
|
|
926
|
+
class SessionExpiredComponent {
|
|
927
|
+
constructor(dialogService) {
|
|
928
|
+
this.dialogService = dialogService;
|
|
929
|
+
this.errorConfig = ERROR_CONFIG.SESSION_EXPIRED;
|
|
930
|
+
this.errorTypes = MODAL_ERROR_TYPES;
|
|
931
|
+
}
|
|
932
|
+
ngOnInit() {
|
|
933
|
+
this.openSessionExpiredModal();
|
|
934
|
+
}
|
|
935
|
+
openSessionExpiredModal() {
|
|
936
|
+
this.dialogService.open(ErrorModalComponent, {
|
|
937
|
+
data: {
|
|
938
|
+
errorType: this.errorTypes.SESSION_EXPIRED,
|
|
939
|
+
errorConfig: this.errorConfig,
|
|
940
|
+
},
|
|
941
|
+
position: 'center',
|
|
942
|
+
background: 'whiteBlur',
|
|
943
|
+
});
|
|
944
|
+
}
|
|
945
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SessionExpiredComponent, deps: [{ token: DialogService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
946
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: SessionExpiredComponent, selector: "lib-vc-error-session-expired", ngImport: i0, template: ``, isInline: true }); }
|
|
947
|
+
}
|
|
948
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SessionExpiredComponent, decorators: [{
|
|
949
|
+
type: Component,
|
|
950
|
+
args: [{
|
|
951
|
+
selector: 'lib-vc-error-session-expired',
|
|
952
|
+
template: ``,
|
|
953
|
+
}]
|
|
954
|
+
}], ctorParameters: function () { return [{ type: DialogService }]; } });
|
|
955
|
+
|
|
956
|
+
class ChunkUnavailableComponent {
|
|
957
|
+
constructor(dialogService) {
|
|
958
|
+
this.dialogService = dialogService;
|
|
959
|
+
this.errorConfig = ERROR_CONFIG.CHUNK_UNAVAILABLE;
|
|
960
|
+
this.errorType = MODAL_ERROR_TYPES;
|
|
961
|
+
}
|
|
962
|
+
ngOnInit() {
|
|
963
|
+
this.openSessionExpiredModal();
|
|
964
|
+
}
|
|
965
|
+
openSessionExpiredModal() {
|
|
966
|
+
this.dialogService.open(ErrorModalComponent, {
|
|
967
|
+
data: {
|
|
968
|
+
errorType: this.errorType.CHUNK_NOT_FOUND,
|
|
969
|
+
errorConfig: this.errorConfig,
|
|
970
|
+
},
|
|
971
|
+
position: 'center',
|
|
972
|
+
background: 'whiteBlur',
|
|
973
|
+
});
|
|
974
|
+
}
|
|
975
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ChunkUnavailableComponent, deps: [{ token: DialogService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
976
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ChunkUnavailableComponent, selector: "lib-vc-error-chunk-unavailable", ngImport: i0, template: ``, isInline: true }); }
|
|
977
|
+
}
|
|
978
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ChunkUnavailableComponent, decorators: [{
|
|
979
|
+
type: Component,
|
|
980
|
+
args: [{
|
|
981
|
+
selector: 'lib-vc-error-chunk-unavailable',
|
|
982
|
+
template: ``,
|
|
983
|
+
}]
|
|
984
984
|
}], ctorParameters: function () { return [{ type: DialogService }]; } });
|
|
985
985
|
|
|
986
|
-
class ServerErrorComponent {
|
|
987
|
-
constructor() {
|
|
988
|
-
this.errorConfig = ERROR_CONFIG.SERVER_ERROR;
|
|
989
|
-
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
990
|
-
this.altImageText = ALT_IMAGE_TEXT;
|
|
991
|
-
}
|
|
992
|
-
refreshPage() {
|
|
993
|
-
window.location.reload();
|
|
994
|
-
}
|
|
995
|
-
}
|
|
996
|
-
|
|
997
|
-
ServerErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: ServerErrorComponent, selector: "lib-vc-error-server-error", ngImport: i0, template: `
|
|
986
|
+
class ServerErrorComponent {
|
|
987
|
+
constructor() {
|
|
988
|
+
this.errorConfig = ERROR_CONFIG.SERVER_ERROR;
|
|
989
|
+
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
990
|
+
this.altImageText = ALT_IMAGE_TEXT;
|
|
991
|
+
}
|
|
992
|
+
refreshPage() {
|
|
993
|
+
window.location.reload();
|
|
994
|
+
}
|
|
995
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ServerErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
996
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ServerErrorComponent, selector: "lib-vc-error-server-error", ngImport: i0, template: `
|
|
998
997
|
<div class="errorPage">
|
|
999
998
|
<div class="errorPage-top">
|
|
1000
999
|
<img
|
|
1001
|
-
[
|
|
1000
|
+
[ngSrc]="VcomplyLogo"
|
|
1002
1001
|
[alt]="altImageText.VCOMPLY_LOGO"
|
|
1003
1002
|
width="24"
|
|
1004
1003
|
height="24"
|
|
@@ -1008,7 +1007,7 @@ ServerErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1008
1007
|
<div class="errorPage-inner">
|
|
1009
1008
|
<div class="errorPage-inner-image">
|
|
1010
1009
|
<img
|
|
1011
|
-
[
|
|
1010
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
1012
1011
|
[alt]="altImageText.ERROR_IMAGE"
|
|
1013
1012
|
width="246"
|
|
1014
1013
|
height="178"
|
|
@@ -1025,14 +1024,15 @@ ServerErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
1025
1024
|
</div>
|
|
1026
1025
|
</div>
|
|
1027
1026
|
</div>
|
|
1028
|
-
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:
|
|
1029
|
-
|
|
1030
|
-
|
|
1027
|
+
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:700;line-height:110px;margin-bottom:1.5rem}.errorPage-inner-right .errorPage-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.errorPage-inner-right .errorPage-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:1.75rem}.errorPage-inner-right .errorPage-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.errorPage-inner-right .errorPage-btn i{font-size:14px;margin-left:.25rem}.errorPage-copyright{font-size:11px;color:#787a8c;font-weight:500;position:absolute;bottom:8px;right:16px;line-height:16px}\n"], dependencies: [{ kind: "directive", type: i1.NgOptimizedImage, selector: "img[ngSrc]", inputs: ["ngSrc", "ngSrcset", "sizes", "width", "height", "loading", "priority", "loaderParams", "disableOptimizedSrcset", "fill", "src", "srcset"] }] }); }
|
|
1028
|
+
}
|
|
1029
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ServerErrorComponent, decorators: [{
|
|
1030
|
+
type: Component,
|
|
1031
1031
|
args: [{ selector: 'lib-vc-error-server-error', template: `
|
|
1032
1032
|
<div class="errorPage">
|
|
1033
1033
|
<div class="errorPage-top">
|
|
1034
1034
|
<img
|
|
1035
|
-
[
|
|
1035
|
+
[ngSrc]="VcomplyLogo"
|
|
1036
1036
|
[alt]="altImageText.VCOMPLY_LOGO"
|
|
1037
1037
|
width="24"
|
|
1038
1038
|
height="24"
|
|
@@ -1042,7 +1042,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
1042
1042
|
<div class="errorPage-inner">
|
|
1043
1043
|
<div class="errorPage-inner-image">
|
|
1044
1044
|
<img
|
|
1045
|
-
[
|
|
1045
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
1046
1046
|
[alt]="altImageText.ERROR_IMAGE"
|
|
1047
1047
|
width="246"
|
|
1048
1048
|
height="178"
|
|
@@ -1059,73 +1059,72 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
1059
1059
|
</div>
|
|
1060
1060
|
</div>
|
|
1061
1061
|
</div>
|
|
1062
|
-
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:
|
|
1062
|
+
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:700;line-height:110px;margin-bottom:1.5rem}.errorPage-inner-right .errorPage-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.errorPage-inner-right .errorPage-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:1.75rem}.errorPage-inner-right .errorPage-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.errorPage-inner-right .errorPage-btn i{font-size:14px;margin-left:.25rem}.errorPage-copyright{font-size:11px;color:#787a8c;font-weight:500;position:absolute;bottom:8px;right:16px;line-height:16px}\n"] }]
|
|
1063
1063
|
}] });
|
|
1064
1064
|
|
|
1065
|
-
class VcErrorHandlersComponent {
|
|
1066
|
-
constructor(errorService, snackBarService) {
|
|
1067
|
-
this.errorService = errorService;
|
|
1068
|
-
this.snackBarService = snackBarService;
|
|
1069
|
-
this.errorConfig = ERROR_CONFIG.NETWORK_UNAVAILABLE;
|
|
1070
|
-
this.unauthorized = false;
|
|
1071
|
-
this.sessionExpired = false;
|
|
1072
|
-
this.chunkUnavailable = false;
|
|
1073
|
-
this.serverError = false;
|
|
1074
|
-
this.isOnline = navigator.onLine;
|
|
1075
|
-
this.onNetworkOnline = () => {
|
|
1076
|
-
this.isOnline = true;
|
|
1077
|
-
this.hideSnackBar();
|
|
1078
|
-
};
|
|
1079
|
-
this.onNetworkOffline = () => {
|
|
1080
|
-
this.isOnline = false;
|
|
1081
|
-
this.showOfflineSnackBar();
|
|
1082
|
-
};
|
|
1083
|
-
this.subscribeGlobalError();
|
|
1084
|
-
}
|
|
1085
|
-
ngOnInit() {
|
|
1086
|
-
this.subscribeNetworkDetection();
|
|
1087
|
-
}
|
|
1088
|
-
ngOnDestroy() {
|
|
1089
|
-
window.removeEventListener('online', this.onNetworkOnline);
|
|
1090
|
-
window.removeEventListener('offline', this.onNetworkOffline);
|
|
1091
|
-
}
|
|
1092
|
-
subscribeGlobalError() {
|
|
1093
|
-
this.errorService.globalError$.subscribe((error) => {
|
|
1094
|
-
this.handleError(error);
|
|
1095
|
-
});
|
|
1096
|
-
}
|
|
1097
|
-
handleError(error) {
|
|
1098
|
-
const errorHandlers = {
|
|
1099
|
-
[ErrorStatusCode.Unauthenticated]: () => (this.sessionExpired = true),
|
|
1100
|
-
[ErrorStatusCode.UnauthorizedAccess]: () => (this.unauthorized = true),
|
|
1101
|
-
[ErrorStatusCode.JSChunkUnavailable]: () => (this.chunkUnavailable = true),
|
|
1102
|
-
[ErrorStatusCode.NetworkUnavailable]: () => this.handleNetworkError(),
|
|
1103
|
-
};
|
|
1104
|
-
if (errorHandlers[error.status]) {
|
|
1105
|
-
errorHandlers[error.status]();
|
|
1106
|
-
}
|
|
1107
|
-
else if (this.errorService.isServerError(error)) {
|
|
1108
|
-
this.serverError = true;
|
|
1109
|
-
}
|
|
1110
|
-
}
|
|
1111
|
-
subscribeNetworkDetection() {
|
|
1112
|
-
window.addEventListener('online', this.onNetworkOnline);
|
|
1113
|
-
window.addEventListener('offline', this.onNetworkOffline);
|
|
1114
|
-
}
|
|
1115
|
-
handleNetworkError() {
|
|
1116
|
-
if (!this.isOnline) {
|
|
1117
|
-
this.showOfflineSnackBar();
|
|
1118
|
-
}
|
|
1119
|
-
}
|
|
1120
|
-
showOfflineSnackBar() {
|
|
1121
|
-
this.snackBarService.show(this.errorConfig.offlineMessage, 'error');
|
|
1122
|
-
}
|
|
1123
|
-
hideSnackBar() {
|
|
1124
|
-
this.snackBarService.hide();
|
|
1125
|
-
}
|
|
1126
|
-
}
|
|
1127
|
-
|
|
1128
|
-
VcErrorHandlersComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: VcErrorHandlersComponent, selector: "lib-vc-error-handlers", ngImport: i0, template: `
|
|
1065
|
+
class VcErrorHandlersComponent {
|
|
1066
|
+
constructor(errorService, snackBarService) {
|
|
1067
|
+
this.errorService = errorService;
|
|
1068
|
+
this.snackBarService = snackBarService;
|
|
1069
|
+
this.errorConfig = ERROR_CONFIG.NETWORK_UNAVAILABLE;
|
|
1070
|
+
this.unauthorized = false;
|
|
1071
|
+
this.sessionExpired = false;
|
|
1072
|
+
this.chunkUnavailable = false;
|
|
1073
|
+
this.serverError = false;
|
|
1074
|
+
this.isOnline = navigator.onLine;
|
|
1075
|
+
this.onNetworkOnline = () => {
|
|
1076
|
+
this.isOnline = true;
|
|
1077
|
+
this.hideSnackBar();
|
|
1078
|
+
};
|
|
1079
|
+
this.onNetworkOffline = () => {
|
|
1080
|
+
this.isOnline = false;
|
|
1081
|
+
this.showOfflineSnackBar();
|
|
1082
|
+
};
|
|
1083
|
+
this.subscribeGlobalError();
|
|
1084
|
+
}
|
|
1085
|
+
ngOnInit() {
|
|
1086
|
+
this.subscribeNetworkDetection();
|
|
1087
|
+
}
|
|
1088
|
+
ngOnDestroy() {
|
|
1089
|
+
window.removeEventListener('online', this.onNetworkOnline);
|
|
1090
|
+
window.removeEventListener('offline', this.onNetworkOffline);
|
|
1091
|
+
}
|
|
1092
|
+
subscribeGlobalError() {
|
|
1093
|
+
this.errorService.globalError$.subscribe((error) => {
|
|
1094
|
+
this.handleError(error);
|
|
1095
|
+
});
|
|
1096
|
+
}
|
|
1097
|
+
handleError(error) {
|
|
1098
|
+
const errorHandlers = {
|
|
1099
|
+
[ErrorStatusCode.Unauthenticated]: () => (this.sessionExpired = true),
|
|
1100
|
+
[ErrorStatusCode.UnauthorizedAccess]: () => (this.unauthorized = true),
|
|
1101
|
+
[ErrorStatusCode.JSChunkUnavailable]: () => (this.chunkUnavailable = true),
|
|
1102
|
+
[ErrorStatusCode.NetworkUnavailable]: () => this.handleNetworkError(),
|
|
1103
|
+
};
|
|
1104
|
+
if (errorHandlers[error.status]) {
|
|
1105
|
+
errorHandlers[error.status]();
|
|
1106
|
+
}
|
|
1107
|
+
else if (this.errorService.isServerError(error)) {
|
|
1108
|
+
this.serverError = true;
|
|
1109
|
+
}
|
|
1110
|
+
}
|
|
1111
|
+
subscribeNetworkDetection() {
|
|
1112
|
+
window.addEventListener('online', this.onNetworkOnline);
|
|
1113
|
+
window.addEventListener('offline', this.onNetworkOffline);
|
|
1114
|
+
}
|
|
1115
|
+
handleNetworkError() {
|
|
1116
|
+
if (!this.isOnline) {
|
|
1117
|
+
this.showOfflineSnackBar();
|
|
1118
|
+
}
|
|
1119
|
+
}
|
|
1120
|
+
showOfflineSnackBar() {
|
|
1121
|
+
this.snackBarService.show(this.errorConfig.offlineMessage, 'error');
|
|
1122
|
+
}
|
|
1123
|
+
hideSnackBar() {
|
|
1124
|
+
this.snackBarService.hide();
|
|
1125
|
+
}
|
|
1126
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersComponent, deps: [{ token: GlobalErrorService }, { token: SnackBarService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1127
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: VcErrorHandlersComponent, selector: "lib-vc-error-handlers", ngImport: i0, template: `
|
|
1129
1128
|
<app-snack-bar></app-snack-bar>
|
|
1130
1129
|
<lib-vc-error-session-expired
|
|
1131
1130
|
*ngIf="sessionExpired"
|
|
@@ -1135,11 +1134,12 @@ VcErrorHandlersComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
|
|
|
1135
1134
|
*ngIf="chunkUnavailable"
|
|
1136
1135
|
></lib-vc-error-chunk-unavailable>
|
|
1137
1136
|
<lib-vc-error-server-error *ngIf="serverError"></lib-vc-error-server-error>
|
|
1138
|
-
`, isInline: true,
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1137
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: SnackBarComponent, selector: "app-snack-bar" }, { kind: "component", type: UnauthorizedComponent, selector: "lib-vc-error-unauthorized" }, { kind: "component", type: SessionExpiredComponent, selector: "lib-vc-error-session-expired" }, { kind: "component", type: ChunkUnavailableComponent, selector: "lib-vc-error-chunk-unavailable" }, { kind: "component", type: ServerErrorComponent, selector: "lib-vc-error-server-error" }] }); }
|
|
1138
|
+
}
|
|
1139
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersComponent, decorators: [{
|
|
1140
|
+
type: Component,
|
|
1141
|
+
args: [{
|
|
1142
|
+
selector: 'lib-vc-error-handlers',
|
|
1143
1143
|
template: `
|
|
1144
1144
|
<app-snack-bar></app-snack-bar>
|
|
1145
1145
|
<lib-vc-error-session-expired
|
|
@@ -1150,29 +1150,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
1150
1150
|
*ngIf="chunkUnavailable"
|
|
1151
1151
|
></lib-vc-error-chunk-unavailable>
|
|
1152
1152
|
<lib-vc-error-server-error *ngIf="serverError"></lib-vc-error-server-error>
|
|
1153
|
-
`,
|
|
1154
|
-
}]
|
|
1153
|
+
`,
|
|
1154
|
+
}]
|
|
1155
1155
|
}], ctorParameters: function () { return [{ type: GlobalErrorService }, { type: SnackBarService }]; } });
|
|
1156
1156
|
|
|
1157
|
-
class PageNotFoundComponent {
|
|
1158
|
-
constructor() {
|
|
1159
|
-
this.errorConfig = ERROR_CONFIG.PAGE_NOT_FOUND;
|
|
1160
|
-
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
1161
|
-
this.altImageText = ALT_IMAGE_TEXT;
|
|
1162
|
-
this.currentYear = new Date().getFullYear();
|
|
1163
|
-
this.redirectionUrl = REDIRECTION_URL;
|
|
1164
|
-
this.organisationName = ORGANISATION_NAME;
|
|
1165
|
-
}
|
|
1166
|
-
redirectToHome() {
|
|
1167
|
-
window.location.replace(this.redirectionUrl.compliance_dashboard);
|
|
1168
|
-
}
|
|
1169
|
-
}
|
|
1170
|
-
|
|
1171
|
-
PageNotFoundComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: PageNotFoundComponent, selector: "lib-vc-error-page-not-found", ngImport: i0, template: `
|
|
1157
|
+
class PageNotFoundComponent {
|
|
1158
|
+
constructor() {
|
|
1159
|
+
this.errorConfig = ERROR_CONFIG.PAGE_NOT_FOUND;
|
|
1160
|
+
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
1161
|
+
this.altImageText = ALT_IMAGE_TEXT;
|
|
1162
|
+
this.currentYear = new Date().getFullYear();
|
|
1163
|
+
this.redirectionUrl = REDIRECTION_URL;
|
|
1164
|
+
this.organisationName = ORGANISATION_NAME;
|
|
1165
|
+
}
|
|
1166
|
+
redirectToHome() {
|
|
1167
|
+
window.location.replace(this.redirectionUrl.compliance_dashboard);
|
|
1168
|
+
}
|
|
1169
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PageNotFoundComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1170
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: PageNotFoundComponent, selector: "lib-vc-error-page-not-found", ngImport: i0, template: `
|
|
1172
1171
|
<div class="errorPage">
|
|
1173
1172
|
<div class="errorPage-top">
|
|
1174
1173
|
<img
|
|
1175
|
-
[
|
|
1174
|
+
[ngSrc]="VcomplyLogo"
|
|
1176
1175
|
[alt]="altImageText.VCOMPLY_LOGO"
|
|
1177
1176
|
width="24"
|
|
1178
1177
|
height="24"
|
|
@@ -1182,7 +1181,7 @@ PageNotFoundComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
1182
1181
|
<div class="errorPage-inner">
|
|
1183
1182
|
<div class="errorPage-inner-image">
|
|
1184
1183
|
<img
|
|
1185
|
-
[
|
|
1184
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
1186
1185
|
[alt]="altImageText.ERROR_IMAGE"
|
|
1187
1186
|
width="246"
|
|
1188
1187
|
height="178"
|
|
@@ -1202,14 +1201,15 @@ PageNotFoundComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
1202
1201
|
</div>
|
|
1203
1202
|
</div>
|
|
1204
1203
|
</div>
|
|
1205
|
-
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:
|
|
1206
|
-
|
|
1207
|
-
|
|
1204
|
+
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:700;line-height:110px;margin-bottom:1.5rem}.errorPage-inner-right .errorPage-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.errorPage-inner-right .errorPage-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:1.75rem}.errorPage-inner-right .errorPage-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.errorPage-inner-right .errorPage-btn i{font-size:14px;margin-left:.25rem}.errorPage-copyright{font-size:11px;color:#787a8c;font-weight:500;position:absolute;bottom:8px;right:16px;line-height:16px}\n"], dependencies: [{ kind: "directive", type: i1.NgOptimizedImage, selector: "img[ngSrc]", inputs: ["ngSrc", "ngSrcset", "sizes", "width", "height", "loading", "priority", "loaderParams", "disableOptimizedSrcset", "fill", "src", "srcset"] }] }); }
|
|
1205
|
+
}
|
|
1206
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PageNotFoundComponent, decorators: [{
|
|
1207
|
+
type: Component,
|
|
1208
1208
|
args: [{ selector: 'lib-vc-error-page-not-found', template: `
|
|
1209
1209
|
<div class="errorPage">
|
|
1210
1210
|
<div class="errorPage-top">
|
|
1211
1211
|
<img
|
|
1212
|
-
[
|
|
1212
|
+
[ngSrc]="VcomplyLogo"
|
|
1213
1213
|
[alt]="altImageText.VCOMPLY_LOGO"
|
|
1214
1214
|
width="24"
|
|
1215
1215
|
height="24"
|
|
@@ -1219,7 +1219,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
1219
1219
|
<div class="errorPage-inner">
|
|
1220
1220
|
<div class="errorPage-inner-image">
|
|
1221
1221
|
<img
|
|
1222
|
-
[
|
|
1222
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
1223
1223
|
[alt]="altImageText.ERROR_IMAGE"
|
|
1224
1224
|
width="246"
|
|
1225
1225
|
height="178"
|
|
@@ -1239,24 +1239,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
1239
1239
|
</div>
|
|
1240
1240
|
</div>
|
|
1241
1241
|
</div>
|
|
1242
|
-
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:
|
|
1242
|
+
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.errorPage{background:#161b2f;position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:9999}.errorPage-top{width:100%;height:3rem;display:flex;align-items:center;padding-left:.75rem}.errorPage-container{background:#f2f2f5;border-radius:.75rem;border:1px solid #e3e3e9;box-shadow:0 4px 8px #1d5dd31a;height:calc(100vh - 3.75rem);display:flex;align-items:center;justify-content:center;padding:0 4rem;margin:0 .75rem;position:relative}.errorPage-inner{display:flex;align-items:center}.errorPage-inner-image{width:16rem}.errorPage-inner-right{margin-left:2rem;width:calc(100% - 18rem)}.errorPage-inner-right .errorPage-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:78px;font-weight:700;line-height:110px;margin-bottom:1.5rem}.errorPage-inner-right .errorPage-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.errorPage-inner-right .errorPage-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:1.75rem}.errorPage-inner-right .errorPage-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.errorPage-inner-right .errorPage-btn i{font-size:14px;margin-left:.25rem}.errorPage-copyright{font-size:11px;color:#787a8c;font-weight:500;position:absolute;bottom:8px;right:16px;line-height:16px}\n"] }]
|
|
1243
1243
|
}] });
|
|
1244
1244
|
|
|
1245
|
-
class ComponentLevelServerErrorComponent {
|
|
1246
|
-
constructor() {
|
|
1247
|
-
this.errorConfig = ERROR_CONFIG.COMPONENT_LEVEL_SERVER_ERROR;
|
|
1248
|
-
this.altImageText = ALT_IMAGE_TEXT;
|
|
1249
|
-
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
1250
|
-
this.onClick = new EventEmitter();
|
|
1251
|
-
}
|
|
1252
|
-
}
|
|
1253
|
-
|
|
1254
|
-
ComponentLevelServerErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: ComponentLevelServerErrorComponent, selector: "lib-vc-error-component-server-error", outputs: { onClick: "onClick" }, ngImport: i0, template: `
|
|
1245
|
+
class ComponentLevelServerErrorComponent {
|
|
1246
|
+
constructor() {
|
|
1247
|
+
this.errorConfig = ERROR_CONFIG.COMPONENT_LEVEL_SERVER_ERROR;
|
|
1248
|
+
this.altImageText = ALT_IMAGE_TEXT;
|
|
1249
|
+
this.VcomplyLogo = VCOMPLY_LOGO_URL;
|
|
1250
|
+
this.onClick = new EventEmitter();
|
|
1251
|
+
}
|
|
1252
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ComponentLevelServerErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1253
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ComponentLevelServerErrorComponent, selector: "lib-vc-error-component-server-error", outputs: { onClick: "onClick" }, ngImport: i0, template: `
|
|
1255
1254
|
<div class="serverError">
|
|
1256
1255
|
<div class="serverError-inner">
|
|
1257
1256
|
<div class="serverError-inner-image">
|
|
1258
1257
|
<img
|
|
1259
|
-
[
|
|
1258
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
1260
1259
|
[alt]="altImageText.ERROR_IMAGE"
|
|
1261
1260
|
width="106"
|
|
1262
1261
|
height="76"
|
|
@@ -1273,15 +1272,16 @@ ComponentLevelServerErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersio
|
|
|
1273
1272
|
</div>
|
|
1274
1273
|
</div>
|
|
1275
1274
|
</div>
|
|
1276
|
-
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.serverError{background:#fff;display:flex;align-items:center;justify-content:center;border-radius:2px;width:100%;height:100%}.serverError-inner{text-align:center}.serverError-inner-image{width:16rem;margin:0 auto}.serverError-inner-bottom{margin-top:1rem}.serverError-inner-bottom .serverError-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:40px;font-weight:
|
|
1277
|
-
|
|
1278
|
-
|
|
1275
|
+
`, isInline: true, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.serverError{background:#fff;display:flex;align-items:center;justify-content:center;border-radius:2px;width:100%;height:100%}.serverError-inner{text-align:center}.serverError-inner-image{width:16rem;margin:0 auto}.serverError-inner-bottom{margin-top:1rem}.serverError-inner-bottom .serverError-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:40px;font-weight:700;line-height:56px;margin-bottom:1.5rem}.serverError-inner-bottom .serverError-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.serverError-inner-bottom .serverError-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:2rem}.serverError-inner-bottom .serverError-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.serverError-inner-bottom .serverError-btn i{font-size:12px;margin-left:8px}\n"], dependencies: [{ kind: "directive", type: i1.NgOptimizedImage, selector: "img[ngSrc]", inputs: ["ngSrc", "ngSrcset", "sizes", "width", "height", "loading", "priority", "loaderParams", "disableOptimizedSrcset", "fill", "src", "srcset"] }] }); }
|
|
1276
|
+
}
|
|
1277
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ComponentLevelServerErrorComponent, decorators: [{
|
|
1278
|
+
type: Component,
|
|
1279
1279
|
args: [{ selector: 'lib-vc-error-component-server-error', template: `
|
|
1280
1280
|
<div class="serverError">
|
|
1281
1281
|
<div class="serverError-inner">
|
|
1282
1282
|
<div class="serverError-inner-image">
|
|
1283
1283
|
<img
|
|
1284
|
-
[
|
|
1284
|
+
[ngSrc]="errorConfig.imageUrl"
|
|
1285
1285
|
[alt]="altImageText.ERROR_IMAGE"
|
|
1286
1286
|
width="106"
|
|
1287
1287
|
height="76"
|
|
@@ -1298,376 +1298,303 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
1298
1298
|
</div>
|
|
1299
1299
|
</div>
|
|
1300
1300
|
</div>
|
|
1301
|
-
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.serverError{background:#fff;display:flex;align-items:center;justify-content:center;border-radius:2px;width:100%;height:100%}.serverError-inner{text-align:center}.serverError-inner-image{width:16rem;margin:0 auto}.serverError-inner-bottom{margin-top:1rem}.serverError-inner-bottom .serverError-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:40px;font-weight:
|
|
1302
|
-
}], propDecorators: { onClick: [{
|
|
1303
|
-
type: Output
|
|
1301
|
+
`, styles: ["@import\"https://cdn.v-comply.com/design-system/css/icons/icons.css\";.serverError{background:#fff;display:flex;align-items:center;justify-content:center;border-radius:2px;width:100%;height:100%}.serverError-inner{text-align:center}.serverError-inner-image{width:16rem;margin:0 auto}.serverError-inner-bottom{margin-top:1rem}.serverError-inner-bottom .serverError-heading{-webkit-text-fill-color:#e3e3e9;-webkit-text-stroke-color:#a9aab6;-webkit-text-stroke-width:1px;color:#e3e3e9;font-size:40px;font-weight:700;line-height:56px;margin-bottom:1.5rem}.serverError-inner-bottom .serverError-text{color:#141724;font-size:19px;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.serverError-inner-bottom .serverError-details{color:#565a6f;font-size:13px;line-height:20px;margin-bottom:2rem}.serverError-inner-bottom .serverError-btn{background:#1e5dd3;border-radius:.25rem;border:none;color:#fff;display:inline-flex;align-items:center;font-size:11px;font-weight:500;line-height:2rem;padding:0 1rem}.serverError-inner-bottom .serverError-btn i{font-size:12px;margin-left:8px}\n"] }]
|
|
1302
|
+
}], propDecorators: { onClick: [{
|
|
1303
|
+
type: Output
|
|
1304
1304
|
}] } });
|
|
1305
1305
|
|
|
1306
|
-
class SnackBarModule {
|
|
1307
|
-
}
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1312
|
-
type: NgModule,
|
|
1313
|
-
args: [{
|
|
1314
|
-
declarations: [SnackBarComponent],
|
|
1315
|
-
imports: [CommonModule],
|
|
1316
|
-
exports: [SnackBarComponent],
|
|
1317
|
-
}]
|
|
1306
|
+
class SnackBarModule {
|
|
1307
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1308
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: SnackBarModule, declarations: [SnackBarComponent], imports: [CommonModule], exports: [SnackBarComponent] }); }
|
|
1309
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarModule, imports: [CommonModule] }); }
|
|
1310
|
+
}
|
|
1311
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SnackBarModule, decorators: [{
|
|
1312
|
+
type: NgModule,
|
|
1313
|
+
args: [{
|
|
1314
|
+
declarations: [SnackBarComponent],
|
|
1315
|
+
imports: [CommonModule],
|
|
1316
|
+
exports: [SnackBarComponent],
|
|
1317
|
+
}]
|
|
1318
1318
|
}] });
|
|
1319
1319
|
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
case 'dev.v-comply.com':
|
|
1327
|
-
domainName = 'devapi.v-comply.com';
|
|
1328
|
-
apiBaseUrl = 'https://api-uat1.v-comply.com';
|
|
1329
|
-
break;
|
|
1330
|
-
case 'beta.v-comply.com':
|
|
1331
|
-
domainName = 'betaapi.v-comply.com';
|
|
1332
|
-
apiBaseUrl = 'https://api-staging.v-comply.com';
|
|
1333
|
-
break;
|
|
1334
|
-
case 'test.v-comply.com':
|
|
1335
|
-
domainName = 'devapi.v-comply.com';
|
|
1336
|
-
break;
|
|
1337
|
-
case 'eu.v-comply.com':
|
|
1338
|
-
domainName = 'euapi.v-comply.com';
|
|
1339
|
-
break;
|
|
1340
|
-
default:
|
|
1341
|
-
domainName = 'api.v-comply.com';
|
|
1342
|
-
break;
|
|
1343
|
-
}
|
|
1344
|
-
const PORT_EDITOR = 8081;
|
|
1345
|
-
const PORT_CONTENT_SAVE = 8834;
|
|
1346
|
-
let endPoint = 'https://devapi.v-comply.com/';
|
|
1347
|
-
const environment = {
|
|
1348
|
-
production: false,
|
|
1349
|
-
appUrl: 'http://localhost:4200/',
|
|
1350
|
-
apiBaseUrl: 'https://api-uat1.v-comply.com',
|
|
1351
|
-
authEndpoint: `${endPoint}VcomplyAuth/`,
|
|
1352
|
-
orgEndpoint_TL: `${endPoint}organization_pwt/?mode=`,
|
|
1353
|
-
s3Url: '',
|
|
1354
|
-
s3BucketUrl: `${endPoint}globals?mode=bucket`,
|
|
1355
|
-
s3Bucket: '',
|
|
1356
|
-
profile: '/profile_pic/thumb/',
|
|
1357
|
-
assessmentEnpoint: `${endPoint}Assessment/?mode=`,
|
|
1358
|
-
organizationPost: `${endPoint}organization_post/?mode=`,
|
|
1359
|
-
organizationGet: `${endPoint}organization/?mode=`,
|
|
1360
|
-
complianceGet: `${endPoint}compliance/?mode=`,
|
|
1361
|
-
compliancePost: `${endPoint}compliance_post/?mode=`,
|
|
1362
|
-
fileUploadEndPoint: 'https://upload-uat1.v-comply.com/fileupload/?destination=',
|
|
1363
|
-
assuranceGet: `${endPoint}assurance/?mode=`,
|
|
1364
|
-
policyGet: `${endPoint}policy/?mode=`,
|
|
1365
|
-
saveDoc: 'https://dev-node.v-comply.com/saveContent?bypass-token=true&id=',
|
|
1366
|
-
docxUpload: 'https://dev-node.v-comply.com/ImportDocument',
|
|
1367
|
-
fileUpload: 'https://dev-node.v-comply.com/importFiles',
|
|
1368
|
-
policyPost: `${endPoint}policy_post/?mode=`,
|
|
1369
|
-
policyPut: `${endPoint}policy_put/?mode=`,
|
|
1370
|
-
responsibilityPost: `${endPoint}responsibilities_post/?mode=`,
|
|
1371
|
-
linkDoc: 'https://dev-node.v-comply.com' + '/ImportDocument',
|
|
1372
|
-
linkPdf: 'https://dev-node.v-comply.com' + '/extractDocs',
|
|
1373
|
-
assuranceApi: 'https://devapi.v-comply.com/Assurance/',
|
|
1374
|
-
assurance: 'https://devapi.v-comply.com/Assurance/',
|
|
1375
|
-
programEndpoint: 'https://devapi.v-comply.com/program',
|
|
1376
|
-
risk: 'https://devapi.v-comply.com/risk/?mode=',
|
|
1377
|
-
risk_put: 'https://devapi.v-comply.com/risk_put/?mode=',
|
|
1378
|
-
riskPdfPost: 'https://devapi.v-comply.com/risk_pdf_post?mode=',
|
|
1379
|
-
riskPost: 'https://devapi.v-comply.com/risk_post/?mode=',
|
|
1380
|
-
riskGet: 'https://devapi.v-comply.com/risk/?mode=',
|
|
1381
|
-
baseUrl: 'https://devapi.v-comply.com/',
|
|
1382
|
-
grc_get: 'https://devapi.v-comply.com/grc_object/?mode=',
|
|
1383
|
-
leftMenuLogo: 'https://cdn.v-comply.com/logo/prod/v-logo.svg?v=1.0',
|
|
1384
|
-
vLoader: 'https://cdn.v-comply.com/logo/prod/v-icon-loader.svg?v=1.0',
|
|
1385
|
-
};
|
|
1386
|
-
/*
|
|
1387
|
-
* For easier debugging in development mode, you can import the following file
|
|
1388
|
-
* to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.
|
|
1389
|
-
*
|
|
1390
|
-
* This import should be commented out in production mode because it will have a negative impact
|
|
1391
|
-
* on performance if an error is thrown.
|
|
1392
|
-
*/
|
|
1393
|
-
// import 'zone.js/plugins/zone-error'; // Included with Angular CLI.
|
|
1320
|
+
class Configurations {
|
|
1321
|
+
constructor() {
|
|
1322
|
+
this.sentryConfig = {};
|
|
1323
|
+
this.envConfig = {};
|
|
1324
|
+
}
|
|
1325
|
+
}
|
|
1394
1326
|
|
|
1395
|
-
class FeatureFlagService {
|
|
1396
|
-
constructor(http, authorizer) {
|
|
1397
|
-
this.http = http;
|
|
1398
|
-
this.authorizer = authorizer;
|
|
1399
|
-
this.flagFetchError = false;
|
|
1400
|
-
this.featuresMap = {};
|
|
1401
|
-
this.AWSFlags = {};
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
this.
|
|
1417
|
-
this.
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
flagObj
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
}
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1327
|
+
class FeatureFlagService {
|
|
1328
|
+
constructor(http, authorizer, config) {
|
|
1329
|
+
this.http = http;
|
|
1330
|
+
this.authorizer = authorizer;
|
|
1331
|
+
this.flagFetchError = false;
|
|
1332
|
+
this.featuresMap = {};
|
|
1333
|
+
this.AWSFlags = {};
|
|
1334
|
+
this.environment = config?.envConfig;
|
|
1335
|
+
}
|
|
1336
|
+
fetchFlags() {
|
|
1337
|
+
return this.http.get(this.environment.baseUrl + 'features').pipe(retry(2));
|
|
1338
|
+
}
|
|
1339
|
+
loadConfig() {
|
|
1340
|
+
if (this.flagSubscription) {
|
|
1341
|
+
this.flagSubscription.unsubscribe();
|
|
1342
|
+
}
|
|
1343
|
+
return new Promise((resolve, reject) => {
|
|
1344
|
+
this.flagSubscription = this.fetchFlags().subscribe({
|
|
1345
|
+
next: (res) => {
|
|
1346
|
+
try {
|
|
1347
|
+
resolve(true);
|
|
1348
|
+
this.flagFetchError = false;
|
|
1349
|
+
this.AWSFlags = res;
|
|
1350
|
+
this.buildFeatureFlags(this.authorizer.getOrganizationId());
|
|
1351
|
+
}
|
|
1352
|
+
catch (error) {
|
|
1353
|
+
reject(error);
|
|
1354
|
+
}
|
|
1355
|
+
},
|
|
1356
|
+
error: (err) => {
|
|
1357
|
+
reject(true);
|
|
1358
|
+
this.flagFetchError = true;
|
|
1359
|
+
console.log('An error occurred while fetching feature flags', err);
|
|
1360
|
+
},
|
|
1361
|
+
});
|
|
1362
|
+
});
|
|
1363
|
+
}
|
|
1364
|
+
buildFeatureFlags(orgId) {
|
|
1365
|
+
orgId = orgId?.toString();
|
|
1366
|
+
const enabledFeatures = {};
|
|
1367
|
+
Object.keys(this.AWSFlags).forEach((flag) => {
|
|
1368
|
+
const flagObj = this.AWSFlags[flag];
|
|
1369
|
+
enabledFeatures[flag] = false;
|
|
1370
|
+
if (flagObj) {
|
|
1371
|
+
if (flagObj?.enabled && !flagObj.hasOwnProperty('enabledOrgIds')) {
|
|
1372
|
+
enabledFeatures[flag] = true;
|
|
1373
|
+
}
|
|
1374
|
+
else if (flagObj?.enabled &&
|
|
1375
|
+
flagObj.hasOwnProperty('enabledOrgIds') &&
|
|
1376
|
+
flagObj?.enabledOrgIds?.length > 0) {
|
|
1377
|
+
if (flagObj?.enabledOrgIds?.includes(orgId)) {
|
|
1378
|
+
enabledFeatures[flag] = true;
|
|
1379
|
+
}
|
|
1380
|
+
else {
|
|
1381
|
+
enabledFeatures[flag] = false;
|
|
1382
|
+
}
|
|
1383
|
+
}
|
|
1384
|
+
else {
|
|
1385
|
+
if (flagObj?.enabled) {
|
|
1386
|
+
enabledFeatures[flag] = true;
|
|
1387
|
+
}
|
|
1388
|
+
else {
|
|
1389
|
+
enabledFeatures[flag] = false;
|
|
1390
|
+
}
|
|
1391
|
+
}
|
|
1392
|
+
}
|
|
1393
|
+
else {
|
|
1394
|
+
enabledFeatures[flag] = true;
|
|
1395
|
+
}
|
|
1396
|
+
});
|
|
1397
|
+
this.featuresMap = enabledFeatures;
|
|
1398
|
+
}
|
|
1399
|
+
isFeatureEnabled(featureFlag) {
|
|
1400
|
+
if (this.featuresMap.hasOwnProperty(featureFlag)) {
|
|
1401
|
+
return this.featuresMap[featureFlag];
|
|
1402
|
+
}
|
|
1403
|
+
else {
|
|
1404
|
+
return true;
|
|
1405
|
+
}
|
|
1406
|
+
}
|
|
1407
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagService, deps: [{ token: i1$2.HttpClient }, { token: i1$1.AuthorizerService }, { token: Configurations, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1408
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagService, providedIn: 'root' }); }
|
|
1409
|
+
}
|
|
1410
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagService, decorators: [{
|
|
1411
|
+
type: Injectable,
|
|
1412
|
+
args: [{
|
|
1413
|
+
providedIn: 'root',
|
|
1414
|
+
}]
|
|
1415
|
+
}], ctorParameters: function () { return [{ type: i1$2.HttpClient }, { type: i1$1.AuthorizerService }, { type: Configurations, decorators: [{
|
|
1416
|
+
type: Optional
|
|
1417
|
+
}] }]; } });
|
|
1483
1418
|
|
|
1484
|
-
class FeatureFlagDirective {
|
|
1485
|
-
constructor(tpl, vcr, featureFlagService) {
|
|
1486
|
-
this.tpl = tpl;
|
|
1487
|
-
this.vcr = vcr;
|
|
1488
|
-
this.featureFlagService = featureFlagService;
|
|
1489
|
-
}
|
|
1490
|
-
ngOnInit() {
|
|
1491
|
-
const isEnabled = this.featureFlagService.isFeatureEnabled(this.featureFlag);
|
|
1492
|
-
if (isEnabled) {
|
|
1493
|
-
this.vcr.createEmbeddedView(this.tpl);
|
|
1494
|
-
}
|
|
1495
|
-
}
|
|
1496
|
-
}
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1500
|
-
type: Directive,
|
|
1501
|
-
args: [{
|
|
1502
|
-
selector: "[featureFlag]"
|
|
1503
|
-
}]
|
|
1504
|
-
}], ctorParameters: function () { return [{ type: i0.TemplateRef }, { type: i0.ViewContainerRef }, { type: FeatureFlagService }]; }, propDecorators: { featureFlag: [{
|
|
1505
|
-
type: Input
|
|
1419
|
+
class FeatureFlagDirective {
|
|
1420
|
+
constructor(tpl, vcr, featureFlagService) {
|
|
1421
|
+
this.tpl = tpl;
|
|
1422
|
+
this.vcr = vcr;
|
|
1423
|
+
this.featureFlagService = featureFlagService;
|
|
1424
|
+
}
|
|
1425
|
+
ngOnInit() {
|
|
1426
|
+
const isEnabled = this.featureFlagService.isFeatureEnabled(this.featureFlag);
|
|
1427
|
+
if (isEnabled) {
|
|
1428
|
+
this.vcr.createEmbeddedView(this.tpl);
|
|
1429
|
+
}
|
|
1430
|
+
}
|
|
1431
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagDirective, deps: [{ token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: FeatureFlagService }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1432
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: FeatureFlagDirective, selector: "[featureFlag]", inputs: { featureFlag: "featureFlag" }, ngImport: i0 }); }
|
|
1433
|
+
}
|
|
1434
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagDirective, decorators: [{
|
|
1435
|
+
type: Directive,
|
|
1436
|
+
args: [{
|
|
1437
|
+
selector: "[featureFlag]"
|
|
1438
|
+
}]
|
|
1439
|
+
}], ctorParameters: function () { return [{ type: i0.TemplateRef }, { type: i0.ViewContainerRef }, { type: FeatureFlagService }]; }, propDecorators: { featureFlag: [{
|
|
1440
|
+
type: Input
|
|
1506
1441
|
}] } });
|
|
1507
1442
|
|
|
1508
|
-
class FeatureFlagModule {
|
|
1509
|
-
}
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
exports: [FeatureFlagDirective]
|
|
1523
|
-
}]
|
|
1443
|
+
class FeatureFlagModule {
|
|
1444
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1445
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagModule, declarations: [FeatureFlagDirective], imports: [CommonModule], exports: [FeatureFlagDirective] }); }
|
|
1446
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagModule, imports: [CommonModule] }); }
|
|
1447
|
+
}
|
|
1448
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FeatureFlagModule, decorators: [{
|
|
1449
|
+
type: NgModule,
|
|
1450
|
+
args: [{
|
|
1451
|
+
declarations: [FeatureFlagDirective],
|
|
1452
|
+
imports: [
|
|
1453
|
+
CommonModule
|
|
1454
|
+
],
|
|
1455
|
+
exports: [FeatureFlagDirective]
|
|
1456
|
+
}]
|
|
1524
1457
|
}] });
|
|
1525
1458
|
|
|
1526
|
-
class
|
|
1527
|
-
constructor() {
|
|
1528
|
-
this.
|
|
1529
|
-
|
|
1459
|
+
class SentryErrorHandler {
|
|
1460
|
+
constructor(authorizerService, errorService, config) {
|
|
1461
|
+
this.authorizerService = authorizerService;
|
|
1462
|
+
this.errorService = errorService;
|
|
1463
|
+
if (config?.sentryConfig) {
|
|
1464
|
+
const SENTRY_CONFIG = config.sentryConfig;
|
|
1465
|
+
Sentry.init({
|
|
1466
|
+
dsn: SENTRY_CONFIG?.DSN,
|
|
1467
|
+
integrations: [
|
|
1468
|
+
new Sentry.BrowserTracing({
|
|
1469
|
+
tracePropagationTargets: SENTRY_CONFIG.ALLOW_ORIGIN,
|
|
1470
|
+
routingInstrumentation: Sentry.routingInstrumentation,
|
|
1471
|
+
}),
|
|
1472
|
+
],
|
|
1473
|
+
tracesSampleRate: SENTRY_CONFIG.TRACES_SAMPLE_RATE,
|
|
1474
|
+
replaysSessionSampleRate: SENTRY_CONFIG.REPLAY_SESSION_SAMPLE_RATE,
|
|
1475
|
+
replaysOnErrorSampleRate: SENTRY_CONFIG.REPLAY_ON_ERROR_SAMPLE_RATE,
|
|
1476
|
+
});
|
|
1477
|
+
Sentry.setUser({ userDetails: this.authorizerService.getUser() });
|
|
1478
|
+
}
|
|
1479
|
+
}
|
|
1480
|
+
handleError(error) {
|
|
1481
|
+
const ERROR = error?.originalError || error;
|
|
1482
|
+
this.handleChunkError(ERROR);
|
|
1483
|
+
Sentry.captureException(ERROR);
|
|
1484
|
+
}
|
|
1485
|
+
handleChunkError(error) {
|
|
1486
|
+
const chunkFailedMessage = /Loading chunk [\d]+ failed/;
|
|
1487
|
+
if (chunkFailedMessage.test(error?.message)) {
|
|
1488
|
+
window.location.reload();
|
|
1489
|
+
}
|
|
1490
|
+
}
|
|
1491
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SentryErrorHandler, deps: [{ token: i1$1.AuthorizerService }, { token: GlobalErrorService }, { token: Configurations, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1492
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SentryErrorHandler }); }
|
|
1530
1493
|
}
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
this.errorService = errorService;
|
|
1536
|
-
if (config?.sentryConfig) {
|
|
1537
|
-
const SENTRY_CONFIG = config.sentryConfig;
|
|
1538
|
-
Sentry.init({
|
|
1539
|
-
dsn: SENTRY_CONFIG?.DSN,
|
|
1540
|
-
integrations: [
|
|
1541
|
-
new Sentry.BrowserTracing({
|
|
1542
|
-
tracePropagationTargets: SENTRY_CONFIG.ALLOW_ORIGIN,
|
|
1543
|
-
routingInstrumentation: Sentry.routingInstrumentation,
|
|
1544
|
-
}),
|
|
1545
|
-
],
|
|
1546
|
-
tracesSampleRate: SENTRY_CONFIG.TRACES_SAMPLE_RATE,
|
|
1547
|
-
replaysSessionSampleRate: SENTRY_CONFIG.REPLAY_SESSION_SAMPLE_RATE,
|
|
1548
|
-
replaysOnErrorSampleRate: SENTRY_CONFIG.REPLAY_ON_ERROR_SAMPLE_RATE,
|
|
1549
|
-
});
|
|
1550
|
-
Sentry.setUser({ userDetails: this.authorizerService.getUser() });
|
|
1551
|
-
}
|
|
1552
|
-
}
|
|
1553
|
-
handleError(error) {
|
|
1554
|
-
const ERROR = error?.originalError || error;
|
|
1555
|
-
this.handleChunkError(ERROR);
|
|
1556
|
-
Sentry.captureException(ERROR);
|
|
1557
|
-
}
|
|
1558
|
-
handleChunkError(error) {
|
|
1559
|
-
const chunkFailedMessage = /Loading chunk [\d]+ failed/;
|
|
1560
|
-
if (chunkFailedMessage.test(error?.message)) {
|
|
1561
|
-
window.location.reload();
|
|
1562
|
-
}
|
|
1563
|
-
}
|
|
1564
|
-
}
|
|
1565
|
-
SentryErrorHandler.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: SentryErrorHandler, deps: [{ token: i1.AuthorizerService }, { token: GlobalErrorService }, { token: Configurations, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1566
|
-
SentryErrorHandler.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: SentryErrorHandler });
|
|
1567
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: SentryErrorHandler, decorators: [{
|
|
1568
|
-
type: Injectable
|
|
1569
|
-
}], ctorParameters: function () { return [{ type: i1.AuthorizerService }, { type: GlobalErrorService }, { type: Configurations, decorators: [{
|
|
1570
|
-
type: Optional
|
|
1494
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SentryErrorHandler, decorators: [{
|
|
1495
|
+
type: Injectable
|
|
1496
|
+
}], ctorParameters: function () { return [{ type: i1$1.AuthorizerService }, { type: GlobalErrorService }, { type: Configurations, decorators: [{
|
|
1497
|
+
type: Optional
|
|
1571
1498
|
}] }]; } });
|
|
1572
1499
|
|
|
1573
|
-
class HttpReqInterceptor {
|
|
1574
|
-
constructor(errorService, featureFlagService) {
|
|
1575
|
-
this.errorService = errorService;
|
|
1576
|
-
this.featureFlagService = featureFlagService;
|
|
1577
|
-
}
|
|
1578
|
-
intercept(req, next) {
|
|
1579
|
-
if (this.featureFlagService.isFeatureEnabled(ERROR_FEATURE_FLAG)) {
|
|
1580
|
-
return next.handle(req).pipe(timeout(API_TIMEOUT_TIME), tap((event) => {
|
|
1581
|
-
if (event instanceof HttpResponse) {
|
|
1582
|
-
this.errorService.handleSoftErrors(event);
|
|
1583
|
-
}
|
|
1584
|
-
}), catchError((error) => {
|
|
1585
|
-
this.errorService.handleError(error, req);
|
|
1586
|
-
return throwError(error);
|
|
1587
|
-
}));
|
|
1588
|
-
}
|
|
1589
|
-
else {
|
|
1590
|
-
return next.handle(req);
|
|
1591
|
-
}
|
|
1592
|
-
}
|
|
1593
|
-
}
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1597
|
-
type: Injectable
|
|
1500
|
+
class HttpReqInterceptor {
|
|
1501
|
+
constructor(errorService, featureFlagService) {
|
|
1502
|
+
this.errorService = errorService;
|
|
1503
|
+
this.featureFlagService = featureFlagService;
|
|
1504
|
+
}
|
|
1505
|
+
intercept(req, next) {
|
|
1506
|
+
if (this.featureFlagService.isFeatureEnabled(ERROR_FEATURE_FLAG)) {
|
|
1507
|
+
return next.handle(req).pipe(timeout(API_TIMEOUT_TIME), tap((event) => {
|
|
1508
|
+
if (event instanceof HttpResponse) {
|
|
1509
|
+
this.errorService.handleSoftErrors(event);
|
|
1510
|
+
}
|
|
1511
|
+
}), catchError((error) => {
|
|
1512
|
+
this.errorService.handleError(error, req);
|
|
1513
|
+
return throwError(error);
|
|
1514
|
+
}));
|
|
1515
|
+
}
|
|
1516
|
+
else {
|
|
1517
|
+
return next.handle(req);
|
|
1518
|
+
}
|
|
1519
|
+
}
|
|
1520
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: HttpReqInterceptor, deps: [{ token: GlobalErrorService }, { token: FeatureFlagService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1521
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: HttpReqInterceptor }); }
|
|
1522
|
+
}
|
|
1523
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: HttpReqInterceptor, decorators: [{
|
|
1524
|
+
type: Injectable
|
|
1598
1525
|
}], ctorParameters: function () { return [{ type: GlobalErrorService }, { type: FeatureFlagService }]; } });
|
|
1599
1526
|
|
|
1600
|
-
const FOR_ROOT_SENTRY_OPTIONS_TOKEN = new InjectionToken('forRoot() SentryErrorHandler options');
|
|
1601
|
-
class VcErrorHandlersModule {
|
|
1602
|
-
constructor(loadConfig) {
|
|
1603
|
-
this.loadConfig = loadConfig;
|
|
1604
|
-
this.loadConfig.loadConfig();
|
|
1605
|
-
}
|
|
1606
|
-
static forRoot(environmentConfig) {
|
|
1607
|
-
return {
|
|
1608
|
-
ngModule: VcErrorHandlersModule,
|
|
1609
|
-
providers: [{ provide: Configurations, useValue: environmentConfig }],
|
|
1610
|
-
};
|
|
1611
|
-
}
|
|
1612
|
-
}
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1634
|
-
type: NgModule,
|
|
1635
|
-
args: [{
|
|
1636
|
-
declarations: [
|
|
1637
|
-
VcErrorHandlersComponent,
|
|
1638
|
-
PageNotFoundComponent,
|
|
1639
|
-
UnauthorizedComponent,
|
|
1640
|
-
SessionExpiredComponent,
|
|
1641
|
-
ChunkUnavailableComponent,
|
|
1642
|
-
ServerErrorComponent,
|
|
1643
|
-
ErrorModalComponent,
|
|
1644
|
-
ComponentLevelServerErrorComponent,
|
|
1645
|
-
],
|
|
1646
|
-
imports: [CommonModule, DialogModule, SnackBarModule, FeatureFlagModule],
|
|
1647
|
-
exports: [
|
|
1648
|
-
VcErrorHandlersComponent,
|
|
1649
|
-
PageNotFoundComponent,
|
|
1650
|
-
UnauthorizedComponent,
|
|
1651
|
-
SessionExpiredComponent,
|
|
1652
|
-
ChunkUnavailableComponent,
|
|
1653
|
-
ServerErrorComponent,
|
|
1654
|
-
ErrorModalComponent,
|
|
1655
|
-
ComponentLevelServerErrorComponent,
|
|
1656
|
-
],
|
|
1657
|
-
providers: [
|
|
1658
|
-
{ provide: ErrorHandler, useClass: SentryErrorHandler },
|
|
1659
|
-
{ provide: HTTP_INTERCEPTORS, useClass: HttpReqInterceptor, multi: true },
|
|
1660
|
-
],
|
|
1661
|
-
bootstrap: [VcErrorHandlersComponent],
|
|
1662
|
-
}]
|
|
1527
|
+
const FOR_ROOT_SENTRY_OPTIONS_TOKEN = new InjectionToken('forRoot() SentryErrorHandler options');
|
|
1528
|
+
class VcErrorHandlersModule {
|
|
1529
|
+
constructor(loadConfig) {
|
|
1530
|
+
this.loadConfig = loadConfig;
|
|
1531
|
+
this.loadConfig.loadConfig();
|
|
1532
|
+
}
|
|
1533
|
+
static forRoot(environmentConfig) {
|
|
1534
|
+
return {
|
|
1535
|
+
ngModule: VcErrorHandlersModule,
|
|
1536
|
+
providers: [{ provide: Configurations, useValue: environmentConfig }],
|
|
1537
|
+
};
|
|
1538
|
+
}
|
|
1539
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersModule, deps: [{ token: FeatureFlagService }], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1540
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersModule, bootstrap: [VcErrorHandlersComponent], declarations: [VcErrorHandlersComponent,
|
|
1541
|
+
PageNotFoundComponent,
|
|
1542
|
+
UnauthorizedComponent,
|
|
1543
|
+
SessionExpiredComponent,
|
|
1544
|
+
ChunkUnavailableComponent,
|
|
1545
|
+
ServerErrorComponent,
|
|
1546
|
+
ErrorModalComponent,
|
|
1547
|
+
ComponentLevelServerErrorComponent], imports: [CommonModule, DialogModule, SnackBarModule, FeatureFlagModule, NgOptimizedImage], exports: [VcErrorHandlersComponent,
|
|
1548
|
+
PageNotFoundComponent,
|
|
1549
|
+
UnauthorizedComponent,
|
|
1550
|
+
SessionExpiredComponent,
|
|
1551
|
+
ChunkUnavailableComponent,
|
|
1552
|
+
ServerErrorComponent,
|
|
1553
|
+
ErrorModalComponent,
|
|
1554
|
+
ComponentLevelServerErrorComponent] }); }
|
|
1555
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersModule, providers: [
|
|
1556
|
+
{ provide: ErrorHandler, useClass: SentryErrorHandler },
|
|
1557
|
+
{ provide: HTTP_INTERCEPTORS, useClass: HttpReqInterceptor, multi: true },
|
|
1558
|
+
], imports: [CommonModule, DialogModule, SnackBarModule, FeatureFlagModule] }); }
|
|
1559
|
+
}
|
|
1560
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: VcErrorHandlersModule, decorators: [{
|
|
1561
|
+
type: NgModule,
|
|
1562
|
+
args: [{
|
|
1563
|
+
declarations: [
|
|
1564
|
+
VcErrorHandlersComponent,
|
|
1565
|
+
PageNotFoundComponent,
|
|
1566
|
+
UnauthorizedComponent,
|
|
1567
|
+
SessionExpiredComponent,
|
|
1568
|
+
ChunkUnavailableComponent,
|
|
1569
|
+
ServerErrorComponent,
|
|
1570
|
+
ErrorModalComponent,
|
|
1571
|
+
ComponentLevelServerErrorComponent,
|
|
1572
|
+
],
|
|
1573
|
+
imports: [CommonModule, DialogModule, SnackBarModule, FeatureFlagModule, NgOptimizedImage],
|
|
1574
|
+
exports: [
|
|
1575
|
+
VcErrorHandlersComponent,
|
|
1576
|
+
PageNotFoundComponent,
|
|
1577
|
+
UnauthorizedComponent,
|
|
1578
|
+
SessionExpiredComponent,
|
|
1579
|
+
ChunkUnavailableComponent,
|
|
1580
|
+
ServerErrorComponent,
|
|
1581
|
+
ErrorModalComponent,
|
|
1582
|
+
ComponentLevelServerErrorComponent,
|
|
1583
|
+
],
|
|
1584
|
+
providers: [
|
|
1585
|
+
{ provide: ErrorHandler, useClass: SentryErrorHandler },
|
|
1586
|
+
{ provide: HTTP_INTERCEPTORS, useClass: HttpReqInterceptor, multi: true },
|
|
1587
|
+
],
|
|
1588
|
+
bootstrap: [VcErrorHandlersComponent],
|
|
1589
|
+
}]
|
|
1663
1590
|
}], ctorParameters: function () { return [{ type: FeatureFlagService }]; } });
|
|
1664
1591
|
|
|
1665
|
-
/*
|
|
1666
|
-
* Public API Surface of vc-error-handlers
|
|
1592
|
+
/*
|
|
1593
|
+
* Public API Surface of vc-error-handlers
|
|
1667
1594
|
*/
|
|
1668
1595
|
|
|
1669
|
-
/**
|
|
1670
|
-
* Generated bundle index. Do not edit.
|
|
1596
|
+
/**
|
|
1597
|
+
* Generated bundle index. Do not edit.
|
|
1671
1598
|
*/
|
|
1672
1599
|
|
|
1673
1600
|
export { ChunkUnavailableComponent, ComponentLevelServerErrorComponent, ErrorModalComponent, FOR_ROOT_SENTRY_OPTIONS_TOKEN, GlobalErrorService, HttpReqInterceptor, PageNotFoundComponent, RouterService, ServerErrorComponent, SessionExpiredComponent, UnauthorizedComponent, VcErrorHandlersComponent, VcErrorHandlersModule, VcErrorHandlersService };
|