@tonconnect/ui 2.0.4 → 2.0.6
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/tonconnect-ui.min.js +3 -3
- package/dist/tonconnect-ui.min.js.map +1 -1
- package/lib/index.cjs +11 -4
- package/lib/index.cjs.map +1 -1
- package/lib/index.mjs +11 -4
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.cjs
CHANGED
|
@@ -7170,7 +7170,7 @@ const computePosition$1 = (reference, floating, config) => __async(exports, null
|
|
|
7170
7170
|
} = config;
|
|
7171
7171
|
const validMiddleware = middleware.filter(Boolean);
|
|
7172
7172
|
const rtl = yield platform2.isRTL == null ? void 0 : platform2.isRTL(floating);
|
|
7173
|
-
if (
|
|
7173
|
+
if ({}.NODE_ENV !== "production") {
|
|
7174
7174
|
if (platform2 == null) {
|
|
7175
7175
|
console.error(["Floating UI: `platform` property was not passed to config. If you", "want to use Floating UI on the web, install @floating-ui/dom", "instead of the /core package. Otherwise, you can create your own", "`platform`: https://floating-ui.com/docs/platform"].join(" "));
|
|
7176
7176
|
}
|
|
@@ -7227,7 +7227,7 @@ const computePosition$1 = (reference, floating, config) => __async(exports, null
|
|
|
7227
7227
|
middlewareData = __spreadProps(__spreadValues({}, middlewareData), {
|
|
7228
7228
|
[name]: __spreadValues(__spreadValues({}, middlewareData[name]), data)
|
|
7229
7229
|
});
|
|
7230
|
-
if (
|
|
7230
|
+
if ({}.NODE_ENV !== "production") {
|
|
7231
7231
|
if (resetCount > 50) {
|
|
7232
7232
|
console.warn(["Floating UI: The middleware lifecycle appears to be running in an", "infinite loop. This is usually caused by a `reset` continually", "being returned without a break condition."].join(" "));
|
|
7233
7233
|
}
|
|
@@ -9656,13 +9656,19 @@ const _tmpl$$1 = /* @__PURE__ */ template$1(`<li></li>`), _tmpl$2 = /* @__PURE__
|
|
|
9656
9656
|
const MobileUniversalModal = (props) => {
|
|
9657
9657
|
const [showQR, setShowQR] = createSignal(false);
|
|
9658
9658
|
const [firstClick, setFirstClick] = createSignal(true);
|
|
9659
|
+
const [universalLink, setUniversalLink] = createSignal(null);
|
|
9659
9660
|
const connector = appState.connector;
|
|
9660
9661
|
const walletsList = () => props.walletsList.filter((w) => supportsMobile(w) && w.appName !== AT_WALLET_APP_NAME);
|
|
9661
9662
|
const shouldShowMoreButton = () => walletsList().length > 7;
|
|
9662
9663
|
const walletsBridges = createMemo(() => getUniqueBridges(props.walletsList), null, {
|
|
9663
9664
|
equals: bridgesIsEqual
|
|
9664
9665
|
});
|
|
9665
|
-
const getUniversalLink =
|
|
9666
|
+
const getUniversalLink = () => {
|
|
9667
|
+
if (!universalLink()) {
|
|
9668
|
+
setUniversalLink(connector.connect(walletsBridges(), props.additionalRequest));
|
|
9669
|
+
}
|
|
9670
|
+
return universalLink();
|
|
9671
|
+
};
|
|
9666
9672
|
setLastSelectedWalletInfo({
|
|
9667
9673
|
openMethod: "universal-link"
|
|
9668
9674
|
});
|
|
@@ -9688,6 +9694,7 @@ const MobileUniversalModal = (props) => {
|
|
|
9688
9694
|
});
|
|
9689
9695
|
};
|
|
9690
9696
|
const onSelectTelegram = () => {
|
|
9697
|
+
setUniversalLink(null);
|
|
9691
9698
|
const atWallet = props.walletsList.find((wallet) => wallet.appName === AT_WALLET_APP_NAME);
|
|
9692
9699
|
if (!atWallet || !sdk.isWalletInfoRemote(atWallet)) {
|
|
9693
9700
|
throw new TonConnectUIError("@wallet bot not found in the wallets list");
|
|
@@ -10904,7 +10911,7 @@ class TonConnectUITracker {
|
|
|
10904
10911
|
}
|
|
10905
10912
|
}
|
|
10906
10913
|
}
|
|
10907
|
-
const tonConnectUiVersion = "2.0.
|
|
10914
|
+
const tonConnectUiVersion = "2.0.5";
|
|
10908
10915
|
class TonConnectUI {
|
|
10909
10916
|
constructor(options) {
|
|
10910
10917
|
__publicField(this, "walletInfoStorage", new WalletInfoStorage());
|