gristlabs_grist-core/app
Cyprien P 33f056a187 (core) Fix js errors when (un)summarizing underlying table of charts
Summary:
Used to throw js errors: `Resize must be passed a displayed plot div element.`

Summarizing (or unsummarizing) causes the ChartView view instance to
be replace by a new one in the view layout.
However, the problem is that the old view instance get disposed only
after the new view instance is added to the view layout.
This causes the old view layout to try to resize chart while chart dom
has been removed from the dom (which Plotly does not support).

This diff fixes it by checking the the chart dom elemnt is still in
the dom before making the plotly call to resize the chart.

TODO: It feels weird that the old view instance gets disposed after
the new one get added. Maybe we should check that also.

Test Plan: New test added.

Reviewers: dsagal

Reviewed By: dsagal

Subscribers: dsagal

Differential Revision: https://phab.getgrist.com/D3035
2021-09-22 17:04:52 +02:00
..
client (core) Fix js errors when (un)summarizing underlying table of charts 2021-09-22 17:04:52 +02:00
common (core) Improve time-parsing for DateTime columns, which was unusable with some formats (e.g. tz-containing ones) 2021-09-21 10:02:59 -04:00
gen-server (core) add tests for site deletion 2021-09-14 10:03:18 -04:00
plugin (core) Suggest correct table when converting to RefList 2021-08-20 23:04:48 +02:00
server (core) apply SchemaEdit flag to metadata changes in general 2021-09-16 13:36:20 -04:00
tsconfig.json