plotly / plotly/plotly.js

Plotly.react doesn't transition correctly when only annotations are changed

未关闭
#4,839 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

bug P3
主要语言
JavaScript
星标
18.3k
派生
2k
平均合并
2 天 12 小时
30 天内合并 PR
28

描述

Here's an example where I'm attempting to transition to a plot with added annotations using Plotly.react. Notice if I update just the layout and not the data, the graph won't update.

Example 1

However if I remove the transition in Example 1, the graph will update correctly.

And if I update the data and the layout together, then also the graph will transition correctly.

Example 2

I have been running into some difficulties with annotations moving around erratically when I try to transition between layouts using Plotly.react, and in trying to debug that noticed the above. This seems to me like a bug related to transitions.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

使用 Plotly.react 复现 CodePen Examples 1 和 2 中的行为,比较仅 layout 的更新、同时更改数据的更新,以及禁用 transitions 时的情况。跟踪 Plotly.react 针对 annotation 更改的 transition 路径。完成标准是:仅 layout 的 annotation 更新能够正确执行 transition 并完成渲染,而不需要更改数据。

由索引模型根据 Issue 内容生成。

评估

技术栈
javascript
领域
data-visualization
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。