Skip to content

[wip] Fix bubble shadows, multi-screen, and overlay visibility#813

Draft
shomix wants to merge 2 commits into
mainfrom
ai_main_de264db98f1440a69a60
Draft

[wip] Fix bubble shadows, multi-screen, and overlay visibility#813
shomix wants to merge 2 commits into
mainfrom
ai_main_de264db98f1440a69a60

Conversation

@shomix
Copy link
Copy Markdown
Contributor

@shomix shomix commented May 21, 2026

Summary

This PR improves the Clips desktop app's camera bubble and overlay behavior by removing drop shadows, enabling the camera bubble and popover to follow the user across all Mission Control spaces and monitors, and ensuring the overlay is visible above other apps before recording starts.

Problem

Three issues existed in the Clips desktop app:

  1. The camera bubble and pill UI elements had drop shadows that were visually distracting.
  2. The camera bubble only appeared on the screen/space where the app was initially started, and did not follow the user to other monitors or Mission Control spaces.
  3. The app overlay (popover) was only shown on the desktop window and was not visible above other apps before recording began.

Solution

  • Removed box-shadow CSS rules from the camera bubble, pill, and close button elements.
  • Introduced a new set_window_can_join_all_spaces utility that sets NSWindowCollectionBehaviorCanJoinAllSpaces on macOS windows via the Objective-C runtime, making them follow the user across all spaces and monitors.
  • Applied this utility to both the camera bubble (on show) and the popover window (on app startup) so both are reachable regardless of the active space or monitor.

Key Changes

  • src/styles.css: Removed box-shadow from the camera bubble container, the bubble close button, and the pill control bar.
  • src-tauri/src/util.rs: Added set_window_can_join_all_spaces utility function (macOS-only) that uses objc2 to set NSWindowCollectionBehaviorCanJoinAllSpaces (bit flag 1) on the underlying NSWindow; no-op stub provided for non-macOS targets.
  • src-tauri/src/clips/mod.rs: Called set_window_can_join_all_spaces on the camera bubble window when it is shown.
  • src-tauri/src/lib.rs: Called set_window_can_join_all_spaces on the popover window at app startup so the overlay appears above all apps on every space before recording starts.

Edit in Builder  Preview


To clone this PR locally use the Github CLI with command gh pr checkout 813

You can tag me at @BuilderIO for anything you want me to fix or change

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@builder-io-integration builder-io-integration Bot changed the title Update from the Builder.io agent Fix bubble shadows, multi-screen, and overlay visibility May 21, 2026
@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

@shomix shomix changed the title Fix bubble shadows, multi-screen, and overlay visibility [wip] Fix bubble shadows, multi-screen, and overlay visibility May 21, 2026
@netlify

This comment has been minimized.

@netlify

This comment has been minimized.

builder-io-integration[bot]

This comment was marked as outdated.

Copy link
Copy Markdown
Contributor

@builder-io-integration builder-io-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Builder reviewed your changes — looks good ✅

Review Details

Incremental Code Review — PR #813 Update

✅ Previous Issue Resolved

The flagged issue about setCollectionBehavior: replacing the behavior bitmask has been correctly fixed.

What changed:

  • Lines 215–219 in util.rs now read the current collection behavior mask and OR in the new flag instead of replacing it
  • Added clear comments explaining why (preserving Tauri's existing window flags like NSWindowCollectionBehaviorManaged)
  • Pattern: let current: usize = objc2::msg_send![&*obj, collectionBehavior]; let _: () = objc2::msg_send![&*obj, setCollectionBehavior: current | 1usize];

Why this fix works:

  • ✅ Preserves all existing window behavior flags Tauri may have set
  • ✅ Properly adds NSWindowCollectionBehaviorCanJoinAllSpaces via bitwise OR
  • ✅ Follows the correct macOS/AppKit pattern for modifying bitmask properties

Code Quality Review

✅ Error handling complete (handles ns_window and main thread dispatch failures)
✅ Null pointer check present
✅ macOS-only guards with proper non-macOS stub
✅ CSS removals are clean (no functional impact)
✅ Logging appropriate (debug on success, stderr on errors)
✅ Function calls consistent (bubble on show, popover at startup)

Verification: Reviewed by 2 independent code-review agents — both confirmed the fix is correct with no new issues detected.

🧪 Browser testing: Skipped — PR modifies Tauri desktop app, no web UI impact

@shomix shomix marked this pull request as draft May 21, 2026 12:54
@shomix
Copy link
Copy Markdown
Contributor Author

shomix commented May 21, 2026

Am testing this changes, will notify when they are ready

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants