codexly-ui 0.5.2 → 0.5.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.
@@ -2322,11 +2322,14 @@ class ClxTooltipDirective {
2322
2322
  host.addEventListener('focus', () => this._scheduleShow(), { signal });
2323
2323
  host.addEventListener('blur', () => this._scheduleHide(), { signal });
2324
2324
  // Touch devices fire 'mouseenter'/'focus' on tap but never a real
2325
- // 'mouseleave' — dismiss immediately (no fade) once the tap completes so
2326
- // the bubble can't outlive the tap and float over whatever the tap
2327
- // triggered (e.g. a modal opening on the same gesture).
2325
+ // 'mouseleave' — dismiss immediately (no fade) so the bubble can't
2326
+ // outlive the tap and float over whatever it triggered (e.g. a modal
2327
+ // opening on the same gesture). Capture-phase 'click' fires before the
2328
+ // host's own (click) handler — the one that actually opens the modal —
2329
+ // so the bubble is gone from the DOM before the modal is created.
2328
2330
  host.addEventListener('touchend', () => this._hideImmediate(), { signal });
2329
2331
  host.addEventListener('touchcancel', () => this._hideImmediate(), { signal });
2332
+ host.addEventListener('click', () => this._hideImmediate(), { signal, capture: true });
2330
2333
  this._destroyRef.onDestroy(() => {
2331
2334
  this._destroyed = true;
2332
2335
  this._abort.abort();