From e4ec20a524a71a5fdc0cb7bf9520e6b0e79af591 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Fri, 1 May 2026 01:11:18 +0000 Subject: [PATCH 1/3] fix: expand Lucene search input on focus to show full query Long Lucene filter queries were truncated in the default (unfocused) view with no way to expand or see the full expression. This change makes the Lucene input behave consistently with the SQL WHERE input: - Unfocused: single-line display with fade gradient indicating overflow - Focused: expands to show full query with text wrapping (up to 150px, then scrollable) Changes: - Remove maxRows cap when focused (was 4, now unlimited via CSS max-height) - Add max-height: 150px and overflow-y: auto on focused textarea - Keep single-line collapsed state with overflow: hidden when unfocused Fixes HDX-4134 Co-authored-by: Mike Shi --- .../src/components/SearchInput/AutocompleteInput.module.scss | 5 +++++ .../app/src/components/SearchInput/AutocompleteInput.tsx | 2 +- .../src/components/SearchInput/SearchWhereInput.module.scss | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/packages/app/src/components/SearchInput/AutocompleteInput.module.scss b/packages/app/src/components/SearchInput/AutocompleteInput.module.scss index 409b36e7e7..9969851d5a 100644 --- a/packages/app/src/components/SearchInput/AutocompleteInput.module.scss +++ b/packages/app/src/components/SearchInput/AutocompleteInput.module.scss @@ -26,6 +26,11 @@ z-index: 100; box-shadow: var(--mb-shadow, var(--mantine-shadow-xs)); border-bottom: 2px solid var(--color-bg-brand) !important; + + textarea { + max-height: 150px; + overflow-y: auto !important; + } } /* Fade at the bottom when collapsed (single-line, not focused); applied to textarea */ diff --git a/packages/app/src/components/SearchInput/AutocompleteInput.tsx b/packages/app/src/components/SearchInput/AutocompleteInput.tsx index 906937cdeb..26ed34cb36 100644 --- a/packages/app/src/components/SearchInput/AutocompleteInput.tsx +++ b/packages/app/src/components/SearchInput/AutocompleteInput.tsx @@ -173,7 +173,7 @@ export default function AutocompleteInput({ size={size} autosize minRows={1} - maxRows={isSearchInputFocused ? 4 : 1} + maxRows={isSearchInputFocused ? undefined : 1} data-testid={dataTestId} onChange={e => onChange(e.target.value)} onFocus={() => { diff --git a/packages/app/src/components/SearchInput/SearchWhereInput.module.scss b/packages/app/src/components/SearchInput/SearchWhereInput.module.scss index a2d3d2d849..128ac0b6fc 100644 --- a/packages/app/src/components/SearchInput/SearchWhereInput.module.scss +++ b/packages/app/src/components/SearchInput/SearchWhereInput.module.scss @@ -51,7 +51,7 @@ border-radius: 0 var(--mantine-radius-default) var(--mantine-radius-default) 0; - /* Prevent scrollbar when placeholder text wraps in narrow containers (maxRows=1 when unfocused) */ + /* Prevent scrollbar in collapsed (single-line) state; focused state overrides via AutocompleteInput styles */ overflow: hidden; } } From 2a1e0ea733489218712219dca4e7f32b224665e1 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Fri, 1 May 2026 02:27:15 +0000 Subject: [PATCH 2/3] Revert "fix: expand Lucene search input on focus to show full query" This reverts commit e4ec20a524a71a5fdc0cb7bf9520e6b0e79af591. --- .../src/components/SearchInput/AutocompleteInput.module.scss | 5 ----- .../app/src/components/SearchInput/AutocompleteInput.tsx | 2 +- .../src/components/SearchInput/SearchWhereInput.module.scss | 2 +- 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/packages/app/src/components/SearchInput/AutocompleteInput.module.scss b/packages/app/src/components/SearchInput/AutocompleteInput.module.scss index 9969851d5a..409b36e7e7 100644 --- a/packages/app/src/components/SearchInput/AutocompleteInput.module.scss +++ b/packages/app/src/components/SearchInput/AutocompleteInput.module.scss @@ -26,11 +26,6 @@ z-index: 100; box-shadow: var(--mb-shadow, var(--mantine-shadow-xs)); border-bottom: 2px solid var(--color-bg-brand) !important; - - textarea { - max-height: 150px; - overflow-y: auto !important; - } } /* Fade at the bottom when collapsed (single-line, not focused); applied to textarea */ diff --git a/packages/app/src/components/SearchInput/AutocompleteInput.tsx b/packages/app/src/components/SearchInput/AutocompleteInput.tsx index 26ed34cb36..906937cdeb 100644 --- a/packages/app/src/components/SearchInput/AutocompleteInput.tsx +++ b/packages/app/src/components/SearchInput/AutocompleteInput.tsx @@ -173,7 +173,7 @@ export default function AutocompleteInput({ size={size} autosize minRows={1} - maxRows={isSearchInputFocused ? undefined : 1} + maxRows={isSearchInputFocused ? 4 : 1} data-testid={dataTestId} onChange={e => onChange(e.target.value)} onFocus={() => { diff --git a/packages/app/src/components/SearchInput/SearchWhereInput.module.scss b/packages/app/src/components/SearchInput/SearchWhereInput.module.scss index 128ac0b6fc..a2d3d2d849 100644 --- a/packages/app/src/components/SearchInput/SearchWhereInput.module.scss +++ b/packages/app/src/components/SearchInput/SearchWhereInput.module.scss @@ -51,7 +51,7 @@ border-radius: 0 var(--mantine-radius-default) var(--mantine-radius-default) 0; - /* Prevent scrollbar in collapsed (single-line) state; focused state overrides via AutocompleteInput styles */ + /* Prevent scrollbar when placeholder text wraps in narrow containers (maxRows=1 when unfocused) */ overflow: hidden; } } From 87e136fc83cd61e3d812fbd6a924cc56377232b5 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Fri, 1 May 2026 02:31:17 +0000 Subject: [PATCH 3/3] fix: use character-level word breaking in Lucene search input Long Lucene filter queries with long attribute values (e.g. key:[really_long_attribute_name]) were wrapping at word boundaries, causing the key to appear on a separate line from its value: key: [really_long_attribute] With word-break: break-all, text now breaks at character boundaries, keeping the key and value together on the same line: key: [really_long_at tribute] This ensures text is packed as tightly as possible on each line, making long queries more readable regardless of whether they contain spaces. Fixes HDX-4134 Co-authored-by: Mike Shi --- .../app/src/components/SearchInput/AutocompleteInput.module.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/app/src/components/SearchInput/AutocompleteInput.module.scss b/packages/app/src/components/SearchInput/AutocompleteInput.module.scss index 409b36e7e7..3539687b8f 100644 --- a/packages/app/src/components/SearchInput/AutocompleteInput.module.scss +++ b/packages/app/src/components/SearchInput/AutocompleteInput.module.scss @@ -12,6 +12,7 @@ textarea { border: none !important; + word-break: break-all; } textarea::placeholder {