@mattrglobal/verifier-sdk-web 1.1.1-unstable.169 → 1.1.1-unstable.171

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.
@@ -7,7 +7,7 @@
7
7
  * Do Not Translate or Localize
8
8
  *
9
9
  * Bundle of @mattrglobal/verifier-sdk-web
10
- * Generated: 2025-05-23
10
+ * Generated: 2025-05-25
11
11
  * Version: 1.1.0
12
12
  * Dependencies:
13
13
  */
@@ -263,7 +263,7 @@ var MessageEventDataType;
263
263
  const OpenId4vpConfigSameDeviceOptionsValidator = v__namespace.object({
264
264
  walletProviderId: v__namespace.optional(v__namespace.string()),
265
265
  mode: v__namespace.literal(exports.Mode.SameDevice),
266
- redirectUri: v__namespace.string()
266
+ redirectUri: v__namespace.pipe(v__namespace.string(), v__namespace.nonEmpty("Must not be empty"), v__namespace.url())
267
267
  });
268
268
 
269
269
  const OpenId4vpConfigCrossDeviceOptionsValidator = v__namespace.object({
@@ -273,7 +273,7 @@ const OpenId4vpConfigCrossDeviceOptionsValidator = v__namespace.object({
273
273
 
274
274
  const OpenId4vpConfigAutoDetectOptionsValidator = v__namespace.object({
275
275
  walletProviderId: v__namespace.optional(v__namespace.string()),
276
- redirectUri: v__namespace.string(),
276
+ redirectUri: v__namespace.pipe(v__namespace.string(), v__namespace.nonEmpty("Must not be empty"), v__namespace.url()),
277
277
  mode: v__namespace.optional(v__namespace.picklist([ exports.Mode.CrossDevice, exports.Mode.SameDevice ]))
278
278
  });
279
279
 
@@ -318,7 +318,7 @@ var AbortSessionErrorMessage;
318
318
  })(AbortSessionErrorMessage || (AbortSessionErrorMessage = {}));
319
319
 
320
320
  const InitializeOptionsValidator = v__namespace.object({
321
- apiBaseUrl: v__namespace.pipe(v__namespace.string(), v__namespace.nonEmpty("Must not be empty")),
321
+ apiBaseUrl: v__namespace.pipe(v__namespace.string(), v__namespace.nonEmpty("Must not be empty"), v__namespace.url()),
322
322
  applicationId: v__namespace.pipe(v__namespace.string(), v__namespace.nonEmpty("Must not be empty"))
323
323
  });
324
324
 
@@ -370,7 +370,12 @@ var InitializeErrorMessage;
370
370
 
371
371
  const initialize = options => {
372
372
  assertType(InitializeOptionsValidator, "Invalid initialize options")(options);
373
- initializeOptions = options;
373
+ const {apiBaseUrl: apiBaseUrl} = options;
374
+ const trimmedApiBaseUrl = apiBaseUrl.trim();
375
+ initializeOptions = {
376
+ apiBaseUrl: trimmedApiBaseUrl,
377
+ applicationId: options.applicationId
378
+ };
374
379
  };
375
380
 
376
381
  const getInitializeOptions = () => initializeOptions;
@@ -994,7 +999,7 @@ const deriveOpenId4vpRedirectUri = openid4vpConfiguration => {
994
999
  detectedMode = isMobileDetect(navigator.userAgent) ? exports.Mode.SameDevice : exports.Mode.CrossDevice;
995
1000
  }
996
1001
  if (detectedMode === exports.Mode.SameDevice && !isType(OpenId4vpConfigCrossDeviceOptionsValidator)(openid4vpConfiguration) && openid4vpConfiguration.redirectUri) {
997
- return openid4vpConfiguration.redirectUri;
1002
+ return openid4vpConfiguration.redirectUri.trim();
998
1003
  }
999
1004
  return undefined;
1000
1005
  };