singerdmx / flutter-quill

Rich text editor for Flutter
https://pub.dev/packages/flutter_quill
MIT License
2.59k stars 837 forks source link

How to refresh QuillController to keep history #1683

Open thanglq1 opened 10 months ago

thanglq1 commented 10 months ago

Is there an existing issue for this?

The question

When I change the document, the Quill Editor loses its history, making undo and redo actions unavailable.

Initial document assignment:

Document doc1 = Document.fromJson(jsonDecode(json1));
_quillController.document = doc1;

Subsequent document update:

Document doc2 = Document.fromJson(jsonDecode(json2));
_quillController.document = doc2;

After updating to doc2, undo and redo functionality is lost within the Quill Editor.

ramees-saleem commented 9 months ago

Have you found a solution?

thanglq1 commented 9 months ago

Have you found a solution?

Not yet. Waiting update from Flutter Quill team.

CatHood0 commented 1 month ago

Do you solve this issue or still persisting?