Post AIloQphu00FPFZNfbE by kev@fosstodon.org
(DIR) More posts by kev@fosstodon.org
(DIR) Post #AIloQphu00FPFZNfbE by kev@fosstodon.org
2022-04-24T09:36:55Z
0 likes, 0 repeats
Fellow Fediverse #WordPress users, do any of you know if there is a way to add a HTML details element using blocks?I know I can use a custom HTML block and mark it up manually, but I’d rather just add a block.
(DIR) Post #AIlsqgWHBEZY6LWdFo by ru@fosstodon.org
2022-04-24T10:26:24Z
0 likes, 0 repeats
@kev Would probably have to be a plugin that adds such a block... I think.
(DIR) Post #AIm5sGlPD5OOChgiIK by stampirl@social.cybershock.life
2022-04-24T11:01:41.228664Z
0 likes, 0 repeats
@kev what kind of details?
(DIR) Post #AIm5sHHfH9CFokmTZo by kev@fosstodon.org
2022-04-24T12:52:20Z
0 likes, 0 repeats
@stampirl the details HTML element.https://www.w3schools.com/TAGS/tag_details.asp
(DIR) Post #AIm617vfQSo5PViA0e by kev@fosstodon.org
2022-04-24T12:54:02Z
0 likes, 0 repeats
@ru yeah, I’m thinking the same. For the amount of times I’ll use them, I’m probably just best writing out the HTML.Suppose i could have a blank one as a reusable block…
(DIR) Post #AIm7NRbv1zOcmCgD3Y by ru@fosstodon.org
2022-04-24T13:09:02Z
0 likes, 0 repeats
@kev I love the block editor but like you I wish it supported all of the HTML spec, not just parts that are more "common."Plugins are so overloaded...
(DIR) Post #AImqcORfZsh5EyO7vM by reykjalin@fosstodon.org
2022-04-24T21:36:13Z
0 likes, 0 repeats
@kev not without a plugin I think. It should be relatively easy to make one.Getting into block development comes with a bit of a learning curve, but there is a nice little quick start package provided in npm that does most of the work for you 🤔If I ever do make a plugin like that I’ll make sure to ping you first :)
(DIR) Post #AIqgRlKruTcW8fL4Ou by m2m@indieweb.social
2022-04-24T13:41:01Z
0 likes, 0 repeats
@ru @kev I used to write plug-ins and shortcodes but never even investigated if it's possible to write a custom editor block. Now I'm curious, even if I'm not using WordPress at the moment.
(DIR) Post #AIqgRm5f6V3CTnERKy by jan@geekcompass.com
2022-04-26T15:03:52Z
0 likes, 0 repeats
@m2m @ru @kev If somehow a reusable Custom HTML block doesn’t cut it and “modern” JavaScript isn’t quite your thing, Genesis Custom Blocks (or a similar plugin) might be of help?
(DIR) Post #AIqgRmwTw7Il7bwcfQ by kev@fosstodon.org
2022-04-26T17:59:09Z
0 likes, 0 repeats
@jan @m2m @ru ill take a look at Genesis, thanks.
(DIR) Post #AIqgRochgcfYKqhr7I by m2m@indieweb.social
2022-04-24T14:52:32Z
0 likes, 0 repeats
@ru @kev while reading an how-to for a custom gutenberg block I've found this: https://github.com/ahmadawais/create-guten-blockI didn't know it's almost all React and JS. I think I'll stick to a SSG.
(DIR) Post #AIqwkKncOU7cbffEPI by jrtashjian@talos.link
2022-04-26T19:16:10Z
0 likes, 0 repeats
@kev In CoBlocks (https://wordpress.org/plugins/coblocks/) we have an "accordion" block that does what you need but it's not available as a singular block.We are working on trimming down the blocks (converting some into core blocks) but the accordion doesn't have a core alternative right now. So it'll be sticking around for a bit.