plotly / plotly/plotly.js

Allow style editing of graph legend labels

Open
#7,063 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature P3
Dominant language
JavaScript
Stars
18.3k
Forks
2k
Avg merge
2d 12h
Merged PRs (30d)
28

Description

Thanks so much for your interest in Dash!

The feature has already been tangentially discussed here: https://community.plotly.com/t/scatter-plot-how-to-wrap-legends-text-when-legend-text-is-too-long/4767/7

Is your feature request related to a problem? Please describe.
I have traces that have very long names. It's problematic because the legend text does not word wrap and so it squishes the graph.
Here's an example: https://postimg.cc/VSq0bQXW

Describe the solution you'd like
Please allow for more stylistic control over legend text, particularly allowing for textoverflow control, like word wrap, hidden+ellipsis, hover tooltip etc.

Describe alternatives you've considered
I had to resorted to displaying a hashmap to translate the long text into a shorter signature.

Additional context
I've had it where the text is really long that the actual graph is completely unreadable.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with traces that have very long names and review the linked community discussion for the requested legend behavior. Clarify which overflow options should be supported, then verify that the graph remains readable with long labels and that the selected behavior is visible to users.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
data-visualization
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.