Skip to content

feat(settings): add editor font controls#2877

Open
rasitakyol wants to merge 1 commit into
generalaction:mainfrom
rasitakyol:agent/editor-font-settings
Open

feat(settings): add editor font controls#2877
rasitakyol wants to merge 1 commit into
generalaction:mainfrom
rasitakyol:agent/editor-font-settings

Conversation

@rasitakyol

@rasitakyol rasitakyol commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Description

Add persistent font family and font size controls for Monaco-backed text previews and diffs.

  • Adds an independent editor app setting with the current 13px behavior as its default.
  • Reuses the terminal font picker and size controls without coupling terminal and editor preferences.
  • Applies changes live to existing code editor and diff editor instances, restoring Monaco's captured default font when reset.
  • Stores the setting in the existing key-value settings table, so no database migration is required.

This is functionally independent from #2876/#2807, but the branches overlap in four small editor/settings files. I verified the combined result in a temporary integration worktree; whichever PR lands second will need a small rebase. If #2876 lands first, resetting the preference will use its updated Monaco default stack.

Related issues

Fixes #2818.

Testing

  • pnpm exec vitest run --project node src/main/core/settings/editor-settings.test.ts src/renderer/tests/editor-config.test.ts src/renderer/features/settings/components/font-settings-cards.test.ts src/renderer/tests/editor-font-live-update.test.ts (12/12)
  • pnpm run lint
  • pnpm run format:check
  • pnpm run typecheck
  • pnpm run build:renderer
  • Combined feat(ui): modernize monospaced typography #2876 + feat(settings): add editor font controls #2877 integration: 19 focused tests, desktop lint/typecheck/format, and full workspace build passed.
  • Broader desktop node suite: one unrelated IssueSelector canvas timeout under concurrent load; the failing test passed when rerun in isolation.
  • git diff --check

Screenshot/Recording (if applicable)

Not included. The settings interactions and live Monaco updates are covered by mounted component tests.

Checklist
  • I kept this PR small and focused
  • I ran a self-review before opening this PR
  • I ran the relevant local checks or explained why not
  • I updated docs when behavior or setup changed, or docs were not needed
  • I added or updated tests when behavior changed, or explained why not
  • I only added comments where the logic is not obvious
  • I used Conventional Commits for commit messages and, when possible, the PR title

@rasitakyol
rasitakyol marked this pull request as ready for review July 15, 2026 14:37
@greptile-apps

greptile-apps Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR adds persistent font controls for Monaco-backed editors. The main changes are:

  • Adds independent editor font-family and font-size settings.
  • Applies settings live to mounted code and diff editors.
  • Extracts shared font controls for terminal and editor settings.
  • Adds focused persistence, UI, and live-update tests.

Confidence Score: 5/5

This looks safe to merge.

  • No blocking issues found in the changed code.

Important Files Changed

Filename Overview
apps/emdash-desktop/src/main/core/settings/schema.ts Adds validation and registration for the editor typography setting.
apps/emdash-desktop/src/main/core/settings/settings-registry.ts Adds the default editor font size to the settings registry.
apps/emdash-desktop/src/renderer/features/settings/components/FontSettingsRows.tsx Extracts reusable font-family and font-size setting controls.
apps/emdash-desktop/src/renderer/features/settings/components/EditorSettingsCard.tsx Adds independent editor font controls with normalization and size bounds.
apps/emdash-desktop/src/renderer/features/tasks/editor/editor-provider.tsx Applies editor typography settings to mounted Monaco code editors.
apps/emdash-desktop/src/renderer/lib/monaco/sticky-diff-editor.tsx Applies editor typography settings to mounted Monaco diff editors.
apps/emdash-desktop/src/renderer/lib/monaco/editor-font-settings.ts Centralizes Monaco font option construction and default restoration.

Reviews (1): Last reviewed commit: "feat(settings): add editor font controls" | Re-trigger Greptile

@arnestrickmann

Copy link
Copy Markdown
Contributor

@rasitakyol, thanks for opening the PR -

We’ll review it soon and follow up with feedback here.

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.

[feat]: Customizable text file preview font family and size

2 participants