Skip to content

fix(hud): restore click-through at original bar position after drag#542

Open
Reedaaz wants to merge 1 commit into
webadderallorg:mainfrom
Reedaaz:pr/fix-floating-bar-passthrough
Open

fix(hud): restore click-through at original bar position after drag#542
Reedaaz wants to merge 1 commit into
webadderallorg:mainfrom
Reedaaz:pr/fix-floating-bar-passthrough

Conversation

@Reedaaz

@Reedaaz Reedaaz commented May 20, 2026

Copy link
Copy Markdown

Fixes #535

Problem

The HUD overlay wrapper kept pointer-events: auto at its layout-original position. When the floating bar is dragged, only the inner hudBarTransformRef div shifts visually via CSS translate3d — the outer wrapper stays put. Any mouseenter on that stale area still triggers handleHudMouseEntersetIgnoreMouseEvents(false) on the full-screen HUD window, which then swallows clicks intended for the underlying app (Excel, browser, etc.).

Fix

Move pointer-events: auto and the mouse enter/leave handlers from the static wrapper onto the transformed hudBarTransformRef div, so the interactive hit area follows the bar's actual rendered position.

Test plan

  • Open Excel (or any app), start recording
  • Drag the floating bar to a new location
  • Click on a cell at the bar's original position → click reaches Excel correctly
  • Click on a button on the bar at its new position → bar still interactive
  • Webcam preview continues to receive its own pointer events (separate sibling with own handlers)

Summary by CodeRabbit

  • Bug Fixes
    • Improved HUD bar hover behavior by refining which element receives pointer events and hover handlers. This makes hover targets more precise, reduces accidental triggers, and yields smoother, more responsive mouse interactions over the HUD.

@coderabbitai

coderabbitai Bot commented May 20, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 4a163a25-08d0-438d-b8c5-a98418777141

📥 Commits

Reviewing files that changed from the base of the PR and between 3550bdd and 936fcf4.

📒 Files selected for processing (1)
  • src/components/launch/LaunchWindow.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/components/launch/LaunchWindow.tsx

📝 Walkthrough

Walkthrough

The HUD wrapper in LaunchWindow.tsx is refactored: the outer container now uses pointer-events-none, and the inner element referenced by hudBarTransformRef is pointer-events-auto and receives onMouseEnter/onMouseLeave handlers.

Changes

HUD wrapper pointer-events handling

Layer / File(s) Summary
HUD wrapper pointer-events restructuring
src/components/launch/LaunchWindow.tsx
The outer HUD container becomes pointer-events-none; the inner transformed element with hudBarTransformRef becomes pointer-events-auto and receives the mouse hover event handlers (onMouseEnter/onMouseLeave).

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~15 minutes

Possibly related PRs

  • webadderallorg/Recordly#616: Related HUD mouse-interaction and pointer-events handling changes, including passthrough/grace logic adjustments.

Poem

🐰 I nudged the HUD from shell to core,
The outer sleeps, the inner leaps for more.
A gentle hover, light and fleet—
The bar now knows the mouse's beat.
🥕

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main bug fix: restoring click-through behavior at the original bar position after dragging, which directly matches the core problem and solution in the changeset.
Description check ✅ Passed The description includes all essential sections: a clear problem statement, detailed explanation of the fix, and a comprehensive test plan with verification steps.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Reedaaz Reedaaz force-pushed the pr/fix-floating-bar-passthrough branch from 3550bdd to 936fcf4 Compare June 10, 2026 17:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Item under floating bar not click-able

1 participant