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
Easy way to set style to body #701
Easy way to set style to body #701
Comments
It’s already possible but undocumented: module.exports = {
components: 'src/components/**/[A-Z]*.js',
styles: {
StyleGuide: {
'@global body': {
fontFamily: 'Helvetica',
},
},
},
}; |
@sapegin Is this issue still open and has the scope just changed to document the feature instead? |
@sanjsanj Exactly! |
@sapegin Perhaps I could pick it up then if you don't mind :) No idea what to do but I'll fork the repo and have a look. |
I think the best way is to expand this question with an example from my comment above: https://react-styleguidist.js.org/docs/cookbook.html#how-to-add-custom-javascript-and-css-or-polyfills |
Cheers! I'll look at that now. I have been looking at this issue and will come back to you with further questions asap. |
@sapegin Apologies for the hassle but I have some questions:
(This is my first time using your package and at first it wasn't clear that
Should |
No, it won’t change style guide styles, only style of user components.
Nice catch! We should add it to the list. Here is the full list of available plugins: react-styleguidist/src/styles/setupjss.js Lines 2 to 7 in 3fce9f2
I think the most common would be setting a font face, otherwise, if you don’t set font face explicitly in each component, they will be rendered with the browser default font.
No, we strip
|
Just opened a PR, not sure if it's what you had in mind or not but let's get the ball rolling. Awaiting feedback :-) |
@sapegin is that |
@sapegin this appears to be broken in prod -- is it because it relies on component name matching, and those component names are removed when minified? |
The text was updated successfully, but these errors were encountered: