Make WordPress Core
Read post

Pseudo and custom style states in WordPress 7.1

WordPress 7.1 introduces pseudo state styling (hover, focus, focus-visible, active) for the Button and Navigation Link blocks, configurable via theme.json, Global Styles, and block instance attributes. A new custom states system allows theming of special block states like the current menu item in navigation links, using a dash-prefixed convention in theme.json. Site owners can disable user-facing state editing via the blockStatesEditingEnabled editor setting, while existing saved styles remain unaffected.

    #php#wordpress
Aug 05•3m read time•From make.wordpress.org
Post cover image
Table of contents
Pseudo statesCustom style statesOpting out of style state editing
2.1K Impressions
Make WordPress Core's image
Make WordPress Core

WordPressCore's platform is a central hub for WordPress developers and contributors, offering insigh...

425 Followers

•

1.4K Upvotes

Would you recommend this post?

Copy link
WhatsApp
Facebook
X
New Squad
  • © 2026 Daily Dev Ltd.
  • Guidelines
  • Explore
  • Tags
  • Sources
  • Squads
  • Leaderboard