[wp-meta] [Making WordPress.org] #7782: Add block-variation detection
Making WordPress.org
noreply at wordpress.org
Mon Sep 23 11:23:07 UTC 2024
#7782: Add block-variation detection
------------------------------+---------------------
Reporter: carstenbach | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone:
Component: Plugin Directory | Resolution:
Keywords: |
------------------------------+---------------------
Comment (by carstenbach):
Replying to [comment:2 dufresnesteven] & ''[comment:4 myself]'':
> Please help me understand, why you differentiate between variations of
core blocks and variations of custom blocks? Does this make any difference
to the user, to the parsing or to the preview? Sorry, I don't understand
that.
>
> > I think if we can get users ''into the plugin'' more easily to preview
using something like playground we can expose these blocks/variations
directly in the editor. The readme can list the blocks in simple terms,
and the interactive experience could highlight the blocks and their
functionality...?
>
> I like Playground and do & experiment a lot using it, so yes this might
be a path to go.
>
> Given that this would need a lot more clicks and loading bars to get to
the "final" block-variations; this idea should – ''from my opinion'' –
considered last, if nothing else worked.
I think I may have got it, this relates to JS & PHP.
While we can get title and description of a block reliably, when parsing
from {{{register_block_type()}}}, or even in JS from {{{"variations":
[...]}}}, but we would need to run the code, to get the same data from
{{{registerBlockVariation()}}} because the arguments are not directly
nested anymore, due to the build process.
Am I right or at least in the right direction?
If that is the case, I understand now too, why running a Playground to get
that data might be a very good idea!
--
Ticket URL: <https://meta.trac.wordpress.org/ticket/7782#comment:5>
Making WordPress.org <https://meta.trac.wordpress.org/>
Making WordPress.org
More information about the wp-meta
mailing list