@idea-ionic/auth 6.11.1 → 6.12.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.
Files changed (35) hide show
  1. package/environment.d.ts +1 -0
  2. package/esm2020/environment.mjs +3 -2
  3. package/esm2020/public-api.mjs +4 -1
  4. package/esm2020/src/auth.module.mjs +19 -6
  5. package/esm2020/src/auth.service.mjs +167 -42
  6. package/esm2020/src/confirmPassword.page.mjs +16 -22
  7. package/esm2020/src/forgotPassword.page.mjs +17 -24
  8. package/esm2020/src/mfaChallenge.page.mjs +45 -0
  9. package/esm2020/src/newPassword.page.mjs +18 -25
  10. package/esm2020/src/resendLink.page.mjs +12 -17
  11. package/esm2020/src/setupMFA/setupMFA.module.mjs +22 -0
  12. package/esm2020/src/setupMFA/setupMFAButton.component.mjs +43 -0
  13. package/esm2020/src/setupMFA/setupMFAModal.component.mjs +77 -0
  14. package/esm2020/src/setupMFA.page.mjs +24 -0
  15. package/esm2020/src/signIn.page.mjs +36 -47
  16. package/esm2020/src/signUp.page.mjs +18 -32
  17. package/fesm2015/idea-ionic-auth.mjs +485 -211
  18. package/fesm2015/idea-ionic-auth.mjs.map +1 -1
  19. package/fesm2020/idea-ionic-auth.mjs +470 -211
  20. package/fesm2020/idea-ionic-auth.mjs.map +1 -1
  21. package/package.json +2 -1
  22. package/public-api.d.ts +3 -0
  23. package/src/auth.module.d.ts +9 -6
  24. package/src/auth.service.d.ts +54 -13
  25. package/src/confirmPassword.page.d.ts +11 -30
  26. package/src/forgotPassword.page.d.ts +6 -19
  27. package/src/mfaChallenge.page.d.ts +20 -0
  28. package/src/newPassword.page.d.ts +7 -28
  29. package/src/resendLink.page.d.ts +5 -17
  30. package/src/setupMFA/setupMFA.module.d.ts +12 -0
  31. package/src/setupMFA/setupMFAButton.component.d.ts +26 -0
  32. package/src/setupMFA/setupMFAModal.component.d.ts +20 -0
  33. package/src/setupMFA.page.d.ts +10 -0
  34. package/src/signIn.page.d.ts +9 -51
  35. package/src/signUp.page.d.ts +8 -29
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Injectable, Component, NgModule } from '@angular/core';
2
+ import { Injectable, Component, EventEmitter, Input, Output, NgModule } from '@angular/core';
3
3
  import * as i4 from '@angular/common';
4
4
  import { CommonModule } from '@angular/common';
5
5
  import * as i5 from '@angular/forms';
@@ -12,9 +12,10 @@ import * as i2 from '@idea-ionic/common';
12
12
  import { IDEATranslationsModule } from '@idea-ionic/common';
13
13
  import { __awaiter } from 'tslib';
14
14
  import { Browser } from '@capacitor/browser';
15
- import { environment } from '@env';
16
15
  import { CognitoUserPool, AuthenticationDetails, CognitoUser, CognitoUserAttribute, CognitoRefreshToken } from 'amazon-cognito-identity-js';
16
+ import { environment } from '@env';
17
17
  import { isEmpty } from 'idea-toolbox';
18
+ import { toCanvas } from 'qrcode';
18
19
 
19
20
  /**
20
21
  * The name of the Cognito's user attribute which contains the key of the last device to login in this project.
@@ -27,7 +28,9 @@ const DEVICE_KEY_ATTRIBUTE = 'custom:'.concat(environment.idea.project);
27
28
  */
