@tiplink/wallet-adapter
Advanced tools
Comparing version 2.1.11 to 2.1.12
@@ -281,3 +281,3 @@ "use strict"; | ||
} | ||
init({ directConnect, autoConnect, forceClickToContinue, showErrorMessage, siwsInput, theme, }) { | ||
init({ directConnect, autoConnect: autoConnect, forceClickToContinue: forceClickToContinue, showErrorMessage, siwsInput, theme, }) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
@@ -297,2 +297,3 @@ if (this.isDisallowed()) { | ||
directConnect = false; | ||
forceClickToContinue = true; | ||
} | ||
@@ -471,7 +472,2 @@ } | ||
let windowPost = undefined; | ||
let forceShowLoginPage = false; | ||
if (directConnect && | ||
(!(windowParams === null || windowParams === void 0 ? void 0 : windowParams.popup) || windowParams.popup.closed)) { | ||
forceShowLoginPage = true; | ||
} | ||
if ((windowParams === null || windowParams === void 0 ? void 0 : windowParams.popup) && !windowParams.popup.closed) { | ||
@@ -505,3 +501,3 @@ const { post, close } = | ||
cb: (data) => __awaiter(this, void 0, void 0, function* () { | ||
var _b, _c, _d, _e, _f; | ||
var _b, _c, _d, _e; | ||
// console.log('received "ready" message from iframe', data); | ||
@@ -565,12 +561,2 @@ if ((_b = this.tipLinkIframe) === null || _b === void 0 ? void 0 : _b.contentWindow) { | ||
} | ||
else if (forceShowLoginPage) { | ||
clearInterval(checkPopupClosed); | ||
if ((_f = this.tipLinkIframe) === null || _f === void 0 ? void 0 : _f.contentWindow) { | ||
this.windowCommunicator.singlePostToWindow(this.tipLinkIframe.contentWindow, { | ||
type: "click_to_continue", | ||
title: this.title, | ||
}); | ||
} | ||
this.showIframe(); | ||
} | ||
}), | ||
@@ -581,3 +567,3 @@ }, | ||
cb: (data) => __awaiter(this, void 0, void 0, function* () { | ||
var _g; | ||
var _f; | ||
// console.log( | ||
@@ -587,3 +573,3 @@ // "received ready_for_tiplink_autoconnect", | ||
// ); | ||
if ((_g = this.tipLinkIframe) === null || _g === void 0 ? void 0 : _g.contentWindow) { | ||
if ((_f = this.tipLinkIframe) === null || _f === void 0 ? void 0 : _f.contentWindow) { | ||
this.windowCommunicator.singlePostToWindow(this.tipLinkIframe.contentWindow, { | ||
@@ -599,7 +585,7 @@ type: "ack", | ||
cb: (data) => __awaiter(this, void 0, void 0, function* () { | ||
var _h; | ||
var _g; | ||
clearInterval(checkPopupClosed); | ||
// console.log("RECEIVED LOADED PUBLIC_KEY"); | ||
this.hideIframe(); | ||
if ((_h = this.tipLinkIframe) === null || _h === void 0 ? void 0 : _h.contentWindow) { | ||
if ((_g = this.tipLinkIframe) === null || _g === void 0 ? void 0 : _g.contentWindow) { | ||
this.windowCommunicator.singlePostToWindow(this.tipLinkIframe.contentWindow, { | ||
@@ -663,6 +649,6 @@ type: "ack_loaded_public_key", | ||
cb: (data) => __awaiter(this, void 0, void 0, function* () { | ||
var _j; | ||
var _h; | ||
// console.log("RECEIVED CANCEL_CONNECT"); | ||
this.hideIframe(); | ||
(_j = windowParams === null || windowParams === void 0 ? void 0 : windowParams.popup) === null || _j === void 0 ? void 0 : _j.close(); | ||
(_h = windowParams === null || windowParams === void 0 ? void 0 : windowParams.popup) === null || _h === void 0 ? void 0 : _h.close(); | ||
this.cleanUp(); | ||
@@ -675,4 +661,4 @@ reject("user clicked close button in iframe"); | ||
cb: (data) => __awaiter(this, void 0, void 0, function* () { | ||
var _k; | ||
(_k = windowParams === null || windowParams === void 0 ? void 0 : windowParams.popup) === null || _k === void 0 ? void 0 : _k.focus(); | ||
var _j; | ||
(_j = windowParams === null || windowParams === void 0 ? void 0 : windowParams.popup) === null || _j === void 0 ? void 0 : _j.focus(); | ||
}), | ||
@@ -679,0 +665,0 @@ }, |
@@ -22,3 +22,3 @@ "use strict"; | ||
exports.GoogleViaTipLinkWalletName = "Google via TipLink"; | ||
exports.NPM_VERSION = "2.1.11"; | ||
exports.NPM_VERSION = "2.1.12"; | ||
// preload for iframe doesn't work https://bugs.chromium.org/p/chromium/issues/detail?id=593267 | ||
@@ -25,0 +25,0 @@ function preLoadIframe(buildEnv, clientId) { |
@@ -256,3 +256,3 @@ /* | ||
} | ||
async init({ directConnect, autoConnect, forceClickToContinue, showErrorMessage, siwsInput, theme, }) { | ||
async init({ directConnect, autoConnect: autoConnect, forceClickToContinue: forceClickToContinue, showErrorMessage, siwsInput, theme, }) { | ||
if (this.isDisallowed()) { | ||
@@ -271,2 +271,3 @@ this.notifyDisallowed(); | ||
directConnect = false; | ||
forceClickToContinue = true; | ||
} | ||
@@ -442,7 +443,2 @@ } | ||
let windowPost = undefined; | ||
let forceShowLoginPage = false; | ||
if (directConnect && | ||
(!windowParams?.popup || windowParams.popup.closed)) { | ||
forceShowLoginPage = true; | ||
} | ||
if (windowParams?.popup && !windowParams.popup.closed) { | ||
@@ -534,12 +530,2 @@ const { post, close } = | ||
} | ||
else if (forceShowLoginPage) { | ||
clearInterval(checkPopupClosed); | ||
if (this.tipLinkIframe?.contentWindow) { | ||
this.windowCommunicator.singlePostToWindow(this.tipLinkIframe.contentWindow, { | ||
type: "click_to_continue", | ||
title: this.title, | ||
}); | ||
} | ||
this.showIframe(); | ||
} | ||
}, | ||
@@ -546,0 +532,0 @@ }, |
@@ -10,3 +10,3 @@ import { BaseSignInMessageSignerWalletAdapter, WalletConfigError, WalletConnectionError, WalletDisconnectionError, WalletNotConnectedError, WalletNotReadyError, WalletPublicKeyError, WalletReadyState, WalletSignInError, WalletSignMessageError, WalletSignTransactionError, } from "@solana/wallet-adapter-base"; | ||
export const GoogleViaTipLinkWalletName = "Google via TipLink"; | ||
export const NPM_VERSION = "2.1.11"; | ||
export const NPM_VERSION = "2.1.12"; | ||
// preload for iframe doesn't work https://bugs.chromium.org/p/chromium/issues/detail?id=593267 | ||
@@ -13,0 +13,0 @@ async function preLoadIframe(buildEnv, clientId) { |
@@ -54,3 +54,3 @@ import type { Connection, SendOptions } from "@solana/web3.js"; | ||
private showIframe; | ||
init({ directConnect, autoConnect, forceClickToContinue, showErrorMessage, siwsInput, theme, }: { | ||
init({ directConnect, autoConnect: autoConnect, forceClickToContinue: forceClickToContinue, showErrorMessage, siwsInput, theme, }: { | ||
directConnect: boolean; | ||
@@ -57,0 +57,0 @@ autoConnect?: boolean; |
@@ -10,3 +10,3 @@ import type { WalletName } from "@solana/wallet-adapter-base"; | ||
export type TipLinkWalletAdapterTheme = "system" | "light" | "dark"; | ||
export declare const NPM_VERSION = "2.1.11"; | ||
export declare const NPM_VERSION = "2.1.12"; | ||
export type CustomSolanaSignInInput = SolanaSignInInput | (() => Promise<SolanaSignInInput>); | ||
@@ -13,0 +13,0 @@ type WalletAdapterConfig = { |
{ | ||
"name": "@tiplink/wallet-adapter", | ||
"version": "2.1.11", | ||
"version": "2.1.12", | ||
"author": "Alex Fung", | ||
@@ -5,0 +5,0 @@ "contributors": [ |
@@ -395,4 +395,4 @@ /* | ||
directConnect, | ||
autoConnect, | ||
forceClickToContinue, | ||
autoConnect: autoConnect, | ||
forceClickToContinue: forceClickToContinue, | ||
showErrorMessage, | ||
@@ -430,2 +430,3 @@ siwsInput, | ||
directConnect = false; | ||
forceClickToContinue = true; | ||
} | ||
@@ -637,9 +638,2 @@ } | ||
let windowPost: PostFn | undefined = undefined; | ||
let forceShowLoginPage = false; | ||
if ( | ||
directConnect && | ||
(!windowParams?.popup || windowParams.popup.closed) | ||
) { | ||
forceShowLoginPage = true; | ||
} | ||
@@ -754,14 +748,2 @@ if (windowParams?.popup && !windowParams.popup.closed) { | ||
this.showIframe(); | ||
} else if (forceShowLoginPage) { | ||
clearInterval(checkPopupClosed); | ||
if (this.tipLinkIframe?.contentWindow) { | ||
this.windowCommunicator.singlePostToWindow( | ||
this.tipLinkIframe.contentWindow, | ||
{ | ||
type: "click_to_continue", | ||
title: this.title, | ||
} | ||
); | ||
} | ||
this.showIframe(); | ||
} | ||
@@ -768,0 +750,0 @@ }, |
@@ -45,3 +45,3 @@ import type { WalletName } from "@solana/wallet-adapter-base"; | ||
export type TipLinkWalletAdapterTheme = "system" | "light" | "dark"; | ||
export const NPM_VERSION = "2.1.11"; | ||
export const NPM_VERSION = "2.1.12"; | ||
export type CustomSolanaSignInInput = | ||
@@ -48,0 +48,0 @@ | SolanaSignInInput |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
469836
7228