add argument to modify hover box position/direction
オープン
まだ誰も着手していません。
cs
feature
P2
- 主要言語
- JavaScript
- スター
- 18.3k
- フォーク
- 2k
- 平均マージ
- 2日 12時間
- マージ済み PR(30日)
- 28
説明
Right now developers can't modify the hover box position respective to the point the user is hovering. The hover box position is determined by:
- The numbers in the
"transform=translate(valuex, valuey)"argument of thegelement withclassName="hovertext": https://github.com/plotly/plotly.js/blob/master/src/components/fx/hover.js#L1200 - The shape specified in
din thepathelement (for the triangle orientation): https://github.com/plotly/plotly.js/issues/7278
https://github.com/user-attachments/assets/0634d079-b4eb-4325-af67-d13ac0fc6ba1
Desired behavior:
- Some argument like dcc.Tooltip
direction: https://dash.plotly.com/dash-core-components/tooltip#tooltip-properties - It should also allow diagonal/combined positions ("bottom+right")
# the python way
fig.update_traces(hoverbox_direction="right")
fig.update_traces(hoverbox_direction="left+top")
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
src/components/fx/hover.js の className="hovertext" を持つ g 要素とその transform の周辺から始め、次に hover 三角形の向きについて issue #7278 を確認します。"left+top" のような組み合わせ方向を含め、方向引数を hover ボックスと三角形にどのように対応付けるかを定義します; 呼び出し元が要求された trace 設定を通じてこれらの位置を選択できれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- javascript
- 領域
- data-visualization, frontend
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 25/100