plotly / plotly/react-plotly.js
How can I hide traces from multiple charts at once?
未關閉
還沒有人認領這個 Issue。
- 主要語言
- JavaScript
- 星號
- 1.1k
- 分支
- 138
- 平均合併
- 3 天 2 小時
- 30 天內合併 PR
- 4
描述
I know that I can set the visibility of the trace on the chart by the visible property but this only affects the chart that I clicked on. On a page with multiple charts using similarly named traces, how can I toggle the visibility of all the similarly named traces at the same time?
Here was my attempt but this didn't have any affect and only toggled the chart I clicked.
let updatedChartingData = [...this.state.chartingData];
for (let chart of updatedData) {
for (let i = 0; i < chart.tickerEntities.length; i++) {
let trace = chart.tickerEntities[i];
if (trace.name === trace_name) {
if (!trace.visible) {
trace.visible = "legendonly";
}
else if ((typeof trace.visible) === "string") {
trace.visible = true;
}
else {
trace.visible = "legendonly";
}
}
}
}
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
未指定任何 repository 檔案或測試。先追蹤 chartingData 和每個 trace 的 visible 屬性如何傳遞至 React 圖表;要完成此工作,需要一種清楚且受支援的方式,在各圖表之間同步名稱相似的 trace 的可見性。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- javascript, react
- 領域
- data-visualization, frontend
- Issue 類型
- 功能
- 難度
- 5/5
- 預估耗時
- 一週以上
- 活躍度
- 停滯
- 描述清晰度
- 需要釐清
- 新手友好度
- 25/100