Skip to content

fix(builder): allow Enter key to create new lines in Additional Info textareas (#763)#788

Open
Frankli9986 wants to merge 8 commits into
srbhr:mainfrom
Frankli9986:fix-763-textarea-enter-key
Open

fix(builder): allow Enter key to create new lines in Additional Info textareas (#763)#788
Frankli9986 wants to merge 8 commits into
srbhr:mainfrom
Frankli9986:fix-763-textarea-enter-key

Conversation

@Frankli9986
Copy link
Copy Markdown
Contributor

@Frankli9986 Frankli9986 commented May 5, 2026

Related Issue

#763

Description

Fixes a bug where pressing Enter in Additional Info textareas (Technical Skills, Languages, Certifications, Awards) would not create a new line. The root cause was handleArrayChange immediately filtering out empty strings with .filter((item) => item.trim() !== ''), which caused the textarea value to be overwritten on every input event — effectively undoing the Enter keystroke.

The fix removes the input-time filtering and moves it to the renderer level in all 4 resume templates, ensuring empty lines are preserved during editing while empty strings are filtered out when rendering the final resume.

Type

  • Bug Fix

Proposed Changes

  1. apps/frontend/components/builder/forms/additional-form.tsx

    • Removed .filter((item) => item.trim() !== '') from handleArrayChange
    • Empty lines are now preserved in the array during editing
  2. apps/frontend/components/resume/resume-single-column.tsx

    • Added .filter((s) => s.trim()) before .join(', ') for technicalSkills, languages, certificationsTraining, awards
  3. apps/frontend/components/resume/resume-modern.tsx

    • Same filter additions as resume-single-column.tsx
  4. apps/frontend/components/resume/resume-two-column.tsx

    • Added .filter((s) => s.trim()) before .map() / .join(' • ') for all 4 additional fields
  5. apps/frontend/components/resume/resume-modern-two-column.tsx

    • Same filter additions as resume-two-column.tsx

How to Test

  1. Open the resume builder and navigate to the Additional Info section
  2. Click on any textarea (e.g., Technical Skills)
  3. Type text and press Enter — a new line should be created
  4. Continue typing the next item on the new line
  5. Preview the resume — no empty items should appear
  6. Test with all 4 fields: Technical Skills, Languages, Certifications, Awards

Checklist

  • The code compiles successfully without any errors or warnings
  • The changes follow the project's coding guidelines and best practices
  • The commit messages are descriptive and follow the project's guidelines
  • This pull request has been linked to the related issue

Summary by cubic

Adds groq as a supported LLM provider and fixes Enter key handling in Additional Info textareas so new lines work. Fixes #763.

  • New Features

    • Added groq provider across backend and frontend (config, API key management, settings UI).
    • Default groq model set to llama-3.3-70b-versatile.
  • Bug Fixes

    • Preserved newlines by removing input-time filtering; now filter empty/whitespace-only strings at render for technicalSkills, languages, certificationsTraining, awards, and in section visibility checks (single- and two-column).
    • Restored deepseek 1.3x timeout multiplier.

Written for commit 44640df. Summary will update on new commits.

Add Groq as a supported LLM provider across the full stack.

Backend:
- config.py: add groq to llm_provider Literal and provider_map
- llm.py: add groq/ prefix mapping, known prefix, key map, and timeout factor
- routers/config.py: add groq to SUPPORTED_PROVIDERS and API key update handler
- schemas/models.py: add groq field to ApiKeysUpdateRequest

Frontend:
- lib/api/config.ts: add groq to LLMProvider, PROVIDER_INFO, ApiKeyProvider,
  ApiKeysUpdateRequest, and API_KEY_PROVIDER_INFO
- settings/page.tsx: add groq to PROVIDERS array
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3 issues found across 11 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="apps/frontend/components/resume/resume-two-column.tsx">

<violation number="1" location="apps/frontend/components/resume/resume-two-column.tsx:422">
P2: Section visibility checks use unfiltered array length, so whitespace-only additional fields can render empty sections with a title but no content</violation>
</file>

<file name="apps/frontend/components/resume/resume-single-column.tsx">

<violation number="1" location="apps/frontend/components/resume/resume-single-column.tsx:397">
P2: Whitespace-only additional items can still pass the raw length checks, so the section/rows render even though the joined display text is empty.</violation>
</file>

<file name="apps/backend/app/llm.py">

<violation number="1" location="apps/backend/app/llm.py:920">
P2: Removing DeepSeek's timeout multiplier regresses a supported provider by lowering its timeout budget from 1.3x to the default 1.0x, which can cause avoidable request timeouts.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Comment thread apps/frontend/components/resume/resume-two-column.tsx
Comment thread apps/frontend/components/resume/resume-single-column.tsx Outdated
Comment thread apps/backend/app/llm.py
- Filter whitespace-only items in section visibility checks (two-column & single-column)

- Restore deepseek 1.3x timeout multiplier in llm.py
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Enter key doesn't create new lines in Additional Info textareas

1 participant