Open
Description
It seems that Typography.js overrideStyles
function defined inside the themes is not called when calling toTheme
.
Example
import { toTheme } from '@theme-ui/typography'
import wp2016 from 'typography-theme-wordpress-2016'
const theme = toTheme(wp2016)
wp2016
defines an overrideStyles function that will modify part of the theme when instantiated with plain typography
package.
For example, for the wp2016
theme :
overrideStyles: ({ adjustFontSizeTo, scale, rhythm }, options) => ({
h1: {
fontFamily: ["Montserrat", "sans-serif"].join(","),
},
// ...
but this function is never called by toTheme
and so h1
will result to have the default
headerFontFamily: ["Merriweather", "Georgia", "serif"],
not the Montserrat
family as defined by overrideStyles
.
This means that Typography.js themes will be slightly different when used in theme-ui, isn't it?
Or am I missing somethings?
Activity