Legend size is calculated incorrectly with orientation 'v', yref 'container'
Personne n'a encore pris cette issue.
- Langage dominant
- JavaScript
- Étoiles
- 18.3k
- Forks
- 2k
- Merge moyen
- 2 j 12 h
- PR mergées (30 j)
- 28
Description
As mentioned in this PR comment (#7359), there appears to be a bug related to the legend size calculation (possible due to an incorrect margin calculation) when the orientation is set to v and the yref is set to container. You can see the issue by going through the following steps:
- Be on master
- Start up the developer dashboard
- Load the legend_horizontal_autowrap mock
- Note that it loads fine
- Edit the JSON for the mock to switch
"orientation"to"v" - Edit the JSON for the mock to add
"yref"with a value of"container"under the"legend"key - Reload the mock
- Note that the legend gets scrunched up into the top right corner of the plot
- Switch to this branch
- Reload the mock
- Note that an error is produced (due to a bad reaction to a negative margin value)
An example of the bug is seen in the following image:
The legend height should be calculated using the plot height (the "container"), but something is going wrong in this configuration.
Guide de contribution
Ouvrir le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Démarre le developer dashboard et charge le legend_horizontal_autowrap mock, puis reproduis le problème en définissant legend orientation sur "v" et yref sur "container". Suis le calcul de la taille et de la marge de la légende à partir de cette reproduction. C’est terminé lorsque la légende utilise la plot height comme conteneur, n’est pas comprimée dans le coin supérieur droit et se recharge sans negative-margin error.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- javascript
- Domaine
- data-visualization
- Type d'issue
- Bug
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 45/100