Skip to content

fix(code): restore zoom after task navigation#3816

Merged
charlesvien merged 1 commit into
mainfrom
posthog-code/fix-zoom-restoration
Jul 26, 2026
Merged

fix(code): restore zoom after task navigation#3816
charlesvien merged 1 commit into
mainfrom
posthog-code/fix-zoom-restoration

Conversation

@richardsolomou

Copy link
Copy Markdown
Member

Problem

Chromium keeps zoom levels for individual hash routes. Switching tasks can render a cached base zoom while Electron still reports the expected global level, so the existing restoration skips the update.

Changes

I restore the in-memory zoom after in-page navigation and always reapply it when restoration runs. There are no UI layout changes.

How did you test this?

  • Added regression coverage for task navigation and stale reported zoom state (16 focused tests pass).
  • Ran the full workspace typecheck and Biome checks.
  • Reproduced the failure in a packaged app with conflicting Chromium Preferences, then verified the fix across 10 native resize and task-switch cycles.

Automatic notifications

  • Publish to changelog?
  • Alert Sales and Marketing teams?

Created with PostHog Code

Chromium can render a cached per-route zoom while reporting the expected Electron zoom level. Reapply the in-memory level after in-page navigation so task switches cannot retain that stale visual scale.

Generated-By: PostHog Code
Task-Id: ae89d6b6-8dc2-4400-b081-8da780930094
@trunk-io

trunk-io Bot commented Jul 25, 2026

Copy link
Copy Markdown

😎 This pull request was merged.

@github-actions

Copy link
Copy Markdown

React Doctor found no issues in the changed files. 🎉

Reviewed by React Doctor for commit 1e406f0.

@greptile-apps

greptile-apps Bot commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Reviews (1): Last reviewed commit: "fix(code): restore zoom after task navig..." | Re-trigger Greptile

@richardsolomou
richardsolomou requested a review from a team July 26, 2026 03:15
@charlesvien
charlesvien merged commit be4d1dc into main Jul 26, 2026
31 of 32 checks passed
@charlesvien
charlesvien deleted the posthog-code/fix-zoom-restoration branch July 26, 2026 04:56
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.

2 participants