Skip to content

fix: use CSS zoom for UI scaling to avoid terminal selection offsets#217

Closed
Dimillian wants to merge 2 commits intomainfrom
codex/github-mention-cannot-highlight-text-in-terminal
Closed

fix: use CSS zoom for UI scaling to avoid terminal selection offsets#217
Dimillian wants to merge 2 commits intomainfrom
codex/github-mention-cannot-highlight-text-in-terminal

Conversation

@Dimillian
Copy link
Copy Markdown
Owner

Motivation

  • The terminal selection and cursor coordinates drift when the app UI is scaled via transform: scale(...), so the UI scale should avoid transforming the coordinate system used by canvas-like components (e.g., xterm.js).

Description

  • Replaced the transform-based scaling on the root .app with zoom: var(--ui-scale, 1) in src/styles/base.css while keeping the existing size compensation via height/width calculations.
  • Added an @supports not (zoom: 1) fallback that restores the previous transform: scale(...) behavior for engines that do not support zoom so older/unsupported runtimes remain functional.
  • Updated the .app.ui-scale-default case to use zoom: 1 (and transform: none in the fallback) so default scale removes any scaling.

Testing

  • Ran npm run lint (ESLint) which completed successfully.
  • Ran npm run typecheck (tsc --noEmit) which completed successfully.

Codex Task

@Dimillian Dimillian changed the title Use CSS zoom for UI scaling to avoid terminal selection offsets fix: use CSS zoom for UI scaling to avoid terminal selection offsets Jan 23, 2026
@Dimillian
Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Swish!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@Dimillian Dimillian closed this Jan 23, 2026
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.

1 participant