plotly / plotly/plotly.js

Hovertemplate not using single text value for all data points

オープン
#5,965 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

bug P3
主要言語
JavaScript
スター
18.3k
フォーク
2k
平均マージ
2日 12時間
マージ済み PR(30日)
28

説明

Hi there 👋, stumbled across this issue while playing around with hovertemplates in Plotly.NET.

The text property can be either set with an array of values (-> every data point gets its own text for hover display), or with a single value (-> every data point gets the same text)

This works well unless the text is used in a hover template. When using an array of text, these values are displayed correctly. But when using a single text for all datums, it does not display on hover.

Expected behavior: Hover template uses the single string of the text property for each hoverlabel
Actual behavior: Hoverlabels display %text

Here is a jsfiddle: https://jsfiddle.net/vsm79h3q/

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

リンクされた jsfiddle で hovertemplate の動作を再現することから始め、配列値の text プロパティと単一の文字列を比較します。スカラーのテキスト値に対する hovertemplate の処理を追跡し、完了した変更によって %text ではなく、すべての hoverlabel に同じ文字列が表示されることを確認します。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
javascript
領域
data-visualization
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。