mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-12-08 06:09:58 +00:00
LibWeb: Add a FIXME comment about multiple DOM nodes in arrow navigation
This commit is contained in:
parent
80412d1ea5
commit
f529a4d98e
Notes:
github-actions[bot]
2025-09-18 11:40:35 +00:00
Author: https://github.com/trflynn89
Commit: f529a4d98e
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5956
Reviewed-by: https://github.com/gmta
1 changed files with 4 additions and 0 deletions
|
|
@ -565,6 +565,10 @@ GC::Ptr<DOM::Position> Selection::cursor_position() const
|
|||
return DOM::Position::create(m_document->realm(), *m_range->start_container(), m_range->start_offset());
|
||||
}
|
||||
|
||||
// FIXME: The offset adjustment algorithms below do not handle moving over multiple DOM nodes. For example, if we have:
|
||||
// `<div contenteditable><p>Well hello</p><p>friends</p></div>`, we should be able to move the cursor between the
|
||||
// two <p> elements. But the algorithms below limit us to a single DOM node.
|
||||
|
||||
void Selection::move_offset_to_next_character(bool collapse_selection)
|
||||
{
|
||||
auto* text_node = as_if<DOM::Text>(anchor_node().ptr());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue