[BUG]: last period label sometimes not drawn when using negative ticklabelindex
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- JavaScript
- Sterne
- 18.3k
- Forks
- 2k
- Ø Merge
- 2 T. 12 Std.
- Gemergte PRs (30 T.)
- 28
Beschreibung
Here is an example of the last ticklabel not being drawn. The figure's ticklabelindex is set to -1:
Plotly 3.6.0 (missing last label)
Plotly 3.5.1 (all labels visible)
This is a regression from #7735. In version 3.5.1 ticklabelindex was ignored because no minor ticks were drawn. In version 3.6.0 ticklabelindex is not ignored and so for this figure, the label is expected to be drawn to the left of each major tick (ticklabelindex -1). However, there is no tick to the right of the last period and so that period is not labeled.
Before ticklabelindex, period labels were only ever drawn to the right of a major tick. There is logic in plotly to add a helper tick before the first period, making sure it will be labeled. For negative ticklabelindex, the same logic is required for the period at the end of the axis range.
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Reproduziere das fehlende Label mit dem verlinkten CodePen und vergleiche dabei das Verhalten von 3.5.1 und 3.6.0. Verfolge die Verarbeitung von ticklabelindex und die bestehende helper-tick-Logik für die erste Periode und stelle dann sicher, dass der entsprechende Fall am Ende des Bereichs die letzte Periode beschriftet, wenn der Index negativ ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- javascript
- Bereich
- data-visualization
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Ruhig
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 65/100