@pooflabs/web 0.0.56 → 0.0.57

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.
@@ -13086,7 +13086,7 @@ async function loadDependencies() {
13086
13086
  const [reactModule, reactDomModule, phantomModule] = await Promise.all([
13087
13087
  import('react'),
13088
13088
  import('react-dom/client'),
13089
- Promise.resolve().then(function () { return require('./index-Bd_yX1y8.js'); })
13089
+ Promise.resolve().then(function () { return require('./index-OppCl1Ve.js'); })
13090
13090
  ]);
13091
13091
  // Extract default export from ESM module namespace
13092
13092
  // Dynamic import() returns { default: Module, ...exports }, not the module directly
@@ -13200,7 +13200,7 @@ class PhantomWalletProvider {
13200
13200
  this.containerElement.style.position = 'fixed';
13201
13201
  this.containerElement.style.inset = '0';
13202
13202
  this.containerElement.style.zIndex = '2147483647';
13203
- this.containerElement.style.pointerEvents = 'auto';
13203
+ this.containerElement.style.pointerEvents = 'none';
13204
13204
  document.body.appendChild(this.containerElement);
13205
13205
  const that = this;
13206
13206
  const { PhantomProvider: ReactPhantomProvider, usePhantom, useConnect, useDisconnect, useModal, useSolana, useDiscoveredWallets, AddressType, darkTheme, lightTheme } = phantomReactSdk;
@@ -13347,14 +13347,17 @@ class PhantomWalletProvider {
13347
13347
  }
13348
13348
  prevModalOpen.current = showWalletModal || modal.isOpened;
13349
13349
  }, [showWalletModal, modal.isOpened, phantom === null || phantom === void 0 ? void 0 : phantom.isConnected]);
13350
- // While custom modal is open, block pointer events on everything behind it.
13350
+ // While any modal is open, block pointer events on everything behind it.
13351
13351
  // This guarantees host app modals (e.g. z-50 stacks) can't steal clicks.
13352
13352
  React$1.useEffect(() => {
13353
- if (!showWalletModal)
13353
+ const isModalOpen = showWalletModal || modal.isOpened;
13354
+ if (!isModalOpen)
13354
13355
  return;
13355
13356
  const container = that.containerElement;
13356
13357
  if (!container || typeof document === 'undefined')
13357
13358
  return;
13359
+ // Enable clicks on the Phantom container while a modal is open
13360
+ container.style.pointerEvents = 'auto';
13358
13361
  const restored = new Map();
13359
13362
  const bodyChildren = Array.from(document.body.children);
13360
13363
  for (const el of bodyChildren) {
@@ -13364,11 +13367,13 @@ class PhantomWalletProvider {
13364
13367
  el.style.pointerEvents = 'none';
13365
13368
  }
13366
13369
  return () => {
13370
+ // Restore pass-through on the container when modal closes
13371
+ container.style.pointerEvents = 'none';
13367
13372
  for (const [el, prev] of restored.entries()) {
13368
13373
  el.style.pointerEvents = prev;
13369
13374
  }
13370
13375
  };
13371
- }, [showWalletModal]);
13376
+ }, [showWalletModal, modal.isOpened]);
13372
13377
  // Handle connection errors
13373
13378
  React$1.useEffect(() => {
13374
13379
  if (connectError && that.pendingLogin) {
@@ -34723,4 +34728,4 @@ exports.signSessionCreateMessage = signSessionCreateMessage;
34723
34728
  exports.signTransaction = signTransaction;
34724
34729
  exports.subscribe = subscribe;
34725
34730
  exports.useAuth = useAuth;
34726
- //# sourceMappingURL=index-ijV9nNFI.js.map
34731
+ //# sourceMappingURL=index-DFi8Tb9p.js.map