@genesislcap/foundation-login 14.176.1-alpha-ed9e3d4.0 → 14.177.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/dts/main/config.d.ts +0 -52
- package/dist/dts/main/config.d.ts.map +1 -1
- package/dist/dts/main/main.d.ts +0 -6
- package/dist/dts/main/main.d.ts.map +1 -1
- package/dist/dts/routes/base.d.ts +2 -9
- package/dist/dts/routes/base.d.ts.map +1 -1
- package/dist/dts/routes/forgot-password/forgot-password.d.ts.map +1 -1
- package/dist/dts/routes/forgot-password/forgot-password.template.d.ts.map +1 -1
- package/dist/dts/routes/login-form/login-form.d.ts +1 -1
- package/dist/dts/routes/login-form/login-form.d.ts.map +1 -1
- package/dist/dts/routes/login-form/login-form.template.d.ts.map +1 -1
- package/dist/dts/routes/request-account/request-account.template.d.ts.map +1 -1
- package/dist/dts/routes/reset-password/reset-password.d.ts +1 -1
- package/dist/dts/routes/reset-password/reset-password.d.ts.map +1 -1
- package/dist/dts/routes/reset-password/reset-password.template.d.ts.map +1 -1
- package/dist/dts/routes/verify/verify.template.d.ts.map +1 -1
- package/dist/esm/main/main.js +0 -4
- package/dist/esm/routes/base.js +19 -51
- package/dist/esm/routes/forgot-password/forgot-password.js +1 -2
- package/dist/esm/routes/forgot-password/forgot-password.template.js +3 -4
- package/dist/esm/routes/login-form/login-form.js +6 -8
- package/dist/esm/routes/login-form/login-form.template.js +11 -15
- package/dist/esm/routes/not-found/not-found.js +1 -1
- package/dist/esm/routes/protected/protected.template.js +1 -1
- package/dist/esm/routes/request-account/request-account.template.js +8 -4
- package/dist/esm/routes/reset-password/reset-password.js +5 -9
- package/dist/esm/routes/reset-password/reset-password.template.js +3 -6
- package/dist/esm/routes/verify/verify.template.js +5 -5
- package/dist/foundation-login.api.json +0 -135
- package/dist/foundation-login.d.ts +2 -68
- package/docs/api/foundation-login.loginconfig.md +0 -2
- package/docs/api/foundation-login.md +0 -2
- package/docs/api-report.md +2 -17
- package/package.json +14 -15
- package/docs/api/foundation-login.loginconfig.localizationresources.md +0 -36
- package/docs/api/foundation-login.loginconfig.messagedelays.md +0 -29
- package/docs/api/foundation-login.messagedelaykey.md +0 -12
- package/docs/api/foundation-login.messagedelays.md +0 -14
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { I18nextConfig } from '@genesislcap/foundation-i18n';
|
|
2
1
|
import { ElementStyles } from '@microsoft/fast-element';
|
|
3
2
|
import { Container } from '@microsoft/fast-foundation';
|
|
4
3
|
/**
|
|
@@ -111,14 +110,6 @@ export type SSOConfig = {
|
|
|
111
110
|
*/
|
|
112
111
|
identityProvidersPath: string;
|
|
113
112
|
};
|
|
114
|
-
/**
|
|
115
|
-
* @public
|
|
116
|
-
*/
|
|
117
|
-
export type MessageDelayKey = 'forgotPassword' | 'resetPassword' | 'base';
|
|
118
|
-
/**
|
|
119
|
-
* @public
|
|
120
|
-
*/
|
|
121
|
-
export type MessageDelays = Partial<Record<MessageDelayKey, number>>;
|
|
122
113
|
/**
|
|
123
114
|
* LoginConfig DI interface.
|
|
124
115
|
*
|
|
@@ -236,49 +227,6 @@ export interface LoginConfig {
|
|
|
236
227
|
* ```
|
|
237
228
|
*/
|
|
238
229
|
versionInformation?: string;
|
|
239
|
-
/**
|
|
240
|
-
* I18n resources.
|
|
241
|
-
*
|
|
242
|
-
* @remarks
|
|
243
|
-
* This property holds the localization resources needed for internationalization of the application.
|
|
244
|
-
* It should follow the structure defined by the I18nextConfig interface, which includes
|
|
245
|
-
* translations grouped by locale and namespace. Each locale can contain multiple namespaces, and each
|
|
246
|
-
* namespace includes key-value pairs for translation strings.
|
|
247
|
-
*
|
|
248
|
-
* @example
|
|
249
|
-
* ```ts
|
|
250
|
-
* resources: {
|
|
251
|
-
* en: {
|
|
252
|
-
* translation: {
|
|
253
|
-
* key: 'Hello World'
|
|
254
|
-
* }
|
|
255
|
-
* },
|
|
256
|
-
* es: {
|
|
257
|
-
* translation: {
|
|
258
|
-
* key: 'Hola Mundo'
|
|
259
|
-
* }
|
|
260
|
-
* }
|
|
261
|
-
* }
|
|
262
|
-
* ```
|
|
263
|
-
*/
|
|
264
|
-
localizationResources?: I18nextConfig['resources'];
|
|
265
|
-
/**
|
|
266
|
-
* Delay configurations for various message-related actions.
|
|
267
|
-
*
|
|
268
|
-
* @remarks
|
|
269
|
-
* This property holds numeric values representing delays (in milliseconds) for specific message-related actions
|
|
270
|
-
* within the application. Each key in this object corresponds to a particular message action.
|
|
271
|
-
*
|
|
272
|
-
* @example
|
|
273
|
-
* ```ts
|
|
274
|
-
* messageDelays: {
|
|
275
|
-
* forgotPassword: 1000, // Delay of 1000ms before processing forgot password action
|
|
276
|
-
* resetPassword: 2000, // Delay of 2000ms for reset password action
|
|
277
|
-
* base: 500 // Base delay used for generic message processing
|
|
278
|
-
* }
|
|
279
|
-
* ```
|
|
280
|
-
*/
|
|
281
|
-
messageDelays?: MessageDelays;
|
|
282
230
|
}
|
|
283
231
|
/**
|
|
284
232
|
* Default LoginConfig DI implementation.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/main/config.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/main/config.ts"],"names":[],"mappings":"AAOA,OAAO,EAAO,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAoB,MAAM,4BAA4B,CAAC;AAKzE;;GAEG;AACH,eAAO,MAAM,mBAAmB,QAAuB,CAAC;AAExD;;GAEG;AACH,eAAO,MAAM,WAAW,QAAe,CAAC;AAExC;;GAEG;AACH,eAAO,MAAM,eAAe,QAAmB,CAAC;AAEhD;;GAEG;AACH,eAAO,MAAM,cAAc,QAAW,CAAC;AAEvC;;GAEG;AACH,eAAO,MAAM,gBAAgB,QAAa,CAAC;AAE3C;;GAEG;AACH,eAAO,MAAM,OAAO,QAAgB,CAAC;AAErC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AE,OAAO,GAAG,WAAW,CAAC,EAAE,CAAC;IACrD;;;;;OAKG;IACH,MAAM,EAAE,cAAc,CAAC;IACvB;;OAEG;IACH,uBAAuB,EAAE,OAAO,CAAC;IACjC;;;;;OAKG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;;OAKG;IACH,kBAAkB,EAAE,MAAM,CAAC;IAC3B;;;OAGG;IACH,eAAe,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC;;;;;;;OAOG;IACH,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B;;;;;OAKG;IACH,GAAG,EAAE,SAAS,GAAG,IAAI,CAAC;IACtB;;;;;;;;;;OAUG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED;;;GAGG;AACH,eAAO,MAAM,kBAAkB,EAAE,WAmChC,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,WAAW,mEAAoC,CAAC;AAE7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6CG;AACH,wBAAgB,SAAS,CAAC,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,OAAO,CAAC,WAAW,CAAC,QAQ3E"}
|
package/dist/dts/main/main.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Session } from '@genesislcap/foundation-comms';
|
|
2
|
-
import { I18next } from '@genesislcap/foundation-i18n';
|
|
3
2
|
import { FASTElement } from '@microsoft/fast-element';
|
|
4
3
|
import { Container } from '@microsoft/fast-foundation';
|
|
5
4
|
import { MainRouterConfig } from '../routes';
|
|
@@ -124,11 +123,6 @@ export declare class Login extends FASTElement {
|
|
|
124
123
|
* @internal
|
|
125
124
|
*/
|
|
126
125
|
session: Session;
|
|
127
|
-
/**
|
|
128
|
-
* i18next instance for managing internationalization.
|
|
129
|
-
* @internal
|
|
130
|
-
*/
|
|
131
|
-
i18next: I18next;
|
|
132
126
|
/**
|
|
133
127
|
* Marked true when remote components are loaded, currently unused.
|
|
134
128
|
* @internal
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../../src/main/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuC,OAAO,EAAE,MAAM,+BAA+B,CAAC;AAC7F,OAAO,
|
|
1
|
+
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../../src/main/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuC,OAAO,EAAE,MAAM,+BAA+B,CAAC;AAC7F,OAAO,EAAiB,WAAW,EAAc,MAAM,yBAAyB,CAAC;AACjF,OAAO,EAAE,SAAS,EAAwB,MAAM,4BAA4B,CAAC;AAG7E,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAI7C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsGG;AACH,qBACa,KAAM,SAAQ,WAAW;IACpC;;;;;OAKG;IACuB,MAAM,EAAG,gBAAgB,CAAC;IAEpD;;;OAGG;IACQ,SAAS,EAAG,SAAS,CAAC;IAEjC;;;OAGG;IACM,OAAO,EAAG,OAAO,CAAC;IAE3B;;;OAGG;IACS,KAAK,EAAE,OAAO,CAAS;IAEnC;;;OAGG;IACS,QAAQ,EAAG,WAAW,CAAC;IAEnC;;OAEG;IACG,iBAAiB;IAQvB;;;;;;;;;;;;;;;;;;;;;OAqBG;IACH,gBAAgB;IAchB;;;OAGG;IACG,wBAAwB;IAa9B;;OAEG;IACH,SAAS,CAAC,sBAAsB;CAgBjC;AAED;;;;;;;GAOG;AACH,qBAIa,WAAY,SAAQ,KAAK;IAC9B,wBAAwB;CAG/B"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Auth, Connect, CredentialManager, Message, MessageBuilder, Session } from '@genesislcap/foundation-comms';
|
|
2
|
-
import { I18next } from '@genesislcap/foundation-i18n';
|
|
3
2
|
import { Binding, FASTElement } from '@microsoft/fast-element';
|
|
4
3
|
import { Container } from '@microsoft/fast-foundation';
|
|
5
4
|
import { FieldConfigMap, LoginConfig, Routes } from '../main/config';
|
|
@@ -22,11 +21,6 @@ export type ConfigHost = {
|
|
|
22
21
|
export declare class ConfigHostElement extends FASTElement implements ConfigHost {
|
|
23
22
|
container: Container;
|
|
24
23
|
config: LoginConfig;
|
|
25
|
-
/**
|
|
26
|
-
* i18next instance for managing internationalization.
|
|
27
|
-
* @internal
|
|
28
|
-
*/
|
|
29
|
-
i18next: I18next;
|
|
30
24
|
connectedCallback(): void;
|
|
31
25
|
}
|
|
32
26
|
/**
|
|
@@ -60,8 +54,7 @@ export declare class BaseRoute extends ConfigHostElement {
|
|
|
60
54
|
queueOnBack(delay?: number): void;
|
|
61
55
|
autofill(): Promise<boolean>;
|
|
62
56
|
storeCredentials(password?: string): void;
|
|
63
|
-
sendMessage<T = any>(message: Message<T>, successFeedback?: string, successCallback?: (result: any) => void
|
|
64
|
-
toLocalisedText(text: string): string;
|
|
57
|
+
sendMessage<T = any>(message: Message<T>, successFeedback?: string, successCallback?: (result: any) => void): Promise<void>;
|
|
65
58
|
}
|
|
66
59
|
/**
|
|
67
60
|
* @internal
|
|
@@ -106,7 +99,7 @@ export declare class LogoElement extends ConfigHostElement {
|
|
|
106
99
|
/**
|
|
107
100
|
* @internal
|
|
108
101
|
*/
|
|
109
|
-
export declare const backButton: <T extends ConfigHost>(binding: Binding
|
|
102
|
+
export declare const backButton: <T extends ConfigHost>(binding: Binding) => import("@microsoft/fast-element").ViewTemplate<T, any>;
|
|
110
103
|
/**
|
|
111
104
|
* @internal
|
|
112
105
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../../src/routes/base.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,IAAI,EACJ,OAAO,EAEP,iBAAiB,EAEjB,OA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AWlB,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,qBAAqB,mFAQjC,CAAC;AAEF;;;;GAIG;AACH,qBA0Ba,cAAe,SAAQ,WAAW;IACjC,UAAU,EAAE,MAAM,CAAM;IAC9B,OAAO,EAAE,MAAM,CAAM;IACwB,QAAQ,EAAE,OAAO,CAAS;IAC7E,eAAe;CAGhB;AAED;;GAEG;AACH,qBAuBa,mBAAoB,SAAQ,WAAW;IACK,YAAY,EAAE,OAAO,CAAS;CACtF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"forgot-password.d.ts","sourceRoot":"","sources":["../../../../src/routes/forgot-password/forgot-password.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAGpC,qBAKa,cAAe,SAAQ,SAAS;IACrC,iBAAiB;IAKjB,QAAQ;
|
|
1
|
+
{"version":3,"file":"forgot-password.d.ts","sourceRoot":"","sources":["../../../../src/routes/forgot-password/forgot-password.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAGpC,qBAKa,cAAe,SAAQ,SAAS;IACrC,iBAAiB;IAKjB,QAAQ;CAUf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"forgot-password.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/forgot-password/forgot-password.template.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD,eAAO,MAAM,sBAAsB,
|
|
1
|
+
{"version":3,"file":"forgot-password.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/forgot-password/forgot-password.template.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD,eAAO,MAAM,sBAAsB,qEAuBlC,CAAC"}
|
|
@@ -18,7 +18,7 @@ export declare class LoginForm extends BaseRoute {
|
|
|
18
18
|
onHostSubmit(): Promise<void>;
|
|
19
19
|
onLoginSubmit(): Promise<void>;
|
|
20
20
|
login(credentials: AuthInfo): Promise<void>;
|
|
21
|
-
get connectActionText():
|
|
21
|
+
get connectActionText(): "Disconnect" | "Connect";
|
|
22
22
|
get submitConnectDisabled(): boolean;
|
|
23
23
|
get submitDisabled(): boolean;
|
|
24
24
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"login-form.d.ts","sourceRoot":"","sources":["../../../../src/routes/login-form/login-form.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAKpE,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAI/B,qBAKa,SAAU,SAAQ,SAAS;IAC1B,IAAI,EAAE,GAAG,EAAE,CAAM;IACjB,WAAW,EAAE,MAAM,CAAM;IACzB,UAAU,EAAE,OAAO,CAAS;IAElC,iBAAiB;IAsBjB,KAAK;IAqBL,gBAAgB,IAAI,OAAO,CAAC,OAAO,GAAG,SAAS,CAAC;IAStD,OAAO,CAAC,yBAAyB;IA8BjC,OAAO,CAAC,iBAAiB;IAczB,iBAAiB;IAmBjB,IACI,eAAe,WAElB;IAED,cAAc,MAAO,WAAW,KAAG,IAAI,CAIrC;IAEF,UAAU;IAiBV,OAAO,CAAC,cAAc;IAQhB,YAAY;IAIZ,aAAa;IAOb,KAAK,CAAC,WAAW,EAAE,QAAQ;IAgDjC,IACI,iBAAiB,
|
|
1
|
+
{"version":3,"file":"login-form.d.ts","sourceRoot":"","sources":["../../../../src/routes/login-form/login-form.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAKpE,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAI/B,qBAKa,SAAU,SAAQ,SAAS;IAC1B,IAAI,EAAE,GAAG,EAAE,CAAM;IACjB,WAAW,EAAE,MAAM,CAAM;IACzB,UAAU,EAAE,OAAO,CAAS;IAElC,iBAAiB;IAsBjB,KAAK;IAqBL,gBAAgB,IAAI,OAAO,CAAC,OAAO,GAAG,SAAS,CAAC;IAStD,OAAO,CAAC,yBAAyB;IA8BjC,OAAO,CAAC,iBAAiB;IAczB,iBAAiB;IAmBjB,IACI,eAAe,WAElB;IAED,cAAc,MAAO,WAAW,KAAG,IAAI,CAIrC;IAEF,UAAU;IAiBV,OAAO,CAAC,cAAc;IAQhB,YAAY;IAIZ,aAAa;IAOb,KAAK,CAAC,WAAW,EAAE,QAAQ;IAgDjC,IACI,iBAAiB,6BAEpB;IAED,IAAI,qBAAqB,YAExB;IAED,IAAI,cAAc,YAEjB;CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"login-form.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/login-form/login-form.template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"login-form.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/login-form/login-form.template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAsH9C,eAAO,MAAM,iBAAiB,gEA8E7B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"request-account.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/request-account/request-account.template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD,eAAO,MAAM,sBAAsB,
|
|
1
|
+
{"version":3,"file":"request-account.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/request-account/request-account.template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD,eAAO,MAAM,sBAAsB,qEAiClC,CAAC"}
|
|
@@ -9,6 +9,6 @@ export declare class ResetPassword extends BaseRoute {
|
|
|
9
9
|
onSubmit(): Promise<void>;
|
|
10
10
|
onForgotPasswordWorkflow(): Promise<void>;
|
|
11
11
|
onChangePasswordWorkflow(): Promise<void>;
|
|
12
|
-
get headingText():
|
|
12
|
+
get headingText(): "Change Password" | "You are required to change your password";
|
|
13
13
|
}
|
|
14
14
|
//# sourceMappingURL=reset-password.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reset-password.d.ts","sourceRoot":"","sources":["../../../../src/routes/reset-password/reset-password.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAG9D,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAGzC,qBAKa,aAAc,SAAQ,SAAS;IAC9B,kBAAkB,EAAE,OAAO,CAAS;IACpC,kBAAkB,EAAE,MAAM,CAAM;IAEtC,iBAAiB;IAKjB,KAAK,CAAC,KAAK,EAAE,eAAe,CAAC,QAAQ,CAAC;IAKtC,QAAQ;IAQR,wBAAwB;
|
|
1
|
+
{"version":3,"file":"reset-password.d.ts","sourceRoot":"","sources":["../../../../src/routes/reset-password/reset-password.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAG9D,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAGzC,qBAKa,aAAc,SAAQ,SAAS;IAC9B,kBAAkB,EAAE,OAAO,CAAS;IACpC,kBAAkB,EAAE,MAAM,CAAM;IAEtC,iBAAiB;IAKjB,KAAK,CAAC,KAAK,EAAE,eAAe,CAAC,QAAQ,CAAC;IAKtC,QAAQ;IAQR,wBAAwB;IAYxB,wBAAwB;IAY9B,IACI,WAAW,mEAEd;CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reset-password.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/reset-password/reset-password.template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEtD,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"reset-password.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/reset-password/reset-password.template.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEtD,eAAO,MAAM,qBAAqB,oEA8BjC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verify.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/verify/verify.template.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAEvC,eAAO,MAAM,cAAc,
|
|
1
|
+
{"version":3,"file":"verify.template.d.ts","sourceRoot":"","sources":["../../../../src/routes/verify/verify.template.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAEvC,eAAO,MAAM,cAAc,6DAkC1B,CAAC"}
|
package/dist/esm/main/main.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { __awaiter, __decorate } from "tslib";
|
|
2
2
|
import { ConnectConfig, defaultConnectConfig, Session } from '@genesislcap/foundation-comms';
|
|
3
|
-
import { I18next } from '@genesislcap/foundation-i18n';
|
|
4
3
|
import { customElement, FASTElement, observable } from '@microsoft/fast-element';
|
|
5
4
|
import { Container, inject, Registration } from '@microsoft/fast-foundation';
|
|
6
5
|
import { DefaultRouteRecognizer } from '@microsoft/fast-router';
|
|
@@ -210,9 +209,6 @@ __decorate([
|
|
|
210
209
|
__decorate([
|
|
211
210
|
Session
|
|
212
211
|
], Login.prototype, "session", void 0);
|
|
213
|
-
__decorate([
|
|
214
|
-
I18next
|
|
215
|
-
], Login.prototype, "i18next", void 0);
|
|
216
212
|
__decorate([
|
|
217
213
|
observable
|
|
218
214
|
], Login.prototype, "ready", void 0);
|
package/dist/esm/routes/base.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { __awaiter, __decorate } from "tslib";
|
|
2
2
|
import { Auth, Connect, CredentialManager, credentialSeparator, MessageBuilder, Session, } from '@genesislcap/foundation-comms';
|
|
3
|
-
import { I18next } from '@genesislcap/foundation-i18n';
|
|
4
3
|
import { sync } from '@genesislcap/foundation-utils';
|
|
5
4
|
import { SecondaryRapidColorHEX } from '@genesislcap/foundation-zero';
|
|
6
5
|
import { attr, css, customElement, FASTElement, html, observable, when, } from '@microsoft/fast-element';
|
|
@@ -24,9 +23,6 @@ export class ConfigHostElement extends FASTElement {
|
|
|
24
23
|
this.config = this.container.has(LoginConfig, true)
|
|
25
24
|
? this.container.get(LoginConfig)
|
|
26
25
|
: defaultLoginConfig;
|
|
27
|
-
if (this.config.localizationResources) {
|
|
28
|
-
this.i18next.addResources(this.config.localizationResources);
|
|
29
|
-
}
|
|
30
26
|
super.connectedCallback();
|
|
31
27
|
}
|
|
32
28
|
}
|
|
@@ -36,9 +32,6 @@ __decorate([
|
|
|
36
32
|
__decorate([
|
|
37
33
|
observable
|
|
38
34
|
], ConfigHostElement.prototype, "config", void 0);
|
|
39
|
-
__decorate([
|
|
40
|
-
I18next
|
|
41
|
-
], ConfigHostElement.prototype, "i18next", void 0);
|
|
42
35
|
/**
|
|
43
36
|
* @internal
|
|
44
37
|
*/
|
|
@@ -76,14 +69,7 @@ export class BaseRoute extends ConfigHostElement {
|
|
|
76
69
|
return __awaiter(this, void 0, void 0, function* () {
|
|
77
70
|
this.isSubmitting = true;
|
|
78
71
|
this.clearError();
|
|
79
|
-
|
|
80
|
-
yield this.ensureConnection();
|
|
81
|
-
}
|
|
82
|
-
catch (err) {
|
|
83
|
-
this.isSubmitting = false;
|
|
84
|
-
logger.error('Failed to establish connection during onSubmit.', err);
|
|
85
|
-
this.setError(this.toLocalisedText("We couldn't connect to our servers to process your request. If the problem persists, contact our support team for help."));
|
|
86
|
-
}
|
|
72
|
+
yield this.ensureConnection();
|
|
87
73
|
});
|
|
88
74
|
}
|
|
89
75
|
ensureConnection() {
|
|
@@ -110,11 +96,10 @@ export class BaseRoute extends ConfigHostElement {
|
|
|
110
96
|
getSubRoutePath(routeName) {
|
|
111
97
|
return this.config.hostPath !== '' ? `${this.config.hostPath}/${routeName}` : routeName;
|
|
112
98
|
}
|
|
113
|
-
queueOnBack(delay) {
|
|
114
|
-
var _a;
|
|
99
|
+
queueOnBack(delay = defaultOnBackMS) {
|
|
115
100
|
setTimeout(() => {
|
|
116
101
|
this.onBack();
|
|
117
|
-
}, delay
|
|
102
|
+
}, delay);
|
|
118
103
|
}
|
|
119
104
|
autofill() {
|
|
120
105
|
var _a, _b, _c;
|
|
@@ -166,31 +151,20 @@ export class BaseRoute extends ConfigHostElement {
|
|
|
166
151
|
this.credentialManager.storeCredentials(data);
|
|
167
152
|
}
|
|
168
153
|
}
|
|
169
|
-
sendMessage(message, successFeedback = '', successCallback
|
|
154
|
+
sendMessage(message, successFeedback = '', successCallback) {
|
|
170
155
|
return __awaiter(this, void 0, void 0, function* () {
|
|
171
156
|
yield this.ensureConnection();
|
|
172
157
|
this.clearError();
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
return;
|
|
178
|
-
}
|
|
179
|
-
this.message = successFeedback;
|
|
180
|
-
successCallback && successCallback(result);
|
|
181
|
-
}
|
|
182
|
-
catch (err) {
|
|
183
|
-
this.isSubmitting = false;
|
|
184
|
-
logger.error('Failed to send message during onSubmit.', err);
|
|
185
|
-
this.setError(this.toLocalisedText('We were unable to process your request at this time. Please try again later. If the problem persists, contact our support team for assistance.'));
|
|
158
|
+
const result = yield this.connect.send(message);
|
|
159
|
+
if (result.ERROR) {
|
|
160
|
+
this.setError(result.ERROR.map((error) => error.TEXT).toString());
|
|
161
|
+
return;
|
|
186
162
|
}
|
|
187
|
-
this.
|
|
188
|
-
|
|
163
|
+
this.message = successFeedback;
|
|
164
|
+
successCallback && successCallback(result);
|
|
165
|
+
this.queueOnBack();
|
|
189
166
|
});
|
|
190
167
|
}
|
|
191
|
-
toLocalisedText(text) {
|
|
192
|
-
return this.i18next.t(text, { lng: this.i18next.language });
|
|
193
|
-
}
|
|
194
168
|
}
|
|
195
169
|
__decorate([
|
|
196
170
|
Auth
|
|
@@ -283,7 +257,7 @@ export const organisationField = () => html `
|
|
|
283
257
|
?required="${(x) => (x.config.fields.organisation.required === false ? false : true)}"
|
|
284
258
|
>
|
|
285
259
|
<span class="form-title">
|
|
286
|
-
${(x) => { var _a; return
|
|
260
|
+
${(x) => { var _a; return (_a = x.config.fields.organisation.label) !== null && _a !== void 0 ? _a : 'Organisation'; }}
|
|
287
261
|
</span>
|
|
288
262
|
</zero-text-field>
|
|
289
263
|
`)}
|
|
@@ -305,9 +279,7 @@ export const usernameField = () => html `
|
|
|
305
279
|
title="${(x) => x.config.fields.username.title}"
|
|
306
280
|
required
|
|
307
281
|
>
|
|
308
|
-
<span class="form-title">
|
|
309
|
-
${(x) => { var _a; return x.toLocalisedText((_a = x.config.fields.username.label) !== null && _a !== void 0 ? _a : 'Username'); }}
|
|
310
|
-
</span>
|
|
282
|
+
<span class="form-title">${(x) => { var _a; return (_a = x.config.fields.username.label) !== null && _a !== void 0 ? _a : 'Username'; }}</span>
|
|
311
283
|
</zero-text-field>
|
|
312
284
|
`;
|
|
313
285
|
/**
|
|
@@ -324,9 +296,7 @@ export const emailField = () => html `
|
|
|
324
296
|
:value="${sync((x) => x.email)}"
|
|
325
297
|
required
|
|
326
298
|
>
|
|
327
|
-
<span class="form-title">
|
|
328
|
-
${(x) => { var _a; return x.toLocalisedText((_a = x.config.fields.email.label) !== null && _a !== void 0 ? _a : 'Email'); }}
|
|
329
|
-
</span>
|
|
299
|
+
<span class="form-title">${(x) => { var _a; return (_a = x.config.fields.email.label) !== null && _a !== void 0 ? _a : 'Email'; }}</span>
|
|
330
300
|
</zero-text-field>
|
|
331
301
|
`)}
|
|
332
302
|
`;
|
|
@@ -343,9 +313,7 @@ export const passwordField = (label) => html `
|
|
|
343
313
|
:value="${sync((x) => x.password)}"
|
|
344
314
|
required
|
|
345
315
|
>
|
|
346
|
-
<span class="form-title">
|
|
347
|
-
${(x) => { var _a; return x.toLocalisedText((_a = label !== null && label !== void 0 ? label : x.config.fields.password.label) !== null && _a !== void 0 ? _a : 'Password'); }}
|
|
348
|
-
</span>
|
|
316
|
+
<span class="form-title">${(x) => { var _a; return (_a = label !== null && label !== void 0 ? label : x.config.fields.password.label) !== null && _a !== void 0 ? _a : 'Password'; }}</span>
|
|
349
317
|
</zero-text-field>
|
|
350
318
|
`;
|
|
351
319
|
const password2FieldMeta = {
|
|
@@ -367,7 +335,7 @@ export const password2Field = (type) => {
|
|
|
367
335
|
:value="${sync((x) => x.password2)}"
|
|
368
336
|
required
|
|
369
337
|
>
|
|
370
|
-
<span class="form-title">${
|
|
338
|
+
<span class="form-title">${label}</span>
|
|
371
339
|
</zero-text-field>
|
|
372
340
|
`;
|
|
373
341
|
};
|
|
@@ -440,7 +408,7 @@ export { LogoElement };
|
|
|
440
408
|
/**
|
|
441
409
|
* @internal
|
|
442
410
|
*/
|
|
443
|
-
export const backButton = (binding
|
|
411
|
+
export const backButton = (binding) => html `
|
|
444
412
|
<zero-button
|
|
445
413
|
appearance="neutral-grey"
|
|
446
414
|
type="button"
|
|
@@ -448,7 +416,7 @@ export const backButton = (binding, label) => html `
|
|
|
448
416
|
@click=${binding}
|
|
449
417
|
data-test-id="back"
|
|
450
418
|
>
|
|
451
|
-
|
|
419
|
+
Back
|
|
452
420
|
</zero-button>
|
|
453
421
|
`;
|
|
454
422
|
/**
|
|
@@ -474,7 +442,7 @@ export const showPasswordsCheckbox = () => html `
|
|
|
474
442
|
name="show-passwords"
|
|
475
443
|
data-test-id="show-passwords"
|
|
476
444
|
>
|
|
477
|
-
|
|
445
|
+
Show Passwords
|
|
478
446
|
</zero-checkbox>
|
|
479
447
|
`;
|
|
480
448
|
/**
|
|
@@ -19,7 +19,6 @@ let ForgotPassword = class ForgotPassword extends BaseRoute {
|
|
|
19
19
|
const _super = Object.create(null, {
|
|
20
20
|
onSubmit: { get: () => super.onSubmit }
|
|
21
21
|
});
|
|
22
|
-
var _a;
|
|
23
22
|
return __awaiter(this, void 0, void 0, function* () {
|
|
24
23
|
logger.debug('forgot password submission');
|
|
25
24
|
yield _super.onSubmit.call(this);
|
|
@@ -28,7 +27,7 @@ let ForgotPassword = class ForgotPassword extends BaseRoute {
|
|
|
28
27
|
*/
|
|
29
28
|
const returnUrl = `${location.protocol}//${hostEnv}/${this.getSubRoutePath('reset-password')}`;
|
|
30
29
|
const message = this.messageBuilder.createForgotPasswordMessage(this.orgUsername, returnUrl);
|
|
31
|
-
yield this.sendMessage(message,
|
|
30
|
+
yield this.sendMessage(message, 'Please check your inbox for reset instructions.');
|
|
32
31
|
});
|
|
33
32
|
}
|
|
34
33
|
};
|
|
@@ -6,14 +6,13 @@ export const ForgotPasswordTemplate = html `
|
|
|
6
6
|
<zero-card class="card-pd">
|
|
7
7
|
<div class="column-content">
|
|
8
8
|
<login-logo></login-logo>
|
|
9
|
-
<div class="heading2"
|
|
10
|
-
<div class="heading3"
|
|
9
|
+
<div class="heading2">Forgotten Password</div>
|
|
10
|
+
<div class="heading3">Enter your account username</div>
|
|
11
11
|
</div>
|
|
12
12
|
<form @submit=${(x) => x.onSubmit()}>
|
|
13
13
|
${organisationField()} ${usernameField()}
|
|
14
14
|
<div class="form-buttons">
|
|
15
|
-
${
|
|
16
|
-
${(x) => backButton(() => x.onBack(), x.toLocalisedText('Back'))}
|
|
15
|
+
${submitButton('Send Recovery Link')} ${backButton((x) => x.onBack())}
|
|
17
16
|
</div>
|
|
18
17
|
<submitting-indicator is-submitting="${(x) => x.isSubmitting}"></submitting-indicator>
|
|
19
18
|
<login-message
|
|
@@ -122,14 +122,14 @@ let LoginForm = class LoginForm extends BaseRoute {
|
|
|
122
122
|
logger.debug('fetched IDPs', idps);
|
|
123
123
|
// it no longer throws, check for 'error' manually
|
|
124
124
|
if (!idps.length || (idps.length === 1 && ((_a = idps[0]) === null || _a === void 0 ? void 0 : _a.id) === 'error')) {
|
|
125
|
-
this.setError(
|
|
125
|
+
this.setError('Failed to fetch identity providers.');
|
|
126
126
|
}
|
|
127
127
|
else {
|
|
128
128
|
this.idps = idps;
|
|
129
129
|
this.selectedIDP = (_c = (_b = this.idps) === null || _b === void 0 ? void 0 : _b[0]) === null || _c === void 0 ? void 0 : _c.id;
|
|
130
130
|
}
|
|
131
131
|
})
|
|
132
|
-
.catch(() => this.setError(
|
|
132
|
+
.catch(() => this.setError('Failed to fetch identity providers.'));
|
|
133
133
|
}
|
|
134
134
|
}
|
|
135
135
|
get selectedIDPName() {
|
|
@@ -182,7 +182,7 @@ let LoginForm = class LoginForm extends BaseRoute {
|
|
|
182
182
|
try {
|
|
183
183
|
const { authToken } = yield this.auth.login(credentials);
|
|
184
184
|
if (!authToken) {
|
|
185
|
-
throw new Error(
|
|
185
|
+
throw new Error('Unable to login. Try again later.');
|
|
186
186
|
}
|
|
187
187
|
this.storeCredentials();
|
|
188
188
|
let url = this.config.defaultRedirectUrl;
|
|
@@ -208,13 +208,13 @@ let LoginForm = class LoginForm extends BaseRoute {
|
|
|
208
208
|
this.storeCredentials();
|
|
209
209
|
this.session.setLocalStorageItem('refreshToken', err.received.REFRESH_AUTH_TOKEN);
|
|
210
210
|
this.session.setLocalStorageItem('username', this.username);
|
|
211
|
-
this.setError(
|
|
211
|
+
this.setError('Please check your inbox for your login link.');
|
|
212
212
|
return;
|
|
213
213
|
}
|
|
214
214
|
if (this.config.fields.organisation &&
|
|
215
215
|
this.config.fields.organisation.required !== false &&
|
|
216
216
|
!this.organisation.length) {
|
|
217
|
-
this.setError(err.message +
|
|
217
|
+
this.setError(err.message + 'Please fill in Comp Id.');
|
|
218
218
|
return;
|
|
219
219
|
}
|
|
220
220
|
this.setError(err.message + err.getMessageError());
|
|
@@ -225,9 +225,7 @@ let LoginForm = class LoginForm extends BaseRoute {
|
|
|
225
225
|
});
|
|
226
226
|
}
|
|
227
227
|
get connectActionText() {
|
|
228
|
-
return this.connect.isConnected
|
|
229
|
-
? this.toLocalisedText('Disconnect')
|
|
230
|
-
: this.toLocalisedText('Connect');
|
|
228
|
+
return this.connect.isConnected ? 'Disconnect' : 'Connect';
|
|
231
229
|
}
|
|
232
230
|
get submitConnectDisabled() {
|
|
233
231
|
return !this.host;
|
|
@@ -4,10 +4,10 @@ import { organisationField, passwordField, showPasswordsCheckbox, usernameField,
|
|
|
4
4
|
const regularLogin = html `
|
|
5
5
|
${when((login) => !login.ssoToggled, html `
|
|
6
6
|
${organisationField()} ${usernameField()} ${passwordField()}
|
|
7
|
-
<span class="case-warning"
|
|
7
|
+
<span class="case-warning">*Fields are case-sensitive</span>
|
|
8
8
|
${showPasswordsCheckbox()}
|
|
9
9
|
<div class="form-buttons">
|
|
10
|
-
${(x) => submitButton(
|
|
10
|
+
${(x) => submitButton('Login', 'submit-login', x.submitDisabled)}
|
|
11
11
|
<div class="links">
|
|
12
12
|
<div class="password-links">
|
|
13
13
|
${when((x) => !x.config.omitRoutes.includes('forgot-password'), html `
|
|
@@ -16,7 +16,7 @@ const regularLogin = html `
|
|
|
16
16
|
@click=${(x) => x.onNavigate(x.getSubRoutePath(`forgot-password`))}
|
|
17
17
|
data-test-id="forgot-password"
|
|
18
18
|
>
|
|
19
|
-
|
|
19
|
+
Forgot Password?
|
|
20
20
|
</a>
|
|
21
21
|
`)}
|
|
22
22
|
${when((x) => !x.config.omitRoutes.includes('reset-password'), html `
|
|
@@ -25,7 +25,7 @@ const regularLogin = html `
|
|
|
25
25
|
@click=${(x) => x.onNavigate(x.getSubRoutePath(`reset-password`))}
|
|
26
26
|
data-test-id="reset-password"
|
|
27
27
|
>
|
|
28
|
-
|
|
28
|
+
Change Password
|
|
29
29
|
</a>
|
|
30
30
|
`)}
|
|
31
31
|
</div>
|
|
@@ -36,7 +36,7 @@ const regularLogin = html `
|
|
|
36
36
|
@click=${(x) => x.onNavigate(x.getSubRoutePath(`request-account`))}
|
|
37
37
|
data-test-id="request-account"
|
|
38
38
|
>
|
|
39
|
-
|
|
39
|
+
Request Account
|
|
40
40
|
</a>
|
|
41
41
|
`)}
|
|
42
42
|
</div>
|
|
@@ -54,7 +54,7 @@ const regularLogin = html `
|
|
|
54
54
|
const ssoLogin = html `
|
|
55
55
|
${when((login) => login.ssoToggled, html `
|
|
56
56
|
<div class="sso">
|
|
57
|
-
<span class="form-title"
|
|
57
|
+
<span class="form-title">Providers</span>
|
|
58
58
|
<zero-select
|
|
59
59
|
name="sso"
|
|
60
60
|
data-test-id="sso"
|
|
@@ -73,15 +73,13 @@ const ssoLogin = html `
|
|
|
73
73
|
data-test-id="sso-login"
|
|
74
74
|
?disabled=${(x) => !x.selectedIDP}
|
|
75
75
|
>
|
|
76
|
-
|
|
76
|
+
SSO Login
|
|
77
77
|
</zero-button>
|
|
78
78
|
</div>
|
|
79
79
|
`)}
|
|
80
80
|
`;
|
|
81
81
|
const httpModeEnabledText = html `
|
|
82
|
-
<pre data-test-id="connect-http-mode">
|
|
83
|
-
${(x) => x.toLocalisedText('Http Polling Mode Enabled.')}</pre
|
|
84
|
-
>
|
|
82
|
+
<pre data-test-id="connect-http-mode">Http Polling Mode Enabled.</pre>
|
|
85
83
|
`;
|
|
86
84
|
const httpMode = html `
|
|
87
85
|
${(x) => (x.connect.httpMode() ? httpModeEnabledText : null)}
|
|
@@ -114,7 +112,7 @@ export const LoginFormTemplate = html `
|
|
|
114
112
|
data-test-id="connect-host"
|
|
115
113
|
required
|
|
116
114
|
>
|
|
117
|
-
<span class="form-title"
|
|
115
|
+
<span class="form-title">Host</span>
|
|
118
116
|
</zero-text-field>
|
|
119
117
|
|
|
120
118
|
${httpMode}
|
|
@@ -129,7 +127,7 @@ export const LoginFormTemplate = html `
|
|
|
129
127
|
<zero-card class="card-pd">
|
|
130
128
|
<div class="column-content">
|
|
131
129
|
<login-logo></login-logo>
|
|
132
|
-
<div class="heading2"
|
|
130
|
+
<div class="heading2">Login</div>
|
|
133
131
|
</div>
|
|
134
132
|
<form
|
|
135
133
|
id="login-form"
|
|
@@ -146,9 +144,7 @@ export const LoginFormTemplate = html `
|
|
|
146
144
|
name="sso-toggle"
|
|
147
145
|
data-test-id="sso-toggle"
|
|
148
146
|
>
|
|
149
|
-
${(x) => x.ssoToggled
|
|
150
|
-
? x.toLocalisedText('SSO Enabled') + x.selectedIDPName
|
|
151
|
-
: x.toLocalisedText('Enable SSO?')}
|
|
147
|
+
${(x) => (x.ssoToggled ? 'SSO Enabled' + x.selectedIDPName : 'Enable SSO?')}
|
|
152
148
|
</zero-checkbox>
|
|
153
149
|
`)}
|
|
154
150
|
<login-message
|
|
@@ -8,7 +8,7 @@ NotFound = __decorate([
|
|
|
8
8
|
customElement({
|
|
9
9
|
name: 'foundation-login-not-found',
|
|
10
10
|
template: html `
|
|
11
|
-
<h1 data-test-id="not-found"
|
|
11
|
+
<h1 data-test-id="not-found">Not found! 404</h1>
|
|
12
12
|
`,
|
|
13
13
|
styles: commonLoginRouteStyles,
|
|
14
14
|
})
|