Repository navigation
Conversation
Contributor
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #46636 +/- ##
=======================================
Coverage 86.42% 86.42%
=======================================
Files 3183 3186 +3
Lines 222605 222648 +43
Branches 52996 53006 +10
=======================================
+ Hits 192377 192418 +41
- Misses 26758 26760 +2
Partials 3470 3470
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Add a "Font size" control to the SQL Lab toolbar that increases,
decreases, or resets the SQL editor font size.
- The size defaults to 12px, moves in steps of 2, and is clamped to 8-32px.
The +/- buttons disable at the limits.
- The choice is persisted in localStorage (sqllab__editor_font_size) and
shared by every open query tab through a small useSyncExternalStore hook,
so changing it in one tab updates all of them.
- Add an optional `fontSize` prop to the editor `EditorProps` contract in
@apache-superset/core and apply it in AceEditorProvider, so editors
contributed by extensions can honor it as well.
- The control reuses existing translatable strings ("Font size",
"Increase", "Decrease", "Reset"), so no new messages.pot entries are
needed.
Includes Jest tests for the control and the hook, and a Playwright spec
covering resize, reset, clamping, and persistence across reload.
pdhdol
force-pushed
the
feat/sqllab-editor-font-size
branch
from
November 29, 2026 14:16
afdb9ec to
d8e6770
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SUMMARY
Adds an adjustable font size to the SQL Lab editor, as an accessibility improvement. A new Text size control in the SQL Lab toolbar (next to the share link) lets users make the editor text larger or smaller, or reset it.
localStorage(sqllab__editor_font_size, registered inLocalStorageKeys) and shared by every open query tab through a smalluseSyncExternalStorehook, so changing it in one tab updates all of them.fontSizeprop to theEditorPropscontract in@apache-superset/coreand applies it inAceEditorProvider. Because the SQL editor can be replaced by an extension, editors contributed that way can honor the setting too.The state lives in a hook rather than the Redux store, so the reducers stay free of
localStorageside effects. This matches how other SQL Lab preferences (autocomplete, render HTML) are stored.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Default (12px):
After three clicks on + (18px):
TESTING INSTRUCTIONS
+and−. The editor font grows or shrinks by 2px per click, and the number between the buttons updates.−until it reaches 8, and+until it reaches 32. The matching button should disable at each limit.Automated:
npx jest src/SqlLab/components/TextSizeEditor src/SqlLab/components/EditorWrapper src/core/editors(new tests for the control and the hook).playwright/tests/sqllab/editor-font-size.spec.tscovers resize, reset, clamping, and persistence across reload.ADDITIONAL INFORMATION