Inconsistent `gap` attributes causes misalignment
オープン
まだ誰も着手していません。
bug
sev-3
- 主要言語
- JavaScript
- スター
- 18.3k
- フォーク
- 2k
- 平均マージ
- 2日 12時間
- マージ済み PR(30日)
- 28
説明
If you provide both bargap and scattergap but they're different, traces in the same alignment and offset group do not properly align. One way or another, ensuring these traces align is more important than honoring both gaps. Here, the orange and green scatter points should be centered on the bars of the same color, but they are not:
https://codepen.io/alexcjohnson/pen/yLdEZvo?editors=0010
This is a little tricky though:
- If there are no bar traces,
bargapwill not be defined, soscattergapshould be honored. - Even if there are bar traces but only
scattergapis explicitly given, seems like it should be honored and used as thebargapvalue as well. - There are also
boxgapandviolingap- in principle you could have ALL of these traces in the same alignment and offset groups, do we define a hierarchy, something like bar beats scatter beats box beats violin? Or do we take the gap from the first trace in the group, and use that for all traces in that group? Or the maximum gap that applies to any trace in the group? I have no strong opinions here, so long as the result is always proper alignment. - All but scatter also have
*groupgapattributes. There's no problem allowing these to be different.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
bar、scatter、box、violin トレースのアラインメントとオフセットグループの処理から始め、リンク先の CodePen を使って不一致を再現します。gap 属性がない場合と明示的に設定されている場合を比較し、そのうえで、正しいアラインメントを維持しながら共有 gap を選択する一貫したルールを確立します。同じグループに属するトレースが、関連するすべてのトレースの組み合わせで正しく中央揃えされれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- javascript
- 領域
- data-visualization
- issue の種類
- バグ
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100