Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(analytics-chart): arrange legend items in grid when horiz [MA-2011] #778

Merged
merged 1 commit into from
Sep 12, 2023

Conversation

filipgutica
Copy link
Contributor

@filipgutica filipgutica commented Sep 11, 2023

Summary

  • When legend display is horizontal, arrange items in a grid
  • Also truncate long labels and provide a tooltip on hover when legend display is horizontal

https://konghq.atlassian.net/jira/software/c/projects/MA/issues/MA-2011

image

PR Checklist

  • Naming & Structure: the files and package structure use the conventions outlined in the Creating a Package docs.
  • Tests pass: check the output of all package unit and/or component tests.
    • If this PR is the result of a bug, test coverage was added accordingly.
  • Functional: all changes do not break existing APIs, but if so, a BREAKING CHANGE commit is in place to bump the major version.
  • Conventional Commits all commits follow the conventional commit standards outlined in the main README.
  • Docs: includes a technically accurate README, and the docs have been updated accordingly based on the changes in this PR.

@filipgutica filipgutica requested a review from a team as a code owner September 11, 2023 20:28
justify-content: center;
margin-top: $kui-space-50;
max-height: 60px;
max-height: $kui-space-150;
row-gap: $kui-space-30;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would go aggressively small here, 4px for both column-gap and row-gap, which equates to$kui-space-20.

And on L187 , for .legend-container li, the margin all around could be as small as 8px ($kui-space-40)

Screenshot 2023-09-11 at 5 06 29 PM

@filipgutica filipgutica force-pushed the fix/analytics-chart-horizontal-legend-grid branch from 8013f74 to 21df09b Compare September 12, 2023 03:57
@filipgutica filipgutica merged commit b56926b into main Sep 12, 2023
5 checks passed
@filipgutica filipgutica deleted the fix/analytics-chart-horizontal-legend-grid branch September 12, 2023 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants