@satoshai/kit 1.0.1 → 1.0.3

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.cjs CHANGED
@@ -1475,7 +1475,20 @@ var useBnsName = (address) => {
1475
1475
  };
1476
1476
  var useWallets = () => {
1477
1477
  const { wallets } = useStacksWalletContext();
1478
- return react.useMemo(() => ({ wallets }), [wallets]);
1478
+ const { installed } = getStacksWallets();
1479
+ const installedKey = installed.join(",");
1480
+ return react.useMemo(
1481
+ () => ({
1482
+ wallets: wallets.map((w) => ({
1483
+ ...w,
1484
+ // wallet-connect availability is controlled by projectId in
1485
+ // the provider — don't override with getStacksWallets() which
1486
+ // unconditionally returns true for it.
1487
+ available: w.id === "wallet-connect" ? w.available : w.available || installed.includes(w.id)
1488
+ }))
1489
+ }),
1490
+ [wallets, installedKey]
1491
+ );
1479
1492
  };
1480
1493
 
1481
1494
  // src/utils/create-contract-config.ts