LibWeb: Fix tofu in textarea newlines on MacOS

Do not insert the codepoint from the platform event. Always insert 10
This commit is contained in:
Jonathan Gamble
2025-12-23 19:36:14 -06:00
committed by Shannon Booth
parent 2a8b83a568
commit e39f73f978
Notes: github-actions[bot] 2025-12-29 19:00:57 +00:00
2 changed files with 8 additions and 0 deletions

View File

@@ -437,6 +437,12 @@ void HTMLTextAreaElement::did_edit_text_node()
update_placeholder_visibility();
}
EventResult HTMLTextAreaElement::handle_return_key(FlyString const&)
{
handle_insert(Utf16String::from_code_point(0x0A)); // Avoid the platform codepoint
return EventResult::Handled;
}
void HTMLTextAreaElement::queue_firing_input_event()
{
queue_an_element_task(HTML::Task::Source::UserInteraction, [this]() {