decord/source/modules/webauthn/WebAuthnSignalManager.tsx

175 lines
5.1 KiB
TypeScript
Raw Normal View History

// Module ID: 17942
// Function ID: 17943
// Name: WebAuthnSignalManager
// Dependencies: [5, 502, 7221, 6699, 2]
2026-07-23 10:11:24 +00:00
// Module 17942 (WebAuthnSignalManager)
import asyncGeneratorStep from "asyncGeneratorStep" /* 5 */;
import AuthenticationStore from "AuthenticationStore" /* 502 */;
import AutomaticLifecycleManager from "AutomaticLifecycleManager" /* 7221 */;
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
class WebAuthnSignalManager extends tmp2 {
constructor() {
applyArgumentsResult = HermesBuiltin.applyArguments(new.target, new.target);
applyArgumentsResult.actions = { AUTHENTICATOR_DELETE: applyArgumentsResult.handleAuthenticatorDelete, MFA_WEBAUTHN_CREDENTIALS_LOADED: applyArgumentsResult.handleWebAuthnCredentialsLoaded, CURRENT_USER_UPDATE: applyArgumentsResult.handleCurrentUserUpdate };
return applyArgumentsResult;
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
const prototype = WebAuthnSignalManager.prototype;
prototype["handleAuthenticatorDelete"] = function handleAuthenticatorDelete(credential) {
credential = credential.credential;
return (async (arg0, value) => {
if (v3 === 2) {
v3 = 3;
throw new TypeError("Generator functions may not be called on executing generators");
2026-07-29 08:29:29 +00:00
} else if (tmp3 === 3) {
if (arg0 === 1) {
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
const obj3 = { value, done: true };
return obj3;
2026-07-29 08:29:29 +00:00
} else {
2026-09-01 10:26:29 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} else {
try {
v3 = 2;
if (0 === c1) {
2026-07-29 08:29:29 +00:00
if (arg0 === 1) {
v3 = 3;
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
v3 = 3;
const obj4 = { value, done: true };
return obj4;
2026-07-29 08:29:29 +00:00
} else {
c1 = 1;
v3 = 1;
const obj5 = { value: v3(c1[3]).signalUnknownCredential(credential), done: false };
return obj5;
2026-07-29 08:29:29 +00:00
}
} else if (arg0 === 1) {
v3 = 3;
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
v3 = 3;
const obj = { value, done: true };
2026-07-29 08:29:29 +00:00
return obj;
} else {
v3 = 3;
2026-09-01 10:26:29 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} catch (tmp8) {
v3 = tmp;
2026-07-29 08:29:29 +00:00
throw tmp8;
}
}
})();
};
prototype["handleWebAuthnCredentialsLoaded"] = function handleWebAuthnCredentialsLoaded(credentials) {
credentials = credentials.credentials;
return (async (arg0, value) => {
if (v3 === 2) {
v3 = 3;
throw new TypeError("Generator functions may not be called on executing generators");
2026-07-29 08:29:29 +00:00
} else if (tmp3 === 3) {
if (arg0 === 1) {
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
const obj3 = { value, done: true };
return obj3;
2026-07-29 08:29:29 +00:00
} else {
2026-09-01 10:26:29 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} else {
try {
v3 = 2;
if (0 === c1) {
2026-07-29 08:29:29 +00:00
if (arg0 === 1) {
v3 = 3;
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
v3 = 3;
const obj4 = { value, done: true };
return obj4;
2026-07-29 08:29:29 +00:00
} else {
id = id.getId();
c1 = 1;
v3 = 1;
const obj5 = { value: v3(c1[3]).signalAllAcceptedCredentials(credentials, id), done: false };
return obj5;
2026-07-29 08:29:29 +00:00
}
} else if (arg0 === 1) {
v3 = 3;
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
v3 = 3;
const obj = { value, done: true };
2026-07-29 08:29:29 +00:00
return obj;
} else {
v3 = 3;
2026-09-01 10:26:29 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} catch (tmp10) {
v3 = tmp;
2026-07-29 08:29:29 +00:00
throw tmp10;
}
}
})();
};
prototype["handleCurrentUserUpdate"] = function handleCurrentUserUpdate(user) {
user = user.user;
return (async (arg0, value) => {
if (v3 === 2) {
v3 = 3;
throw new TypeError("Generator functions may not be called on executing generators");
2026-07-29 08:29:29 +00:00
} else if (tmp3 === 3) {
if (arg0 === 1) {
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
const obj3 = { value, done: true };
return obj3;
2026-07-29 08:29:29 +00:00
} else {
2026-09-01 10:26:29 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} else {
try {
v3 = 2;
if (0 === c1) {
2026-07-29 08:29:29 +00:00
if (arg0 === 1) {
v3 = 3;
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
v3 = 3;
const obj4 = { value, done: true };
return obj4;
2026-07-29 08:29:29 +00:00
} else {
c1 = 1;
v3 = 1;
const obj5 = { value: v3(c1[3]).signalCurrentUserDetails(user), done: false };
return obj5;
2026-07-29 08:29:29 +00:00
}
} else if (arg0 === 1) {
v3 = 3;
throw value;
2026-07-29 08:29:29 +00:00
} else if (arg0 === 2) {
v3 = 3;
const obj = { value, done: true };
2026-07-29 08:29:29 +00:00
return obj;
} else {
v3 = 3;
2026-09-01 10:26:29 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} catch (tmp8) {
v3 = tmp;
2026-07-29 08:29:29 +00:00
throw tmp8;
}
}
})();
};
const webAuthnSignalManager = new WebAuthnSignalManager();
const size = fn(2);
const result = size.fileFinishedImporting("modules/webauthn/WebAuthnSignalManager.tsx");
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
export default webAuthnSignalManager;