@babylonlabs-io/wallet-connector 1.0.6 → 1.0.8

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/index.es.js CHANGED
@@ -91474,19 +91474,26 @@ function pr(e) {
91474
91474
  }
91475
91475
  function Kt(e) {
91476
91476
  const t = t0(m0), [r, n] = useState(), o = () => {
91477
- const s = le(t), a = zt() === "desktop";
91478
- return s.filter((u) => e ? u.chainType === e : !0).map((u) => {
91479
- let p = !0;
91477
+ const s = le(t);
91478
+ let a = !1;
91479
+ const u = zt() === "desktop";
91480
+ return s.filter((p) => e ? p.chainType === e : !0).map((p) => {
91481
+ let d = !0;
91480
91482
  try {
91481
- new u.connectProvider({
91483
+ new p.connectProvider({
91482
91484
  chains: [],
91483
91485
  ...t.providerOptions
91484
91486
  });
91485
91487
  } catch {
91486
- p = !1;
91488
+ d = !1;
91487
91489
  }
91488
- return u.isInstall = p, (u == null ? void 0 : u.type) === "injected" && !a && !p ? null : u;
91489
- }).filter((u) => u ? a ? u.isInstall || u.type !== "injected" : u.isInstall : !1);
91490
+ if (p.isInstall = d, (p == null ? void 0 : p.type) === "injected" && !u)
91491
+ if (d)
91492
+ a = !0;
91493
+ else
91494
+ return null;
91495
+ return p;
91496
+ }).filter((p) => p ? u ? p.isInstall || p.type !== "injected" : p.isInstall || !a : !1);
91490
91497
  };
91491
91498
  return useEffect(() => {
91492
91499
  n(o());
@@ -91666,7 +91673,7 @@ const ExternalWallets = ({ chainName: e, onError: t }) => {
91666
91673
  };
91667
91674
  return /* @__PURE__ */ jsxs("div", { className: "pt-10 text-accent-primary", children: [
91668
91675
  /* @__PURE__ */ jsx(Text, { className: "mb-4", children: "More wallets with Tomo Connect" }),
91669
- /* @__PURE__ */ jsx("div", { className: "grid grid-cols-4 md:grid-cols-7 gap-6 items-center justify-between border border-secondary-strokeLight rounded p-6", children: (n || []).map((s) => /* @__PURE__ */ jsxs(
91676
+ /* @__PURE__ */ jsx("div", { className: "grid grid-cols-3 md:grid-cols-7 gap-6 items-center justify-between border border-secondary-strokeLight rounded p-6", children: (n || []).map((s) => /* @__PURE__ */ jsxs(
91670
91677
  "button",
91671
91678
  {
91672
91679
  disabled: !s.isInstall,
@@ -98465,7 +98472,7 @@ function useWalletConnectors({ persistent: e, accountStorage: t, onError: r }) {
98465
98472
  var T, D, G;
98466
98473
  try {
98467
98474
  if (!y || !y.account || (s == null || s("BTC", y), e && t.set(F.id, y.id), !o)) return;
98468
- validateAddress(F.config.network, y.account.publicKeyHex), await (x == null ? void 0 : x({
98475
+ validateAddress(F.config.network, y.account.address), await (x == null ? void 0 : x({
98469
98476
  address: y.account.address,
98470
98477
  public_key: y.account.publicKeyHex
98471
98478
  }));