소스 검색

tui: prevent default Enter key behavior when selecting dialog options to avoid conflicts

Dax Raad 3 달 전
부모
커밋
bfbcb5f200
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      packages/opencode/src/cli/cmd/tui/ui/dialog-select.tsx

+ 1 - 0
packages/opencode/src/cli/cmd/tui/ui/dialog-select.tsx

@@ -130,6 +130,7 @@ export function DialogSelect<T>(props: DialogSelectProps<T>) {
     if (evt.name === "return") {
       const option = selected()
       if (option) {
+        evt.preventDefault()
         if (option.onSelect) option.onSelect(dialog)
         props.onSelect?.(option)
       }