28
29
  class IDEAAuthService {
29
30
  constructor(storage) {
31
+ var _a;
30
32
  this.storage = storage;
33
+ this.mfaProjectName = (_a = environment.idea.app.title) !== null && _a !== void 0 ? _a : environment.idea.project;
31
34
  this.userPool = new CognitoUserPool({
32
35
  UserPoolId: environment.aws.cognito.userPoolId,
33
36
  ClientId: environment.aws.cognito.userPoolClientId
@@ -56,33 +59,63 @@ class IDEAAuthService {
56
59
  */
57
60
  login(username, password) {
58
61
  return new Promise((resolve, reject) => {
59
- // get a cognito user and try to authenticate
60
- this.prepareCognitoUser(username).authenticateUser(this.prepareAuthDetails(username, password), {
61
- onSuccess: () => resolve(false),
62
+ const user = this.prepareCognitoUser(username);
63
+ user.authenticateUser(this.prepareAuthDetails(username, password), {
64
+ onSuccess: () => resolve(environment.idea.auth.forceLoginWithMFA ? LoginOutcomeActions.MFA_SETUP : LoginOutcomeActions.NONE),
62
65
  onFailure: (err) => reject(err),
63
- newPasswordRequired: () => resolve(true)
66
+ newPasswordRequired: () => {
67
+ this.challengeUsername = username;
68
+ this.challengePassword = password;
69
+ resolve(LoginOutcomeActions.NEW_PASSWORD);
70
+ },
71
+ totpRequired: () => {
72
+ this.challengeUsername = username;
73
+ this.challengePassword = password;
74
+ resolve(LoginOutcomeActions.MFA_CHALLENGE);
75
+ }
64
76
  });
65
77
  });
66
78
  }
67
79
  /**
68
- * Complete a complete new password flow in the authentication.
80
+ * Complete the new password flow in the authentication.
69
81
  */
70
- confirmNewPassword(username, tempPassword, newPassword) {
82
+ confirmNewPassword(newPassword) {
71
83
  return new Promise((resolve, reject) => {
72
- // login with the old password
73
- const user = this.prepareCognitoUser(username);
74
- user.authenticateUser(this.prepareAuthDetails(username, tempPassword), {
84
+ const user = this.prepareCognitoUser(this.challengeUsername);
85
+ user.authenticateUser(this.prepareAuthDetails(this.challengeUsername, this.challengePassword), {
75
86
  onSuccess: () => resolve(),
76
87
  onFailure: (err) => reject(err),
77
- newPasswordRequired: () =>
78
- // complete the new password challenge
79
- user.completeNewPasswordChallenge(newPassword, {}, {
80
- onSuccess: () => resolve(),
88
+ newPasswordRequired: () => user.completeNewPasswordChallenge(newPassword, {}, {
89
+ onSuccess: () => {
90
+ this.challengeUsername = null;
91
+ this.challengePassword = null;
92
+ resolve();
93
+ },
81
94
  onFailure: (err) => reject(err)
82
95
  })
83
96
  });
84
97
  });
85
98
  }
99
+ /**
100
+ * Complete the MFA challenge flow in the authentication.
101
+ */
102
+ completeMFAChallenge(otpCode) {
103
+ return new Promise((resolve, reject) => {
104
+ const user = this.prepareCognitoUser(this.challengeUsername);
105
+ user.authenticateUser(this.prepareAuthDetails(this.challengeUsername, this.challengePassword), {
106
+ onSuccess: () => resolve(),
107
+ onFailure: (err) => reject(err),
108
+ totpRequired: (challengeName) => user.sendMFACode(otpCode, {
109
+ onSuccess: () => {
110
+ this.challengeUsername = null;
111
+ this.challengePassword = null;
112
+ resolve();
113
+ },
114
+ onFailure: err => reject(err)
115
+ }, challengeName)
116
+ });
117
+ });
118
+ }
86
119
  /**
87
120
  * Register a new user a set its default attributes.
88
121
  */
@@ -98,9 +131,20 @@ class IDEAAuthService {
98
131
  if (!attributes.email)
99
132
  attrs.push(this.prepareUserAttribute('email', username));
100
133
  // register the new user to the pool
101
- this.userPool.signUp(username, password, attrs, null, (err, res) => err ? reject(err) : resolve(res.user));
134
+ this.userPool.signUp(username, password, attrs, null, (err, res) => {
135
+ if (err)
136
+ return reject(err);
137
+ this.newAccountJustRegistered = username;
138
+ resolve(res.user);
139
+ });
102
140
  });
103
141
  }
142
+ /**
143
+ * In case new account has just been registered, return the username.
144
+ */
145
+ getNewAccountJustRegistered() {
146
+ return this.newAccountJustRegistered;
147
+ }
104
148
  /**
105
149
  * Confirm a new registration through the confirmation code sent by Cognito.
106
150
  */
@@ -163,13 +207,80 @@ class IDEAAuthService {
163
207
  */
164
208
  confirmPassword(username, code, newPwd) {
165
209
  return new Promise((resolve, reject) => {
166
- // get the user and confirm a new password
167
210
  this.prepareCognitoUser(username).confirmPassword(code, newPwd, {
168
211
  onSuccess: () => resolve(),
169
212
  onFailure: (err) => reject(err)
170
213
  });
171
214
  });
172
215
  }
216
+ /**
217
+ * Gets the URL for enabling MFA. This URL can be used to generate a QR Code to read with an authenticator app.
218
+ */
219
+ getURLForEnablingMFA() {
220
+ return new Promise((resolve, reject) => {
221
+ const user = this.userPool.getCurrentUser();
222
+ if (!user)
223
+ return reject();
224
+ user.getSession((err) => {
225
+ if (err)
226
+ return reject(err);
227
+ user.associateSoftwareToken({
228
+ associateSecretCode: (secretCode) => resolve(`otpauth://totp/${encodeURI(this.mfaProjectName)}?secret=${secretCode}`),
229
+ onFailure: (err) => reject(err)
230
+ });
231
+ });
232
+ });
233
+ }
234
+ /**
235
+ * Check whether the user has MFA enabled.
236
+ */
237
+ checkIfUserHasMFAEnabled(bypassCache = false) {
238
+ return new Promise((resolve, reject) => {
239
+ const user = this.userPool.getCurrentUser();
240
+ if (!user)
241
+ return reject();
242
+ user.getSession((err) => {
243
+ if (err)
244
+ return reject(err);
245
+ user.getUserData((err, data) => {
246
+ if (err)
247
+ return reject(err);
248
+ const isMFAEnabled = !!(data.UserMFASettingList && data.UserMFASettingList.includes('SOFTWARE_TOKEN_MFA'));
249
+ resolve(isMFAEnabled);
250
+ }, { bypassCache });
251
+ });
252
+ });
253
+ }
254
+ /**
255
+ * Configure a MFA device for the user.
256
+ */
257
+ setMFADevice(otp, mfaDeviceName, enabled = true, preferred = true) {
258
+ return new Promise((resolve, reject) => {
259
+ const user = this.userPool.getCurrentUser();
260
+ if (!user)
261
+ return reject();
262
+ user.getSession((err) => {
263
+ if (err)
264
+ return reject(err);
265
+ user.verifySoftwareToken(otp, mfaDeviceName, {
266
+ onSuccess: () => user.setUserMfaPreference(null, { Enabled: enabled, PreferredMfa: preferred }, (err) => err ? reject(err) : resolve()),
267
+ onFailure: (err) => reject(err)
268
+ });
269
+ });
270
+ });
271
+ }
272
+ /**
273
+ * Enable a new MFA device for the user by inserting an OTP code generated by it.
274
+ */
275
+ enableMFA(otp, mfaDeviceName = 'default') {
276
+ return this.setMFADevice(otp, mfaDeviceName, true, true);
277
+ }
278
+ /**
279
+ * Disable MFA for a user by inserting an OTP code generated by it.
280
+ */
281
+ disableMFA(otp, mfaDeviceName = 'default') {
282
+ return this.setMFADevice(otp, mfaDeviceName, false, false);
283
+ }
173
284
  /**
174
285
  * Check if a user is currently authenticated.
175
286
  * @param offlineAllowed if set and if offline, skip authentication and retrieve data locally
@@ -191,33 +302,39 @@ class IDEAAuthService {
191
302
  user.getSession((err, session) => {
192
303
  if (err)
193
304
  return reject(err);
194
- // get user attributes
195
- user.getUserAttributes((e, attributes) => {
196
- if (e)
197
- return reject(e);
198
- // remap user attributes
199
- const userDetails = {};
200
- attributes.forEach((a) => (userDetails[a.getName()] = a.getValue()));
201
- // add the user's groups to the attributes
202
- const sessionInfo = session.getAccessToken().decodePayload();
203
- const groups = sessionInfo['cognito:groups'] || [];
204
- userDetails['groups'] = groups;
205
- // run some checks considering the user's groups and devices (based on the project's configuration)
206
- this.runPostAuthChecks(userDetails, err => {
207
- // in case some check failed, reject the authorisation flow
208
- if (err)
209
- return reject(err);
210
- // (async) save the refresh token so it can be accessed by other procedures
211
- this.storage.set('AuthRefreshToken', session.getRefreshToken().getToken());
212
- // set a timer to manage the autorefresh of the idToken (through the refreshToken)
213
- setTimeout(() => this.refreshSession(user, session.getRefreshToken().getToken(), getFreshIdTokenOnExp), 15 * 60 * 1000); // every 15 minutes
214
- // (async) if offlineAllowed, save data locally, to use it next time we'll be offline
215
- if (offlineAllowed)
216
- this.storage.set('AuthUserDetails', userDetails);
217
- // return the idToken (to use with API)
218
- resolve({ idToken: session.getIdToken().getJwtToken(), userDetails });
305
+ user.getUserData((err, data) => {
306
+ if (err)
307
+ return reject(err);
308
+ const isMFAEnabled = !!(data.UserMFASettingList && data.UserMFASettingList.includes('SOFTWARE_TOKEN_MFA'));
309
+ if (!isMFAEnabled && environment.idea.auth.forceLoginWithMFA)
310
+ return reject(new Error(LoginOutcomeActions.MFA_SETUP));
311
+ user.getUserAttributes((e, attributes) => {
312
+ if (e)
313
+ return reject(e);
314
+ // remap user attributes
315
+ const userDetails = {};
316
+ attributes.forEach((a) => (userDetails[a.getName()] = a.getValue()));
317
+ // add the user's groups to the attributes
318
+ const sessionInfo = session.getAccessToken().decodePayload();
319
+ const groups = sessionInfo['cognito:groups'] || [];
320
+ userDetails['groups'] = groups;
321
+ // run some checks considering the user's groups and devices (based on the project's configuration)
322
+ this.runPostAuthChecks(userDetails, err => {
323
+ // in case some check failed, reject the authorisation flow
324
+ if (err)
325
+ return reject(err);
326
+ // (async) save the refresh token so it can be accessed by other procedures
327
+ this.storage.set('AuthRefreshToken', session.getRefreshToken().getToken());
328
+ // set a timer to manage the autorefresh of the idToken (through the refreshToken)
329
+ setTimeout(() => this.refreshSession(user, session.getRefreshToken().getToken(), getFreshIdTokenOnExp), 15 * 60 * 1000); // every 15 minutes
330
+ // (async) if offlineAllowed, save data locally, to use it next time we'll be offline
331
+ if (offlineAllowed)
332
+ this.storage.set('AuthUserDetails', userDetails);
333
+ // return the idToken (to use with API)
334
+ resolve({ idToken: session.getIdToken().getJwtToken(), userDetails });
335
+ });
219
336
  });
220
- });
337
+ }, { bypassCache: true });
221
338
  });
222
339
  }
223
340
  });
@@ -330,212 +447,191 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
330
447
  type: Injectable,
331
448
  args: [{ providedIn: 'root' }]
332
449
  }], ctorParameters: function () { return [{ type: i2.IDEAStorageService }]; } });
450
+ /**
451
+ * The possible actions following a successful login.
452
+ */
453
+ var LoginOutcomeActions;
454
+ (function (LoginOutcomeActions) {
455
+ LoginOutcomeActions["NONE"] = "none";
456
+ LoginOutcomeActions["NEW_PASSWORD"] = "newPassword";
457
+ LoginOutcomeActions["MFA_CHALLENGE"] = "mfaChallenge";
458
+ LoginOutcomeActions["MFA_SETUP"] = "mfaSetup";
459
+ })(LoginOutcomeActions || (LoginOutcomeActions = {}));
333
460
 
334
461
  class IDEASignInPage {
335
- constructor(navCtrl, tc, message, loading, auth, t) {
462
+ constructor(navCtrl, message, loading, auth, t) {
336
463
  this.navCtrl = navCtrl;
337
- this.tc = tc;
338
464
  this.message = message;
339
465
  this.loading = loading;
340
466
  this.auth = auth;
341
467
  this.t = t;
342
- this.darkMode = window.matchMedia('(prefers-color-scheme: dark)').matches;
343
468
  this.title = environment.idea.app.title;
344
469
  this.registrationPossible = environment.idea.auth.registrationIsPossible;
345
470
  this.hasIntroPage = environment.idea.app.hasIntroPage;
346
471
  this.website = environment.idea.website;
347
472
  this.agreementsCheck = true;
473
+ this.newAccountRegistered = false;
474
+ this.darkMode = window.matchMedia('(prefers-color-scheme: dark)').matches;
348
475
  }
349
476
  ionViewDidEnter() {
350
477
  // manage the scenario in which we just created a new account (show a explanatory message: email must be confirmed)
351
- if (this.tc.get('newAccountRegistered')) {
352
- this.newAccountRegistered = true;
353
- this.email = this.tc.get('newAccountRegistered', true);
354
- }
478
+ this.newAccountRegistered = !!this.auth.getNewAccountJustRegistered();
479
+ if (this.newAccountRegistered)
480
+ this.email = this.auth.getNewAccountJustRegistered();
355
481
  }
356
- /**
357
- * Sign-in with the auth details provided.
358
- */
359
482
  login() {
483
+ var _a;
360
484
  return __awaiter(this, void 0, void 0, function* () {
361
485
  if (!this.agreementsCheck)
362
486
  return;
363
- this.errorMsg = null;
364
- yield this.loading.show();
365
- this.auth
366
- .login(this.email, this.password)
367
- .then(needNewPassword => {
368
- if (needNewPassword) {
369
- this.tc.set('email', this.email);
370
- this.tc.set('password', this.password);
371
- this.navCtrl.navigateForward(['auth/new-password']);
372
- }
487
+ try {
488
+ this.errorMsg = null;
489
+ yield this.loading.show();
490
+ const loginAction = yield this.auth.login(this.email, this.password);
491
+ if (loginAction === LoginOutcomeActions.NEW_PASSWORD)
492
+ this.navCtrl.navigateForward(['auth', 'new-password']);
493
+ else if (loginAction === LoginOutcomeActions.MFA_CHALLENGE)
494
+ this.navCtrl.navigateForward(['auth', 'mfa-challenge']);
495
+ else if (loginAction === LoginOutcomeActions.MFA_SETUP)
496
+ this.navCtrl.navigateForward(['auth', 'setup-mfa']);
373
497
  else
374
- window.location.assign(''); // hard reload
375
- })
376
- .catch(err => {
377
- var _a;
498
+ window.location.assign('');
499
+ }
500
+ catch (err) {
378
501
  if (err.name === 'UserNotConfirmedException')
379
502
  this.errorMsg = this.t._('IDEA_AUTH.CONFIRM_YOUR_EMAIL_TO_LOGIN');
380
- else if (err.name === 'UserLambdaValidationException' && ((_a = err.message) === null || _a === void 0 ? void 0 : _a.includes('@IDEA_COGNITO_TRANSITION')))
503
+ else if (err.name === 'UserLambdaValidationException' &&
504
+ ((_a = err.message) === null || _a === void 0 ? void 0 : _a.includes('@IDEA_COGNITO_TRANSITION')))
381
505
  this.errorMsg = this.t._('IDEA_AUTH.CHANGE_YOUR_PASSWORD_TO_LOGIN');
382
506
  this.message.error('IDEA_AUTH.AUTHENTICATION_FAILED');
383
- })
384
- .finally(() => this.loading.hide());
507
+ }
508
+ finally {
509
+ this.loading.hide();
510
+ }
385
511
  });
386
512
  }
387
- /**
388
- * Go to the homepage.
389
- */
390
513
  goToIntro() {
391
514
  this.navCtrl.navigateBack(['intro']);
392
515
  }
393
- /**
394
- * Go to the forgot password page.
395
- */
396
516
  goToForgotPassword() {
397
517
  this.navCtrl.navigateForward(['auth/forgot-password']);
398
518
  }
399
- /**
400
- * Go to registration page.
401
- */
402
519
  goToRegistration() {
403
- this.tc.set('email', this.email);
404
- this.tc.set('password', this.password);
405
520
  this.navCtrl.navigateForward(['auth', 'sign-up']);
406
521
  }
407
- /**
408
- * Open a URL in the browser.
409
- */
522
+ translationExists(key) {
523
+ return !!this.t._(key);
524
+ }
410
525
  openLink(url) {
411
- Browser.open({ url });
526
+ return __awaiter(this, void 0, void 0, function* () {
527
+ yield Browser.open({ url });
528
+ });
412
529
  }
413
530
  }
414
- IDEASignInPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASignInPage, deps: [{ token: i1.NavController }, { token: i2.IDEATinCanService }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
415
- IDEASignInPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASignInPage, selector: "idea-sign-in", ngImport: i0, template: "<ion-content>\n <ion-card color=\"warning\" *ngIf=\"newAccountRegistered\">\n <ion-card-content>{{ 'IDEA_AUTH.CONFIRM_YOUR_EMAIL_TO_LOGIN' | translate }}</ion-card-content>\n </ion-card>\n <form class=\"flexBox\">\n <div>\n <ion-card class=\"authCard\">\n <ion-img\n [title]=\"t._('IDEA_AUTH.SERVICE_LOGO')\"\n [src]=\"darkMode ? 'assets/icons/icon-auth-alt.svg' : 'assets/icons/icon-auth.svg'\"\n ></ion-img>\n <ion-card-header>\n <ion-card-title color=\"primary\" *ngIf=\"title\">{{ title }}</ion-card-title>\n <ion-card-subtitle *ngIf=\"t._('IDEA_VARIABLES.TAGLINE')\">\n {{ 'IDEA_VARIABLES.TAGLINE' | translate }}\n </ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\"><b>{{ 'IDEA_AUTH.WARNING' | translate }}.</b> {{ errorMsg }}</p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n id=\"current-password\"\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"current-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.PASSWORD_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"\n !registrationPossible &&\n (t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || t._('IDEA_VARIABLES.PRIVACY_POLICY_URL'))\n \"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_LOGIN' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"t._('IDEA_AUTH.TERMS_AND_CONDITIONS_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n t._('IDEA_VARIABLES.PRIVACY_POLICY_URL') && t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"t._('IDEA_AUTH.PRIVACY_POLICY_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"t._('IDEA_AUTH.SIGN_IN_HINT')\"\n (click)=\"login()\"\n >\n {{ 'IDEA_AUTH.SIGN_IN' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n *ngIf=\"registrationPossible\"\n [title]=\"t._('IDEA_AUTH.CREATE_AN_ACCOUNT_HINT')\"\n (click)=\"goToRegistration()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.I_FORGOT_MY_PASSWORD_HINT')\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.I_FORGOT_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n color=\"medium\"\n class=\"smallCaseButton\"\n *ngIf=\"hasIntroPage\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_INTRO_HINT')\"\n (click)=\"goToIntro()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_INTRO' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n <ion-img\n class=\"ideaLogo\"\n *ngIf=\"website\"\n [src]=\"darkMode ? './assets/icons/idea-alt.png' : './assets/icons/idea.png'\"\n [title]=\"t._('IDEA_AUTH.IDEA_TAGLINE')\"\n (click)=\"openLink(website)\"\n ></ion-img>\n </div>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCheckbox, selector: "ion-checkbox", inputs: ["checked", "color", "disabled", "indeterminate", "mode", "name", "value"] }, { kind: "component", type: i1.IonCol, selector: "ion-col", inputs: ["offset", "offsetLg", "offsetMd", "offsetSm", "offsetXl", "offsetXs", "pull", "pullLg", "pullMd", "pullSm", "pullXl", "pullXs", "push", "pushLg", "pushMd", "pushSm", "pushXl", "pushXs", "size", "sizeLg", "sizeMd", "sizeSm", "sizeXl", "sizeXs"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonImg, selector: "ion-img", inputs: ["alt", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i1.IonRow, selector: "ion-row" }, { kind: "component", type: i1.IonText, selector: "ion-text", inputs: ["color", "mode"] }, { kind: "directive", type: i1.BooleanValueAccessor, selector: "ion-checkbox,ion-toggle" }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
531
+ IDEASignInPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASignInPage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
532
+ IDEASignInPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASignInPage, selector: "idea-sign-in", ngImport: i0, template: "<ion-content>\n <ion-card color=\"warning\" *ngIf=\"newAccountRegistered\">\n <ion-card-content>{{ 'IDEA_AUTH.CONFIRM_YOUR_EMAIL_TO_LOGIN' | translate }}</ion-card-content>\n </ion-card>\n <form class=\"flexBox\">\n <div>\n <ion-card class=\"authCard\">\n <ion-img\n [title]=\"'IDEA_AUTH.SERVICE_LOGO' | translate\"\n [src]=\"darkMode ? 'assets/icons/icon-auth-alt.svg' : 'assets/icons/icon-auth.svg'\"\n ></ion-img>\n <ion-card-header>\n <ion-card-title color=\"primary\" *ngIf=\"title\">{{ title }}</ion-card-title>\n <ion-card-subtitle *ngIf=\"translationExists('IDEA_VARIABLES.TAGLINE')\">\n {{ 'IDEA_VARIABLES.TAGLINE' | translate }}\n </ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\"><b>{{ 'IDEA_AUTH.WARNING' | translate }}.</b> {{ errorMsg }}</p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n id=\"current-password\"\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"current-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.PASSWORD_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"\n !registrationPossible &&\n (translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL'))\n \"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_LOGIN' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"'IDEA_AUTH.TERMS_AND_CONDITIONS_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL' | translate\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL') && translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"'IDEA_AUTH.PRIVACY_POLICY_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.PRIVACY_POLICY_URL' | translate\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"'IDEA_AUTH.SIGN_IN_HINT' | translate\"\n (click)=\"login()\"\n >\n {{ 'IDEA_AUTH.SIGN_IN' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n *ngIf=\"registrationPossible\"\n [title]=\"'IDEA_AUTH.CREATE_AN_ACCOUNT_HINT' | translate\"\n (click)=\"goToRegistration()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.I_FORGOT_MY_PASSWORD_HINT' | translate\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.I_FORGOT_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n color=\"medium\"\n class=\"smallCaseButton\"\n *ngIf=\"hasIntroPage\"\n [title]=\"'IDEA_AUTH.BACK_TO_INTRO_HINT' | translate\"\n (click)=\"goToIntro()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_INTRO' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n <ion-img\n class=\"ideaLogo\"\n *ngIf=\"website\"\n [src]=\"darkMode ? './assets/icons/idea-alt.png' : './assets/icons/idea.png'\"\n [title]=\"'IDEA_AUTH.IDEA_TAGLINE' | translate\"\n (click)=\"openLink(website)\"\n ></ion-img>\n </div>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCheckbox, selector: "ion-checkbox", inputs: ["checked", "color", "disabled", "indeterminate", "mode", "name", "value"] }, { kind: "component", type: i1.IonCol, selector: "ion-col", inputs: ["offset", "offsetLg", "offsetMd", "offsetSm", "offsetXl", "offsetXs", "pull", "pullLg", "pullMd", "pullSm", "pullXl", "pullXs", "push", "pushLg", "pushMd", "pushSm", "pushXl", "pushXs", "size", "sizeLg", "sizeMd", "sizeSm", "sizeXl", "sizeXs"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonImg, selector: "ion-img", inputs: ["alt", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i1.IonRow, selector: "ion-row" }, { kind: "component", type: i1.IonText, selector: "ion-text", inputs: ["color", "mode"] }, { kind: "directive", type: i1.BooleanValueAccessor, selector: "ion-checkbox,ion-toggle" }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
416
533
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASignInPage, decorators: [{
417
534
  type: Component,
418
- args: [{ selector: 'idea-sign-in', template: "<ion-content>\n <ion-card color=\"warning\" *ngIf=\"newAccountRegistered\">\n <ion-card-content>{{ 'IDEA_AUTH.CONFIRM_YOUR_EMAIL_TO_LOGIN' | translate }}</ion-card-content>\n </ion-card>\n <form class=\"flexBox\">\n <div>\n <ion-card class=\"authCard\">\n <ion-img\n [title]=\"t._('IDEA_AUTH.SERVICE_LOGO')\"\n [src]=\"darkMode ? 'assets/icons/icon-auth-alt.svg' : 'assets/icons/icon-auth.svg'\"\n ></ion-img>\n <ion-card-header>\n <ion-card-title color=\"primary\" *ngIf=\"title\">{{ title }}</ion-card-title>\n <ion-card-subtitle *ngIf=\"t._('IDEA_VARIABLES.TAGLINE')\">\n {{ 'IDEA_VARIABLES.TAGLINE' | translate }}\n </ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\"><b>{{ 'IDEA_AUTH.WARNING' | translate }}.</b> {{ errorMsg }}</p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n id=\"current-password\"\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"current-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.PASSWORD_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"\n !registrationPossible &&\n (t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || t._('IDEA_VARIABLES.PRIVACY_POLICY_URL'))\n \"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_LOGIN' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"t._('IDEA_AUTH.TERMS_AND_CONDITIONS_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n t._('IDEA_VARIABLES.PRIVACY_POLICY_URL') && t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"t._('IDEA_AUTH.PRIVACY_POLICY_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"t._('IDEA_AUTH.SIGN_IN_HINT')\"\n (click)=\"login()\"\n >\n {{ 'IDEA_AUTH.SIGN_IN' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n *ngIf=\"registrationPossible\"\n [title]=\"t._('IDEA_AUTH.CREATE_AN_ACCOUNT_HINT')\"\n (click)=\"goToRegistration()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.I_FORGOT_MY_PASSWORD_HINT')\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.I_FORGOT_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n color=\"medium\"\n class=\"smallCaseButton\"\n *ngIf=\"hasIntroPage\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_INTRO_HINT')\"\n (click)=\"goToIntro()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_INTRO' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n <ion-img\n class=\"ideaLogo\"\n *ngIf=\"website\"\n [src]=\"darkMode ? './assets/icons/idea-alt.png' : './assets/icons/idea.png'\"\n [title]=\"t._('IDEA_AUTH.IDEA_TAGLINE')\"\n (click)=\"openLink(website)\"\n ></ion-img>\n </div>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
419
- }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEATinCanService }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
535
+ args: [{ selector: 'idea-sign-in', template: "<ion-content>\n <ion-card color=\"warning\" *ngIf=\"newAccountRegistered\">\n <ion-card-content>{{ 'IDEA_AUTH.CONFIRM_YOUR_EMAIL_TO_LOGIN' | translate }}</ion-card-content>\n </ion-card>\n <form class=\"flexBox\">\n <div>\n <ion-card class=\"authCard\">\n <ion-img\n [title]=\"'IDEA_AUTH.SERVICE_LOGO' | translate\"\n [src]=\"darkMode ? 'assets/icons/icon-auth-alt.svg' : 'assets/icons/icon-auth.svg'\"\n ></ion-img>\n <ion-card-header>\n <ion-card-title color=\"primary\" *ngIf=\"title\">{{ title }}</ion-card-title>\n <ion-card-subtitle *ngIf=\"translationExists('IDEA_VARIABLES.TAGLINE')\">\n {{ 'IDEA_VARIABLES.TAGLINE' | translate }}\n </ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\"><b>{{ 'IDEA_AUTH.WARNING' | translate }}.</b> {{ errorMsg }}</p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n id=\"current-password\"\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"current-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.PASSWORD_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"login()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"\n !registrationPossible &&\n (translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL'))\n \"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_LOGIN' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"'IDEA_AUTH.TERMS_AND_CONDITIONS_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL' | translate\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL') && translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"'IDEA_AUTH.PRIVACY_POLICY_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.PRIVACY_POLICY_URL' | translate\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"'IDEA_AUTH.SIGN_IN_HINT' | translate\"\n (click)=\"login()\"\n >\n {{ 'IDEA_AUTH.SIGN_IN' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n *ngIf=\"registrationPossible\"\n [title]=\"'IDEA_AUTH.CREATE_AN_ACCOUNT_HINT' | translate\"\n (click)=\"goToRegistration()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.I_FORGOT_MY_PASSWORD_HINT' | translate\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.I_FORGOT_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n color=\"medium\"\n class=\"smallCaseButton\"\n *ngIf=\"hasIntroPage\"\n [title]=\"'IDEA_AUTH.BACK_TO_INTRO_HINT' | translate\"\n (click)=\"goToIntro()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_INTRO' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n <ion-img\n class=\"ideaLogo\"\n *ngIf=\"website\"\n [src]=\"darkMode ? './assets/icons/idea-alt.png' : './assets/icons/idea.png'\"\n [title]=\"'IDEA_AUTH.IDEA_TAGLINE' | translate\"\n (click)=\"openLink(website)\"\n ></ion-img>\n </div>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
536
+ }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
420
537
 
421
538
  class IDEASignUpPage {
422
- constructor(navCtrl, tc, message, loading, auth, t) {
539
+ constructor(navCtrl, message, loading, auth, t) {
423
540
  this.navCtrl = navCtrl;
424
- this.tc = tc;
425
541
  this.message = message;
426
542
  this.loading = loading;
427
543
  this.auth = auth;
428
544
  this.t = t;
429
- this.email = this.tc.get('email', true);
430
- this.password = this.tc.get('password', true);
431
545
  this.agreementsCheck = false;
432
546
  }
433
547
  ngOnInit() {
434
548
  if (!environment.idea.auth.registrationIsPossible)
435
549
  return this.goToAuth();
436
- // if there isn't any agreement to agree to, set the check true
437
550
  this.agreementsCheck =
438
551
  this.t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || this.t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')
439
552
  ? this.agreementsCheck
440
553
  : true;
441
554
  }
442
- /**
443
- * Register the new user in cognito (note DynamoDB still need to be managed).
444
- */
445
555
  register() {
446
556
  return __awaiter(this, void 0, void 0, function* () {
447
557
  this.errorMsg = null;
448
- // check the fields
449
558
  if (isEmpty(this.email, 'email'))
450
559
  this.errorMsg = this.t._('IDEA_AUTH.VALID_EMAIL_OBLIGATORY');
451
560
  else if (!this.password || this.password.length < 8)
452
561
  this.errorMsg = this.t._('IDEA_AUTH.PASSWORD_POLICY_VIOLATION', { n: 8 });
453
- // output the error, if there was one
454
562
  if (this.errorMsg)
455
563
  return this.message.error('IDEA_AUTH.REGISTRATION_FAILED');
456
- // start the registration
457
- yield this.loading.show();
458
- this.auth
459
- .register(this.email, this.password)
460
- .then(() => {
564
+ try {
565
+ yield this.loading.show();
566
+ yield this.auth.register(this.email, this.password);
461
567
  this.message.success('IDEA_AUTH.REGISTRATION_COMPLETED');
462
- this.tc.set('newAccountRegistered', this.email);
463
568
  this.goToAuth();
464
- })
465
- .catch(err => {
466
- // show the unexpected error on screen (english)
569
+ }
570
+ catch (err) {
467
571
  this.errorMsg = err.message;
468
572
  this.message.error('IDEA_AUTH.REGISTRATION_FAILED');
469
- })
470
- .finally(() => this.loading.hide());
573
+ }
574
+ finally {
575
+ this.loading.hide();
576
+ }
471
577
  });
472
578
  }
473
- /**
474
- * Go to the resend link page.
475
- */
579
+ translationExists(key) {
580
+ return !!this.t._(key);
581
+ }
476
582
  goToResendLink() {
477
583
  this.navCtrl.navigateForward(['auth/resend-link']);
478
584
  }
479
- /**
480
- * Go to auth page.
481
- */
482
585
  goToAuth() {
483
586
  this.navCtrl.navigateBack(['auth']);
484
587
  }
485
588
  }
486
- IDEASignUpPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASignUpPage, deps: [{ token: i1.NavController }, { token: i2.IDEATinCanService }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
487
- IDEASignUpPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASignUpPage, selector: "idea-sign-up", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.NEW_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.REGISTER_A_NEW_ACCOUNT_TO_THE_SYSTEM' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.REGISTRATION_EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.CHOOSE_A_PASSWORD')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_REGISTRATION' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"t._('IDEA_AUTH.TERMS_AND_CONDITIONS_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n t._('IDEA_VARIABLES.PRIVACY_POLICY_URL') && t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"t._('IDEA_AUTH.PRIVACY_POLICY_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"t._('IDEA_AUTH.CREATE_AN_ACCOUNT_HINT')\"\n (click)=\"register()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK_HINT')\"\n (click)=\"goToResendLink()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCheckbox, selector: "ion-checkbox", inputs: ["checked", "color", "disabled", "indeterminate", "mode", "name", "value"] }, { kind: "component", type: i1.IonCol, selector: "ion-col", inputs: ["offset", "offsetLg", "offsetMd", "offsetSm", "offsetXl", "offsetXs", "pull", "pullLg", "pullMd", "pullSm", "pullXl", "pullXs", "push", "pushLg", "pushMd", "pushSm", "pushXl", "pushXs", "size", "sizeLg", "sizeMd", "sizeSm", "sizeXl", "sizeXs"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i1.IonRow, selector: "ion-row" }, { kind: "component", type: i1.IonText, selector: "ion-text", inputs: ["color", "mode"] }, { kind: "directive", type: i1.BooleanValueAccessor, selector: "ion-checkbox,ion-toggle" }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
589
+ IDEASignUpPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASignUpPage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
590
+ IDEASignUpPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASignUpPage, selector: "idea-sign-up", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.NEW_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.REGISTER_A_NEW_ACCOUNT_TO_THE_SYSTEM' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.REGISTRATION_EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_REGISTRATION' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"'IDEA_AUTH.TERMS_AND_CONDITIONS_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL' | translate\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL') && translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"'IDEA_AUTH.PRIVACY_POLICY_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.PRIVACY_POLICY_URL' | translate\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"'IDEA_AUTH.CREATE_AN_ACCOUNT_HINT' | translate\"\n (click)=\"register()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK_HINT' | translate\"\n (click)=\"goToResendLink()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCheckbox, selector: "ion-checkbox", inputs: ["checked", "color", "disabled", "indeterminate", "mode", "name", "value"] }, { kind: "component", type: i1.IonCol, selector: "ion-col", inputs: ["offset", "offsetLg", "offsetMd", "offsetSm", "offsetXl", "offsetXs", "pull", "pullLg", "pullMd", "pullSm", "pullXl", "pullXs", "push", "pushLg", "pushMd", "pushSm", "pushXl", "pushXs", "size", "sizeLg", "sizeMd", "sizeSm", "sizeXl", "sizeXs"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i1.IonRow, selector: "ion-row" }, { kind: "component", type: i1.IonText, selector: "ion-text", inputs: ["color", "mode"] }, { kind: "directive", type: i1.BooleanValueAccessor, selector: "ion-checkbox,ion-toggle" }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
488
591
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASignUpPage, decorators: [{
489
592
  type: Component,
490
- args: [{ selector: 'idea-sign-up', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.NEW_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.REGISTER_A_NEW_ACCOUNT_TO_THE_SYSTEM' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.REGISTRATION_EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.CHOOSE_A_PASSWORD')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_REGISTRATION' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"t._('IDEA_AUTH.TERMS_AND_CONDITIONS_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n t._('IDEA_VARIABLES.PRIVACY_POLICY_URL') && t._('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"t._('IDEA_AUTH.PRIVACY_POLICY_HINT')\"\n [href]=\"t._('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"t._('IDEA_AUTH.CREATE_AN_ACCOUNT_HINT')\"\n (click)=\"register()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK_HINT')\"\n (click)=\"goToResendLink()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
491
- }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEATinCanService }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
593
+ args: [{ selector: 'idea-sign-up', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.NEW_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.REGISTER_A_NEW_ACCOUNT_TO_THE_SYSTEM' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.REGISTRATION_EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"password\"\n (keyup.enter)=\"register()\"\n ></ion-input>\n </ion-item>\n <ion-row\n class=\"agreementsAcceptanceRow\"\n *ngIf=\"translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL') || translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n >\n <ion-col>\n <ion-checkbox\n size=\"small\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"agreementsCheck\"\n ></ion-checkbox>\n {{ 'IDEA_AUTH.AGREEMENTS_CHECK_REGISTRATION' | translate }}:\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\"\n [title]=\"'IDEA_AUTH.TERMS_AND_CONDITIONS_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL' | translate\"\n >\n {{ 'IDEA_AUTH.TERMS_AND_CONDITIONS' | translate }}\n </a>\n <ion-text\n *ngIf=\"\n translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL') && translationExists('IDEA_VARIABLES.TERMS_AND_CONDITIONS_URL')\n \"\n >\n &\n </ion-text>\n <a\n ion-text\n color=\"primary\"\n target=\"_blank\"\n *ngIf=\"translationExists('IDEA_VARIABLES.PRIVACY_POLICY_URL')\"\n [title]=\"'IDEA_AUTH.PRIVACY_POLICY_HINT' | translate\"\n [href]=\"'IDEA_VARIABLES.PRIVACY_POLICY_URL' | translate\"\n >\n {{ 'IDEA_AUTH.PRIVACY_POLICY' | translate }}\n </a>\n </ion-col>\n </ion-row>\n <ion-button\n expand=\"block\"\n [disabled]=\"!agreementsCheck\"\n [title]=\"'IDEA_AUTH.CREATE_AN_ACCOUNT_HINT' | translate\"\n (click)=\"register()\"\n >\n {{ 'IDEA_AUTH.CREATE_AN_ACCOUNT' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK_HINT' | translate\"\n (click)=\"goToResendLink()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_CONFIRMATION_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
594
+ }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
492
595
 
493
596
  class IDEANewPasswordPage {
494
- constructor(navCtrl, tc, message, loading, auth, t) {
597
+ constructor(navCtrl, message, loading, auth, t) {
495
598
  this.navCtrl = navCtrl;
496
- this.tc = tc;
497
599
  this.message = message;
498
600
  this.loading = loading;
499
601
  this.auth = auth;
500
602
  this.t = t;
501
603
  }
502
604
  ngOnInit() {
503
- this.email = this.tc.get('email', true);
504
- this.password = this.tc.get('password', true);
505
- if (!this.email || !this.password)
605
+ if (!this.auth.challengeUsername)
506
606
  this.goToAuth();
507
607
  }
508
- /**
509
- * Confirm a new password (auth flow that follows a registration or a password reset).
510
- */
511
608
  confirmNewPassword() {
512
609
  return __awaiter(this, void 0, void 0, function* () {
513
- this.errorMsg = null;
514
- yield this.loading.show();
515
- this.auth
516
- .confirmNewPassword(this.email, this.password, this.newPassword)
517
- // we are logged in
518
- .then(() => window.location.assign(''))
519
- .catch(() => {
610
+ try {
611
+ this.errorMsg = null;
612
+ yield this.loading.show();
613
+ yield this.auth.confirmNewPassword(this.newPassword);
614
+ window.location.assign('');
615
+ }
616
+ catch (error) {
520
617
  this.errorMsg = this.t._('IDEA_AUTH.PASSWORD_POLICY_VIOLATION', { n: 8 });
521
618
  this.message.error(this.errorMsg, true);
522
- })
523
- .finally(() => this.loading.hide());
619
+ }
620
+ finally {
621
+ this.loading.hide();
622
+ }
524
623
  });
525
624
  }
526
- /**
527
- * Go to auth page.
528
- */
529
625
  goToAuth() {
530
626
  this.navCtrl.navigateBack(['auth']);
531
627
  }
532
628
  }
533
- IDEANewPasswordPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEANewPasswordPage, deps: [{ token: i1.NavController }, { token: i2.IDEATinCanService }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
534
- IDEANewPasswordPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEANewPasswordPage, selector: "idea-new-password", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.YOU_NEED_TO_CHOOSE_A_NEW_PASSWORD' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.CHOOSE_A_PASSWORD')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmNewPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.CONFIRM_NEW_PASSWORD_HINT')\" (click)=\"confirmNewPassword()\">\n {{ 'IDEA_AUTH.CONFIRM_NEW_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
629
+ IDEANewPasswordPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEANewPasswordPage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
630
+ IDEANewPasswordPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEANewPasswordPage, selector: "idea-new-password", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.YOU_NEED_TO_CHOOSE_A_NEW_PASSWORD' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmNewPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.CONFIRM_NEW_PASSWORD_HINT' | translate\"\n (click)=\"confirmNewPassword()\"\n >\n {{ 'IDEA_AUTH.CONFIRM_NEW_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
535
631
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEANewPasswordPage, decorators: [{
536
632
  type: Component,
537
- args: [{ selector: 'idea-new-password', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.YOU_NEED_TO_CHOOSE_A_NEW_PASSWORD' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.CHOOSE_A_PASSWORD')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmNewPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.CONFIRM_NEW_PASSWORD_HINT')\" (click)=\"confirmNewPassword()\">\n {{ 'IDEA_AUTH.CONFIRM_NEW_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
538
- }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEATinCanService }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
633
+ args: [{ selector: 'idea-new-password', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.YOU_NEED_TO_CHOOSE_A_NEW_PASSWORD' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmNewPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.CONFIRM_NEW_PASSWORD_HINT' | translate\"\n (click)=\"confirmNewPassword()\"\n >\n {{ 'IDEA_AUTH.CONFIRM_NEW_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
634
+ }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
539
635
 
540
636
  class IDEAResendLinkPage {
541
637
  constructor(navCtrl, message, loading, auth, t) {
@@ -545,9 +641,6 @@ class IDEAResendLinkPage {
545
641
  this.auth = auth;
546
642
  this.t = t;
547
643
  }
548
- /**
549
- * Resend the link to confirm the email address.
550
- */
551
644
  resendConfirmationLink() {
552
645
  return __awaiter(this, void 0, void 0, function* () {
553
646
  this.errorMsg = null;
@@ -556,77 +649,69 @@ class IDEAResendLinkPage {
556
649
  this.message.error('IDEA_AUTH.SENDING_FAILED');
557
650
  return;
558
651
  }
559
- yield this.loading.show();
560
- this.auth
561
- .resendConfirmationCode(this.email)
562
- .then(() => {
652
+ try {
653
+ yield this.loading.show();
654
+ yield this.auth.resendConfirmationCode(this.email);
563
655
  this.message.success('IDEA_AUTH.CONFIRMATION_LINK_SENT');
564
656
  this.goToAuth();
565
- })
566
- .catch(() => {
657
+ }
658
+ catch (error) {
567
659
  this.errorMsg = this.t._('IDEA_AUTH.IS_THE_EMAIL_CORRECT');
568
660
  this.message.error('IDEA_AUTH.SENDING_FAILED');
569
- })
570
- .finally(() => this.loading.hide());
661
+ }
662
+ finally {
663
+ this.loading.hide();
664
+ }
571
665
  });
572
666
  }
573
- /**
574
- * Go to auth page.
575
- */
576
667
  goToAuth() {
577
668
  this.navCtrl.navigateBack(['auth']);
578
669
  }
579
670
  }
580
671
  IDEAResendLinkPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAResendLinkPage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
581
- IDEAResendLinkPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAResendLinkPage, selector: "idea-resend-link", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CONFIRM_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.RESEND_CONFIRMATION_LINK_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"resendConfirmationLink()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.RESEND_LINK_HINT')\" (click)=\"resendConfirmationLink()\">\n {{ 'IDEA_AUTH.RESEND_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
672
+ IDEAResendLinkPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAResendLinkPage, selector: "idea-resend-link", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CONFIRM_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.RESEND_CONFIRMATION_LINK_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"resendConfirmationLink()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.RESEND_LINK_HINT' | translate\"\n (click)=\"resendConfirmationLink()\"\n >\n {{ 'IDEA_AUTH.RESEND_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
582
673
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAResendLinkPage, decorators: [{
583
674
  type: Component,
584
- args: [{ selector: 'idea-resend-link', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CONFIRM_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.RESEND_CONFIRMATION_LINK_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"resendConfirmationLink()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.RESEND_LINK_HINT')\" (click)=\"resendConfirmationLink()\">\n {{ 'IDEA_AUTH.RESEND_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
675
+ args: [{ selector: 'idea-resend-link', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CONFIRM_ACCOUNT' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.RESEND_CONFIRMATION_LINK_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"resendConfirmationLink()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.RESEND_LINK_HINT' | translate\"\n (click)=\"resendConfirmationLink()\"\n >\n {{ 'IDEA_AUTH.RESEND_LINK' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
585
676
  }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
586
677
 
587
678
  class IDEAForgotPasswordPage {
588
- constructor(navCtrl, message, loading, auth, t) {
679
+ constructor(navCtrl, message, loading, auth) {
589
680
  this.navCtrl = navCtrl;
590
681
  this.message = message;
591
682
  this.loading = loading;
592
683
  this.auth = auth;
593
- this.t = t;
594
684
  }
595
- /**
596
- * "I forgot my password" procedure.
597
- */
598
685
  forgotPassword() {
599
686
  return __awaiter(this, void 0, void 0, function* () {
600
- yield this.loading.show();
601
- this.auth
602
- .forgotPassword(this.email)
603
- .then(() => {
687
+ try {
688
+ yield this.loading.show();
689
+ yield this.auth.forgotPassword(this.email);
604
690
  this.message.success('IDEA_AUTH.PASSWORD_RESET_CODE_SENT');
605
691
  this.goToConfirmPassword();
606
- })
607
- .catch(() => this.message.error('IDEA_AUTH.USER_NOT_FOUND'))
608
- .finally(() => this.loading.hide());
692
+ }
693
+ catch (error) {
694
+ this.message.error('IDEA_AUTH.USER_NOT_FOUND');
695
+ }
696
+ finally {
697
+ this.loading.hide();
698
+ }
609
699
  });
610
700
  }
611
- /**
612
- * Go to the confirm password page.
613
- */
614
701
  goToConfirmPassword() {
615
- this.navCtrl.navigateForward(['auth/confirm-password'], { queryParams: { email: this.email || null } });
702
+ var _a;
703
+ this.navCtrl.navigateForward(['auth/confirm-password'], { queryParams: { email: (_a = this.email) !== null && _a !== void 0 ? _a : null } });
616
704
  }
617
- /**
618
- * Go to auth page.
619
- */
620
705
  goToAuth() {
621
706
  this.navCtrl.navigateBack(['auth']);
622
707
  }
623
708
  }
624
- IDEAForgotPasswordPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAForgotPasswordPage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
625
- IDEAForgotPasswordPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAForgotPasswordPage, selector: "idea-forgot-password", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.PASSWORD_RESET' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.PASSWORD_RESET_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"forgotPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.RESET_MY_PASSWORD_HINT')\" (click)=\"forgotPassword()\">\n {{ 'IDEA_AUTH.RESET_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE_HINT')\"\n (click)=\"goToConfirmPassword()\"\n >\n {{ 'IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
709
+ IDEAForgotPasswordPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAForgotPasswordPage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }], target: i0.ɵɵFactoryTarget.Component });
710
+ IDEAForgotPasswordPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAForgotPasswordPage, selector: "idea-forgot-password", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.PASSWORD_RESET' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.PASSWORD_RESET_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"forgotPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"'IDEA_AUTH.RESET_MY_PASSWORD_HINT' | translate\" (click)=\"forgotPassword()\">\n {{ 'IDEA_AUTH.RESET_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE_HINT' | translate\"\n (click)=\"goToConfirmPassword()\"\n >\n {{ 'IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
626
711
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAForgotPasswordPage, decorators: [{
627
712
  type: Component,
628
- args: [{ selector: 'idea-forgot-password', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.PASSWORD_RESET' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.PASSWORD_RESET_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"forgotPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.RESET_MY_PASSWORD_HINT')\" (click)=\"forgotPassword()\">\n {{ 'IDEA_AUTH.RESET_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE_HINT')\"\n (click)=\"goToConfirmPassword()\"\n >\n {{ 'IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
629
- }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
713
+ args: [{ selector: 'idea-forgot-password', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.PASSWORD_RESET' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.PASSWORD_RESET_HINT' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"forgotPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"'IDEA_AUTH.RESET_MY_PASSWORD_HINT' | translate\" (click)=\"forgotPassword()\">\n {{ 'IDEA_AUTH.RESET_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE_HINT' | translate\"\n (click)=\"goToConfirmPassword()\"\n >\n {{ 'IDEA_AUTH.ALREADY_HAVE_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
714
+ }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }]; } });
630
715
 
631
716
  class IDEAConfirmPasswordPage {
632
717
  constructor(navCtrl, route, message, loading, auth, t) {
@@ -636,51 +721,231 @@ class IDEAConfirmPasswordPage {
636
721
  this.loading = loading;
637
722
  this.auth = auth;
638
723
  this.t = t;
639
- this.email = this.route.snapshot.queryParamMap.get('email') || null;
724
+ }
725
+ ngOnInit() {
726
+ var _a;
727
+ this.email = (_a = this.route.snapshot.queryParamMap.get('email')) !== null && _a !== void 0 ? _a : null;
640
728
  if (!this.email && this.route.snapshot.queryParams.user)
641
729
  this.email = decodeURIComponent(this.route.snapshot.queryParams.user);
642
730
  this.code = this.route.snapshot.queryParams.code;
643
731
  }
644
- /**
645
- * Confirm new password.
646
- */
647
732
  confirmPassword() {
648
733
  return __awaiter(this, void 0, void 0, function* () {
649
- this.errorMsg = null;
650
- yield this.loading.show();
651
- this.auth
652
- .confirmPassword(this.email, this.code, this.newPassword)
653
- .then(() => {
734
+ try {
735
+ this.errorMsg = null;
736
+ yield this.loading.show();
737
+ yield this.auth.confirmPassword(this.email, this.code, this.newPassword);
654
738
  this.message.success('IDEA_AUTH.PASSWORD_CHANGED');
655
739
  this.goToAuth();
656
- })
657
- .catch(() => {
740
+ }
741
+ catch (error) {
658
742
  this.errorMsg = this.t._('IDEA_AUTH.CONFIRM_PASSWORD_ERROR', { n: 8 });
659
743
  this.message.error(this.errorMsg, true);
660
- })
661
- .finally(() => this.loading.hide());
744
+ }
745
+ finally {
746
+ this.loading.hide();
747
+ }
662
748
  });
663
749
  }
664
- /**
665
- * Go to forgot password page.
666
- */
667
750
  goToForgotPassword() {
668
751
  this.navCtrl.navigateBack(['auth/forgot-password']);
669
752
  }
670
- /**
671
- * Go to auth page.
672
- */
673
753
  goToAuth() {
674
754
  this.navCtrl.navigateBack(['auth']);
675
755
  }
676
756
  }
677
757
  IDEAConfirmPasswordPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAConfirmPasswordPage, deps: [{ token: i1.NavController }, { token: i2$1.ActivatedRoute }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
678
- IDEAConfirmPasswordPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAConfirmPasswordPage, selector: "idea-confirm-password", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD_HINT' | translate: { n: 8 } }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"disc\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"text\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"t._('IDEA_AUTH.RESET_CODE')\"\n [title]=\"t._('IDEA_AUTH.RESET_CODE_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"code\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.NEW_PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.CHOOSE_A_PASSWORD')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.CHANGE_MY_PASSWORD_HINT')\" (click)=\"confirmPassword()\">\n {{ 'IDEA_AUTH.CHANGE_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE_HINT')\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
758
+ IDEAConfirmPasswordPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAConfirmPasswordPage, selector: "idea-confirm-password", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD_HINT' | translate: { n: 8 } }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"disc\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"text\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"'IDEA_AUTH.RESET_CODE' | translate\"\n [title]=\"'IDEA_AUTH.RESET_CODE_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"code\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.NEW_PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.CHANGE_MY_PASSWORD_HINT' | translate\"\n (click)=\"confirmPassword()\"\n >\n {{ 'IDEA_AUTH.CHANGE_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE_HINT' | translate\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
679
759
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAConfirmPasswordPage, decorators: [{
680
760
  type: Component,
681
- args: [{ selector: 'idea-confirm-password', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD_HINT' | translate: { n: 8 } }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"t._('IDEA_AUTH.EMAIL')\"\n [title]=\"t._('IDEA_AUTH.EMAIL_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"disc\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"text\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"t._('IDEA_AUTH.RESET_CODE')\"\n [title]=\"t._('IDEA_AUTH.RESET_CODE_HINT')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"code\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"t._('IDEA_AUTH.NEW_PASSWORD')\"\n [title]=\"t._('IDEA_AUTH.CHOOSE_A_PASSWORD')\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button expand=\"block\" [title]=\"t._('IDEA_AUTH.CHANGE_MY_PASSWORD_HINT')\" (click)=\"confirmPassword()\">\n {{ 'IDEA_AUTH.CHANGE_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE_HINT')\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"t._('IDEA_AUTH.BACK_TO_SIGN_IN_HINT')\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--ion-color-white-shade)}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--ion-color-white);border:1px solid var(--ion-color-light);border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--ion-color-white);--border-color: var(--ion-color-light)}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
761
+ args: [{ selector: 'idea-confirm-password', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.CHANGE_THE_PASSWORD_HINT' | translate: { n: 8 } }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b> {{ 'IDEA_AUTH.ERROR' | translate }}. </b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"person-circle\" color=\"primary\"> </ion-icon>\n </ion-label>\n <ion-input\n type=\"email\"\n inputmode=\"email\"\n pattern=\"[A-Za-z0-9._%+-]{2,}@[a-zA-Z-_.]{2,}[.]{1}[a-zA-Z]{2,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"email\"\n [placeholder]=\"'IDEA_AUTH.EMAIL' | translate\"\n [title]=\"'IDEA_AUTH.EMAIL_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"email\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"disc\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"text\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"off\"\n [placeholder]=\"'IDEA_AUTH.RESET_CODE' | translate\"\n [title]=\"'IDEA_AUTH.RESET_CODE_HINT' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"code\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n type=\"password\"\n pattern=\".{8,}\"\n spellcheck=\"false\"\n autocorrect=\"off\"\n autocapitalize=\"off\"\n autocomplete=\"new-password\"\n [clearOnEdit]=\"false\"\n [placeholder]=\"'IDEA_AUTH.NEW_PASSWORD' | translate\"\n [title]=\"'IDEA_AUTH.CHOOSE_A_PASSWORD' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"newPassword\"\n (keyup.enter)=\"confirmPassword()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.CHANGE_MY_PASSWORD_HINT' | translate\"\n (click)=\"confirmPassword()\"\n >\n {{ 'IDEA_AUTH.CHANGE_MY_PASSWORD' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE_HINT' | translate\"\n (click)=\"goToForgotPassword()\"\n >\n {{ 'IDEA_AUTH.HAVEN_T_RECEIVED_A_RESET_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
682
762
  }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2$1.ActivatedRoute }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
683
763
 
764
+ class IDEAMFAChallengePage {
765
+ constructor(navCtrl, message, loading, auth, t) {
766
+ this.navCtrl = navCtrl;
767
+ this.message = message;
768
+ this.loading = loading;
769
+ this.auth = auth;
770
+ this.t = t;
771
+ }
772
+ ngOnInit() {
773
+ if (!this.auth.challengeUsername)
774
+ this.goToAuth();
775
+ }
776
+ completeMFAChallenge() {
777
+ return __awaiter(this, void 0, void 0, function* () {
778
+ try {
779
+ this.errorMsg = null;
780
+ yield this.loading.show();
781
+ yield this.auth.completeMFAChallenge(this.otpCode);
782
+ window.location.assign('');
783
+ }
784
+ catch (error) {
785
+ this.errorMsg = this.t._('IDEA_AUTH.INVALID_OTP_CODE');
786
+ this.message.error(this.errorMsg, true);
787
+ }
788
+ finally {
789
+ this.loading.hide();
790
+ }
791
+ });
792
+ }
793
+ goToAuth() {
794
+ this.navCtrl.navigateBack(['auth']);
795
+ }
796
+ }
797
+ IDEAMFAChallengePage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAMFAChallengePage, deps: [{ token: i1.NavController }, { token: i2.IDEAMessageService }, { token: i2.IDEALoadingService }, { token: IDEAAuthService }, { token: i2.IDEATranslationsService }], target: i0.ɵɵFactoryTarget.Component });
798
+ IDEAMFAChallengePage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEAMFAChallengePage, selector: "idea-mfa-challenge", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.ENTER_OTP_CODE' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.ENTER_OTP_CODE_I' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b>{{ 'IDEA_AUTH.ERROR' | translate }}.</b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n inputmode=\"numeric\"\n [placeholder]=\"'IDEA_AUTH.OTP_CODE' | translate\"\n [title]=\"'IDEA_AUTH.ENTER_OTP_CODE' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"otpCode\"\n (keyup.enter)=\"completeMFAChallenge()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.CONFIRM_OTP_CODE_HINT' | translate\"\n (click)=\"completeMFAChallenge()\"\n >\n {{ 'IDEA_AUTH.CONFIRM_OTP_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
799
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAMFAChallengePage, decorators: [{
800
+ type: Component,
801
+ args: [{ selector: 'idea-mfa-challenge', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.ENTER_OTP_CODE' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.ENTER_OTP_CODE_I' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <p class=\"errorBox\" *ngIf=\"errorMsg\">\n <b>{{ 'IDEA_AUTH.ERROR' | translate }}.</b>\n {{ errorMsg }}\n </p>\n <ion-item>\n <ion-label position=\"inline\">\n <ion-icon name=\"key\" color=\"primary\"></ion-icon>\n </ion-label>\n <ion-input\n inputmode=\"numeric\"\n [placeholder]=\"'IDEA_AUTH.OTP_CODE' | translate\"\n [title]=\"'IDEA_AUTH.ENTER_OTP_CODE' | translate\"\n [ngModelOptions]=\"{ standalone: true }\"\n [(ngModel)]=\"otpCode\"\n (keyup.enter)=\"completeMFAChallenge()\"\n ></ion-input>\n </ion-item>\n <ion-button\n expand=\"block\"\n [title]=\"'IDEA_AUTH.CONFIRM_OTP_CODE_HINT' | translate\"\n (click)=\"completeMFAChallenge()\"\n >\n {{ 'IDEA_AUTH.CONFIRM_OTP_CODE' | translate }}\n </ion-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
802
+ }], ctorParameters: function () { return [{ type: i1.NavController }, { type: i2.IDEAMessageService }, { type: i2.IDEALoadingService }, { type: IDEAAuthService }, { type: i2.IDEATranslationsService }]; } });
803
+
804
+ class IDEASetupMFAModalComponent {
805
+ constructor(modalCtrl, loading, message, auth) {
806
+ this.modalCtrl = modalCtrl;
807
+ this.loading = loading;
808
+ this.message = message;
809
+ this.auth = auth;
810
+ }
811
+ ngOnInit() {
812
+ return __awaiter(this, void 0, void 0, function* () {
813
+ try {
814
+ yield this.loading.show();
815
+ this.isMFAEnabled = yield this.auth.checkIfUserHasMFAEnabled(true);
816
+ if (!this.isMFAEnabled) {
817
+ const url = yield this.auth.getURLForEnablingMFA();
818
+ yield this.generateQRCodeCanvasByURL(url);
819
+ }
820
+ }
821
+ catch (error) {
822
+ this.message.error('COMMON.OPERATION_FAILED');
823
+ }
824
+ finally {
825
+ this.loading.hide();
826
+ }
827
+ });
828
+ }
829
+ generateQRCodeCanvasByURL(url) {
830
+ return new Promise((resolve, reject) => {
831
+ const container = document.getElementById('qrCodeContainer');
832
+ container.innerHTML = '';
833
+ toCanvas(url, { errorCorrectionLevel: 'L' }, (err, canvas) => {
834
+ if (err)
835
+ return reject(err);
836
+ canvas.style.width = '100%';
837
+ canvas.style.height = '100%';
838
+ canvas.style.borderRadius = '4px';
839
+ container.appendChild(canvas);
840
+ resolve();
841
+ });
842
+ });
843
+ }
844
+ setMFA(enable) {
845
+ return __awaiter(this, void 0, void 0, function* () {
846
+ if (!this.otpCode)
847
+ return;
848
+ try {
849
+ yield this.loading.show();
850
+ if (enable)
851
+ yield this.auth.enableMFA(this.otpCode);
852
+ else
853
+ yield this.auth.disableMFA(this.otpCode);
854
+ this.isMFAEnabled = enable;
855
+ this.message.success('COMMON.OPERATION_COMPLETED');
856
+ this.modalCtrl.dismiss({ enabled: enable });
857
+ }
858
+ catch (error) {
859
+ this.message.error('COMMON.OPERATION_FAILED');
860
+ }
861
+ finally {
862
+ this.loading.hide();
863
+ }
864
+ });
865
+ }
866
+ close() {
867
+ this.modalCtrl.dismiss();
868
+ }
869
+ }
870
+ IDEASetupMFAModalComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAModalComponent, deps: [{ token: i1.ModalController }, { token: i2.IDEALoadingService }, { token: i2.IDEAMessageService }, { token: IDEAAuthService }], target: i0.ɵɵFactoryTarget.Component });
871
+ IDEASetupMFAModalComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASetupMFAModalComponent, selector: "idea-setup-mfa-modal", ngImport: i0, template: "<ion-header>\n <ion-toolbar color=\"ideaToolbar\">\n <ion-buttons slot=\"start\">\n <ion-button [title]=\"'COMMON.CLOSE' | translate\" (click)=\"close()\">\n <ion-icon name=\"close-circle-outline\" slot=\"icon-only\"></ion-icon>\n </ion-button>\n </ion-buttons>\n <ion-title>{{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA' : 'IDEA_AUTH.SETUP_MFA') | translate }}</ion-title>\n </ion-toolbar>\n</ion-header>\n<ion-content class=\"ion-padding\">\n <ion-list class=\"aList\">\n <ion-list-header>\n <ion-label class=\"ion-text-center\">\n <h2>{{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA_I' : 'IDEA_AUTH.SETUP_MFA_I') | translate }}</h2>\n <p>{{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA_II' : 'IDEA_AUTH.SETUP_MFA_II') | translate }}</p>\n </ion-label>\n </ion-list-header>\n <ion-card color=\"white\">\n <ion-card-content>\n <div id=\"qrCodeContainer\" *ngIf=\"!isMFAEnabled\"></div>\n <ion-item color=\"light\">\n <ion-label position=\"floating\">{{ 'IDEA_AUTH.OTP_CODE' | translate }}</ion-label>\n <ion-input type=\"text\" inputmode=\"numeric\" [(ngModel)]=\"otpCode\"></ion-input>\n </ion-item>\n <ion-button expand=\"block\" class=\"ion-margin-top\" [disabled]=\"!otpCode\" (click)=\"setMFA(!isMFAEnabled)\">\n {{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA' : 'IDEA_AUTH.ENABLE_MFA') | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </ion-list>\n</ion-content>\n", styles: ["ion-list.aList{padding-top:0}ion-list.aList ion-card{margin:10px auto;max-width:300px}ion-list.aList #qrCodeContainer{width:180px;margin:10px auto}\n"], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonButtons, selector: "ion-buttons", inputs: ["collapse"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: i1.IonHeader, selector: "ion-header", inputs: ["collapse", "mode", "translucent"] }, { kind: "component", type: i1.IonIcon, selector: "ion-icon", inputs: ["color", "flipRtl", "icon", "ios", "lazy", "md", "mode", "name", "sanitize", "size", "src"] }, { kind: "component", type: i1.IonInput, selector: "ion-input", inputs: ["accept", "autocapitalize", "autocomplete", "autocorrect", "autofocus", "clearInput", "clearOnEdit", "color", "debounce", "disabled", "enterkeyhint", "inputmode", "max", "maxlength", "min", "minlength", "mode", "multiple", "name", "pattern", "placeholder", "readonly", "required", "size", "spellcheck", "step", "type", "value"] }, { kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "counter", "counterFormatter", "detail", "detailIcon", "disabled", "download", "fill", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "shape", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i1.IonList, selector: "ion-list", inputs: ["inset", "lines", "mode"] }, { kind: "component", type: i1.IonListHeader, selector: "ion-list-header", inputs: ["color", "lines", "mode"] }, { kind: "component", type: i1.IonTitle, selector: "ion-title", inputs: ["color", "size"] }, { kind: "component", type: i1.IonToolbar, selector: "ion-toolbar", inputs: ["color", "mode"] }, { kind: "directive", type: i1.TextValueAccessor, selector: "ion-input:not([type=number]),ion-textarea,ion-searchbar" }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
872
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAModalComponent, decorators: [{
873
+ type: Component,
874
+ args: [{ selector: 'idea-setup-mfa-modal', template: "<ion-header>\n <ion-toolbar color=\"ideaToolbar\">\n <ion-buttons slot=\"start\">\n <ion-button [title]=\"'COMMON.CLOSE' | translate\" (click)=\"close()\">\n <ion-icon name=\"close-circle-outline\" slot=\"icon-only\"></ion-icon>\n </ion-button>\n </ion-buttons>\n <ion-title>{{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA' : 'IDEA_AUTH.SETUP_MFA') | translate }}</ion-title>\n </ion-toolbar>\n</ion-header>\n<ion-content class=\"ion-padding\">\n <ion-list class=\"aList\">\n <ion-list-header>\n <ion-label class=\"ion-text-center\">\n <h2>{{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA_I' : 'IDEA_AUTH.SETUP_MFA_I') | translate }}</h2>\n <p>{{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA_II' : 'IDEA_AUTH.SETUP_MFA_II') | translate }}</p>\n </ion-label>\n </ion-list-header>\n <ion-card color=\"white\">\n <ion-card-content>\n <div id=\"qrCodeContainer\" *ngIf=\"!isMFAEnabled\"></div>\n <ion-item color=\"light\">\n <ion-label position=\"floating\">{{ 'IDEA_AUTH.OTP_CODE' | translate }}</ion-label>\n <ion-input type=\"text\" inputmode=\"numeric\" [(ngModel)]=\"otpCode\"></ion-input>\n </ion-item>\n <ion-button expand=\"block\" class=\"ion-margin-top\" [disabled]=\"!otpCode\" (click)=\"setMFA(!isMFAEnabled)\">\n {{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA' : 'IDEA_AUTH.ENABLE_MFA') | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </ion-list>\n</ion-content>\n", styles: ["ion-list.aList{padding-top:0}ion-list.aList ion-card{margin:10px auto;max-width:300px}ion-list.aList #qrCodeContainer{width:180px;margin:10px auto}\n"] }]
875
+ }], ctorParameters: function () { return [{ type: i1.ModalController }, { type: i2.IDEALoadingService }, { type: i2.IDEAMessageService }, { type: IDEAAuthService }]; } });
876
+
877
+ class IDEASetupMFAButtonComponent {
878
+ constructor(modalCtrl, auth) {
879
+ this.modalCtrl = modalCtrl;
880
+ this.auth = auth;
881
+ /**
882
+ * Trigger then the MFA setup changes.
883
+ */
884
+ this.change = new EventEmitter();
885
+ }
886
+ ngOnInit() {
887
+ return __awaiter(this, void 0, void 0, function* () {
888
+ this.isMFAEnabled = yield this.auth.checkIfUserHasMFAEnabled(true);
889
+ });
890
+ }
891
+ openMFAModal() {
892
+ return __awaiter(this, void 0, void 0, function* () {
893
+ const modal = yield this.modalCtrl.create({ component: IDEASetupMFAModalComponent, backdropDismiss: false });
894
+ modal.onDidDismiss().then(({ data }) => {
895
+ if (data) {
896
+ this.isMFAEnabled = data.enabled;
897
+ this.change.emit(data.enabled);
898
+ }
899
+ });
900
+ yield modal.present();
901
+ });
902
+ }
903
+ }
904
+ IDEASetupMFAButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAButtonComponent, deps: [{ token: i1.ModalController }, { token: IDEAAuthService }], target: i0.ɵɵFactoryTarget.Component });
905
+ IDEASetupMFAButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASetupMFAButtonComponent, selector: "idea-setup-mfa-button", inputs: { color: "color", fill: "fill" }, outputs: { change: "change" }, ngImport: i0, template: "<ion-button *ngIf=\"isMFAEnabled !== undefined\" [color]=\"color\" [fill]=\"fill\" (click)=\"openMFAModal()\">\n {{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA' : 'IDEA_AUTH.SETUP_MFA') | translate }}\n</ion-button>\n", styles: [""], dependencies: [{ kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
906
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAButtonComponent, decorators: [{
907
+ type: Component,
908
+ args: [{ selector: 'idea-setup-mfa-button', template: "<ion-button *ngIf=\"isMFAEnabled !== undefined\" [color]=\"color\" [fill]=\"fill\" (click)=\"openMFAModal()\">\n {{ (isMFAEnabled ? 'IDEA_AUTH.DISABLE_MFA' : 'IDEA_AUTH.SETUP_MFA') | translate }}\n</ion-button>\n" }]
909
+ }], ctorParameters: function () { return [{ type: i1.ModalController }, { type: IDEAAuthService }]; }, propDecorators: { color: [{
910
+ type: Input
911
+ }], fill: [{
912
+ type: Input
913
+ }], change: [{
914
+ type: Output
915
+ }] } });
916
+
917
+ class IDEASetupMFAPage {
918
+ constructor(navCtrl) {
919
+ this.navCtrl = navCtrl;
920
+ }
921
+ reloadApp() {
922
+ window.location.assign('');
923
+ }
924
+ goToAuth() {
925
+ this.navCtrl.navigateBack(['auth']);
926
+ }
927
+ }
928
+ IDEASetupMFAPage.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAPage, deps: [{ token: i1.NavController }], target: i0.ɵɵFactoryTarget.Component });
929
+ IDEASetupMFAPage.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: IDEASetupMFAPage, selector: "idea-mfa-setup", ngImport: i0, template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.SETUP_MFA' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.MFA_IS_MANDATORY' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <idea-setup-mfa-button (change)=\"reloadApp()\"></idea-setup-mfa-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i5.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i1.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i1.IonCard, selector: "ion-card", inputs: ["button", "color", "disabled", "download", "href", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonCardContent, selector: "ion-card-content", inputs: ["mode"] }, { kind: "component", type: i1.IonCardHeader, selector: "ion-card-header", inputs: ["color", "mode", "translucent"] }, { kind: "component", type: i1.IonCardSubtitle, selector: "ion-card-subtitle", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonCardTitle, selector: "ion-card-title", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonContent, selector: "ion-content", inputs: ["color", "forceOverscroll", "fullscreen", "scrollEvents", "scrollX", "scrollY"] }, { kind: "component", type: IDEASetupMFAButtonComponent, selector: "idea-setup-mfa-button", inputs: ["color", "fill"], outputs: ["change"] }, { kind: "pipe", type: i2.IDEATranslatePipe, name: "translate" }] });
930
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAPage, decorators: [{
931
+ type: Component,
932
+ args: [{ selector: 'idea-mfa-setup', template: "<ion-content>\n <form class=\"flexBox\">\n <ion-card class=\"authCard\">\n <ion-card-header>\n <ion-card-title color=\"primary\">{{ 'IDEA_AUTH.SETUP_MFA' | translate }}</ion-card-title>\n <ion-card-subtitle>{{ 'IDEA_AUTH.MFA_IS_MANDATORY' | translate }}</ion-card-subtitle>\n </ion-card-header>\n <ion-card-content>\n <idea-setup-mfa-button (change)=\"reloadApp()\"></idea-setup-mfa-button>\n <ion-button\n fill=\"clear\"\n expand=\"block\"\n class=\"smallCaseButton\"\n [title]=\"'IDEA_AUTH.BACK_TO_SIGN_IN_HINT' | translate\"\n (click)=\"goToAuth()\"\n >\n {{ 'IDEA_AUTH.BACK_TO_SIGN_IN' | translate }}\n </ion-button>\n </ion-card-content>\n </ion-card>\n </form>\n</ion-content>\n", styles: [".flexBox{background:var(--idea-auth-background-color, var(--ion-color-white-shade))}.authCard{min-width:400px;max-width:550px;margin:0 10px;padding:20px;background-color:var(--idea-auth-card-background-color, var(--ion-color-white));border:1px solid var(--idea-auth-card-border-color, var(--ion-color-light));border-radius:10px;box-shadow:none;text-align:center}.authCard ion-img{width:150px;display:block;margin:0 auto}.authCard ion-card-title{font-family:auth-title;font-size:3em}.authCard ion-card-subtitle{font-family:auth-title;font-size:1.2em}.authCard ion-card-content{padding-top:16px}.authCard ion-card-content .errorBox{padding-left:10px;margin-bottom:20px;text-align:left;border-left:2px solid var(--ion-color-danger)}.authCard ion-card-content ion-item{--ion-item-background: var(--idea-auth-card-background-color, var(--ion-color-white));--border-color: var(--idea-auth-card-border-color, var(--ion-color-light))}.authCard ion-card-content ion-icon{padding-top:4px;padding-right:5px;font-size:1.3em}.authCard ion-card-content .agreementsAcceptanceRow{margin-top:15px;font-size:.9em}.authCard ion-card-content .agreementsAcceptanceRow ion-checkbox{vertical-align:bottom;margin-right:3px}.authCard ion-card-content ion-button{margin-top:15px}.authCard ion-card-content .smallCaseButton{text-transform:none;letter-spacing:normal;font-size:1em}@media only screen and (max-width: 500px){.authCard{background-color:transparent;border:none}}.ideaLogo{width:65px;margin:40px auto 0;cursor:pointer}\n"] }]
933
+ }], ctorParameters: function () { return [{ type: i1.NavController }]; } });
934
+
935
+ class IDEASetupMFAModule {
936
+ }
937
+ IDEASetupMFAModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
938
+ IDEASetupMFAModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAModule, declarations: [IDEASetupMFAModalComponent, IDEASetupMFAButtonComponent], imports: [CommonModule, FormsModule, IonicModule, IDEATranslationsModule], exports: [IDEASetupMFAModalComponent, IDEASetupMFAButtonComponent] });
939
+ IDEASetupMFAModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAModule, imports: [CommonModule, FormsModule, IonicModule, IDEATranslationsModule] });
940
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEASetupMFAModule, decorators: [{
941
+ type: NgModule,
942
+ args: [{
943
+ imports: [CommonModule, FormsModule, IonicModule, IDEATranslationsModule],
944
+ declarations: [IDEASetupMFAModalComponent, IDEASetupMFAButtonComponent],
945
+ exports: [IDEASetupMFAModalComponent, IDEASetupMFAButtonComponent]
946
+ }]
947
+ }] });
948
+
684
949
  class IDEAAuthModule {
685
950
  }
686
951
  IDEAAuthModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAAuthModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
@@ -689,10 +954,12 @@ IDEAAuthModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version:
689
954
  IDEANewPasswordPage,
690
955
  IDEAResendLinkPage,
691
956
  IDEAForgotPasswordPage,
692
- IDEAConfirmPasswordPage], imports: [CommonModule,
957
+ IDEAConfirmPasswordPage,
958
+ IDEAMFAChallengePage,
959
+ IDEASetupMFAPage], imports: [CommonModule,
693
960
  FormsModule,
694
961
  IonicModule,
695
- IDEATranslationsModule, i2$1.RouterModule] });
962
+ IDEATranslationsModule, i2$1.RouterModule, IDEASetupMFAModule] });
696
963
  IDEAAuthModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAAuthModule, imports: [CommonModule,
697
964
  FormsModule,
698
965
  IonicModule,
@@ -702,10 +969,13 @@ IDEAAuthModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version:
702
969
  { path: 'sign-in', component: IDEASignInPage },
703
970
  { path: 'sign-up', component: IDEASignUpPage },
704
971
  { path: 'new-password', component: IDEANewPasswordPage },
972
+ { path: 'mfa-challenge', component: IDEAMFAChallengePage },
973
+ { path: 'setup-mfa', component: IDEASetupMFAPage },
705
974
  { path: 'resend-link', component: IDEAResendLinkPage },
706
975
  { path: 'forgot-password', component: IDEAForgotPasswordPage },
707
976
  { path: 'confirm-password', component: IDEAConfirmPasswordPage }
708
- ])] });
977
+ ]),
978
+ IDEASetupMFAModule] });
709
979
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: IDEAAuthModule, decorators: [{
710
980
  type: NgModule,
711
981
  args: [{
@@ -719,10 +989,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
719
989
  { path: 'sign-in', component: IDEASignInPage },
720
990
  { path: 'sign-up', component: IDEASignUpPage },
721
991
  { path: 'new-password', component: IDEANewPasswordPage },
992
+ { path: 'mfa-challenge', component: IDEAMFAChallengePage },
993
+ { path: 'setup-mfa', component: IDEASetupMFAPage },
722
994
  { path: 'resend-link', component: IDEAResendLinkPage },
723
995
  { path: 'forgot-password', component: IDEAForgotPasswordPage },
724
996
  { path: 'confirm-password', component: IDEAConfirmPasswordPage }
725
- ])
997
+ ]),
998
+ IDEASetupMFAModule
726
999
  ],
727
1000
  declarations: [
728
1001
  IDEASignInPage,
@@ -730,7 +1003,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
730
1003
  IDEANewPasswordPage,
731
1004
  IDEAResendLinkPage,
732
1005
  IDEAForgotPasswordPage,
733
- IDEAConfirmPasswordPage
1006
+ IDEAConfirmPasswordPage,
1007
+ IDEAMFAChallengePage,
1008
+ IDEASetupMFAPage
734
1009
  ]
735
1010
  }]
736
1011
  }] });
@@ -739,6 +1014,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
739
1014
  * Generated bundle index. Do not edit.
740
1015
  */
741
1016
 
742
- export { IDEAAuthModule, IDEAAuthService };
743
- //# sourceMappingURL=idea-ionic-auth.mjs.map
1017
+ export { IDEAAuthModule, IDEAAuthService, IDEASetupMFAButtonComponent, IDEASetupMFAModalComponent, IDEASetupMFAModule, LoginOutcomeActions };
744
1018
  //# sourceMappingURL=idea-ionic-auth.mjs.map