Kevin Batdorf
Forum Replies Created
-
Forum: Plugins
In reply to: [Code Block Pro - Beautiful Syntax Highlighting] Disable FontsYou should be able to set the font to system on the code block and it won’t load anything. Is that not working?
It loads through JavaScript. Two things you can do to short circuit it is by adding the class
cbp-ff-loaded
to where ever the attributedata-code-block-pro-font-family
is found, or by settingwindow.codeBlockPro.pluginUrl
to null (only used for loading fonts currently)The code is here: https://github.com/KevinBatdorf/code-block-pro/blob/main/src/front/front.js#L101
Forum: Reviews
In reply to: [Code Block Pro - Beautiful Syntax Highlighting] Code BlockHi it only works with the modern editor. Its deely integrated into it so it wouldn’t be possible to support the classic one.
Hey Annza, given the way the plugin functions I’d have to write an entirely new one and maintain both. Do you plan to never use the new editor?
Forum: Reviews
In reply to: [Pattern CSS - Pattern and Block Styles] Simple CSS editor for blocks!Thanks for the kind words and review!
This should be fixed in the latest release but if something is still off just let me know. And thanks again for reporting this
Hey, very sorry about that. I’ll look into this asap.
I saw your issue on GitHub. I’ll reply there: https://github.com/KevinBatdorf/code-block-pro/issues/339
That makes sense. Are you okay with your fix? Might be a bit complicated for me to add it on a per block basis.
Ah ok that’s why then. Well, thanks for sharing a workaround. I agree that’s something they should support.
It seemed to work when I tested it out using a custom shortcode. I’m assuming php is the language? If one gets wrapped in a span or something then it would break. I’m going to work on it now though and hope to have a fix released in a bit. But if you can share an example (plugin name and code) I can test it out and confirm it’s working before I do.
ah right. Probably shortcodes are processed here too. Can you check the docs? There’s a section on escaping. Just double the square brackets
i have a solution for this but deciding on whether I should make it opt-in via a checkbox or not. Will have something by the weekend though.
For the meantime, you can use and which will signal to WordPress to escape the shortcode and not run it. But if I don’t make it opt in then you’ll have to remove the extra [ (which is why I’m considering making it opt in)
Yeah good idea on that. I’ll look into it this week and follow up here. Thanks Zack.
Thanks for the kind review and giving the plugin a chance! If you have any issues or feel like a feature is missing, please reach out ??
Forum: Plugins
In reply to: [Code Block Pro - Beautiful Syntax Highlighting] Selectors on spansHey, a future version will use css variables but I don’t know when I’ll be able to rewrite this as it’s a big project overhaul. I don’t want to make any timeline promises. But if you want to just tweak a few things, what you could do now is select the span by style attribute. For example:
[class*='code-block-pro'] span[style*="#F07178"] {
color: lawngreen !important;
}Yeah it’s just not possible, unfortunately. The code is processed through in webassembly so it’s not likely it will ever be possible either unless I added an entire runtime to the plugin. The only way you could automate it is with some sort of CI script that opens the page in a browser, edits it, processes it, the persists it somewhere. You could do that with something like playwright or cypress.