-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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
Style Customization #92
Comments
I did not. I looked for it, but didn't come across it easily. I feared that I had possibly overlooked it within the docs, and would alternately propose possibly adding another level of items to the navigation within the docs to help those absent-minded devs like myself from overlooking this info. I have also noticed since posting that the lack of CSS classes comes from |
We need to add another chapter dedicated to theming. Now that you know how it works, would you like to bootstrap it? |
I'm not 100% sure what you mean by "bootstrap it". If you mean bootstrapping a custom theme into my implementation via the |
@MattWilliamsDev: @fzaninotto meant bootstrapping the new chapter dedicated to theming. |
As in begin to write it? Sorry, but I seem unfamiliar with that usage of "bootstrap/bootstrapping". If so, I would be happy to once I get things working on my end. Currently, using the const myTheme = {
fontFamily: 'Roboto, sans-serif'
, palette: {
primary1Color: colors.orange2
, primary2Color: darkBlack
, primary3Color: colors.grey
, accent1Color: colors.orange2
, accent2Color: colors.ltGrey
, accent3Color: colors.grey
, textColor: darkBlack
, secondaryTextColor: fade( darkBlack, 0.54 )
, alternateTextColor: white
, canvasColor: white
, borderColor: colors.ltGrey
, disabledColor: fade( darkBlack, 0.3 )
, pickerHeaderColor: colors.orange2
, clockCircleColor: fade( darkBlack, 0.07 )
, shadowColor: fullBlack
}
, appBar: {
backgroundColor: colors.orange2
, color: darkBlack
}
};
...
class App extends Component {
render() {
return (
<Admin
restClient={ RestClient }
title="MyTitle"
theme={ getMuiTheme( myTheme ) }
>
...
</Admin>
);
}
} The theme doesn't seem to ever change. Still investigating what I'm doing incorrectly, as the theme data itself seems to be correct. |
It seems everything is being overwritten with the normal theme in spite of my addition of the |
Investigating the This is from the const Admin = ({ restClient, dashboard, children, title = 'Admin on REST', appLayout = withAppTitle(title)(Layout) }) => {
...
}; Note how it doesn't seem to have any way of accounting for |
Which version are you using? The theme is used at https://github.com/marmelab/admin-on-rest/blob/master/src/Admin.js#L15 |
I'm using |
Are there any breaking changes or anything to know about before making a jump to |
No BC break, you can upgrade safely. |
Thank you both for your assistance. Will close this issue once I verify it working in |
Once I worked out the issue with NPM not installing peer dependencies (quill), the What exactly is it you'd like me to do with the "bootstrapping" of the theming docs? |
Add a new
Sounds feasible? |
Definitely sounds feasible. I will make the update sometime today (hopefully). |
There currently seems to be no easy way to edit the styles for the application. Part of this is due to the lack of traditional CSS classes, replaced by
<Element style={ ... }>
. It would be wonderful to have a simple way to edit the styles for various parts of the application without having to dig into source code.If this is already feasible, then I would propose including instructions to do so within the docs as there is currently no mention of style changes.
The text was updated successfully, but these errors were encountered: