Replies: 1 comment 1 reply
-
Hi, using ThemeManager for this seems like the right solution for you. The first, sets default props for the component that can be overridden by the instance. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm wondering the correct way to customize button text color. I would expect that I can do something like this:
But the text color won't change in this case. The simplest working alternative I can find is:
While this particular example is simple, I am struggling to figure out the correct way to create reusable component variations. I'm building an app that has 5 different button styles, and each one requires 6 or 7 custom style attributes to be applied. Spelling out the whole styles object every time is quite verbose and will get difficult to maintain.
I've also tried using the theme manager:
But only the
backgroundColor
seems to be applied. I think I must be doing something wrong. I can't imagine that it's impossible to modify something as simple as the text color on a button without resorting to inline style props.Beta Was this translation helpful? Give feedback.
All reactions