@mattrglobal/verifier-sdk-web 1.1.1-unstable.160 → 1.1.1-unstable.161
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/lib/verifier-js-no-deps.cjs.js +2 -22
- package/dist/lib/verifier-js-no-deps.cjs.js.map +1 -1
- package/dist/lib/verifier-js.cjs.js +2 -22
- package/dist/lib/verifier-js.cjs.js.map +1 -1
- package/dist/typings/verifier/types/credential-presentation.d.ts +0 -27
- package/dist/verifier-js.development.js +2 -19
- package/dist/verifier-js.development.js.map +1 -1
- package/dist/verifier-js.production.esm.js +1 -1
- package/dist/verifier-js.production.esm.js.map +1 -1
- package/dist/verifier-js.production.js +1 -1
- package/dist/verifier-js.production.js.map +1 -1
- package/package.json +2 -2
|
@@ -165,14 +165,6 @@ var PresentationErrorType;
|
|
|
165
165
|
PresentationErrorType["Unknown"] = "Unknown";
|
|
166
166
|
})(PresentationErrorType || (PresentationErrorType = {}));
|
|
167
167
|
|
|
168
|
-
const PresentationSuccessResultValidator = v__namespace.object({
|
|
169
|
-
sessionId: v__namespace.string(),
|
|
170
|
-
challenge: v__namespace.string(),
|
|
171
|
-
credentialQuery: v__namespace.array(CredentialQueryValidator),
|
|
172
|
-
credentials: v__namespace.optional(v__namespace.array(v__namespace.any())),
|
|
173
|
-
credentialErrors: v__namespace.optional(v__namespace.array(v__namespace.any()))
|
|
174
|
-
});
|
|
175
|
-
|
|
176
168
|
const PresentationResultRelaxValidator = v__namespace.object({
|
|
177
169
|
sessionId: v__namespace.string(),
|
|
178
170
|
challenge: v__namespace.optional(v__namespace.string()),
|
|
@@ -182,18 +174,6 @@ const PresentationResultRelaxValidator = v__namespace.object({
|
|
|
182
174
|
error: v__namespace.optional(v__namespace.unknown())
|
|
183
175
|
});
|
|
184
176
|
|
|
185
|
-
const PresentationFailureResultValidator = v__namespace.object({
|
|
186
|
-
sessionId: v__namespace.string(),
|
|
187
|
-
challenge: v__namespace.string(),
|
|
188
|
-
credentialQuery: v__namespace.array(CredentialQueryValidator),
|
|
189
|
-
error: v__namespace.object({
|
|
190
|
-
type: v__namespace.picklist(Object.values(PresentationErrorType)),
|
|
191
|
-
message: v__namespace.string()
|
|
192
|
-
})
|
|
193
|
-
});
|
|
194
|
-
|
|
195
|
-
const PresentationSessionResultValidator = v__namespace.union([ PresentationSuccessResultValidator, PresentationFailureResultValidator ]);
|
|
196
|
-
|
|
197
177
|
exports.Mode = void 0;
|
|
198
178
|
|
|
199
179
|
(function(Mode) {
|
|
@@ -627,7 +607,7 @@ const receiveMessageHandler = options => async event => {
|
|
|
627
607
|
return;
|
|
628
608
|
}
|
|
629
609
|
onComplete({
|
|
630
|
-
result:
|
|
610
|
+
result: "challenge" in result.value ? result.value : undefined,
|
|
631
611
|
sessionId: result.value.sessionId,
|
|
632
612
|
sessionCompletedInRedirect: false
|
|
633
613
|
});
|
|
@@ -770,7 +750,7 @@ const requestCredentialsWithDigitalCredentialsApi = async options => {
|
|
|
770
750
|
}
|
|
771
751
|
const verificationResult = credentialVerificationResult.value;
|
|
772
752
|
return neverthrow.ok({
|
|
773
|
-
result:
|
|
753
|
+
result: "challenge" in verificationResult ? verificationResult : undefined,
|
|
774
754
|
sessionId: sessionId
|
|
775
755
|
});
|
|
776
756
|
};
|