@equinor/fusion-framework-vite-plugin-spa 3.1.6 → 3.1.7
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/CHANGELOG.md +7 -0
- package/dist/esm/version.js +1 -1
- package/dist/html/bootstrap.js +25 -2
- package/dist/html/bootstrap.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/html/index.html.d.ts +1 -1
- package/dist/types/version.d.ts +1 -1
- package/package.json +4 -4
- package/src/version.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @equinor/fusion-framework-vite-plugin-spa
|
|
2
2
|
|
|
3
|
+
## 3.1.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`dcf51aa`](https://github.com/equinor/fusion-framework/commit/dcf51aa87ac79200893ec4909632554464e75055)]:
|
|
8
|
+
- @equinor/fusion-framework-module-msal@7.2.0
|
|
9
|
+
|
|
3
10
|
## 3.1.6
|
|
4
11
|
|
|
5
12
|
### Patch Changes
|
package/dist/esm/version.js
CHANGED
package/dist/html/bootstrap.js
CHANGED
|
@@ -40463,7 +40463,7 @@ const createClientLogCallback = (provider, metadata, scope) => {
|
|
|
40463
40463
|
};
|
|
40464
40464
|
|
|
40465
40465
|
// Generated by genversion.
|
|
40466
|
-
const version$2 = '7.
|
|
40466
|
+
const version$2 = '7.2.0';
|
|
40467
40467
|
|
|
40468
40468
|
/**
|
|
40469
40469
|
* Zod schema for telemetry configuration validation.
|
|
@@ -40488,6 +40488,7 @@ const MsalConfigSchema = z.object({
|
|
|
40488
40488
|
provider: z.custom().optional(),
|
|
40489
40489
|
requiresAuth: z.boolean().optional(),
|
|
40490
40490
|
redirectUri: z.string().optional(),
|
|
40491
|
+
loginHint: z.string().optional(),
|
|
40491
40492
|
authCode: z.string().optional(),
|
|
40492
40493
|
version: z.string().transform((x) => String(semver.coerce(x))),
|
|
40493
40494
|
telemetry: TelemetryConfigSchema,
|
|
@@ -40610,6 +40611,24 @@ class MsalConfigurator extends BaseConfigBuilder {
|
|
|
40610
40611
|
this._set('requiresAuth', async () => requiresAuth);
|
|
40611
40612
|
return this;
|
|
40612
40613
|
}
|
|
40614
|
+
/**
|
|
40615
|
+
* Sets a default login hint for authentication flows.
|
|
40616
|
+
*
|
|
40617
|
+
* The login hint is used to pre-fill the username during authentication and
|
|
40618
|
+
* enables silent SSO when no account is available.
|
|
40619
|
+
*
|
|
40620
|
+
* @param loginHint - The preferred username/email to use as login hint
|
|
40621
|
+
* @returns The configurator instance for method chaining
|
|
40622
|
+
*
|
|
40623
|
+
* @example
|
|
40624
|
+
* ```typescript
|
|
40625
|
+
* configurator.setLoginHint('user@company.com');
|
|
40626
|
+
* ```
|
|
40627
|
+
*/
|
|
40628
|
+
setLoginHint(loginHint) {
|
|
40629
|
+
this._set('loginHint', async () => loginHint);
|
|
40630
|
+
return this;
|
|
40631
|
+
}
|
|
40613
40632
|
/**
|
|
40614
40633
|
* @deprecated - since version 5.1.0, use setClient instead
|
|
40615
40634
|
*/
|
|
@@ -41474,6 +41493,7 @@ class MsalProvider extends BaseModuleProvider {
|
|
|
41474
41493
|
#telemetry;
|
|
41475
41494
|
#requiresAuth;
|
|
41476
41495
|
#authCode;
|
|
41496
|
+
#loginHint;
|
|
41477
41497
|
/**
|
|
41478
41498
|
* The MSAL module version enum value indicating the API compatibility level.
|
|
41479
41499
|
*
|
|
@@ -41531,6 +41551,7 @@ class MsalProvider extends BaseModuleProvider {
|
|
|
41531
41551
|
});
|
|
41532
41552
|
this.#requiresAuth = config.requiresAuth;
|
|
41533
41553
|
this.#telemetry = config.telemetry;
|
|
41554
|
+
this.#loginHint = config.loginHint;
|
|
41534
41555
|
// Extract auth code from config if present
|
|
41535
41556
|
// This will be used during initialize to exchange for tokens
|
|
41536
41557
|
this.#authCode = config.authCode;
|
|
@@ -41791,6 +41812,8 @@ class MsalProvider extends BaseModuleProvider {
|
|
|
41791
41812
|
*/
|
|
41792
41813
|
async login(options) {
|
|
41793
41814
|
const { behavior = 'redirect', silent = true, request } = options;
|
|
41815
|
+
request.loginHint ??=
|
|
41816
|
+
this.#loginHint ?? this.account?.username ?? this.account?.loginHint ?? undefined;
|
|
41794
41817
|
// Determine if silent login is possible based on available account/hint information
|
|
41795
41818
|
// Silent login requires either an account object or a loginHint to work
|
|
41796
41819
|
const canLoginSilently = silent && (request.account || request.loginHint);
|
|
@@ -44905,7 +44928,7 @@ async function registerServiceWorker(framework) {
|
|
|
44905
44928
|
}
|
|
44906
44929
|
|
|
44907
44930
|
// Generated by genversion.
|
|
44908
|
-
const version = '3.1.
|
|
44931
|
+
const version = '3.1.7';
|
|
44909
44932
|
|
|
44910
44933
|
// Allow dynamic import without vite
|
|
44911
44934
|
const importWithoutVite = (path) => import(/* @vite-ignore */ path);
|