Skip to content

fix(ui): smooth notification drawer slide-in/out#2038

Open
elibosley wants to merge 1 commit into
mainfrom
fix/notification-drawer-animation
Open

fix(ui): smooth notification drawer slide-in/out#2038
elibosley wants to merge 1 commit into
mainfrom
fix/notification-drawer-animation

Conversation

@elibosley

@elibosley elibosley commented Jul 12, 2026

Copy link
Copy Markdown
Member

Summary

Smooths the notification drawer (and every other Sheet / ResponsiveModal) open/close, which was extremely janky on mobile. The fix lives in the design-system primitive (@unraid/ui Sheet), not patched only in the notification consumer, so all sheets benefit.

Diagnosis

  • sheet.variants.ts set a blanket transition ease-in-out that ran alongside reka's enter/exit keyframes — so every property (box-shadow, filter, transform) transitioned each frame, and the panel was never promoted to its own compositor layer.
  • Durations were long and asymmetric (500ms open / 300ms close) with no will-change hint.
  • Opening the notification drawer mounted the full body — Tabs + two Apollo-backed NotificationsLists — synchronously, stalling the slide's first frames.

Not the cause (ruled out): it was already animating translate3d (not width/left), and Sheet.vue's viewport-meta rewrite is benign (the live webgui viewport is already width=device-width, initial-scale=1, so it only toggles zoom-lock — no reflow).

Changes

  • sheet.variants.ts — drop the blanket transition; animate only via the transform/opacity keyframes; add will-change-transform (compositor promotion); snappy symmetric timing (300ms open / 200ms close, ease-out / ease-in).
  • SheetContent.vue — match the overlay fade duration to the panel (300/200ms).
  • Notifications/Sidebar.vue — bind v-model:open and defer mounting the tab/list body ~2 frames after open (cheap first paint → slide starts immediately); the body stays mounted through the exit slide, and reka unmounts it with the panel.

Design system

The change is in the @unraid/ui Sheet primitive (design system), so it fixes the animation for all consumers (ResponsiveModal included). The existing Sheet.stories.ts renders the improved animation automatically and asserts nothing about timing, so no story changes are needed. pnpm --filter @unraid/ui build is clean.

Testing

Deployed to a 7.3.2 dev server; open/close the notification bell — the slide is smooth and no longer hitches on mount.

The Sheet primitive animated with a blanket 'transition ease-in-out' running
alongside the reka enter/exit keyframes, so every property (box-shadow, filter,
transform) transitioned each frame and the panel was never promoted to its own
compositor layer. Opening the notification drawer then mounted the full tab/list
body synchronously, stalling the slide's first frames.

- sheet.variants.ts: drop the blanket transition; animate only via the
  transform/opacity keyframes; add will-change-transform so the slide runs on the
  compositor; snappier, symmetric timing (300ms open / 200ms close, ease-out/in).
- SheetContent.vue: match the overlay fade duration to the panel.
- Notifications/Sidebar.vue: defer mounting the tab/list body until a couple
  frames after open so the panel's first paint is cheap and the slide starts
  immediately; the body stays mounted through the exit slide.

Benefits every Sheet/ResponsiveModal, not just notifications.
@coderabbitai

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 52 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: a6862fd6-5708-4431-83dd-176ee081d33e

📥 Commits

Reviewing files that changed from the base of the PR and between 2679fda and 16d3baf.

📒 Files selected for processing (3)
  • unraid-ui/src/components/common/sheet/SheetContent.vue
  • unraid-ui/src/components/common/sheet/sheet.variants.ts
  • web/src/components/Notifications/Sidebar.vue
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/notification-drawer-animation

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

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@github-actions

Copy link
Copy Markdown
Contributor

🚀 Storybook has been deployed to staging: https://unraid-ui-storybook-staging.unraid-workers.workers.dev

@codecov

codecov Bot commented Jul 12, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 88.23529% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 52.78%. Comparing base (2679fda) to head (16d3baf).

Files with missing lines Patch % Lines
...id-ui/src/components/common/sheet/SheetContent.vue 0.00% 1 Missing ⚠️
...d-ui/src/components/common/sheet/sheet.variants.ts 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2038   +/-   ##
=======================================
  Coverage   52.77%   52.78%           
=======================================
  Files        1035     1035           
  Lines       72060    72073   +13     
  Branches     8303     8298    -5     
=======================================
+ Hits        38031    38044   +13     
  Misses      33903    33903           
  Partials      126      126           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions

Copy link
Copy Markdown
Contributor

This plugin has been deployed to Cloudflare R2 and is available for testing.
Download it at this URL:

https://preview.dl.unraid.net/unraid-api/tag/PR2038/dynamix.unraid.net.plg

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant