dream-num / univer

Univer is an open-source productivity tool dev kit helping you integrate spreadsheets, docs and slides into your applications.
https://univer.ai
Apache License 2.0
6.86k stars 596 forks source link

[Bug] Calling DocumentDataModel.apply(actions: JSONXActions) does not rerender visually #3515

Closed LeosPrograms closed 1 hour ago

LeosPrograms commented 1 month ago

Before you submit this issue, have you checked the following

Affected packages and versions

0.2.14

Reproduction link

  1. Generate a document using document1 = univer.createUnit(UniverInstanceType.UNIVER_DOC, {});
  2. Create a JSONXActions object let jxa = [ "body", { "et": "text-x", "e": [ { "body": { "dataStream": "a" }, "len": 1, "line": 0, "segmentId": "", "t": "i" } ] } ]
  3. Apply the JSONXActions with document1.apply(jxa)

Expected behavior

Changes are applied, and the document updates visually.

Actual behavior

Changes are applied to the Univer doc object, but they are not reflected visually. Changes are updated visually only after manual adjustments, or after a command is executed.

System information

Running in electron on Ubuntu 22.04.4

Jocs commented 1 month ago

Any error message in console?

LeosPrograms commented 4 weeks ago

No, none.

Jocs commented 1 week ago

@LeosPrograms Can you provide a minimal demo for reproduce this issue?

jikkai commented 1 hour ago

We are closing this issue for now due to the lack of enough information. Please feel free to reopen it once you can provide a minimal reproduction.