@axa-fr/react-oidc 6.26.6 → 7.0.1-alpha.996
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/README.md +79 -69
- package/dist/FetchToken.d.ts +0 -1
- package/dist/OidcProvider.d.ts +2 -3
- package/dist/OidcSecure.d.ts +0 -1
- package/dist/ReactOidc.d.ts +0 -1
- package/dist/User.d.ts +0 -1
- package/dist/core/default-component/AuthenticateError.component.d.ts +0 -1
- package/dist/core/default-component/Authenticating.component.d.ts +0 -1
- package/dist/core/default-component/Callback.component.d.ts +0 -1
- package/dist/core/default-component/Loading.component.d.ts +0 -1
- package/dist/core/default-component/ServiceWorkerNotSupported.component.d.ts +0 -1
- package/dist/core/default-component/SessionLost.component.d.ts +0 -1
- package/dist/core/default-component/SilentCallback.component.d.ts +0 -1
- package/dist/core/default-component/SilentLogin.component.d.ts +0 -1
- package/dist/core/default-component/index.d.ts +0 -1
- package/dist/core/routes/OidcRoutes.d.ts +0 -1
- package/dist/core/routes/index.d.ts.map +1 -1
- package/dist/core/routes/withRouter.d.ts +0 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.js +42 -42
- package/dist/index.umd.cjs +9 -9
- package/package.json +3 -3
- package/src/FetchToken.tsx +3 -3
- package/src/OidcProvider.tsx +19 -19
- package/src/OidcSecure.tsx +2 -2
- package/src/ReactOidc.tsx +19 -19
- package/src/User.ts +2 -2
- package/src/core/default-component/Callback.component.tsx +2 -2
- package/src/core/default-component/SilentCallback.component.tsx +2 -2
- package/src/core/default-component/SilentLogin.component.tsx +2 -2
- package/dist/FetchToken.d.ts.map +0 -1
- package/dist/OidcProvider.d.ts.map +0 -1
- package/dist/OidcSecure.d.ts.map +0 -1
- package/dist/ReactOidc.d.ts.map +0 -1
- package/dist/User.d.ts.map +0 -1
- package/dist/core/default-component/AuthenticateError.component.d.ts.map +0 -1
- package/dist/core/default-component/Authenticating.component.d.ts.map +0 -1
- package/dist/core/default-component/Callback.component.d.ts.map +0 -1
- package/dist/core/default-component/Loading.component.d.ts.map +0 -1
- package/dist/core/default-component/ServiceWorkerNotSupported.component.d.ts.map +0 -1
- package/dist/core/default-component/SessionLost.component.d.ts.map +0 -1
- package/dist/core/default-component/SilentCallback.component.d.ts.map +0 -1
- package/dist/core/default-component/SilentLogin.component.d.ts.map +0 -1
- package/dist/core/default-component/index.d.ts.map +0 -1
- package/dist/core/routes/OidcRoutes.d.ts.map +0 -1
- package/dist/core/routes/withRouter.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
package/README.md
CHANGED
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
# @axa-fr/react-oidc
|
|
2
2
|
|
|
3
|
-
[](https://github.com/AxaFrance/react-oidc/actions/workflows/npm-publish.yml)
|
|
4
4
|
[](https://sonarcloud.io/dashboard?id=AxaGuilDEv_react-oidc) [](https://sonarcloud.io/component_measures?id=AxaGuilDEv_react-oidc&metric=reliability_rating) [](https://sonarcloud.io/component_measures?id=AxaGuilDEv_react-oidc&metric=security_rating) [](https://sonarcloud.io/component_measures?id=AxaGuilDEv_react-oidc&metric=Coverage) [](https://twitter.com/intent/follow?screen_name=GuildDEvOpen)
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
**@axa-fr/oidc-client** the lightest and securest library to manage authentication with OpenID Connect (OIDC) and OAuth2 protocol. It is compatible with all OIDC providers.
|
|
7
|
+
**@axa-fr/oidc-client** is a pure javascript library. It works with any JavaScript framework or library.
|
|
7
8
|
|
|
8
|
-
|
|
9
|
+
We provide a wrapper **@axa-fr/react-oidc** for **React** (compatible next.js) and we expect soon to provide one for **Vue**, **Angular** and **Svelte**.
|
|
9
10
|
|
|
10
|
-
|
|
11
|
+
- Try the react demo at https://black-rock-0dc6b0d03.1.azurestaticapps.net/ (most advanced)
|
|
12
|
+
- Try the pure javascript demo at https://icy-glacier-004ab4303.2.azurestaticapps.net/
|
|
13
|
+
|
|
14
|
+
<p align="center">
|
|
15
|
+
<img src="https://github.com/AxaFrance/react-oidc/blob/master/docs/img/introduction.gif?raw=true"
|
|
16
|
+
alt="Sample React Oicd"
|
|
17
|
+
/>
|
|
18
|
+
</p>
|
|
11
19
|
|
|
12
20
|
- [About](#about)
|
|
13
21
|
- [Getting Started](#getting-started)
|
|
@@ -20,22 +28,21 @@ A set of react components to make OIDC (OpenID Connect) client easy. It aim to s
|
|
|
20
28
|
|
|
21
29
|
## About
|
|
22
30
|
|
|
23
|
-
|
|
24
|
-
It is a real alternative to existing oidc-client libraries.
|
|
31
|
+
@axa-fr/react is:
|
|
25
32
|
|
|
26
33
|
- **Secure** :
|
|
27
|
-
- With the use of Service Worker, your tokens (refresh_token and access_token) are not accessible to the JavaScript client code (big protection against
|
|
28
|
-
- OIDC using client side Code Credential Grant with
|
|
29
|
-
- **Lightweight**
|
|
30
|
-
- **Simple**
|
|
34
|
+
- With the use of Service Worker, your tokens (refresh_token and access_token) are not accessible to the JavaScript client code (big protection against XSS attacks)
|
|
35
|
+
- OIDC using client side Code Credential Grant with pkce only
|
|
36
|
+
- **Lightweight** : Unpacked Size on npm is **274 kB**
|
|
37
|
+
- **Simple**
|
|
31
38
|
- refresh_token and access_token are auto refreshed in background
|
|
32
|
-
- with the use of the Service Worker, you do not need to inject the access_token in every fetch, you have only to configure
|
|
33
|
-
- **No cookies problem** : You can disable silent signin (that internally use an iframe). For your information, your OIDC server should be in the same domain of your website in order to be able to send OIDC server cookies from your website via an internal IFRAME, else, you may encounter COOKIES problem.
|
|
39
|
+
- with the use of the Service Worker, you do not need to inject the access_token in every fetch, you have only to configure OidcTrustedDomains.js file
|
|
34
40
|
- **Multiple Authentication** :
|
|
35
41
|
- You can authenticate many times to the same provider with different scope (for example you can acquire a new 'payment' scope for a payment)
|
|
36
42
|
- You can authenticate to multiple different providers inside the same SPA (single page application) website
|
|
37
43
|
- **Flexible** :
|
|
38
|
-
- Work with Service Worker (more secure) and without for older browser (less secure)
|
|
44
|
+
- Work with Service Worker (more secure) and without for older browser (less secure).
|
|
45
|
+
- You can disable Service Worker if you want (but less secure) and just use SessionStorage or LocalStorage mode.
|
|
39
46
|
|
|
40
47
|

|
|
41
48
|
|
|
@@ -63,23 +70,32 @@ The only file you should edit is "OidcTrustedDomains.js".
|
|
|
63
70
|
|
|
64
71
|
// Domains used by OIDC server must be also declared here
|
|
65
72
|
const trustedDomains = {
|
|
66
|
-
default:
|
|
73
|
+
default: {
|
|
74
|
+
oidcDomains :["https://demo.duendesoftware.com"],
|
|
75
|
+
accessTokenDomains : ["https://www.myapi.com/users"]
|
|
76
|
+
},
|
|
67
77
|
};
|
|
68
78
|
|
|
69
79
|
// Service worker will continue to give access token to the JavaScript client
|
|
70
80
|
// Ideal to hide refresh token from client JavaScript, but to retrieve access_token for some
|
|
71
81
|
// scenarios which require it. For example, to send it via websocket connection.
|
|
72
|
-
trustedDomains.config_show_access_token = {
|
|
82
|
+
trustedDomains.config_show_access_token = {
|
|
83
|
+
oidcDomains :["https://demo.duendesoftware.com"],
|
|
84
|
+
accessTokenDomains : ["https://www.myapi.com/users"],
|
|
85
|
+
showAccessToken: true
|
|
86
|
+
};
|
|
73
87
|
|
|
74
88
|
```
|
|
75
89
|
|
|
76
90
|
## Run The Demo
|
|
77
91
|
|
|
78
92
|
```sh
|
|
79
|
-
git clone https://github.com/
|
|
80
|
-
cd
|
|
81
|
-
|
|
82
|
-
|
|
93
|
+
git clone https://github.com/AxaFrance/oidc-client.git
|
|
94
|
+
cd oidc-client
|
|
95
|
+
pnpm install
|
|
96
|
+
cd /examples/react-oidc-demo
|
|
97
|
+
pnpm install
|
|
98
|
+
pnpm start
|
|
83
99
|
# then navigate to http://localhost:4200
|
|
84
100
|
```
|
|
85
101
|
|
|
@@ -111,7 +127,7 @@ const configuration = {
|
|
|
111
127
|
window.location.origin + "/authentication/silent-callback",
|
|
112
128
|
scope: "openid profile email api offline_access", // offline_access scope allow your client to retrieve the refresh_token
|
|
113
129
|
authority: "https://demo.duendesoftware.com",
|
|
114
|
-
service_worker_relative_url: "/OidcServiceWorker.js",
|
|
130
|
+
service_worker_relative_url: "/OidcServiceWorker.js", // just comment that line to disable service worker mode
|
|
115
131
|
service_worker_only: false,
|
|
116
132
|
};
|
|
117
133
|
|
|
@@ -128,49 +144,50 @@ render(<App />, document.getElementById("root"));
|
|
|
128
144
|
```
|
|
129
145
|
|
|
130
146
|
```javascript
|
|
131
|
-
const
|
|
132
|
-
loadingComponent:
|
|
133
|
-
sessionLostComponent:
|
|
134
|
-
authenticating:
|
|
135
|
-
authenticatingErrorComponent:
|
|
136
|
-
callbackSuccessComponent:
|
|
137
|
-
serviceWorkerNotSupportedComponent:
|
|
138
|
-
onSessionLost:
|
|
139
|
-
configuration:
|
|
140
|
-
client_id:
|
|
141
|
-
redirect_uri:
|
|
142
|
-
silent_redirect_uri:
|
|
143
|
-
silent_login_uri:
|
|
144
|
-
silent_login_timeout:
|
|
145
|
-
scope:
|
|
146
|
-
authority:
|
|
147
|
-
storage: Storage, // Default sessionStorage, you can set localStorage but it is less secure
|
|
148
|
-
authority_configuration:
|
|
149
|
-
// Optional for providers that
|
|
150
|
-
authorization_endpoint:
|
|
151
|
-
token_endpoint:
|
|
152
|
-
userinfo_endpoint:
|
|
153
|
-
end_session_endpoint:
|
|
154
|
-
revocation_endpoint:
|
|
155
|
-
check_session_iframe:
|
|
156
|
-
issuer:
|
|
157
|
-
}
|
|
158
|
-
refresh_time_before_tokens_expiration_in_second:
|
|
159
|
-
service_worker_relative_url:
|
|
160
|
-
service_worker_only:
|
|
161
|
-
service_worker_convert_all_requests_to_cors:
|
|
162
|
-
extras: StringMap | undefined, // ex: {'prompt': 'consent', 'access_type': 'offline'} list of key/value that
|
|
163
|
-
token_request_extras: StringMap | undefined, // ex: {'prompt': 'consent', 'access_type': 'offline'} list of key/value that
|
|
164
|
-
withCustomHistory:
|
|
165
|
-
authority_time_cache_wellknowurl_in_second: 60 * 60, // Time to cache in
|
|
166
|
-
authority_timeout_wellknowurl_in_millisecond: 10000, // Timeout in
|
|
167
|
-
monitor_session:
|
|
168
|
-
onLogoutFromAnotherTab: Function, // Optional, can be set to override the default behavior, this function is triggered when user with the same subject is logged out from another tab when session_monitor is active
|
|
169
|
-
onLogoutFromSameTab: Function, // Optional, can be set to override the default behavior, this function is triggered when user is logged out from same tab when session_monitor is active
|
|
170
|
-
token_renew_mode:
|
|
171
|
-
logout_tokens_to_invalidate
|
|
172
|
-
}
|
|
147
|
+
const configuration = {
|
|
148
|
+
loadingComponent: ReactComponent, // you can inject your own loading component
|
|
149
|
+
sessionLostComponent: ReactComponent, // you can inject your own session lost component
|
|
150
|
+
authenticating: ReactComponent, // you can inject your own authenticating component
|
|
151
|
+
authenticatingErrorComponent: ReactComponent,
|
|
152
|
+
callbackSuccessComponent: ReactComponent, // you can inject your own call back success component
|
|
153
|
+
serviceWorkerNotSupportedComponent: ReactComponent, // you can inject your page that explains you require a more modern browser
|
|
154
|
+
onSessionLost: Function, // If set, "sessionLostComponent" is not displayed, and onSessionLost callback is called instead
|
|
155
|
+
configuration: {
|
|
156
|
+
client_id: String.isRequired, // oidc client id
|
|
157
|
+
redirect_uri: String.isRequired, // oidc redirect url
|
|
158
|
+
silent_redirect_uri: String, // Optional activate silent-signin that use cookies between OIDC server and client javascript to restore sessions
|
|
159
|
+
silent_login_uri: String, // Optional, route that triggers the signin
|
|
160
|
+
silent_login_timeout: Number, // Optional, default is 12000 milliseconds
|
|
161
|
+
scope: String.isRequired, // oidc scope (you need to set "offline_access")
|
|
162
|
+
authority: String.isRequired,
|
|
163
|
+
storage: Storage, // Default sessionStorage, you can set localStorage, but it is less secure against XSS attacks
|
|
164
|
+
authority_configuration: {
|
|
165
|
+
// Optional for providers that do not implement OIDC server auto-discovery via a .wellknown URL
|
|
166
|
+
authorization_endpoint: String,
|
|
167
|
+
token_endpoint: String,
|
|
168
|
+
userinfo_endpoint: String,
|
|
169
|
+
end_session_endpoint: String,
|
|
170
|
+
revocation_endpoint: String,
|
|
171
|
+
check_session_iframe: String,
|
|
172
|
+
issuer: String,
|
|
173
|
+
},
|
|
174
|
+
refresh_time_before_tokens_expiration_in_second: Number, // default is 120 seconds
|
|
175
|
+
service_worker_relative_url: String,
|
|
176
|
+
service_worker_only: Boolean, // default false
|
|
177
|
+
service_worker_convert_all_requests_to_cors: Boolean, // force all requests that service worker upgrades to have 'cors' mode. This allows setting an authentication token on requests initiated by HTML parsing (e.g., img tags, download links, etc.).
|
|
178
|
+
extras: StringMap | undefined, // ex: {'prompt': 'consent', 'access_type': 'offline'} list of key/value that is sent to the OIDC server (more info: https://github.com/openid/AppAuth-JS)
|
|
179
|
+
token_request_extras: StringMap | undefined, // ex: {'prompt': 'consent', 'access_type': 'offline'} list of key/value that is sent to the OIDC server during token request (more info: https://github.com/openid/AppAuth-JS)
|
|
180
|
+
withCustomHistory: Function, // Override history modification, return an instance with replaceState(url, stateHistory) implemented (like History.replaceState())
|
|
181
|
+
authority_time_cache_wellknowurl_in_second: 60 * 60, // Time to cache in seconds of the openid well-known URL, default is 1 hour
|
|
182
|
+
authority_timeout_wellknowurl_in_millisecond: 10000, // Timeout in milliseconds of the openid well-known URL, default is 10 seconds, then an error is thrown
|
|
183
|
+
monitor_session: Boolean, // Add OpenID monitor session, default is false (more information https://openid.net/specs/openid-connect-session-1_0.html), if you need to set it to true consider https://infi.nl/nieuws/spa-necromancy/
|
|
184
|
+
onLogoutFromAnotherTab: Function, // Optional, can be set to override the default behavior, this function is triggered when a user with the same subject is logged out from another tab when session_monitor is active
|
|
185
|
+
onLogoutFromSameTab: Function, // Optional, can be set to override the default behavior, this function is triggered when a user is logged out from the same tab when session_monitor is active
|
|
186
|
+
token_renew_mode: String, // Optional, update tokens based on the selected token(s) lifetime: "access_token_or_id_token_invalid" (default), "access_token_invalid", "id_token_invalid"
|
|
187
|
+
logout_tokens_to_invalidate: Array<string>, // Optional tokens to invalidate during logout, default: ['access_token', 'refresh_token']
|
|
188
|
+
}.isRequired,
|
|
173
189
|
};
|
|
190
|
+
|
|
174
191
|
```
|
|
175
192
|
|
|
176
193
|
## How to consume
|
|
@@ -626,10 +643,3 @@ export const configurationIdentityServerWithHash = {
|
|
|
626
643
|
service_worker_only: false,
|
|
627
644
|
};
|
|
628
645
|
```
|
|
629
|
-
|
|
630
|
-
## Service Worker Support
|
|
631
|
-
|
|
632
|
-
- Firefox : tested on Firefox 98.0.2
|
|
633
|
-
- Chrome/Edge : tested on version upper to 90
|
|
634
|
-
- Opera : tested on version upper to 80
|
|
635
|
-
- Safari : tested on Safari/605.1.15
|
package/dist/FetchToken.d.ts
CHANGED
|
@@ -6,4 +6,3 @@ export declare const withOidcFetch: (fetch?: Fetch, configurationName?: string)
|
|
|
6
6
|
export declare const useOidcFetch: (fetch?: Fetch, configurationName?: string) => {
|
|
7
7
|
fetch: (input: RequestInfo | URL, init?: RequestInit) => Promise<Response>;
|
|
8
8
|
};
|
|
9
|
-
//# sourceMappingURL=FetchToken.d.ts.map
|
package/dist/OidcProvider.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Fetch, OidcConfiguration,
|
|
1
|
+
import { Fetch, OidcConfiguration, OidcClient } from '@axa-fr/oidc-client';
|
|
2
2
|
import { ComponentType, FC, PropsWithChildren } from 'react';
|
|
3
3
|
import { CustomHistory } from './core/routes/withRouter.js';
|
|
4
4
|
export type oidcContext = {
|
|
5
|
-
(name?: string):
|
|
5
|
+
(name?: string): OidcClient;
|
|
6
6
|
};
|
|
7
7
|
export type OidcProviderProps = {
|
|
8
8
|
callbackSuccessComponent?: ComponentType<any>;
|
|
@@ -27,4 +27,3 @@ export type OidcSessionProps = {
|
|
|
27
27
|
};
|
|
28
28
|
export declare const OidcProvider: FC<PropsWithChildren<OidcProviderProps>>;
|
|
29
29
|
export default OidcProvider;
|
|
30
|
-
//# sourceMappingURL=OidcProvider.d.ts.map
|
package/dist/OidcSecure.d.ts
CHANGED
|
@@ -7,4 +7,3 @@ export type OidcSecureProps = {
|
|
|
7
7
|
};
|
|
8
8
|
export declare const OidcSecure: FC<PropsWithChildren<OidcSecureProps>>;
|
|
9
9
|
export declare const withOidcSecure: (WrappedComponent: FC<PropsWithChildren<OidcSecureProps>>, callbackPath?: any, extras?: any, configurationName?: string) => (props: any) => import("react/jsx-runtime").JSX.Element;
|
|
10
|
-
//# sourceMappingURL=OidcSecure.d.ts.map
|
package/dist/ReactOidc.d.ts
CHANGED
package/dist/User.d.ts
CHANGED
|
@@ -4,4 +4,3 @@ export { default as Callback, CallBackSuccess } from './Callback.component.js';
|
|
|
4
4
|
export { default as Loading } from './Loading.component.js';
|
|
5
5
|
export { default as ServiceWorkerNotSupported } from './ServiceWorkerNotSupported.component.js';
|
|
6
6
|
export { default as SessionLost } from './SessionLost.component.js';
|
|
7
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/routes/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -5,4 +5,3 @@ export { useOidc, useOidcAccessToken, useOidcIdToken } from './ReactOidc.js';
|
|
|
5
5
|
export { OidcUserStatus, useOidcUser } from './User.js';
|
|
6
6
|
export type { AuthorityConfiguration, Fetch, OidcConfiguration, StringMap, } from '@axa-fr/oidc-client';
|
|
7
7
|
export { type OidcUserInfo, TokenRenewMode } from '@axa-fr/oidc-client';
|
|
8
|
-
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import be, { useCallback as kt, useState as P, useEffect as O } from "react";
|
|
2
|
-
import {
|
|
2
|
+
import { OidcClient as f, getParseQueryStringFromLocation as mt, getPath as z, getFetchDefault as Et } from "@axa-fr/oidc-client";
|
|
3
3
|
import { TokenRenewMode as rr } from "@axa-fr/oidc-client";
|
|
4
4
|
var ye = { exports: {} }, G = {};
|
|
5
5
|
/**
|
|
@@ -18,14 +18,14 @@ function Tt() {
|
|
|
18
18
|
Ye = 1;
|
|
19
19
|
var o = be, s = Symbol.for("react.element"), r = Symbol.for("react.fragment"), a = Object.prototype.hasOwnProperty, u = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, l = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
20
20
|
function h(c, v, g) {
|
|
21
|
-
var b, m = {},
|
|
22
|
-
g !== void 0 && (
|
|
21
|
+
var b, m = {}, C = null, D = null;
|
|
22
|
+
g !== void 0 && (C = "" + g), v.key !== void 0 && (C = "" + v.key), v.ref !== void 0 && (D = v.ref);
|
|
23
23
|
for (b in v)
|
|
24
24
|
a.call(v, b) && !l.hasOwnProperty(b) && (m[b] = v[b]);
|
|
25
25
|
if (c && c.defaultProps)
|
|
26
26
|
for (b in v = c.defaultProps, v)
|
|
27
27
|
m[b] === void 0 && (m[b] = v[b]);
|
|
28
|
-
return { $$typeof: s, type: c, key:
|
|
28
|
+
return { $$typeof: s, type: c, key: C, ref: D, props: m, _owner: u.current };
|
|
29
29
|
}
|
|
30
30
|
return G.Fragment = r, G.jsx = h, G.jsxs = h, G;
|
|
31
31
|
}
|
|
@@ -42,7 +42,7 @@ var H = {};
|
|
|
42
42
|
var Me;
|
|
43
43
|
function wt() {
|
|
44
44
|
return Me || (Me = 1, process.env.NODE_ENV !== "production" && function() {
|
|
45
|
-
var o = be, s = Symbol.for("react.element"), r = Symbol.for("react.portal"), a = Symbol.for("react.fragment"), u = Symbol.for("react.strict_mode"), l = Symbol.for("react.profiler"), h = Symbol.for("react.provider"), c = Symbol.for("react.context"), v = Symbol.for("react.forward_ref"), g = Symbol.for("react.suspense"), b = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"),
|
|
45
|
+
var o = be, s = Symbol.for("react.element"), r = Symbol.for("react.portal"), a = Symbol.for("react.fragment"), u = Symbol.for("react.strict_mode"), l = Symbol.for("react.profiler"), h = Symbol.for("react.provider"), c = Symbol.for("react.context"), v = Symbol.for("react.forward_ref"), g = Symbol.for("react.suspense"), b = Symbol.for("react.suspense_list"), m = Symbol.for("react.memo"), C = Symbol.for("react.lazy"), D = Symbol.for("react.offscreen"), K = Symbol.iterator, U = "@@iterator";
|
|
46
46
|
function ne(e) {
|
|
47
47
|
if (e === null || typeof e != "object")
|
|
48
48
|
return null;
|
|
@@ -50,7 +50,7 @@ function wt() {
|
|
|
50
50
|
return typeof t == "function" ? t : null;
|
|
51
51
|
}
|
|
52
52
|
var L = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
53
|
-
function
|
|
53
|
+
function R(e) {
|
|
54
54
|
{
|
|
55
55
|
for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), d = 1; d < t; d++)
|
|
56
56
|
n[d - 1] = arguments[d];
|
|
@@ -70,7 +70,7 @@ function wt() {
|
|
|
70
70
|
var oe = !1, se = !1, ae = !1, ie = !1, W = !1, X;
|
|
71
71
|
X = Symbol.for("react.module.reference");
|
|
72
72
|
function ce(e) {
|
|
73
|
-
return !!(typeof e == "string" || typeof e == "function" || e === a || e === l || W || e === u || e === g || e === b || ie || e === D || oe || se || ae || typeof e == "object" && e !== null && (e.$$typeof ===
|
|
73
|
+
return !!(typeof e == "string" || typeof e == "function" || e === a || e === l || W || e === u || e === g || e === b || ie || e === D || oe || se || ae || typeof e == "object" && e !== null && (e.$$typeof === C || e.$$typeof === m || e.$$typeof === h || e.$$typeof === c || e.$$typeof === v || // This needs to include all possible module reference object
|
|
74
74
|
// types supported by any Flight configuration anywhere since
|
|
75
75
|
// we don't know which Flight build this will end up being used
|
|
76
76
|
// with.
|
|
@@ -89,7 +89,7 @@ function wt() {
|
|
|
89
89
|
function A(e) {
|
|
90
90
|
if (e == null)
|
|
91
91
|
return null;
|
|
92
|
-
if (typeof e.tag == "number" &&
|
|
92
|
+
if (typeof e.tag == "number" && R("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
|
|
93
93
|
return e.displayName || e.name || null;
|
|
94
94
|
if (typeof e == "string")
|
|
95
95
|
return e;
|
|
@@ -120,7 +120,7 @@ function wt() {
|
|
|
120
120
|
case m:
|
|
121
121
|
var d = e.displayName || null;
|
|
122
122
|
return d !== null ? d : A(e.type) || "Memo";
|
|
123
|
-
case
|
|
123
|
+
case C: {
|
|
124
124
|
var y = e, k = y._payload, _ = y._init;
|
|
125
125
|
try {
|
|
126
126
|
return A(_(k));
|
|
@@ -131,18 +131,18 @@ function wt() {
|
|
|
131
131
|
}
|
|
132
132
|
return null;
|
|
133
133
|
}
|
|
134
|
-
var S = Object.assign, F = 0, T, N, me, Ee, Te, we,
|
|
135
|
-
function
|
|
134
|
+
var S = Object.assign, F = 0, T, N, me, Ee, Te, we, Ce;
|
|
135
|
+
function Re() {
|
|
136
136
|
}
|
|
137
|
-
|
|
137
|
+
Re.__reactDisabledLog = !0;
|
|
138
138
|
function Je() {
|
|
139
139
|
{
|
|
140
140
|
if (F === 0) {
|
|
141
|
-
T = console.log, N = console.info, me = console.warn, Ee = console.error, Te = console.group, we = console.groupCollapsed,
|
|
141
|
+
T = console.log, N = console.info, me = console.warn, Ee = console.error, Te = console.group, we = console.groupCollapsed, Ce = console.groupEnd;
|
|
142
142
|
var e = {
|
|
143
143
|
configurable: !0,
|
|
144
144
|
enumerable: !0,
|
|
145
|
-
value:
|
|
145
|
+
value: Re,
|
|
146
146
|
writable: !0
|
|
147
147
|
};
|
|
148
148
|
Object.defineProperties(console, {
|
|
@@ -186,11 +186,11 @@ function wt() {
|
|
|
186
186
|
value: we
|
|
187
187
|
}),
|
|
188
188
|
groupEnd: S({}, e, {
|
|
189
|
-
value:
|
|
189
|
+
value: Ce
|
|
190
190
|
})
|
|
191
191
|
});
|
|
192
192
|
}
|
|
193
|
-
F < 0 &&
|
|
193
|
+
F < 0 && R("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
194
194
|
}
|
|
195
195
|
}
|
|
196
196
|
var le = L.ReactCurrentDispatcher, ue;
|
|
@@ -309,7 +309,7 @@ function wt() {
|
|
|
309
309
|
return Qe(e.render);
|
|
310
310
|
case m:
|
|
311
311
|
return ee(e.type, t, n);
|
|
312
|
-
case
|
|
312
|
+
case C: {
|
|
313
313
|
var d = e, y = d._payload, k = d._init;
|
|
314
314
|
try {
|
|
315
315
|
return ee(k(y), t, n);
|
|
@@ -342,7 +342,7 @@ function wt() {
|
|
|
342
342
|
} catch (E) {
|
|
343
343
|
p = E;
|
|
344
344
|
}
|
|
345
|
-
p && !(p instanceof Error) && (re(y),
|
|
345
|
+
p && !(p instanceof Error) && (re(y), R("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", d || "React class", n, _, typeof p), re(null)), p instanceof Error && !(p.message in je) && (je[p.message] = !0, re(y), R("Failed %s type: %s", n, p.message), re(null));
|
|
346
346
|
}
|
|
347
347
|
}
|
|
348
348
|
}
|
|
@@ -368,7 +368,7 @@ function wt() {
|
|
|
368
368
|
}
|
|
369
369
|
function Pe(e) {
|
|
370
370
|
if (nt(e))
|
|
371
|
-
return
|
|
371
|
+
return R("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", rt(e)), Se(e);
|
|
372
372
|
}
|
|
373
373
|
var q = L.ReactCurrentOwner, ot = {
|
|
374
374
|
key: !0,
|
|
@@ -396,13 +396,13 @@ function wt() {
|
|
|
396
396
|
function it(e, t) {
|
|
397
397
|
if (typeof e.ref == "string" && q.current && t && q.current.stateNode !== t) {
|
|
398
398
|
var n = A(q.current.type);
|
|
399
|
-
ve[n] || (
|
|
399
|
+
ve[n] || (R('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', A(q.current.type), e.ref), ve[n] = !0);
|
|
400
400
|
}
|
|
401
401
|
}
|
|
402
402
|
function ct(e, t) {
|
|
403
403
|
{
|
|
404
404
|
var n = function() {
|
|
405
|
-
Ae || (Ae = !0,
|
|
405
|
+
Ae || (Ae = !0, R("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", t));
|
|
406
406
|
};
|
|
407
407
|
n.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
408
408
|
get: n,
|
|
@@ -413,7 +413,7 @@ function wt() {
|
|
|
413
413
|
function lt(e, t) {
|
|
414
414
|
{
|
|
415
415
|
var n = function() {
|
|
416
|
-
Fe || (Fe = !0,
|
|
416
|
+
Fe || (Fe = !0, R("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", t));
|
|
417
417
|
};
|
|
418
418
|
n.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
419
419
|
get: n,
|
|
@@ -527,7 +527,7 @@ Check the top-level render call using <` + n + ">.");
|
|
|
527
527
|
return;
|
|
528
528
|
De[n] = !0;
|
|
529
529
|
var d = "";
|
|
530
|
-
e && e._owner && e._owner !== he.current && (d = " It was passed a child from " + A(e._owner.type) + "."), V(e),
|
|
530
|
+
e && e._owner && e._owner !== he.current && (d = " It was passed a child from " + A(e._owner.type) + "."), V(e), R('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', n, d), V(null);
|
|
531
531
|
}
|
|
532
532
|
}
|
|
533
533
|
function We(e, t) {
|
|
@@ -569,9 +569,9 @@ Check the top-level render call using <` + n + ">.");
|
|
|
569
569
|
} else if (t.PropTypes !== void 0 && !pe) {
|
|
570
570
|
pe = !0;
|
|
571
571
|
var y = A(t);
|
|
572
|
-
|
|
572
|
+
R("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", y || "Unknown");
|
|
573
573
|
}
|
|
574
|
-
typeof t.getDefaultProps == "function" && !t.getDefaultProps.isReactClassApproved &&
|
|
574
|
+
typeof t.getDefaultProps == "function" && !t.getDefaultProps.isReactClassApproved && R("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
575
575
|
}
|
|
576
576
|
}
|
|
577
577
|
function pt(e) {
|
|
@@ -579,11 +579,11 @@ Check the top-level render call using <` + n + ">.");
|
|
|
579
579
|
for (var t = Object.keys(e.props), n = 0; n < t.length; n++) {
|
|
580
580
|
var d = t[n];
|
|
581
581
|
if (d !== "children" && d !== "key") {
|
|
582
|
-
V(e),
|
|
582
|
+
V(e), R("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", d), V(null);
|
|
583
583
|
break;
|
|
584
584
|
}
|
|
585
585
|
}
|
|
586
|
-
e.ref !== null && (V(e),
|
|
586
|
+
e.ref !== null && (V(e), R("Invalid attribute `ref` supplied to `React.Fragment`."), V(null));
|
|
587
587
|
}
|
|
588
588
|
}
|
|
589
589
|
function Ue(e, t, n, d, y, k) {
|
|
@@ -595,7 +595,7 @@ Check the top-level render call using <` + n + ">.");
|
|
|
595
595
|
var x = ft(y);
|
|
596
596
|
x ? p += x : p += Ie();
|
|
597
597
|
var E;
|
|
598
|
-
e === null ? E = "null" : fe(e) ? E = "array" : e !== void 0 && e.$$typeof === s ? (E = "<" + (A(e.type) || "Unknown") + " />", p = " Did you accidentally export a JSX literal instead of a component?") : E = typeof e,
|
|
598
|
+
e === null ? E = "null" : fe(e) ? E = "array" : e !== void 0 && e.$$typeof === s ? (E = "<" + (A(e.type) || "Unknown") + " />", p = " Did you accidentally export a JSX literal instead of a component?") : E = typeof e, R("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", E, p);
|
|
599
599
|
}
|
|
600
600
|
var w = dt(e, t, n, y, k);
|
|
601
601
|
if (w == null)
|
|
@@ -609,7 +609,7 @@ Check the top-level render call using <` + n + ">.");
|
|
|
609
609
|
We(j[B], e);
|
|
610
610
|
Object.freeze && Object.freeze(j);
|
|
611
611
|
} else
|
|
612
|
-
|
|
612
|
+
R("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
613
613
|
else
|
|
614
614
|
We(j, e);
|
|
615
615
|
}
|
|
@@ -628,22 +628,22 @@ Check the top-level render call using <` + n + ">.");
|
|
|
628
628
|
}
|
|
629
629
|
process.env.NODE_ENV === "production" ? ye.exports = Tt() : ye.exports = wt();
|
|
630
630
|
var i = ye.exports;
|
|
631
|
-
const Be = "default",
|
|
632
|
-
var
|
|
631
|
+
const Be = "default", Ct = (o, s) => async (...r) => {
|
|
632
|
+
var C;
|
|
633
633
|
const [a, u, ...l] = r, h = u ? { ...u } : { method: "GET" };
|
|
634
634
|
let c = new Headers();
|
|
635
635
|
h.headers && (c = h.headers instanceof Headers ? h.headers : new Headers(h.headers));
|
|
636
|
-
const g = await s().getValidTokenAsync(), b = (
|
|
636
|
+
const g = await s().getValidTokenAsync(), b = (C = g == null ? void 0 : g.tokens) == null ? void 0 : C.accessToken;
|
|
637
637
|
c.has("Accept") || c.set("Accept", "application/json"), b && (c.set("Authorization", `Bearer ${b}`), h.credentials || (h.credentials = "same-origin"));
|
|
638
638
|
const m = { ...h, headers: c };
|
|
639
639
|
return await o(a, m, ...l);
|
|
640
640
|
}, Gt = (o = null, s = Be) => (r) => (a) => {
|
|
641
|
-
const { fetch: u } =
|
|
641
|
+
const { fetch: u } = Rt(o || a.fetch, s);
|
|
642
642
|
return /* @__PURE__ */ i.jsx(r, { ...a, fetch: u });
|
|
643
|
-
},
|
|
643
|
+
}, Rt = (o = null, s = Be) => {
|
|
644
644
|
const r = o || window.fetch, a = f.get;
|
|
645
645
|
return { fetch: kt(
|
|
646
|
-
(l, h) =>
|
|
646
|
+
(l, h) => Ct(r, () => a(s))(l, h),
|
|
647
647
|
[r, s]
|
|
648
648
|
) };
|
|
649
649
|
}, qe = () => /* @__PURE__ */ i.jsx("div", { className: "oidc-authenticating", children: /* @__PURE__ */ i.jsxs("div", { className: "oidc-authenticating__container", children: [
|
|
@@ -714,8 +714,8 @@ const Be = "default", Rt = (o, s) => async (...r) => {
|
|
|
714
714
|
}) => {
|
|
715
715
|
const v = window ? z(window.location.href) : "", [g, b] = P(v);
|
|
716
716
|
O(() => {
|
|
717
|
-
const
|
|
718
|
-
return
|
|
717
|
+
const C = () => b(z(window.location.href));
|
|
718
|
+
return C(), window.addEventListener("popstate", C, !1), () => window.removeEventListener("popstate", C, !1);
|
|
719
719
|
}, []);
|
|
720
720
|
const m = z(r);
|
|
721
721
|
if (a && g === z(a))
|
|
@@ -756,11 +756,11 @@ const Be = "default", Rt = (o, s) => async (...r) => {
|
|
|
756
756
|
onSessionLost: g = null,
|
|
757
757
|
onLogoutFromAnotherTab: b = null,
|
|
758
758
|
onLogoutFromSameTab: m = null,
|
|
759
|
-
withCustomHistory:
|
|
759
|
+
withCustomHistory: C = null,
|
|
760
760
|
onEvent: D = null,
|
|
761
761
|
getFetch: K = null
|
|
762
762
|
}) => {
|
|
763
|
-
const U = (S = "default") => f.getOrCreate(K ?? Et)(s, S), [ne, L] = P(!0), [
|
|
763
|
+
const U = (S = "default") => f.getOrCreate(K ?? Et)(s, S), [ne, L] = P(!0), [R, $] = P(Ve), [oe, se] = P("default");
|
|
764
764
|
O(() => {
|
|
765
765
|
const F = U(r).subscribeEvents((T, N) => {
|
|
766
766
|
D && D(r, T, N);
|
|
@@ -790,7 +790,7 @@ const Be = "default", Rt = (o, s) => async (...r) => {
|
|
|
790
790
|
};
|
|
791
791
|
}, [s, r]);
|
|
792
792
|
const ae = v, ie = u, W = l, X = h, ce = c, Y = ne || oe !== r, M = U(r);
|
|
793
|
-
switch (
|
|
793
|
+
switch (R.name) {
|
|
794
794
|
case f.eventNames.service_worker_not_supported_by_browser:
|
|
795
795
|
return /* @__PURE__ */ i.jsx(J, { loadingComponent: W, isLoading: Y, configurationName: r, children: /* @__PURE__ */ i.jsx(X, { configurationName: r }) });
|
|
796
796
|
case f.eventNames.loginAsync_begin:
|
|
@@ -813,7 +813,7 @@ const Be = "default", Rt = (o, s) => async (...r) => {
|
|
|
813
813
|
callbackErrorComponent: c,
|
|
814
814
|
authenticatingComponent: u,
|
|
815
815
|
configurationName: r,
|
|
816
|
-
withCustomHistory:
|
|
816
|
+
withCustomHistory: C,
|
|
817
817
|
children: /* @__PURE__ */ i.jsx($t, { loadingComponent: W, configurationName: r, children: o })
|
|
818
818
|
}
|
|
819
819
|
) });
|
|
@@ -956,7 +956,7 @@ export {
|
|
|
956
956
|
rr as TokenRenewMode,
|
|
957
957
|
Kt as useOidc,
|
|
958
958
|
Xt as useOidcAccessToken,
|
|
959
|
-
|
|
959
|
+
Rt as useOidcFetch,
|
|
960
960
|
Qt as useOidcIdToken,
|
|
961
961
|
Zt as useOidcUser,
|
|
962
962
|
Gt as withOidcFetch,
|