@@ -4,7 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use Flynt; |
6 | 6 | |
7 | -add_filter('Flynt/addComponentData?name=BlockWysiwyg', function ($data) { |
|
7 | +add_filter('Flynt/addComponentData?name=BlockWysiwyg', function($data) { |
|
8 | 8 | return $data; |
9 | 9 | }); |
10 | 10 |
@@ -5,7 +5,7 @@ |
||
5 | 5 | use Flynt; |
6 | 6 | use Flynt\Utils\Component; |
7 | 7 | |
8 | -add_filter('Flynt/addComponentData?name=SliderImageGallery', function ($data) { |
|
8 | +add_filter('Flynt/addComponentData?name=SliderImageGallery', function($data) { |
|
9 | 9 | Component::enqueueAssets('SliderImageGallery', [ |
10 | 10 | [ |
11 | 11 | 'name' => 'slick-carousel', |
@@ -5,7 +5,7 @@ |
||
5 | 5 | use Flynt; |
6 | 6 | use Flynt\Utils\Options; |
7 | 7 | |
8 | -add_filter('Flynt/addComponentData?name=GridPosts', function ($data) { |
|
8 | +add_filter('Flynt/addComponentData?name=GridPosts', function($data) { |
|
9 | 9 | return $data; |
10 | 10 | }, 10, 2); |
11 | 11 |
@@ -4,7 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use Flynt; |
6 | 6 | |
7 | -add_filter('Flynt/addComponentData?name=AccordionDefault', function ($data) { |
|
7 | +add_filter('Flynt/addComponentData?name=AccordionDefault', function($data) { |
|
8 | 8 | return $data; |
9 | 9 | }); |
10 | 10 |
@@ -6,11 +6,11 @@ discard block |
||
6 | 6 | use Flynt\ComponentManager; |
7 | 7 | use Flynt\Utils\Asset; |
8 | 8 | |
9 | -add_filter('Flynt/addComponentData?name=ListComponents', function ($data) { |
|
9 | +add_filter('Flynt/addComponentData?name=ListComponents', function($data) { |
|
10 | 10 | if (!empty($data['componentBlocks'])) { |
11 | - $data['componentBlocks'] = array_map(function ($block) { |
|
11 | + $data['componentBlocks'] = array_map(function($block) { |
|
12 | 12 | $componentPaths = explode('/', $block['component']); |
13 | - $block['component'] = implode('/', array_slice($componentPaths, count($componentPaths)-3, 3)); |
|
13 | + $block['component'] = implode('/', array_slice($componentPaths, count($componentPaths) - 3, 3)); |
|
14 | 14 | |
15 | 15 | if (file_exists(Asset::requirePath($block['component'] . 'preview-desktop.jpg'))) { |
16 | 16 | $src = Asset::requireUrl($block['component'] . 'preview-desktop.jpg'); |
@@ -22,7 +22,7 @@ discard block |
||
22 | 22 | ]; |
23 | 23 | } |
24 | 24 | |
25 | - if (file_exists(Asset::requirePath($block['component']."preview-mobile.jpg"))) { |
|
25 | + if (file_exists(Asset::requirePath($block['component'] . "preview-mobile.jpg"))) { |
|
26 | 26 | $src = Asset::requireUrl($block['component'] . 'preview-mobile.jpg'); |
27 | 27 | list($width, $height) = getimagesize(Asset::requirePath($block['component'] . 'preview-mobile.jpg')); |
28 | 28 | |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | }); |
46 | 46 | |
47 | 47 | |
48 | -add_filter('acf/load_field/name=component', function ($field) { |
|
48 | +add_filter('acf/load_field/name=component', function($field) { |
|
49 | 49 | $componentManager = ComponentManager::getInstance(); |
50 | 50 | $field['choices'] = array_flip($componentManager->getAll()); |
51 | 51 | return $field; |