Skip to content

Commit de34ffd

Browse files
committed
Allow setting default render style.
1 parent f93d199 commit de34ffd

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

.distignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ phpunit.xml.dist
2020
multisite.xml
2121
multisite.xml.dist
2222
phpcs.xml
23-
phpcs.xml.dist
23+
phpcs.ruleset.xml
2424
wp-cli.local.yml
2525
yarn.lock
2626
tests

app/Hametuha/ForYourEyesOnly.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ public function register_assets() {
5959
wp_localize_script( 'fyeo-block', 'FyeoBlockVars', [
6060
'capabilities' => $this->capability->capabilities_list(),
6161
'default' => $this->capability->default_capability(),
62+
'dynamic' => apply_filters( 'fyeo_default_render_style', '' ),
6263
'placeholder' => $this->parser->tag_line(),
6364
] );
6465
wp_localize_script( 'fyeo-block-renderer', 'FyeoBlockRenderer', [

src/js/block.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ registerBlockType( 'fyeo/block', {
5555
},
5656
dynamic: {
5757
type: 'string',
58-
default: '',
58+
default: FyeoBlockVars.dynamic,
5959
},
6060
},
6161

0 commit comments

Comments
 (0)