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

Add theme.anchor.icon.color #7198

Open
taysea opened this issue Apr 11, 2024 · 0 comments
Open

Add theme.anchor.icon.color #7198

taysea opened this issue Apr 11, 2024 · 0 comments
Labels
enhancement A suggestion to add to or change behavior

Comments

@taysea
Copy link
Collaborator

taysea commented Apr 11, 2024

Expected Behavior

Should be able to define an icon color to be used by default in Anchors. I'd expect the logic to be:

  1. If the caller defines a color directly as prop on the icon, this color should apply.
  2. If the caller defines a color on the Anchor itself, this color should apply to the anchor text + icon (this is current behavior)
  3. If no color prop is used on Anchor or icon, then theme.anchor.icon.color should be applied to the icon.
  4. If theme.anchor.icon.color is not defined, then just apply the anchor color to icon (this is current behavior).

This will allow easier enforcement across applications of what currently is just guidance: https://github.com/grommet/grommet-theme-hpe/wiki/Migrating-from-HPE-Theme-4.x-to-5.x#updated-anchor-treatment

Actual Behavior

No ability to theme icon color.

URL, screen shot, or Codepen exhibiting the issue

Steps to Reproduce

Your Environment

  • Grommet version:
  • Browser Name and version:
  • Operating System and version (desktop or mobile):
@taysea taysea added the enhancement A suggestion to add to or change behavior label Apr 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement A suggestion to add to or change behavior
Projects
None yet
Development

No branches or pull requests

1 participant