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
Hello. I have a setup where the I highlight some text in the RichTextEditor, and then make it bold. I'm listening for changes to the attributedString, and if there is a change, I persist it.
Here are the steps and issue I'm seeing. I'm on 1.0.0, on iOS.
Use RichTextEditor to write some text.
Listen for changes to the attributedString with onChange(context.attributedString
Select a range of text.
Use RichTextKeyboardToolbar to make the text bold.
Notice that the text is bold and onChange did not fire.
Deselect the text.
Notice now that the onChange method did fire.
Expected result:
The onChange method should fire after the user makes the text bold.
Actual result:
The onChange method only fires after the user deselects the text.
Any work arounds?
The text was updated successfully, but these errors were encountered:
I think the reason to why this doesn't work is that (if I remember correctly) the text binging is not updated continuously, since it would cause the text editor to redraw. Instead, it's synced at certain points.
I'm currently swamped with other projects, but I'll revisit this once iOS 18 is out. My idea is to actually change the text binding at all times, but have a second decoupled text binding that is bound to the editor.
Hello. I have a setup where the I highlight some text in the RichTextEditor, and then make it bold. I'm listening for changes to the attributedString, and if there is a change, I persist it.
Here are the steps and issue I'm seeing. I'm on 1.0.0, on iOS.
Expected result:
Actual result:
Any work arounds?
The text was updated successfully, but these errors were encountered: