feat(editor):add configurable shortcut to force IntelliSense suggestions#371
Conversation
…o suggestion widget, complementing the existing automatic completion
…toradd_configurable_shortcut_to_force_suggestions
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Files Reviewed (12 files)
Previous Review Summaries (3 snapshots, latest commit f866ae9)Current summary above is authoritative. Previous snapshots are kept for context only. Previous review (commit f866ae9)Status: No Issues Found | Recommendation: Merge Files Reviewed (12 files)
Previous review (commit 7dee78f)Status: No Issues Found | Recommendation: Merge Files Reviewed (12 files)
Previous review (commit 768449f)Status: No Issues Found | Recommendation: Merge Files Reviewed (11 files)
Reviewed by nemotron-nano-9b-v2:free · Input: 77.5K · Output: 2K · Cached: 2.2K |
…table` keybinding
…toradd_configurable_shortcut_to_force_suggestions
…ns' of github.com:GabrielMalava/tabularis into feat/editoradd_configurable_shortcut_to_force_suggestions
|
Hi @GabrielMalava , |
|
Hi @debba , I had closed the PR because I thought you didn’t like the implementation, but I’ve reopened it now. |
|
No sorry, tbh I didn't check it for now . |
…oradd_configurable_shortcut_to_force_suggestions
…ns' of github.com:GabrielMalava/tabularis into feat/editoradd_configurable_shortcut_to_force_suggestions
…toradd_configurable_shortcut_to_force_suggestions
There was a problem hiding this comment.
Pull request overview
Adds new keyboard shortcuts to improve SQL editor/table workflows by integrating with Tabularis’s existing keybindings system (including user overrides) and surfacing the labels in i18n.
Changes:
- Add
trigger_suggestionskeybinding (default ⌘+I / Ctrl+Space) and wire it into Monaco-based SQL editors to force-open IntelliSense suggestions. - Add
refresh_tablekeybinding (default ⌘/Ctrl+R) and wire it into the Editor page to re-run the current tab query when a table is active. - Add localized shortcut labels across all supported locales.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/components/ui/SqlEditorWrapper.test.tsx | Mocks useKeybindings so tests don’t crash after SqlEditorWrapper starts consuming keybindings context. |
| src/pages/Editor.tsx | Handles the new refresh_table shortcut and triggers a refresh via runQuery. |
| src/components/ui/SqlEditorWrapper.tsx | Adds trigger_suggestions handling inside Monaco’s keydown to force the suggest widget. |
| src/config/shortcuts.json | Defines refresh_table and trigger_suggestions shortcut definitions (defaults + match rules + i18n keys). |
| src/i18n/locales/en.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/de.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/es.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/fr.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/it.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/ja.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/ru.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
| src/i18n/locales/zh.json | Adds shortcut label strings for triggerSuggestions and refreshTable. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| // Force the suggestion widget via the user-configurable shortcut | ||
| editor.onKeyDown((e) => { | ||
| if (matchesShortcutRef.current(e.browserEvent, "trigger_suggestions")) { | ||
| e.preventDefault(); | ||
| e.stopPropagation(); | ||
| editor.trigger("keyboard", "editor.action.triggerSuggest", {}); | ||
| } | ||
| }); |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
…toradd_configurable_shortcut_to_force_suggestions
…ns' of github.com:GabrielMalava/tabularis into feat/editoradd_configurable_shortcut_to_force_suggestions
Adds a configurable keyboard shortcut to force database suggestions in the SQL editor, like SQL Server's IntelliSense trigger. Autocomplete already appears automatically, but there was no way to manually re-open the suggestion widget when it didn't show up this adds that.
The shortcut defaults to ⌘+I on macOS (Ctrl+Space on Linux, avoided on macOS since the system reserves it) and can be remapped from Settings → Keyboard Shortcuts → Editor. It works in both the main editor and notebook cells, wired through the existing keybindings system so user overrides are respected.
-Add configurable shortcut to reload the current table a
refresh_tablekeybinding