diff --git a/frontend/src/components/QueryInput.tsx b/frontend/src/components/QueryInput.tsx index b26ebf0..c8d770c 100644 --- a/frontend/src/components/QueryInput.tsx +++ b/frontend/src/components/QueryInput.tsx @@ -49,7 +49,7 @@ export const QueryInput: React.FC = ({ onSubmit, onHalfQuestion } } - const isDisabled = isLoading || displayValue.trim() === '' || (!hasUserInput && !!partialText) + const isDisabled = isLoading || displayValue.trim() === '' const textareaClassName = [ 'w-full rounded border border-gray-300 px-3 py-2 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent disabled:bg-gray-100 disabled:cursor-not-allowed', diff --git a/frontend/src/test/test_phase2_QueryInput_integration.test.tsx b/frontend/src/test/test_phase2_QueryInput_integration.test.tsx index 185f4c9..3f1f84c 100644 --- a/frontend/src/test/test_phase2_QueryInput_integration.test.tsx +++ b/frontend/src/test/test_phase2_QueryInput_integration.test.tsx @@ -151,9 +151,9 @@ describe('QueryInput with partialText (Phase 2.4)', () => { const textarea = screen.getByPlaceholderText('Ask a question about your documents...') const button = screen.getByRole('button', { name: /submit/i }) - // partialText is shown but user hasn't typed, button should be disabled - // (partial text is not a real user input — it's just display) - expect(button).toBeDisabled() + // partialText is shown and user hasn't typed — button should be enabled + // (users can now submit during interim ASR text) + expect(button).toBeEnabled() }) it('test_user_can_submit_after_typing_over_partialText', () => {