Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin Tweaks: Support the Code Syntax Block #387

Draft
wants to merge 1 commit into
base: trunk
Choose a base branch
from

Conversation

ryelle
Copy link
Contributor

@ryelle ryelle commented Apr 7, 2023

Drafting this, as it isn't necessary anywhere just yet— just something I started on because of WordPress/wporg-documentation-2022#56 (before realizing we hadn't set up Code Syntax Block there). When the redesigns start up again, we can revisit it.

When working on the Developer site, we switched from SyntaxHighlighter Evolved to the Code Syntax Block plugin, with a custom style for the syntax highlight. SyntaxHighlighter also provided some shortcodes, so when that is deactivated, those shortcodes break.

This PR pulls out the code from Developer to support those legacy shortcodes by injecting in the Code block, if Code Syntax Block is active. This allows us to deactivate SyntaxHighlighter Evolved without needing to update all the old content.

This also adds in the custom prism theme, so that we can have a central place for those styles to live.

Before After
Screenshot 2023-04-07 at 12 32 14 PM Screenshot 2023-04-07 at 12 31 58 PM

@ryelle ryelle self-assigned this Apr 7, 2023
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