Found some more code examples and am now able to either add a new formatting button that will trigger a completely inaccessible “href” popover but otherwise sorta works, or replace the core link button with something that, uh, will add an `a` tag with a class. But I’m a React noob. Plus, _all_ we need is for core links to accept a class.
Folks have been wanting a way to easily extend these links forever—three years, at least; there’s several GitHub issues—so not gonna get my hopes up. I did, however, just implement a different approach, where I add, e.g., a `u-bookmark-of` class to a _paragraph_ block, and a `the_content` filter then _removes_ that class and adds it to that paragraph’s first _link_ instead. Hacky, but probably more robust than “Edit as HTML.”
@jan Jan, I believe there are programmic ways of accessing the blocks. Either by filter or some other method:
@nathand Custom blocks, patterns, or variations could be very handy, too, but the one thing I would really like is a way to easily address _inline_ links, e.g., those inside a paragraph block. (You’d pretty much have to create your own `Format`, i.e., what Yoast does.) One thing I could probably do, tho, is just add a class to the parent block and then let the `the_content` filter, i.e., PHP, handle the rest.
The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!