Skip to content

Core Button "Outline" Style Bug #71858

@j2trumpet

Description

@j2trumpet

Description

WordPress 6.8.2 incorrectly treats the core "outline" button style as a custom style variation, generating duplicate CSS and applying incorrect class names.

Expected Behavior

When applying the "Outline" style to a button block, WordPress should:

  • Apply the class is-style-outline
  • Use existing core CSS for outline button styling
  • Not generate additional inline CSS

Actual Behavior

When applying the "Outline" style to a button block, WordPress:

  • Applies both is-style-outline AND is-style-outline--2 classes
  • Generates duplicate inline CSS with style ID block-style-variation-styles-inline-css
  • Creates potential CSS specificity and load order conflicts

Impact

CSS load order and specificity conflicts make child theme development difficult

Step-by-step reproduction instructions

  1. Install fresh WordPress 6.8.2 from wordpress.org
  2. Activate Twenty Twenty-Five theme (default)
  3. Create new post/page
  4. Add a Button block
  5. Apply "Outline" style variation
  6. View frontend and inspect HTML/CSS

Screenshots, screen recording, code snippet

Image Image

Environment info

  • WordPress Version: 6.8.2
  • Theme: Twenty Twenty-Five (default, unmodified)
  • Plugins: None active (only default Akismet/Hello Dolly present but inactive)
  • Installation: Fresh download from wordpress.org
  • Browser: Google Chrome v140.0.7339.134
  • Device: 16" 2021 MacBook Pro running MacOS Sonoma 14.5
  • Local Server: MAMP v6.9 running PHP 8.2.0

Please confirm that you have searched existing issues in the repo.

  • Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

  • Yes

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs TestingNeeds further testing to be confirmed.[Block] ButtonsAffects the Buttons Block[Status] StaleGives the original author opportunity to update before closing. Can be reopened as needed.[Type] BugAn existing feature does not function as intended

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions