Skip to content

[Legend] Set default for legend.labelOptions.widthLimit in themes #2801

@maryam-saeidi

Description

@maryam-saeidi

Summary

As you can see here, we set default values for the legend properties to eliminate the need for setting a default value in the component and define those properties as required without forcing the consumer to always pass those parameters.

In this PR, we introduced a new label option property called widthLimit and we need to make this field required and set a default for it in the themes. Something like:

labelOptions: {
      maxLines: 1,
      widthLimit: 250
}

Note

If no theme is selected on the consumer side, the LIGHT theme will be used as a fallback.

Users can adjust these properties by passing a different theme or adding customization (that will be merged together with the current base theme)

Acceptance criteria

  • Add default widthLimit: 250 to the themes
  • Make maxLines and widthLimit fields required

Metadata

Metadata

Assignees

Labels

:legendLegend related issue

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions