-
I haven't found a similar question or some guide about customizing a theme.
That has a type of |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
Say me, if I missed something, I'd add the info that's needed |
Beta Was this translation helpful? Give feedback.
-
Hello. I think you can use useTheme hook and console.log it. Also i was able to give other css properties to its objects and they were ok. |
Beta Was this translation helpful? Give feedback.
-
The theme object can be customized, using TypeScript will probably help for discoverability, but otherwise, you can have a look at the default theme here: https://github.com/plouc/nivo/blob/master/packages/core/src/theming/defaultTheme.js. @krau5 it's not really hardcoded, it acts as a base for custom themes so that you don't have to define everything, your custom theme is merged with this one. You can also have a look at the TS definition for it to see what you can customize: https://github.com/plouc/nivo/blob/master/packages/core/index.d.ts#L53. I added a guide on how to use the theme object, but it's not complete yet: https://nivo.rocks/guides/theming/. |
Beta Was this translation helpful? Give feedback.
The theme object can be customized, using TypeScript will probably help for discoverability, but otherwise, you can have a look at the default theme here: https://github.com/plouc/nivo/blob/master/packages/core/src/theming/defaultTheme.js.
@krau5 it's not really hardcoded, it acts as a base for custom themes so that you don't have to define everything, your custom theme is merged with this one.
You can also have a look at the TS definition for it to see what you can customize: https://github.com/plouc/nivo/blob/master/packages/core/index.d.ts#L53.
I added a guide on how to use the theme object, but it's not complete yet: https://nivo.rocks/guides/theming/.