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

Meter Grommet component doesn't accept linear gradient as color value #6552

Closed
japebo opened this issue Dec 27, 2022 · 6 comments
Closed

Meter Grommet component doesn't accept linear gradient as color value #6552

japebo opened this issue Dec 27, 2022 · 6 comments
Labels
waiting Awaiting response to latest comments

Comments

@japebo
Copy link

japebo commented Dec 27, 2022

Expected Behavior

Meter component should accept linear gradient as color value.

Actual Behavior

Meter component is not accepting linear gradient as color value.

Your Environment

  • Grommet version: 2.21.0
  • Browser Name and version: Chrome Version 108.0.5359.124 (Official Build) (arm64)
  • Operating System and version (desktop or mobile): MacOS Monterey v12.3.1
@ericsoderberghp
Copy link
Member

Can you provide an example of how you are wanting to pass the gradient and a visual example of what the design intent is? In other words, what information is the gradient intended to convey?

@japebo
Copy link
Author

japebo commented Dec 27, 2022

Can you provide an example of how you are wanting to pass the gradient and a visual example of what the design intent is? In other words, what information is the gradient intended to convey?

Sure, and thanks for the fast reply.

image

The above image shows the desired result. I have tried to pass a color like this 'linear-gradient(90deg, #0ABB4F 0%, #62E38E 100%)' (Note that it is of type string) to the values Meter prop, but in vain.

@ericsoderberghp
Copy link
Member

From this, it appears that the gradient might be purely decorative, that it doesn't convey any particular meaning in itself. Is that right?

@japebo
Copy link
Author

japebo commented Dec 28, 2022

From this, it appears that the gradient might be purely decorative, that it doesn't convey any particular meaning in itself. Is that right?

Yes, merely decorative.

@ericsoderberghp
Copy link
Member

Since the Meter is rendered via SVG, I'm wondering if and how the desired design can be achieved. SVG gradients appear to be primarily oriented based on the entire graphic and then the stroke or fill acts as a mask to reveal the portions of the gradient where the stroke or fill would be. I don't think the desired graphic can be represented by a linear or radial gradient. But, perhaps I am missing something.

@jcfilben jcfilben added the waiting Awaiting response to latest comments label Jan 17, 2023
@jcfilben
Copy link
Collaborator

jcfilben commented May 9, 2023

Closing due to inactivity but feel free to re-open if you would like to continue discussion on this.

@jcfilben jcfilben closed this as not planned Won't fix, can't repro, duplicate, stale May 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting Awaiting response to latest comments
Projects
None yet
Development

No branches or pull requests

3 participants