Skip to content

Improve design tokens - #263

Open
amjadr360 wants to merge 11 commits into
mainfrom
feature/design-base-sync
Open

amjadr360 wants to merge 11 commits into
mainfrom
feature/design-base-sync

Conversation

@amjadr360

Copy link
Copy Markdown
Contributor

Updates the theme's design tokens and keeps older token names working, so existing content looks the same.

Updates the theme's design tokens in theme.json. Older token names that
saved content still uses keep working through a dated alias block in
style.css, and a site's own saved values still take precedence.
@amjadr360
amjadr360 force-pushed the feature/design-base-sync branch from 8653568 to 651ceb4 Compare October 15, 2026 08:41
WordPress before 6.9 prints no radius presets and before 6.8 no button
focus ring, so on those versions buttons lost their corners and their
focus outline. style.css now declares both at zero specificity, so the
values WordPress prints itself still win on newer versions.

Buttons, search and form buttons read a site's own button radius again,
so style variations with square or pill buttons keep them. The five new
button styles are registered, since WordPress ignores theme.json styles
for a block style nobody registers. Drops a typography setting that
WordPress does not have.
theme.json and the generated block in style.css now carry the final token
set: links in the brand ink, buttons and inputs on one size scale, and
named colour steps for every hover, active and disabled state. The
natural-1 block styles are replaced so a site's vibe resets every value
the theme's copy sets, instead of WordPress merging the two leaf by leaf.
The eleven paragraph and heading text styles are registered, because
WordPress drops a theme.json style no block style is registered for.
Orange no longer overrides the font sizes, which would drop sizes that
saved content uses.
Links, navigation links, post titles and post terms had a second set of
hover, focus and active rules beside theme.json, so the two disagreed and
the last one loaded won. Those copies go, along with the 1px click
outline, the inherited input outline colour and the comment-form field
colours, which out-ranked the input styles. The search field now takes
the input corner radius instead of the button pill, and the outline
button hover uses its named colour step instead of a fixed grey.
Seventy-seven retired names were only ever declared by the theme itself, so their alias
lines in the generated block render nothing. The twenty-three names live sites still read
keep their aliases.
Each button and paragraph style is now one file under styles/blocks, registered by WordPress
from the file, and the button styles also apply to the WooCommerce product button. Type sizes
come from one eleven-step ladder with named sizes, links and inputs read shared tokens, the
theme uses WordPress's own aspect ratios, and a cover's text colour is left to WordPress. The
system block presets are hidden from the style picker and keep only what theme.json cannot say.
Unregistering a preset in the editor left its class on a block switched to another
style, because the editor only removes the class of a style it still knows. Hiding the
preset in the Styles panel keeps it registered, so the switch cleans up. h6 takes weight
500 like h5, so it no longer prints the same as Large text, and full-width galleries keep
the image radius.
Sites and patterns built on this theme rely on the overlay's light text and light button, so the preset keeps them for now.
The card's text sat flush against its photo. Its content groups pad at the medium spacing step again.
On phones, large hero headings broke plain words mid-word ("ti-tle"). overflow-wrap already keeps long words and email addresses inside the screen, which is what the hyphenation was added for, so headings now break only where a word would overflow.
Saved content that wears the align-center card style relied on the
theme to centre its heading and paragraph. Restore that, and drop the
rules that only matched markup no centred card carries.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant