mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-09 20:30:43 +01:00
dac4e3be11
This commit adds three style variations to Twenty Twenty-Two, allowing users to quickly swap between different visual styles — "Blue", "Pink", and "Swiss" — for the default theme. The variations are previewed and selected from the Site Editor's global styles panel. For the implementation, each variation is defined by its own theme.json file within the "/styles" directory of the theme. All variations leverage the internal-only theme.json handler of the Webfonts API [53282] to load locally hosted fonts. Props kjellr, hellofromtonya. See #55433. Built from https://develop.svn.wordpress.org/trunk@53286 git-svn-id: http://core.svn.wordpress.org/trunk@52875 1a063a9b-81f0-0310-95a4-ce76da25c4cd
168 lines
3.2 KiB
JSON
168 lines
3.2 KiB
JSON
{
|
|
"version": 2,
|
|
"title": "Swiss",
|
|
"settings": {
|
|
"color": {
|
|
"duotone": [
|
|
{
|
|
"colors": [
|
|
"#000000",
|
|
"#FFFFFF"
|
|
],
|
|
"slug": "default-filter",
|
|
"name": "Default filter"
|
|
}
|
|
],
|
|
"palette": [
|
|
{
|
|
"slug": "foreground",
|
|
"color": "#FFFFFF",
|
|
"name": "Foreground"
|
|
},
|
|
{
|
|
"slug": "background",
|
|
"color": "#1A1A1A",
|
|
"name": "Background"
|
|
},
|
|
{
|
|
"slug": "primary",
|
|
"color": "#FF7179",
|
|
"name": "Primary"
|
|
},
|
|
{
|
|
"slug": "secondary",
|
|
"color": "#F4F4F2",
|
|
"name": "Secondary"
|
|
},
|
|
{
|
|
"slug": "tertiary",
|
|
"color": "#0000000",
|
|
"name": "Tertiary"
|
|
}
|
|
]
|
|
},
|
|
"custom": {
|
|
"spacing": {
|
|
"small": "max(1.25rem, 5vw)",
|
|
"medium": "clamp(1.75rem, 6vw, calc(3 * var(--wp--style--block-gap)))",
|
|
"large": "clamp(3.5rem, 8vw, 6rem)",
|
|
"outer": "var(--wp--custom--spacing--small, 1.25rem)"
|
|
},
|
|
"typography": {
|
|
"font-size": {
|
|
"colossal": "clamp(3.5rem, 8vw, 5rem)"
|
|
}
|
|
}
|
|
},
|
|
"typography": {
|
|
"fontFamilies": [
|
|
{
|
|
"fontFamily": "\"Inter\", sans-serif",
|
|
"name": "Inter",
|
|
"slug": "inter",
|
|
"fontFace": [
|
|
{
|
|
"fontFamily": "Inter",
|
|
"fontWeight": "200 900",
|
|
"fontStretch": "normal",
|
|
"src": [ "file:./assets/fonts/inter/Inter.ttf" ]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"styles": {
|
|
"blocks": {
|
|
"core/cover": {
|
|
"filter": {
|
|
"duotone": "var(--wp--preset--duotone--default-filter)"
|
|
}
|
|
},
|
|
"core/image": {
|
|
"filter": {
|
|
"duotone": "var(--wp--preset--duotone--default-filter)"
|
|
}
|
|
},
|
|
"core/post-author": {
|
|
"filter": {
|
|
"duotone": "var(--wp--preset--duotone--default-filter)"
|
|
}
|
|
},
|
|
"core/post-featured-image": {
|
|
"filter": {
|
|
"duotone": "var(--wp--preset--duotone--default-filter)"
|
|
}
|
|
},
|
|
"core/post-title": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"core/query-title": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)"
|
|
}
|
|
},
|
|
"core/site-logo": {
|
|
"filter": {
|
|
"duotone": "var(--wp--preset--duotone--default-filter)"
|
|
}
|
|
},
|
|
"core/site-title": {
|
|
"typography": {
|
|
"fontWeight": "700",
|
|
"fontStyle":"normal"
|
|
}
|
|
}
|
|
},
|
|
"elements": {
|
|
"h1": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"h2": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"h3": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"h4": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"h5": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"h6": {
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)",
|
|
"fontWeight": "700"
|
|
}
|
|
},
|
|
"link": {
|
|
"color": {
|
|
"text": "var(--wp--preset--color--primary)"
|
|
}
|
|
}
|
|
},
|
|
"typography": {
|
|
"fontFamily": "var(--wp--preset--font-family--inter)"
|
|
}
|
|
}
|
|
}
|