fix: auto login inside imtoken browser

This commit is contained in:
TerryM
2026-06-04 09:46:24 +08:00
parent 53eab4a066
commit f8369b6361
3 changed files with 42 additions and 6 deletions

View File

@@ -138,7 +138,7 @@ export function getInjectedEthereum(): EthereumProvider | null {
return maybeWindow.ethereum ?? null;
}
function isImTokenBrowser(): boolean {
export function isImTokenBrowser(): boolean {
if (typeof navigator === "undefined") return false;
return /imtoken/i.test(navigator.userAgent || "");
}