Skip to content

Fix Ghost Focus Dead Zone Between Rubric Feedback Text Boxes#2101

Draft
Copilot wants to merge 2 commits intomainfrom
copilot/fix-ghost-focus-area
Draft

Fix Ghost Focus Dead Zone Between Rubric Feedback Text Boxes#2101
Copilot wants to merge 2 commits intomainfrom
copilot/fix-ghost-focus-area

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 22, 2026

Clicking in the margin between the "Great Job" and "Think About" feedback text boxes caused the cursor to enter an unrecoverable ghost-focused state where no input was possible.

Root Cause

A CSS specificity conflict between two MUI sx props silently zeroed out TableCell padding, while TextField retained an 8px p: 1 wrapper padding — creating a dead zone on each side of every input.

  • TableRow sx: '& .MuiTableCell-root': { padding: '0px' } — specificity (0,2,0), overrides TableCell's own padding: '0.75em' at (0,1,0)
  • TextField sx: p: 1 — 8px on the FormControl wrapper (not the <textarea>)
  • Net result: ~17px unclickable gap (8px + 1px border + 8px) where clicks land on a non-focusable div

Changes

  • apps/frontend & apps/portalfeedback-row.tsx:
    • Removed padding: '0px' from TableRow's nested '& .MuiTableCell-root' selector, allowing TableCell's padding: '0.75em' to apply correctly
    • Removed p: 1 from TextField's sx, eliminating the dead-zone wrapper padding
- '& .MuiTableCell-root': {
-   padding: '0px',
-   '&:first-of-type': { borderRadius: '0 0 0 12px' },
+ '& .MuiTableCell-root': {
+   '&:first-of-type': { borderRadius: '0 0 0 12px' },

- sx={{
-   p: 1,
-   borderRadius: '12px',
+ sx={{
+   borderRadius: '12px',

The TableCell now correctly provides 0.75em spacing; TextField fills the padded area with no dead zones. Border-radius styles on the row are preserved.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Screenshots

Ghost focus reproduction

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • My changes generate no new warnings

…xt boxes

Agent-Logs-Url: https://github.com/FIRSTIsrael/lems/sessions/f5a6d226-47bd-41eb-a97e-9dc76e75a9d4

Co-authored-by: johnmeshulam <55348702+johnmeshulam@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix ghost focus area between feedback text boxes Fix Ghost Focus Dead Zone Between Rubric Feedback Text Boxes Apr 22, 2026
Copilot AI requested a review from johnmeshulam April 22, 2026 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

Fix Ghost Focus Area Between Feedback Text Boxes

2 participants