@asgardeo/react 0.15.2 → 0.15.4
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/cjs/index.js +149 -151
- package/dist/cjs/index.js.map +4 -4
- package/dist/index.d.ts +1 -1
- package/dist/index.js +72 -72
- package/dist/index.js.map +4 -4
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -188,4 +188,4 @@ export { default as getSchemas, GetSchemasConfig } from './api/getSchemas';
|
|
|
188
188
|
export { default as updateMeProfile, UpdateMeProfileConfig } from './api/updateMeProfile';
|
|
189
189
|
export { default as getMeProfile } from './api/getScim2Me';
|
|
190
190
|
export * from './api/getScim2Me';
|
|
191
|
-
export { AsgardeoRuntimeError, http, getActiveTheme, navigate, EmbeddedFlowComponentTypeV2 as EmbeddedFlowComponentType, EmbeddedFlowActionVariantV2 as EmbeddedFlowActionVariant, EmbeddedFlowTextVariantV2 as EmbeddedFlowTextVariant, EmbeddedFlowEventTypeV2 as EmbeddedFlowEventType, type EmbeddedFlowComponentV2 as EmbeddedFlowComponent, type EmbeddedFlowResponseDataV2 as EmbeddedFlowResponseData, type EmbeddedFlowExecuteRequestConfigV2 as EmbeddedFlowExecuteRequestConfig, EmbeddedSignInFlowStatusV2 as EmbeddedSignInFlowStatus, EmbeddedSignInFlowTypeV2 as EmbeddedSignInFlowType, type ExtendedEmbeddedSignInFlowResponseV2 as ExtendedEmbeddedSignInFlowResponse, type EmbeddedSignInFlowResponseV2 as EmbeddedSignInFlowResponse, type EmbeddedSignInFlowCompleteResponseV2 as EmbeddedSignInFlowCompleteResponse, type EmbeddedSignInFlowInitiateRequestV2 as EmbeddedSignInFlowInitiateRequest, type EmbeddedSignInFlowRequestV2 as EmbeddedSignInFlowRequest, type EmbeddedSignUpFlowStatusV2 as EmbeddedSignUpFlowStatus, type EmbeddedSignUpFlowTypeV2 as EmbeddedSignUpFlowType, type ExtendedEmbeddedSignUpFlowResponseV2 as ExtendedEmbeddedSignUpFlowResponse, type EmbeddedSignUpFlowResponseV2 as EmbeddedSignUpFlowResponse, type EmbeddedSignUpFlowCompleteResponseV2 as EmbeddedSignUpFlowCompleteResponse, type EmbeddedSignUpFlowInitiateRequestV2 as EmbeddedSignUpFlowInitiateRequest, type EmbeddedSignUpFlowRequestV2 as EmbeddedSignUpFlowRequest, type EmbeddedSignUpFlowErrorResponseV2 as EmbeddedSignUpFlowErrorResponse, } from '@asgardeo/browser';
|
|
191
|
+
export { AsgardeoRuntimeError, http, getActiveTheme, navigate, resolveEmojiUrisInHtml, isEmojiUri, EMOJI_URI_SCHEME, extractEmojiFromUri, resolveMeta, resolveFlowTemplateLiterals, countryCodeToFlagEmoji, resolveLocaleDisplayName, resolveLocaleEmoji, EmbeddedFlowComponentTypeV2 as EmbeddedFlowComponentType, EmbeddedFlowActionVariantV2 as EmbeddedFlowActionVariant, EmbeddedFlowTextVariantV2 as EmbeddedFlowTextVariant, EmbeddedFlowEventTypeV2 as EmbeddedFlowEventType, type EmbeddedFlowComponentV2 as EmbeddedFlowComponent, type EmbeddedFlowResponseDataV2 as EmbeddedFlowResponseData, type EmbeddedFlowExecuteRequestConfigV2 as EmbeddedFlowExecuteRequestConfig, EmbeddedSignInFlowStatusV2 as EmbeddedSignInFlowStatus, EmbeddedSignInFlowTypeV2 as EmbeddedSignInFlowType, type ExtendedEmbeddedSignInFlowResponseV2 as ExtendedEmbeddedSignInFlowResponse, type EmbeddedSignInFlowResponseV2 as EmbeddedSignInFlowResponse, type EmbeddedSignInFlowCompleteResponseV2 as EmbeddedSignInFlowCompleteResponse, type EmbeddedSignInFlowInitiateRequestV2 as EmbeddedSignInFlowInitiateRequest, type EmbeddedSignInFlowRequestV2 as EmbeddedSignInFlowRequest, type EmbeddedSignUpFlowStatusV2 as EmbeddedSignUpFlowStatus, type EmbeddedSignUpFlowTypeV2 as EmbeddedSignUpFlowType, type ExtendedEmbeddedSignUpFlowResponseV2 as ExtendedEmbeddedSignUpFlowResponse, type EmbeddedSignUpFlowResponseV2 as EmbeddedSignUpFlowResponse, type EmbeddedSignUpFlowCompleteResponseV2 as EmbeddedSignUpFlowCompleteResponse, type EmbeddedSignUpFlowInitiateRequestV2 as EmbeddedSignUpFlowInitiateRequest, type EmbeddedSignUpFlowRequestV2 as EmbeddedSignUpFlowRequest, type EmbeddedSignUpFlowErrorResponseV2 as EmbeddedSignUpFlowErrorResponse, } from '@asgardeo/browser';
|
package/dist/index.js
CHANGED
|
@@ -796,8 +796,7 @@ var AsgardeoReactClient = class extends AsgardeoBrowserClient {
|
|
|
796
796
|
const arg1 = args[0];
|
|
797
797
|
const arg2 = args[1];
|
|
798
798
|
const config = await this.asgardeo.getConfigData();
|
|
799
|
-
const
|
|
800
|
-
const isV2Platform = config && config.platform === Platform.AsgardeoV2 || platformFromStorage === "AsgardeoV2";
|
|
799
|
+
const isV2Platform = config && config.platform === Platform.AsgardeoV2;
|
|
801
800
|
if (isV2Platform && typeof arg1 === "object" && arg1 !== null && arg1.callOnlyOnRedirect === true) {
|
|
802
801
|
return void 0;
|
|
803
802
|
}
|
|
@@ -805,8 +804,7 @@ var AsgardeoReactClient = class extends AsgardeoBrowserClient {
|
|
|
805
804
|
const authIdFromUrl = new URL(window.location.href).searchParams.get("authId");
|
|
806
805
|
const authIdFromStorage = sessionStorage.getItem("asgardeo_auth_id");
|
|
807
806
|
const authId = authIdFromUrl || authIdFromStorage;
|
|
808
|
-
const
|
|
809
|
-
const baseUrl = config?.baseUrl || baseUrlFromStorage;
|
|
807
|
+
const baseUrl = config?.baseUrl;
|
|
810
808
|
const response = await executeEmbeddedSignInFlowV2({
|
|
811
809
|
authId,
|
|
812
810
|
baseUrl,
|
|
@@ -1106,13 +1104,7 @@ var FlowProvider_default = FlowProvider;
|
|
|
1106
1104
|
// src/contexts/FlowMeta/FlowMetaProvider.tsx
|
|
1107
1105
|
import { FlowMetaType, getFlowMetaV2 } from "@asgardeo/browser";
|
|
1108
1106
|
import { TranslationBundleConstants } from "@asgardeo/i18n";
|
|
1109
|
-
import {
|
|
1110
|
-
useCallback as useCallback3,
|
|
1111
|
-
useContext as useContext2,
|
|
1112
|
-
useEffect as useEffect2,
|
|
1113
|
-
useRef,
|
|
1114
|
-
useState as useState3
|
|
1115
|
-
} from "react";
|
|
1107
|
+
import { useCallback as useCallback3, useEffect as useEffect2, useRef, useState as useState3 } from "react";
|
|
1116
1108
|
|
|
1117
1109
|
// src/contexts/FlowMeta/FlowMetaContext.ts
|
|
1118
1110
|
import { createContext as createContext4 } from "react";
|
|
@@ -1150,6 +1142,19 @@ var useAsgardeo = () => {
|
|
|
1150
1142
|
};
|
|
1151
1143
|
var useAsgardeo_default = useAsgardeo;
|
|
1152
1144
|
|
|
1145
|
+
// src/contexts/I18n/useI18n.ts
|
|
1146
|
+
import { useContext as useContext2 } from "react";
|
|
1147
|
+
var useI18n = () => {
|
|
1148
|
+
const context = useContext2(I18nContext_default);
|
|
1149
|
+
if (!context) {
|
|
1150
|
+
throw new Error(
|
|
1151
|
+
"useI18n must be used within an I18nProvider. Make sure your component is wrapped with AsgardeoProvider which includes I18nProvider."
|
|
1152
|
+
);
|
|
1153
|
+
}
|
|
1154
|
+
return context;
|
|
1155
|
+
};
|
|
1156
|
+
var useI18n_default = useI18n;
|
|
1157
|
+
|
|
1153
1158
|
// src/contexts/FlowMeta/FlowMetaProvider.tsx
|
|
1154
1159
|
import { jsx as jsx3 } from "react/jsx-runtime";
|
|
1155
1160
|
var FlowMetaProvider = ({
|
|
@@ -1157,7 +1162,7 @@ var FlowMetaProvider = ({
|
|
|
1157
1162
|
enabled = true
|
|
1158
1163
|
}) => {
|
|
1159
1164
|
const { baseUrl, applicationId } = useAsgardeo_default();
|
|
1160
|
-
const i18nContext =
|
|
1165
|
+
const i18nContext = useI18n_default();
|
|
1161
1166
|
const [meta, setMeta] = useState3(null);
|
|
1162
1167
|
const [isLoading, setIsLoading] = useState3(false);
|
|
1163
1168
|
const [error, setError] = useState3(null);
|
|
@@ -1171,14 +1176,19 @@ var FlowMetaProvider = ({
|
|
|
1171
1176
|
setIsLoading(true);
|
|
1172
1177
|
setError(null);
|
|
1173
1178
|
try {
|
|
1174
|
-
const result = await getFlowMetaV2({
|
|
1179
|
+
const result = await getFlowMetaV2({
|
|
1180
|
+
baseUrl,
|
|
1181
|
+
id: applicationId,
|
|
1182
|
+
language: i18nContext?.currentLanguage,
|
|
1183
|
+
type: FlowMetaType.App
|
|
1184
|
+
});
|
|
1175
1185
|
setMeta(result);
|
|
1176
1186
|
} catch (err) {
|
|
1177
1187
|
setError(err instanceof Error ? err : new Error(String(err)));
|
|
1178
1188
|
} finally {
|
|
1179
1189
|
setIsLoading(false);
|
|
1180
1190
|
}
|
|
1181
|
-
}, [enabled, baseUrl, applicationId]);
|
|
1191
|
+
}, [enabled, baseUrl, applicationId, i18nContext?.currentLanguage]);
|
|
1182
1192
|
const switchLanguage = useCallback3(
|
|
1183
1193
|
async (language) => {
|
|
1184
1194
|
if (!enabled) return;
|
|
@@ -2039,12 +2049,6 @@ var AsgardeoProvider = ({
|
|
|
2039
2049
|
await asgardeo.initialize(config);
|
|
2040
2050
|
const initializedConfig = await asgardeo.getConfiguration();
|
|
2041
2051
|
setConfig(initializedConfig);
|
|
2042
|
-
if (initializedConfig?.platform) {
|
|
2043
|
-
sessionStorage.setItem("asgardeo_platform", initializedConfig.platform);
|
|
2044
|
-
}
|
|
2045
|
-
if (initializedConfig?.baseUrl) {
|
|
2046
|
-
sessionStorage.setItem("asgardeo_base_url", initializedConfig.baseUrl);
|
|
2047
|
-
}
|
|
2048
2052
|
})();
|
|
2049
2053
|
}, []);
|
|
2050
2054
|
async function updateSession() {
|
|
@@ -2359,7 +2363,7 @@ var AsgardeoProvider = ({
|
|
|
2359
2363
|
const value = useMemo7(
|
|
2360
2364
|
() => ({
|
|
2361
2365
|
afterSignInUrl,
|
|
2362
|
-
applicationId,
|
|
2366
|
+
applicationId: config.applicationId,
|
|
2363
2367
|
baseUrl,
|
|
2364
2368
|
clearSession,
|
|
2365
2369
|
clientId,
|
|
@@ -2491,23 +2495,10 @@ var useFlow = () => {
|
|
|
2491
2495
|
};
|
|
2492
2496
|
var useFlow_default = useFlow;
|
|
2493
2497
|
|
|
2494
|
-
// src/contexts/I18n/useI18n.ts
|
|
2495
|
-
import { useContext as useContext8 } from "react";
|
|
2496
|
-
var useI18n = () => {
|
|
2497
|
-
const context = useContext8(I18nContext_default);
|
|
2498
|
-
if (!context) {
|
|
2499
|
-
throw new Error(
|
|
2500
|
-
"useI18n must be used within an I18nProvider. Make sure your component is wrapped with AsgardeoProvider which includes I18nProvider."
|
|
2501
|
-
);
|
|
2502
|
-
}
|
|
2503
|
-
return context;
|
|
2504
|
-
};
|
|
2505
|
-
var useI18n_default = useI18n;
|
|
2506
|
-
|
|
2507
2498
|
// src/contexts/Theme/useTheme.ts
|
|
2508
|
-
import { useContext as
|
|
2499
|
+
import { useContext as useContext8 } from "react";
|
|
2509
2500
|
var useTheme = () => {
|
|
2510
|
-
const context =
|
|
2501
|
+
const context = useContext8(ThemeContext_default);
|
|
2511
2502
|
if (!context) {
|
|
2512
2503
|
throw new Error("useTheme must be used within a ThemeProvider");
|
|
2513
2504
|
}
|
|
@@ -2518,7 +2509,7 @@ var useTheme_default = useTheme;
|
|
|
2518
2509
|
// src/hooks/useTranslation.ts
|
|
2519
2510
|
import { deepMerge as deepMerge2 } from "@asgardeo/browser";
|
|
2520
2511
|
import { normalizeTranslations as normalizeTranslations2 } from "@asgardeo/i18n";
|
|
2521
|
-
import { useContext as
|
|
2512
|
+
import { useContext as useContext9, useMemo as useMemo8 } from "react";
|
|
2522
2513
|
|
|
2523
2514
|
// src/contexts/I18n/ComponentPreferencesContext.ts
|
|
2524
2515
|
import { createContext as createContext9 } from "react";
|
|
@@ -2527,8 +2518,8 @@ var ComponentPreferencesContext_default = ComponentPreferencesContext;
|
|
|
2527
2518
|
|
|
2528
2519
|
// src/hooks/useTranslation.ts
|
|
2529
2520
|
var useTranslation = (componentPreferences) => {
|
|
2530
|
-
const context =
|
|
2531
|
-
const componentPrefs =
|
|
2521
|
+
const context = useContext9(I18nContext_default);
|
|
2522
|
+
const componentPrefs = useContext9(ComponentPreferencesContext_default);
|
|
2532
2523
|
const contextPreferences = componentPrefs?.i18n;
|
|
2533
2524
|
if (!context) {
|
|
2534
2525
|
throw new Error(
|
|
@@ -3777,7 +3768,6 @@ var useStyles4 = (theme, colorScheme, helperTextAlign, helperTextMarginLeft, has
|
|
|
3777
3768
|
const formControl = css4`
|
|
3778
3769
|
text-align: start;
|
|
3779
3770
|
font-family: ${theme.vars.typography.fontFamily};
|
|
3780
|
-
margin-bottom: calc(${theme.vars.spacing.unit} * 2);
|
|
3781
3771
|
`;
|
|
3782
3772
|
const helperText = css4`
|
|
3783
3773
|
margin-top: calc(${theme.vars.spacing.unit} / 2);
|
|
@@ -6039,7 +6029,7 @@ import { cx as cx15 } from "@emotion/css";
|
|
|
6039
6029
|
import {
|
|
6040
6030
|
forwardRef as forwardRef8,
|
|
6041
6031
|
createContext as createContext10,
|
|
6042
|
-
useContext as
|
|
6032
|
+
useContext as useContext10
|
|
6043
6033
|
} from "react";
|
|
6044
6034
|
|
|
6045
6035
|
// src/components/primitives/Alert/Alert.styles.ts
|
|
@@ -6226,7 +6216,7 @@ var getDefaultIcon = (variant) => {
|
|
|
6226
6216
|
}
|
|
6227
6217
|
};
|
|
6228
6218
|
var AlertVariantContext = createContext10("info");
|
|
6229
|
-
var useAlertVariant = () =>
|
|
6219
|
+
var useAlertVariant = () => useContext10(AlertVariantContext);
|
|
6230
6220
|
var Alert = forwardRef8(({ variant = "info", showIcon = true, children, className, style, ...rest }, ref) => {
|
|
6231
6221
|
const { theme, colorScheme } = useTheme_default();
|
|
6232
6222
|
const styles = Alert_styles_default(theme, colorScheme, variant);
|
|
@@ -7796,8 +7786,7 @@ import {
|
|
|
7796
7786
|
EmbeddedFlowEventTypeV2 as EmbeddedFlowEventType,
|
|
7797
7787
|
createPackageComponentLogger as createPackageComponentLogger5,
|
|
7798
7788
|
resolveFlowTemplateLiterals as resolveFlowTemplateLiterals3,
|
|
7799
|
-
|
|
7800
|
-
isEmojiUri as isEmojiUri2
|
|
7789
|
+
resolveEmojiUrisInHtml
|
|
7801
7790
|
} from "@asgardeo/browser";
|
|
7802
7791
|
import { css as css17 } from "@emotion/css";
|
|
7803
7792
|
import DOMPurify from "dompurify";
|
|
@@ -8109,24 +8098,6 @@ var logger5 = createPackageComponentLogger5(
|
|
|
8109
8098
|
"@asgardeo/react",
|
|
8110
8099
|
"AuthOptionFactory"
|
|
8111
8100
|
);
|
|
8112
|
-
var resolveEmojiUrisInHtml = (html) => {
|
|
8113
|
-
const withEmojiImages = html.replace(
|
|
8114
|
-
/<img([^>]*)src="(emoji:[^"]+)"([^>]*)\/?>/gi,
|
|
8115
|
-
(_match, pre, src, post) => {
|
|
8116
|
-
const emoji = extractEmojiFromUri2(src);
|
|
8117
|
-
if (!emoji) {
|
|
8118
|
-
return _match;
|
|
8119
|
-
}
|
|
8120
|
-
const altMatch = (pre + post).match(/alt="([^"]*)"/i);
|
|
8121
|
-
const label = altMatch ? altMatch[1] : emoji;
|
|
8122
|
-
return `<span role="img" aria-label="${label}">${emoji}</span>`;
|
|
8123
|
-
}
|
|
8124
|
-
);
|
|
8125
|
-
return withEmojiImages.replace(
|
|
8126
|
-
/emoji:([^\s"<>&]+)/g,
|
|
8127
|
-
(_, rest) => isEmojiUri2(`emoji:${rest}`) ? rest : `emoji:${rest}`
|
|
8128
|
-
);
|
|
8129
|
-
};
|
|
8130
8101
|
var richTextClass = css17`
|
|
8131
8102
|
overflow-wrap: anywhere;
|
|
8132
8103
|
& * {
|
|
@@ -8194,6 +8165,7 @@ var matchesSocialProvider = (actionId, eventType, buttonText, provider, authType
|
|
|
8194
8165
|
return providerMatches;
|
|
8195
8166
|
};
|
|
8196
8167
|
var createAuthComponentFromFlow = (component, formValues, touchedFields, formErrors, isLoading, isFormValid, onInputChange, authType, options = {}) => {
|
|
8168
|
+
const { theme } = useTheme_default();
|
|
8197
8169
|
const key = options.key || component.id;
|
|
8198
8170
|
const resolve = (text) => {
|
|
8199
8171
|
if (!text || !options.t && !options.meta) {
|
|
@@ -8363,6 +8335,11 @@ var createAuthComponentFromFlow = (component, formValues, touchedFields, formErr
|
|
|
8363
8335
|
}
|
|
8364
8336
|
case EmbeddedFlowComponentType.Block: {
|
|
8365
8337
|
if (component.components && component.components.length > 0) {
|
|
8338
|
+
const formStyles = {
|
|
8339
|
+
display: "flex",
|
|
8340
|
+
flexDirection: "column",
|
|
8341
|
+
gap: `calc(${theme.vars.spacing.unit} * 2)`
|
|
8342
|
+
};
|
|
8366
8343
|
const blockComponents = component.components.map(
|
|
8367
8344
|
(childComponent, index) => createAuthComponentFromFlow(
|
|
8368
8345
|
childComponent,
|
|
@@ -8379,7 +8356,7 @@ var createAuthComponentFromFlow = (component, formValues, touchedFields, formErr
|
|
|
8379
8356
|
}
|
|
8380
8357
|
)
|
|
8381
8358
|
).filter(Boolean);
|
|
8382
|
-
return /* @__PURE__ */ jsx66("form", { id: component.id, children: blockComponents }, key);
|
|
8359
|
+
return /* @__PURE__ */ jsx66("form", { id: component.id, style: formStyles, children: blockComponents }, key);
|
|
8383
8360
|
}
|
|
8384
8361
|
return null;
|
|
8385
8362
|
}
|
|
@@ -13008,7 +12985,7 @@ import {
|
|
|
13008
12985
|
createContext as createContext11,
|
|
13009
12986
|
forwardRef as forwardRef10,
|
|
13010
12987
|
isValidElement,
|
|
13011
|
-
useContext as
|
|
12988
|
+
useContext as useContext11,
|
|
13012
12989
|
useLayoutEffect,
|
|
13013
12990
|
useMemo as useMemo33,
|
|
13014
12991
|
useState as useState23
|
|
@@ -13210,7 +13187,7 @@ function useDialog({
|
|
|
13210
13187
|
}
|
|
13211
13188
|
var DialogContext = createContext11(null);
|
|
13212
13189
|
var useDialogContext = () => {
|
|
13213
|
-
const context =
|
|
13190
|
+
const context = useContext11(DialogContext);
|
|
13214
13191
|
if (context == null) {
|
|
13215
13192
|
throw new Error("Dialog components must be wrapped in <Dialog />");
|
|
13216
13193
|
}
|
|
@@ -17419,12 +17396,12 @@ var BaseLanguageSwitcher_default = BaseLanguageSwitcher;
|
|
|
17419
17396
|
|
|
17420
17397
|
// src/components/presentation/LanguageSwitcher/LanguageSwitcher.tsx
|
|
17421
17398
|
import { resolveLocaleDisplayName, resolveLocaleEmoji } from "@asgardeo/browser";
|
|
17422
|
-
import { useMemo as useMemo44 } from "react";
|
|
17399
|
+
import { useEffect as useEffect26, useMemo as useMemo44 } from "react";
|
|
17423
17400
|
|
|
17424
17401
|
// src/contexts/FlowMeta/useFlowMeta.ts
|
|
17425
|
-
import { useContext as
|
|
17402
|
+
import { useContext as useContext12 } from "react";
|
|
17426
17403
|
var useFlowMeta = () => {
|
|
17427
|
-
const context =
|
|
17404
|
+
const context = useContext12(FlowMetaContext_default);
|
|
17428
17405
|
if (!context) {
|
|
17429
17406
|
throw new Error("useFlowMeta must be used within a FlowMetaProvider");
|
|
17430
17407
|
}
|
|
@@ -17438,10 +17415,10 @@ var LanguageSwitcher = ({ children, className }) => {
|
|
|
17438
17415
|
const { meta, switchLanguage, isLoading } = useFlowMeta_default();
|
|
17439
17416
|
const { currentLanguage } = useTranslation_default();
|
|
17440
17417
|
const availableLanguageCodes = meta?.i18n?.languages ?? [];
|
|
17441
|
-
const effectiveLanguageCodes = useMemo44(
|
|
17442
|
-
|
|
17443
|
-
|
|
17444
|
-
|
|
17418
|
+
const effectiveLanguageCodes = useMemo44(
|
|
17419
|
+
() => availableLanguageCodes.length > 0 ? availableLanguageCodes : [currentLanguage],
|
|
17420
|
+
[availableLanguageCodes, currentLanguage]
|
|
17421
|
+
);
|
|
17445
17422
|
const languages = useMemo44(
|
|
17446
17423
|
() => effectiveLanguageCodes.map((code) => ({
|
|
17447
17424
|
code,
|
|
@@ -17451,6 +17428,11 @@ var LanguageSwitcher = ({ children, className }) => {
|
|
|
17451
17428
|
})),
|
|
17452
17429
|
[effectiveLanguageCodes]
|
|
17453
17430
|
);
|
|
17431
|
+
useEffect26(() => {
|
|
17432
|
+
if (availableLanguageCodes.length > 0 && !availableLanguageCodes.includes(currentLanguage)) {
|
|
17433
|
+
switchLanguage(availableLanguageCodes[0]);
|
|
17434
|
+
}
|
|
17435
|
+
}, [availableLanguageCodes, currentLanguage, switchLanguage]);
|
|
17454
17436
|
const handleLanguageChange = (language) => {
|
|
17455
17437
|
if (language !== currentLanguage) {
|
|
17456
17438
|
switchLanguage(language);
|
|
@@ -17476,6 +17458,15 @@ import {
|
|
|
17476
17458
|
http,
|
|
17477
17459
|
getActiveTheme as getActiveTheme2,
|
|
17478
17460
|
navigate as navigate5,
|
|
17461
|
+
resolveEmojiUrisInHtml as resolveEmojiUrisInHtml2,
|
|
17462
|
+
isEmojiUri as isEmojiUri2,
|
|
17463
|
+
EMOJI_URI_SCHEME,
|
|
17464
|
+
extractEmojiFromUri as extractEmojiFromUri2,
|
|
17465
|
+
resolveMeta,
|
|
17466
|
+
resolveFlowTemplateLiterals as resolveFlowTemplateLiterals4,
|
|
17467
|
+
countryCodeToFlagEmoji,
|
|
17468
|
+
resolveLocaleDisplayName as resolveLocaleDisplayName2,
|
|
17469
|
+
resolveLocaleEmoji as resolveLocaleEmoji2,
|
|
17479
17470
|
EmbeddedFlowComponentTypeV2,
|
|
17480
17471
|
EmbeddedFlowActionVariantV2,
|
|
17481
17472
|
EmbeddedFlowTextVariantV2,
|
|
@@ -17519,6 +17510,7 @@ export {
|
|
|
17519
17510
|
CreateOrganization,
|
|
17520
17511
|
DatePicker_default as DatePicker,
|
|
17521
17512
|
Divider_default as Divider,
|
|
17513
|
+
EMOJI_URI_SCHEME,
|
|
17522
17514
|
EmailOtp_default as EmailOtp,
|
|
17523
17515
|
EmbeddedFlowActionVariantV2 as EmbeddedFlowActionVariant,
|
|
17524
17516
|
EmbeddedFlowComponentTypeV2 as EmbeddedFlowComponentType,
|
|
@@ -17584,11 +17576,13 @@ export {
|
|
|
17584
17576
|
UserProfile_default as UserProfile,
|
|
17585
17577
|
UserProvider_default as UserProvider,
|
|
17586
17578
|
UsernamePassword_default as UsernamePassword,
|
|
17579
|
+
countryCodeToFlagEmoji,
|
|
17587
17580
|
createField,
|
|
17588
17581
|
createOrganization_default as createOrganization,
|
|
17589
17582
|
createPatchOperations,
|
|
17590
17583
|
createSignInOption,
|
|
17591
17584
|
createSignInOptionFromAuthenticator,
|
|
17585
|
+
extractEmojiFromUri2 as extractEmojiFromUri,
|
|
17592
17586
|
getActiveTheme2 as getActiveTheme,
|
|
17593
17587
|
getAllOrganizations_default as getAllOrganizations,
|
|
17594
17588
|
getConsentOptionalKey,
|
|
@@ -17597,7 +17591,13 @@ export {
|
|
|
17597
17591
|
getOrganization_default as getOrganization,
|
|
17598
17592
|
getSchemas_default as getSchemas,
|
|
17599
17593
|
http,
|
|
17594
|
+
isEmojiUri2 as isEmojiUri,
|
|
17600
17595
|
navigate5 as navigate,
|
|
17596
|
+
resolveEmojiUrisInHtml2 as resolveEmojiUrisInHtml,
|
|
17597
|
+
resolveFlowTemplateLiterals4 as resolveFlowTemplateLiterals,
|
|
17598
|
+
resolveLocaleDisplayName2 as resolveLocaleDisplayName,
|
|
17599
|
+
resolveLocaleEmoji2 as resolveLocaleEmoji,
|
|
17600
|
+
resolveMeta,
|
|
17601
17601
|
updateMeProfile_default as updateMeProfile,
|
|
17602
17602
|
updateOrganization_default as updateOrganization,
|
|
17603
17603
|
useAsgardeo_default as useAsgardeo,
|