Rect utility returns wrong sizes in case of sequenced range #7838
Labels
package:engine
package:utils
squad:core
Issue to be handled by the Core team.
type:bug
This issue reports a buggy (incorrect) behavior.
Milestone
📝 Provide detailed reproduction steps (if any)
While working on #7705 I found out that there are cases when balloon panel being mispositioned, due to the fact that the
Rect
utility cares only for the first range's client rectangle (while it can contain multiple).Example repro case:
The [capital] city
The [capital city of
Malta
is the top destination this summer.]
✔️ Expected result
The balloon points to the middle of selection.
❌ Actual result
The balloon point to the beginning of the selection.
Reason is that it contains multiple boxes, the first of which (on chrome from my testing is often) 0px width, thus it points to the very beginning.
📃 Other details
If you'd like to see this fixed sooner, add a 👍 reaction to this post.
The text was updated successfully, but these errors were encountered: