You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TextPosition globalToLocalPosition(TextPosition position) {
assert(container.containsOffset(position.offset),
'The provided text position is not in the current node');
return TextPosition(
offset: position.offset - container.documentOffset,
affinity: position.affinity,
);
}
When adding print( 'position.offset=${position.offset}, container.containsOffset(position.offset)=${container.containsOffset(position.offset)}'); before assert it prints
Is there an existing issue for this?
Flutter Quill version
master
Steps to reproduce
Expected results
No assertion failures.
Actual results
The following assertion fails:
When adding
print( 'position.offset=${position.offset}, container.containsOffset(position.offset)=${container.containsOffset(position.offset)}');
beforeassert
it printsposition.offset=4, container.containsOffset(position.offset)=true
several times after Undo was pressed but then for some reason it prints
position.offset=5, container.containsOffset(position.offset)=false
and then the assert statement fails.
Code sample
Code sample
[Paste your code here]
Screenshots or Video
Assert.swipe.typing.undo.webm
Logs
Logs
[Paste your logs here]
The text was updated successfully, but these errors were encountered: