yangzhang75 opened a new issue, #8497:
URL: https://github.com/apache/texera/issues/8497

   ### Symptom
   
   On the Form View, a rebuild of the input cards that arrives while the focus 
is in a form control is silently discarded. Two paths reach it:
   
   - Compilation finishes while a reader is typing in a card: the schema 
refresh (for example the column names an attribute dropdown offers) never lands 
until the next compile or a reload.
   - With #8455's edit mode, ticking a property in the step panel to expose it: 
the tick box is an `<input type="checkbox">` inside the page, so it has the 
focus at the moment the change fires, the rebuild is dropped, and the card only 
appears after some unrelated rebuild or a refresh. Unticking behaves the same 
way.
   
   ### Root cause
   
   `isTypingInTheForm()` (from #8437) counts any focused `INPUT` inside the 
page as typing, tick boxes included, and both subscribers 
(`getCompilationStateInfoChangedStream`, `formBindingChanged$`) `return` when 
it says so. The emission is gone; nothing runs it later.
   
   ### Fix
   
   - A tick box, radio or button is not typing: only text-like inputs, 
textareas, selects and content-editables are.
   - A rebuild that arrives while typing is held, not dropped, and runs once 
the focus leaves the text control (`focusout` on the host, decided a tick later 
so tabbing to the next text field keeps it held).
   - Tests: a focused tick box is not typing; a held rebuild runs once on 
focusout for both streams; it stays held when the focus only moves to another 
text field; a focusout with nothing held rebuilds nothing.
   
   Found while verifying #8455 on a flag-on instance (parent #8011); confirmed 
in a headless browser (tick box click changes the card count within a second 
after the fix). #8455 carries the same change so it stays self-contained; 
whichever merges first, the other rebases and the duplicate hunk disappears.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to