@@ -5,7 +5,7 @@ discard block |
||
| 5 | 5 | |
| 6 | 6 | define(__NAMESPACE__ . '\NS', __NAMESPACE__ . '\\'); |
| 7 | 7 | |
| 8 | -add_action('wp_enqueue_scripts', function () { |
|
| 8 | +add_action('wp_enqueue_scripts', function() { |
|
| 9 | 9 | if (is_user_logged_in()) { |
| 10 | 10 | Asset::register([ |
| 11 | 11 | 'type' => 'script', |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | wp_localize_script('Flynt/assets/auth', 'wpData', $data); |
| 21 | 21 | }); |
| 22 | 22 | |
| 23 | -add_action('admin_enqueue_scripts', function () { |
|
| 23 | +add_action('admin_enqueue_scripts', function() { |
|
| 24 | 24 | $data = [ |
| 25 | 25 | 'templateDirectoryUri' => get_template_directory_uri() . '/dist', |
| 26 | 26 | ]; |
@@ -31,7 +31,7 @@ discard block |
||
| 31 | 31 | if (is_user_logged_in() || is_admin()) { |
| 32 | 32 | if (is_admin()) { |
| 33 | 33 | // add image to the flexible content component name |
| 34 | - add_filter('acf/fields/flexible_content/layout_title', function ($title, $field, $layout, $i) { |
|
| 34 | + add_filter('acf/fields/flexible_content/layout_title', function($title, $field, $layout, $i) { |
|
| 35 | 35 | $componentName = ucfirst($layout['name']); |
| 36 | 36 | $componentPath = "Components/{$componentName}"; |
| 37 | 37 | $componentPreviewDesktopPath = Asset::requirePath("{$componentPath}/preview-desktop.jpg"); |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | }, 11, 4); |
| 48 | 48 | } else { |
| 49 | 49 | // adds Component Previews button to admin bar on front-end when logged in |
| 50 | - add_action('admin_bar_menu', function ($wpAdminBar) { |
|
| 50 | + add_action('admin_bar_menu', function($wpAdminBar) { |
|
| 51 | 51 | $title = __('Component Previews', 'flynt-starter-theme'); |
| 52 | 52 | $wpAdminBar->add_node([ |
| 53 | 53 | 'id' => 'toggleComponentPreviews', |