Skip to content
New issue

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

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

Already on GitHub? # to your account

Check pattern content before return pattern blade view #52

Closed
aitormendez opened this issue May 1, 2023 · 0 comments
Closed

Check pattern content before return pattern blade view #52

aitormendez opened this issue May 1, 2023 · 0 comments

Comments

@aitormendez
Copy link

aitormendez commented May 1, 2023

Pattern content provided in the block pattern registration arguments are ignored. So this doesn' work:

'block_pattern' => [
    'sage/hero' => [
        'title' => 'Page Hero',
        'description' => 'Draw attention to the main focus of the page, and highlight key CTAs',
        'content' => '<!-- wp:paragraph --><p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ratione nulla culpa repudiandae nisi nostrum et, labore earum repellendus porro, mollitia voluptas quam? Modi sint tempore deleniti nesciunt ab, perferendis et.</p><!-- /wp:paragraph -->',
        'categories' => ['all'],
    ],
],

$view = 'block-patterns.' . Str::after($key, '/');

Discourse ref

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant