Skip to content

Commit 9a0add4

Browse files
committed
fix(tui): allow commands when filter text exists but input not focused
1 parent 6285fa2 commit 9a0add4

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

packages/awsesh/src/cli/cmd/tui/ui/filterable-list.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,11 +141,11 @@ export function FilterableList<T>(props: FilterableListProps<T>) {
141141

142142
let commandsSuspended = false
143143
createEffect(() => {
144-
const hasFilter = store.filter.length > 0
145-
if (hasFilter && !commandsSuspended) {
144+
const shouldSuspend = store.filterActive
145+
if (shouldSuspend && !commandsSuspended) {
146146
command.suspend(true)
147147
commandsSuspended = true
148-
} else if (!hasFilter && commandsSuspended) {
148+
} else if (!shouldSuspend && commandsSuspended) {
149149
command.suspend(false)
150150
commandsSuspended = false
151151
}

0 commit comments

Comments
 (0)