feat: Cmd+K Enter applies full-text search to dashboard
All checks were successful
CI / cleanup-branch (push) Has been skipped
CI / build (push) Successful in 1m47s
CI / docker (push) Successful in 1m16s
CI / deploy-feature (push) Has been skipped
CI / deploy (push) Successful in 36s

When pressing Enter in the command palette without explicitly selecting
a result (via arrow keys or mouse), the search query is now applied as
a server-side full-text filter on the Dashboard table. Explicit
selection still navigates to the exchange. Updates design system to
v0.1.18 for the new onSubmit prop.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-03-27 23:33:39 +01:00
parent 004574d442
commit 1702200a60
5 changed files with 61 additions and 11 deletions

View File

@@ -199,6 +199,14 @@ function LayoutContent() {
setPaletteOpen(false);
}, [navigate, setPaletteOpen]);
const handlePaletteSubmit = useCallback((query: string) => {
// Navigate to dashboard with full-text search applied
const currentPath = location.pathname;
// Stay on the current app/route context if we're already there
const basePath = currentPath.startsWith('/apps/') ? currentPath.split('/').slice(0, 4).join('/') : '/apps';
navigate(`${basePath}?text=${encodeURIComponent(query)}`);
}, [navigate, location.pathname]);
return (
<AppShell
sidebar={
@@ -217,6 +225,7 @@ function LayoutContent() {
onClose={() => setPaletteOpen(false)}
onOpen={() => setPaletteOpen(true)}
onSelect={handlePaletteSelect}
onSubmit={handlePaletteSubmit}
onQueryChange={setPaletteQuery}
data={searchData}
/>