@virtonetwork/authenticators-webauthn 1.1.0 → 1.1.2

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 CHANGED
@@ -62,9 +62,9 @@ var WebAuthn = /** @class */ (function () {
62
62
  * @param credentialsHandler - An implementation of {@link CredentialsHandler},
63
63
  *
64
64
  */
65
- function WebAuthn(userId, getChallenge, addressGenerator, _a) {
66
- if (addressGenerator === void 0) { addressGenerator = signer_1.kreivoPassDefaultAddressGenerator; }
65
+ function WebAuthn(userId, getChallenge, _a, addressGenerator) {
67
66
  var _b = _a === void 0 ? new in_memory_credentials_handler_ts_1.InMemoryCredentialsHandler() : _a, publicKeyCreateOptions = _b.publicKeyCreateOptions, publicKeyRequestOptions = _b.publicKeyRequestOptions, onCreatedCredentials = _b.onCreatedCredentials;
67
+ if (addressGenerator === void 0) { addressGenerator = signer_1.kreivoPassDefaultAddressGenerator; }
68
68
  this.userId = userId;
69
69
  this.getChallenge = getChallenge;
70
70
  this.addressGenerator = addressGenerator;
@@ -52,7 +52,7 @@ export declare class WebAuthn implements Authenticator<number> {
52
52
  * @param credentialsHandler - An implementation of {@link CredentialsHandler},
53
53
  *
54
54
  */
55
- constructor(userId: string, getChallenge: Challenger<number>, addressGenerator?: AddressGenerator, { publicKeyCreateOptions, publicKeyRequestOptions, onCreatedCredentials, }?: CredentialsHandler);
55
+ constructor(userId: string, getChallenge: Challenger<number>, { publicKeyCreateOptions, publicKeyRequestOptions, onCreatedCredentials, }?: CredentialsHandler, addressGenerator?: AddressGenerator);
56
56
  /**
57
57
  * Pre‑computes {@link hashedUserId}.
58
58
  *
package/dist/esm/index.js CHANGED
@@ -34,7 +34,7 @@ export class WebAuthn {
34
34
  * @param credentialsHandler - An implementation of {@link CredentialsHandler},
35
35
  *
36
36
  */
37
- constructor(userId, getChallenge, addressGenerator = kreivoPassDefaultAddressGenerator, { publicKeyCreateOptions, publicKeyRequestOptions, onCreatedCredentials, } = new InMemoryCredentialsHandler()) {
37
+ constructor(userId, getChallenge, { publicKeyCreateOptions, publicKeyRequestOptions, onCreatedCredentials, } = new InMemoryCredentialsHandler(), addressGenerator = kreivoPassDefaultAddressGenerator) {
38
38
  this.userId = userId;
39
39
  this.getChallenge = getChallenge;
40
40
  this.addressGenerator = addressGenerator;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@virtonetwork/authenticators-webauthn",
3
3
  "description": "An Authenticator compatible with KreivoPassSigner that uses the WebAuthn standard",
4
- "version": "1.1.0",
4
+ "version": "1.1.2",
5
5
  "type": "module",
6
6
  "files": [
7
7
  "dist"
@@ -36,7 +36,7 @@
36
36
  ],
37
37
  "dependencies": {
38
38
  "@simplewebauthn/server": "^13.1.1",
39
- "@virtonetwork/signer": "^1.0.14",
39
+ "@virtonetwork/signer": "^1.1.0",
40
40
  "nid-webauthn-emulator": "^0.2.4"
41
41
  },
42
42
  "devDependencies": {