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

Unable to override HvButton font color with variant=warning #4266

Open
2 tasks done
fookoo opened this issue Aug 9, 2024 · 1 comment
Open
2 tasks done

Unable to override HvButton font color with variant=warning #4266

fookoo opened this issue Aug 9, 2024 · 1 comment
Labels
📬 waiting feedback Waiting for assigned user feedback

Comments

@fookoo
Copy link

fookoo commented Aug 9, 2024

Which UI Kit version is this bug for?

v5.x

Latest version

  • I have tested the latest version

No Hitachi confidential content

  • I'm not including any Hitachi confidential content

Current behavior 😯

const theme = createTheme({
  name: 'theme',
  base: 'ds5',
  inheritColorModes: true,
  components: {
    HvButton: {
      classes: {
        warning: {
          color: 'red'
        }
      }
    }
  }
})

it doesnt affect my <HvButton variant='warning'>Ok</HvButton>

works with "secondaryGhost" and others

Expected behavior 🤔

i would like to be able to override this

Your Environment 🌎

Build tool: Vite
Device & OS: PC Linux
Browser: Chrome

@fookoo fookoo added the ⌛ needs triage Waiting for a review. These issues haven't been looked at yet by a maintainer. label Aug 9, 2024
@MEsteves22
Copy link
Contributor

Hello @fookoo 👋

This is not working because the component doesn't have a warning class at the moment.
Just to get a better understanding, do you want to change the color for all buttons with the warning variant in your app or only one specific component? If the latter, creating a specific component would be better. If the former, don't you want to change the warning color in your app globally and not just for the button? If so, overriding the color tokens is more appropriate. 🙏

@MEsteves22 MEsteves22 added 📬 waiting feedback Waiting for assigned user feedback and removed ⌛ needs triage Waiting for a review. These issues haven't been looked at yet by a maintainer. labels Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📬 waiting feedback Waiting for assigned user feedback
Projects
None yet
Development

No branches or pull requests

2 participants