[TBD] feat(Header): adding color, background, subheaderColor and subheaderBackground props#18
[TBD] feat(Header): adding color, background, subheaderColor and subheaderBackground props#18
Conversation
|
I want to stop the propagation of background / color to every component. This is going to explode the API with design concerns and push developers back into hard coding design implementations. Before we do that, I'd like to make sure I understand where the requirements are coming from for the background / color props. Could you shed some more light on that? The part I'm having difficulty with is seeing how this is going to be handled in every component when used in concert. I don't think it is reasonable to assume users will have to put a background and foreground color on every component in a tree to achieve a colored look. Is there another angle I'm missing? |
|
If the background of the header is always inherited, then I guess the color prop would be sufficient. The thing is, we had request for handing header in the following case: I wasn't sure if this is the inverted version of the Header, with just changing the color to white, or if in some cases we want to specify the exact color we want to use, because this is still part of the default theme, not the dark mode theme. What would be your suggestion for handling this? |
|
closing as there is another (simplified) PR to handle this concept: #72 |

Header
Added new props in the Header component:
The aim for this PR is to allow the user to fully customize the colors for the headers and subheaders. The properties will be used in the following manner:
color: string
The color for the Header.

background: string
The background for the Header.

subheaderColor: string
The color for the subheader.

subheaderBackground: string
The background for the subheader.

Note:
In order for consistency in the usage of the shorthand vs children API, there are color and background properties added in the Header.Subheader component as well.