Repository navigation
fix(ui): grid, editor, connection and backup P1s - #856
Conversation
Keep the typed text for Port and the timeouts apart from the form, take the value only once it parses, flag out-of-range values inline, and disable Save and Test while a field is invalid. Fixes #813. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
saveProfile now rethrows, as connect does, so the form can stay open and show the error in the dialog instead of closing and losing what was typed. Fixes #792. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Delete Profile now asks first, naming the profile and saying its open tabs will disconnect. Saved profiles that are not connected get Edit, Duplicate and Delete on a right-click in the connect popover, and the Edit dialog footer offers Delete and Duplicate. Fixes #795. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Run resolved the selected connection while the editor tab's markers came from the tab's own, so a tab marked production could run on dev. Run now uses the tab's live connection, switching editor tabs selects its connection, clicking a connection tab moves to (or opens) one of its editor tabs, and connecting a new server opens a tab for it instead of re-pointing the open one. Fixes #788. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Run, Explain and Explain Analyze now read the SQL through one helper, sqlAtCursor, which Ctrl+Enter already used: the selection if there is one, otherwise the statement under the cursor. Explain no longer sends a two-statement buffer that the backend rejects. Fixes #846. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Cancelling a query now records how long it ran (cancelledAfterMs) instead of putting "Query cancelled by user" into the error slot, and clears the previous query's results so the status bar no longer shows its row count. The results pane says "Cancelled after 1.2 s" in neutral styling, the executing placeholder shows an elapsed-time counter, and the Run/Cancel button has a fixed width so the toolbar does not shift. Fixes #850. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Close, middle-click, Delete, Ctrl+W, Close Others and Close to the Right now go through editorStore.requestClose, which asks before discarding a query tab whose SQL was typed or edited. Empty and untouched tabs still close at once. The open-transaction indicator and the close warning for an open transaction need execute_query to report the session's transaction state, which the backend does not do yet; that part is left for a backend change. Part of #843 (the transaction part is still open). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The restore passed an empty statement list to the production guard, which waves through anything without a destructive statement, so the prompt never appeared. Ask regardless. Fixes #789. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
A cancelled or partly applied restore was shown in green with a check mark. Keep green for a clean full run only, word the heading by whether Stop on error was on, and key the error list by index so repeated errors do not collide. Fixes #793. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Starting a backup, restore or import unmounted or disabled the focused button, dropping focus to the page body where Escape did nothing and Tab walked the page behind. Move focus to Cancel (or the import's progress region) when a run starts, and have Modal answer Escape and Tab on the document when focus has fallen out of the topmost dialog. Fixes #798. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Closing Backup or Restore during a run hid the dialog and left the run going invisibly. While a run is active, the header X, Escape and the backdrop now ask "Cancel the backup/restore?" and cancel it on yes; the backdrop is ignored. Restore's footer Close is disabled mid-run, Import routes Escape and backdrop through its guarded handleClose, and both X buttons get an accessible name. Fixes #803. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The whole Backup and Restore panel scrolled, so the progress box pushed the footer and its Cancel button out of view on short windows. Make the panel a flex column with a scrolling body and fixed header and footer, as ImportDialog already does. Fixes #807. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
A cancelled backup dropped back to the plain form without a word; it now says the backup was cancelled and the partial file removed. The bar divided the 1-based current table by the total, so a one-table backup read 100% at once; it now counts finished tables whole and the current one by rows against the server's estimate. A "Starting…" status shows until the first progress event, and the unreachable button spinner is gone. Fixes #811. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The row handlers passed the row's position on screen, but the context menu, delete, Set NULL, copy and the row highlight look rows up by their index in the result. Pass row.index instead, and extend Shift ranges over the on-screen order. Fixes #839. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Grid saves resolved the target table from the editor's current text and the connection from the editor tab, so edits made after the editor moved on were written to another table or connection. Use the result's own statement and the connection, database and session it was read on, and refresh with that statement. Fixes #840. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The column definitions captured the editing state in inline cell renderers, so they were rebuilt on every render and flexRender treated each as a new component type. Every cell remounted after the first click of a double-click, so dblclick never fired. Render all cells through one stable GridCell component that reads the editing state from context. Fixes #841. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Virtual rows were positioned from the top of the container, whose first child is the one-row sticky header, so row 1 sat underneath it. Offset every virtual row by the header height. Fixes #847. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The input stored only values in 1-100,000 on every keystroke, so it could not be emptied and new digits were appended to the old value. Edit a local draft instead and store it on blur or Enter, clamping out of range numbers, reverting anything else, reverting on Escape, and showing the allowed range while the draft is invalid. Fixes #848. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Cancelling with no query in flight wiped the results on screen and showed "Cancelled after 0.0 s". Also retitle the Run button now that it runs the statement at the cursor. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
main.tsx imports Monaco by deep paths the test did not mock, so it loaded the whole editor into jsdom. That took most of the 10 s hook timeout and failed on slow runners (always in the cloud container, and now in CI). Mocked, the file runs in about a second. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
|
Test Frontend failed on 6fcfedd. All 3066 tests passed; the only failure was This isn't caused by this PR's changes, because 9670a7d mocks those deep paths. The file now runs in about a second, including in the container. I also removed the CLAUDE.md note that said it times out there. Generated by Claude Code |
Opening a SQLite file only changed the selected connection. Since Run follows the editor tab's own live connection (#788), it kept going to the tab's MySQL server while the toolbar showed the file. Opening a file now goes through the same attach path as a new connection. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
rowsExported is the total over every table so far, so from the second table on the bar treated the current table as full and the time left went blank. The dialog now notes where each table's rows began. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
- LIMIT box: 2.5 and 1e3 revert instead of truncating to 2 and 1. - Delete Profile: stop if its connection failed to close. - Restore: reset only when the dialog opens, so a selection change mid-run no longer hides Cancel. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
|
Fixes from a review of this PR:
The virtualized grid's context menu always using column 0, and Tab following result order in a sorted grid, are older bugs. They're tracked in #858. The full suite passes, now including Generated by Claude Code |
Explain now reads the statement at the cursor (#846) and Run follows the tab's live connection (#788). The fake editor had no getPosition and the connection store mock no activeConnections, so the browser test threw. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
The cloud container's Chromium is not the build Playwright expects, so the browser suite could not run there and its failures only showed in CI. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WTypK4RjzzdjoFxd3qk14g
This is the second batch of fixes from the UX review (#783). Each fix is its own commit with a regression test.
Fixes #839, fixes #840, fixes #841, fixes #847, fixes #848, fixes #846, fixes #850, fixes #788, fixes #792, fixes #795, fixes #813, fixes #789, fixes #793, fixes #798, fixes #803, fixes #807, fixes #811. Part of #843.
Results grid (two data-loss bugs in 1.3.0)
resultSource. It no longer uses the editor's current text. When there is no source, the save is refused with "Run the query again".GridCellreads the editing state from context, so a click no longer remounts the cells and double-click can open the editor.Query editor
Connections
+popover's right-click menu or from the Edit dialog.Backup, restore and import
Held back
The #842 fix (results per editor tab) was reviewed and has blocking bugs: grid edits carry across tabs, a DDL tab's result lands in the previous tab, and runs without a session are filed under the wrong tab. It will come in its own PR.
Other changes
git stash, because the stash list is shared across worktrees.Checks
tsc --noEmitis clean, and dprint is clean.main.test.tsx, which times out in this container: 154 files, 3066 tests.Generated by Claude Code