@thunderid/vue 1.2.0 → 1.3.1
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.cjs
CHANGED
|
@@ -976,6 +976,10 @@ const ThunderIDProvider = (0, vue.defineComponent)({
|
|
|
976
976
|
default: void 0,
|
|
977
977
|
type: [Array, String]
|
|
978
978
|
},
|
|
979
|
+
session: {
|
|
980
|
+
default: void 0,
|
|
981
|
+
type: Object
|
|
982
|
+
},
|
|
979
983
|
signInOptions: {
|
|
980
984
|
default: void 0,
|
|
981
985
|
type: Object
|
|
@@ -992,10 +996,6 @@ const ThunderIDProvider = (0, vue.defineComponent)({
|
|
|
992
996
|
default: void 0,
|
|
993
997
|
type: String
|
|
994
998
|
},
|
|
995
|
-
syncSession: {
|
|
996
|
-
default: void 0,
|
|
997
|
-
type: Boolean
|
|
998
|
-
},
|
|
999
999
|
vendor: {
|
|
1000
1000
|
default: void 0,
|
|
1001
1001
|
type: String
|
|
@@ -1026,11 +1026,11 @@ const ThunderIDProvider = (0, vue.defineComponent)({
|
|
|
1026
1026
|
organizationHandle: props.organizationHandle,
|
|
1027
1027
|
preferences: props.preferences,
|
|
1028
1028
|
scopes: props.scopes,
|
|
1029
|
+
session: props.session,
|
|
1029
1030
|
signInOptions: props.signInOptions,
|
|
1030
1031
|
signInUrl: props.signInUrl,
|
|
1031
1032
|
signUpUrl: props.signUpUrl,
|
|
1032
1033
|
storage: props.storage,
|
|
1033
|
-
syncSession: props.syncSession,
|
|
1034
1034
|
vendor
|
|
1035
1035
|
};
|
|
1036
1036
|
}
|
|
@@ -1182,7 +1182,7 @@ const ThunderIDProvider = (0, vue.defineComponent)({
|
|
|
1182
1182
|
const code = urlParams.get("code");
|
|
1183
1183
|
const executionIdFromUrl = urlParams.get("executionId");
|
|
1184
1184
|
const storedExecutionId = sessionStorage.getItem(`${vendor}_execution_id`);
|
|
1185
|
-
if (code && !executionIdFromUrl && !storedExecutionId) await signIn();
|
|
1185
|
+
if ((code || __thunderid_browser.SPAUtils.isSilentStatePresentInURL()) && !executionIdFromUrl && !storedExecutionId) await signIn();
|
|
1186
1186
|
} catch (error) {
|
|
1187
1187
|
throw new __thunderid_browser.ThunderIDRuntimeError(`Sign in failed: ${error instanceof Error ? error.message : String(JSON.stringify(error))}`, "thunderid-signIn-Error", "vue", "An error occurred while trying to sign in.");
|
|
1188
1188
|
}
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ConsentConstants, CredentialConstants, DEFAULT_THEME, EmbeddedFlowActionVariant, EmbeddedFlowComponentType, EmbeddedFlowComponentType as EmbeddedFlowComponentType$1, EmbeddedFlowEventType, EmbeddedFlowEventType as EmbeddedFlowEventType$1, EmbeddedFlowResponseType, EmbeddedFlowTextVariant, EmbeddedFlowType, EmbeddedSignInFlowStatus, EmbeddedSignInFlowStatus as EmbeddedSignInFlowStatus$1, EmbeddedSignInFlowType, EmbeddedSignInFlowType as EmbeddedSignInFlowType$1, EmbeddedSignUpFlowStatus, EmbeddedSignUpFlowStatus as EmbeddedSignUpFlowStatus$1, EmbeddedSignUpFlowType, FetchHttpClient, FieldType, FieldType as FieldType$1, FlowMetaType, ThunderIDAPIError, ThunderIDBrowserClient, ThunderIDError, ThunderIDRuntimeError, ThunderIDRuntimeError as ThunderIDRuntimeError$1, TranslationBundleConstants, arrayBufferToBase64url, base64urlToArrayBuffer, createClassObserver, createClassObserver as createClassObserver$1, createHttpClientFetcher, createMediaQueryListener, createMediaQueryListener as createMediaQueryListener$1, createPackageComponentLogger, createPackageLogger, createTheme, deepMerge, detectThemeMode, detectThemeMode as detectThemeMode$1, evaluateChangePasswordForm, executeEmbeddedSignInFlow, executeEmbeddedSignUpFlow, extractEmojiFromUri, extractUserClaimsFromIdToken, generateFlattenedUserProfile, get, getActiveTheme, getDefaultI18nBundles, getFlowMeta, getUsersMe, getUsersMeMeta, getVendorPrefix, handleWebAuthnAuthentication, hasAuthParamsInUrl, hasAuthParamsInUrl as hasAuthParamsInUrl$1, hasCalledForThisInstanceInUrl, hasUnresolvedTranslationParams, http, isEmojiUri, isEmpty, mapCredentialUpdateError, navigate, navigate as navigate$1, normalizeBorderRadius, normalizeTranslations, parseKeyValuePairs, parseKeyValuePairs as parseKeyValuePairs$1, resolveChangeCredentialPolicy, resolveFlowTemplateLiterals, resolveLogoUri, resolveResourceEndpoint, startCase, substituteTranslationParams, supportsCredential, updateMeCredentials, updateMeProfile, withVendorCSSClassPrefix } from "@thunderid/browser";
|
|
1
|
+
import { ConsentConstants, CredentialConstants, DEFAULT_THEME, EmbeddedFlowActionVariant, EmbeddedFlowComponentType, EmbeddedFlowComponentType as EmbeddedFlowComponentType$1, EmbeddedFlowEventType, EmbeddedFlowEventType as EmbeddedFlowEventType$1, EmbeddedFlowResponseType, EmbeddedFlowTextVariant, EmbeddedFlowType, EmbeddedSignInFlowStatus, EmbeddedSignInFlowStatus as EmbeddedSignInFlowStatus$1, EmbeddedSignInFlowType, EmbeddedSignInFlowType as EmbeddedSignInFlowType$1, EmbeddedSignUpFlowStatus, EmbeddedSignUpFlowStatus as EmbeddedSignUpFlowStatus$1, EmbeddedSignUpFlowType, FetchHttpClient, FieldType, FieldType as FieldType$1, FlowMetaType, SPAUtils, ThunderIDAPIError, ThunderIDBrowserClient, ThunderIDError, ThunderIDRuntimeError, ThunderIDRuntimeError as ThunderIDRuntimeError$1, TranslationBundleConstants, arrayBufferToBase64url, base64urlToArrayBuffer, createClassObserver, createClassObserver as createClassObserver$1, createHttpClientFetcher, createMediaQueryListener, createMediaQueryListener as createMediaQueryListener$1, createPackageComponentLogger, createPackageLogger, createTheme, deepMerge, detectThemeMode, detectThemeMode as detectThemeMode$1, evaluateChangePasswordForm, executeEmbeddedSignInFlow, executeEmbeddedSignUpFlow, extractEmojiFromUri, extractUserClaimsFromIdToken, generateFlattenedUserProfile, get, getActiveTheme, getDefaultI18nBundles, getFlowMeta, getUsersMe, getUsersMeMeta, getVendorPrefix, handleWebAuthnAuthentication, hasAuthParamsInUrl, hasAuthParamsInUrl as hasAuthParamsInUrl$1, hasCalledForThisInstanceInUrl, hasUnresolvedTranslationParams, http, isEmojiUri, isEmpty, mapCredentialUpdateError, navigate, navigate as navigate$1, normalizeBorderRadius, normalizeTranslations, parseKeyValuePairs, parseKeyValuePairs as parseKeyValuePairs$1, resolveChangeCredentialPolicy, resolveFlowTemplateLiterals, resolveLogoUri, resolveResourceEndpoint, startCase, substituteTranslationParams, supportsCredential, updateMeCredentials, updateMeProfile, withVendorCSSClassPrefix } from "@thunderid/browser";
|
|
2
2
|
import { Fragment, Teleport, computed, defineComponent, h, inject, nextTick, onBeforeUnmount, onMounted, onUnmounted, provide, readonly, ref, shallowReadonly, shallowRef, useId, watch } from "vue";
|
|
3
3
|
import DOMPurify from "dompurify";
|
|
4
4
|
|
|
@@ -950,6 +950,10 @@ const ThunderIDProvider = defineComponent({
|
|
|
950
950
|
default: void 0,
|
|
951
951
|
type: [Array, String]
|
|
952
952
|
},
|
|
953
|
+
session: {
|
|
954
|
+
default: void 0,
|
|
955
|
+
type: Object
|
|
956
|
+
},
|
|
953
957
|
signInOptions: {
|
|
954
958
|
default: void 0,
|
|
955
959
|
type: Object
|
|
@@ -966,10 +970,6 @@ const ThunderIDProvider = defineComponent({
|
|
|
966
970
|
default: void 0,
|
|
967
971
|
type: String
|
|
968
972
|
},
|
|
969
|
-
syncSession: {
|
|
970
|
-
default: void 0,
|
|
971
|
-
type: Boolean
|
|
972
|
-
},
|
|
973
973
|
vendor: {
|
|
974
974
|
default: void 0,
|
|
975
975
|
type: String
|
|
@@ -1000,11 +1000,11 @@ const ThunderIDProvider = defineComponent({
|
|
|
1000
1000
|
organizationHandle: props.organizationHandle,
|
|
1001
1001
|
preferences: props.preferences,
|
|
1002
1002
|
scopes: props.scopes,
|
|
1003
|
+
session: props.session,
|
|
1003
1004
|
signInOptions: props.signInOptions,
|
|
1004
1005
|
signInUrl: props.signInUrl,
|
|
1005
1006
|
signUpUrl: props.signUpUrl,
|
|
1006
1007
|
storage: props.storage,
|
|
1007
|
-
syncSession: props.syncSession,
|
|
1008
1008
|
vendor
|
|
1009
1009
|
};
|
|
1010
1010
|
}
|
|
@@ -1156,7 +1156,7 @@ const ThunderIDProvider = defineComponent({
|
|
|
1156
1156
|
const code = urlParams.get("code");
|
|
1157
1157
|
const executionIdFromUrl = urlParams.get("executionId");
|
|
1158
1158
|
const storedExecutionId = sessionStorage.getItem(`${vendor}_execution_id`);
|
|
1159
|
-
if (code && !executionIdFromUrl && !storedExecutionId) await signIn();
|
|
1159
|
+
if ((code || SPAUtils.isSilentStatePresentInURL()) && !executionIdFromUrl && !storedExecutionId) await signIn();
|
|
1160
1160
|
} catch (error) {
|
|
1161
1161
|
throw new ThunderIDRuntimeError$1(`Sign in failed: ${error instanceof Error ? error.message : String(JSON.stringify(error))}`, "thunderid-signIn-Error", "vue", "An error occurred while trying to sign in.");
|
|
1162
1162
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ThunderIDProvider.d.ts","sourceRoot":"","sources":["../../src/providers/ThunderIDProvider.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ThunderIDProvider.d.ts","sourceRoot":"","sources":["../../src/providers/ThunderIDProvider.ts"],"names":[],"mappings":"AAsBA,OAAO,EACL,KAAK,SAAS,EAaf,MAAM,KAAK,CAAC;AA6Cb;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,iBAAiB,EAAE,SA+bvB,CAAC;AAEH,eAAe,iBAAiB,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Re-export of the auth params URL check from the Browser SDK.
|
|
3
3
|
*
|
|
4
|
-
* Checks if `code`
|
|
4
|
+
* Checks if `code` is present in the URL search params,
|
|
5
5
|
* indicating an OAuth2 authorization code callback.
|
|
6
6
|
*
|
|
7
7
|
* @see {@link @thunderid/browser#hasAuthParamsInUrl}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thunderid/vue",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.1",
|
|
4
4
|
"description": "Vue SDK for ThunderID",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"thunderid",
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
}
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@thunderid/browser": "^1.1
|
|
60
|
+
"@thunderid/browser": "^1.2.1",
|
|
61
61
|
"dompurify": "3.4.13",
|
|
62
62
|
"tslib": "2.8.1"
|
|
63
63
|
},
|