Skip to content

[P1/bug] FormatterSettingsDialog doesn't show live preview of new format #355

Closed

Description

@EVWorth

Context

FormatterSettingsDialog.tsx:148-159 (the SQL preview shows the editor's current content, not the formatted result).

Problem

The settings dialog has a SQL preview label but the preview is just the editor's current content, not formatted with the NEW settings. The user can change settings, click Save, then realize the new settings produce ugly output and have to undo. A live preview affordance is the standard expectation for a settings dialog of this kind.

Files

  • src/components/editor/FormatterSettingsDialog.tsx:148-159

Expected

Changing the "Keyword case" from UPPER to lower in the dialog instantly updates the preview to show lowercase SQL; clicking Save applies the same settings to the editor's Format button.

Proposed fix

Scope M — add a

 showing the editor content formatted with the NEW settings (not the saved ones); update on every change. The postProcessSQL utility and sql-formatter library are the formatter engines.

Acceptance

Changing the "Keyword case" from UPPER to lower in the dialog instantly updates the preview to show lowercase SQL; clicking Save applies the same settings to the editor's Format button.

Needs human verify

no

Activity

  1. added
    audit
    severity/p1
    kind/bug
    area/theming
    on Jul 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/themingauditkind/bugseverity/p1

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions