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

Update index.js #851

Closed
wants to merge 1 commit into from
Closed

Update index.js #851

wants to merge 1 commit into from

Conversation

awais-124
Copy link

return value of getTextColor updated...

  • The function named getTextColor in index.js was returning undefined, updated it to 'black'. So that when we have light theme applied, the text color is set to black instead of undefined.

  • Previously, when we have light these the text was not shown because its color are background color were both white.

  • It must be set to black for white background

Changes Suggested in following function

const getTextColor = (props) => {
  const darkTheme = getTheme(props) === 'dark'
  if (darkTheme) return 'white'
  return undefined // should be black
}

Suggested Change

- return undefined
+ return 'black'

The function named getTextColor in index.js was returning undefined, updated it to 'black'. So that when we have light theme applied, the text color is set to black instead of undefined
@henninghall
Copy link
Owner

Thanks for your contribution! This fix is integrated in v5.0.6

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