Disable Gutenberg - Version 1.5.2

Version Description

To upgrade this plugin, remove the old version and replace with the new version. Or just click "Update" from the Plugins screen and let WordPress do it for you automatically.

Note: uninstalling the plugin from the WP Plugins screen results in the removal of all settings and data from the WP database.

Download this release

Release Info

Developer specialk
Plugin Icon 128x128 Disable Gutenberg
Version 1.5.2
Comparing to
See all releases

Code changes from version 1.5.1 to 1.5.2

disable-gutenberg.php CHANGED
@@ -10,8 +10,8 @@
10
  Contributors: specialk
11
  Requires at least: 4.9
12
  Tested up to: 5.0
13
- Stable tag: 1.5.1
14
- Version: 1.5.1
15
  Requires PHP: 5.2.4
16
  Text Domain: disable-gutenberg
17
  Domain Path: /languages
@@ -51,8 +51,8 @@ if (!class_exists('DisableGutenberg')) {
51
  add_filter('plugin_action_links', array($this, 'action_links'), 10, 2);
52
  add_filter('plugin_row_meta', array($this, 'plugin_links'), 10, 2);
53
 
54
- add_action('admin_enqueue_scripts', 'disable_gutenberg_enqueue_resources_admin');
55
- add_action('admin_print_scripts', 'disable_gutenberg_print_js_vars_admin');
56
  add_action('admin_notices', 'disable_gutenberg_admin_notice');
57
  add_action('admin_init', 'disable_gutenberg_register_settings');
58
  add_action('admin_init', 'disable_gutenberg_reset_options');
@@ -63,11 +63,13 @@ if (!class_exists('DisableGutenberg')) {
63
  add_filter('admin_init', 'disable_gutenberg_disable_nag');
64
  add_filter('admin_init', 'disable_gutenberg_init');
65
 
 
 
66
  }
67
 
68
  function constants() {
69
 
70
- if (!defined('DISABLE_GUTENBERG_VERSION')) define('DISABLE_GUTENBERG_VERSION', '1.5.1');
71
  if (!defined('DISABLE_GUTENBERG_REQUIRE')) define('DISABLE_GUTENBERG_REQUIRE', '4.9');
72
  if (!defined('DISABLE_GUTENBERG_AUTHOR')) define('DISABLE_GUTENBERG_AUTHOR', 'Jeff Starr');
73
  if (!defined('DISABLE_GUTENBERG_NAME')) define('DISABLE_GUTENBERG_NAME', __('Disable Gutenberg', 'disable-gutenberg'));
@@ -84,7 +86,6 @@ if (!class_exists('DisableGutenberg')) {
84
  if (is_admin()) {
85
 
86
  require_once DISABLE_GUTENBERG_DIR .'inc/classic-editor.php';
87
-
88
  require_once DISABLE_GUTENBERG_DIR .'inc/plugin-core.php';
89
  require_once DISABLE_GUTENBERG_DIR .'inc/resources-enqueue.php';
90
  require_once DISABLE_GUTENBERG_DIR .'inc/settings-display.php';
@@ -97,6 +98,10 @@ if (!class_exists('DisableGutenberg')) {
97
 
98
  }
99
 
 
 
 
 
100
  }
101
 
102
  }
@@ -112,11 +117,12 @@ if (!class_exists('DisableGutenberg')) {
112
  'templates' => '',
113
  'post-ids' => '',
114
  'acf-enable' => 0,
115
- 'disable-links' => 0,
116
  'whitelist-id' => '',
117
  'whitelist-slug' => '',
118
  'whitelist-title' => '',
119
  'whitelist' => 0,
 
120
 
121
  );
122
 
10
  Contributors: specialk
11
  Requires at least: 4.9
12
  Tested up to: 5.0
13
+ Stable tag: 1.5.2
14
+ Version: 1.5.2
15
  Requires PHP: 5.2.4
16
  Text Domain: disable-gutenberg
17
  Domain Path: /languages
51
  add_filter('plugin_action_links', array($this, 'action_links'), 10, 2);
52
  add_filter('plugin_row_meta', array($this, 'plugin_links'), 10, 2);
53
 
54
+ add_action('admin_enqueue_scripts', 'disable_gutenberg_admin_enqueue_scripts');
55
+ add_action('admin_print_scripts', 'disable_gutenberg_admin_print_scripts');
56
  add_action('admin_notices', 'disable_gutenberg_admin_notice');
57
  add_action('admin_init', 'disable_gutenberg_register_settings');
58
  add_action('admin_init', 'disable_gutenberg_reset_options');
63
  add_filter('admin_init', 'disable_gutenberg_disable_nag');
64
  add_filter('admin_init', 'disable_gutenberg_init');
65
 
66
+ add_filter('wp_enqueue_scripts', 'disable_gutenberg_wp_enqueue_scripts', 100);
67
+
68
  }
69
 
70
  function constants() {
71
 
72
+ if (!defined('DISABLE_GUTENBERG_VERSION')) define('DISABLE_GUTENBERG_VERSION', '1.5.2');
73
  if (!defined('DISABLE_GUTENBERG_REQUIRE')) define('DISABLE_GUTENBERG_REQUIRE', '4.9');
74
  if (!defined('DISABLE_GUTENBERG_AUTHOR')) define('DISABLE_GUTENBERG_AUTHOR', 'Jeff Starr');
75
  if (!defined('DISABLE_GUTENBERG_NAME')) define('DISABLE_GUTENBERG_NAME', __('Disable Gutenberg', 'disable-gutenberg'));
86
  if (is_admin()) {
87
 
88
  require_once DISABLE_GUTENBERG_DIR .'inc/classic-editor.php';
 
89
  require_once DISABLE_GUTENBERG_DIR .'inc/plugin-core.php';
90
  require_once DISABLE_GUTENBERG_DIR .'inc/resources-enqueue.php';
91
  require_once DISABLE_GUTENBERG_DIR .'inc/settings-display.php';
98
 
99
  }
100
 
101
+ } else {
102
+
103
+ require_once DISABLE_GUTENBERG_DIR .'inc/plugin-frontend.php';
104
+
105
  }
106
 
107
  }
117
  'templates' => '',
118
  'post-ids' => '',
119
  'acf-enable' => 0,
120
+ 'links-enable' => 0,
121
  'whitelist-id' => '',
122
  'whitelist-slug' => '',
123
  'whitelist-title' => '',
124
  'whitelist' => 0,
125
+ 'styles-enable' => 0,
126
 
127
  );
128
 
inc/plugin-features.php CHANGED
@@ -8,7 +8,7 @@ function disable_gutenberg_add_submenus() {
8
 
9
  if (disable_gutenberg()) return;
10
 
11
- if (disable_gutenberg_disable_features()) return;
12
 
13
  $types = array();
14
 
@@ -59,7 +59,7 @@ add_action('admin_menu', 'disable_gutenberg_add_submenus');
59
 
60
  function disable_gutenberg_page_row_actions($actions, $post) {
61
 
62
- if (disable_gutenberg_disable_features()) return $actions;
63
 
64
  if (disable_gutenberg_whitelist($post->ID)) return $actions;
65
 
@@ -69,41 +69,41 @@ function disable_gutenberg_page_row_actions($actions, $post) {
69
 
70
  if ('trash' === $post->post_status || !post_type_supports($post->post_type, 'editor')) return $actions;
71
 
 
 
72
  $edit_url = get_edit_post_link($post->ID, 'raw');
73
 
74
  if (!$edit_url) return $actions;
75
 
76
- $title = _draft_or_post_title($post->ID);
77
 
78
- if ($post->ID && disable_gutenberg($post->ID)) {
79
-
80
- $url = remove_query_arg('classic-editor', $edit_url);
81
-
82
- $url = add_query_arg('block-editor', '', $url);
83
-
84
- $text = __('Block Editor', 'disable-gutenberg');
85
-
86
- $label = sprintf(__('Edit “%s” in the Block Editor', 'disable-gutenberg'), $title);
87
-
88
- $edit_action = sprintf('<a href="%s" aria-label="%s" title="%s">%s</a>', esc_url($url), esc_attr($label), esc_attr($label), $text);
89
-
90
- } else {
91
-
92
- $url = remove_query_arg('block-editor', $edit_url);
93
-
94
- $url = add_query_arg('classic-editor', '', $url);
95
-
96
- $text = __('Classic Editor', 'disable-gutenberg');
97
-
98
- $label = sprintf(__('Edit &#8220;%s&#8221; in the Classic Editor', 'disable-gutenberg'), $title);
99
-
100
- $edit_action = sprintf('<a href="%s" aria-label="%s" title="%s">%s</a>', esc_url($url), esc_attr($label), esc_attr($label), $text);
101
-
102
- }
103
 
104
  $edit_offset = array_search('edit', array_keys($actions), true);
105
 
106
- array_splice($actions, $edit_offset, 1, $edit_action);
 
 
107
 
108
  return $actions;
109
 
@@ -168,12 +168,12 @@ add_action('edit_form_top', 'disable_gutenberg_edit_form_top');
168
 
169
 
170
 
171
- function disable_gutenberg_disable_features() {
172
 
173
  $options = disable_gutenberg_get_options();
174
 
175
- $disable = (isset($options['disable-links']) && !empty($options['disable-links'])) ? true : false;
176
 
177
- return $disable;
178
 
179
  }
8
 
9
  if (disable_gutenberg()) return;
10
 
11
+ if (!disable_gutenberg_enable_features()) return;
12
 
13
  $types = array();
14
 
59
 
60
  function disable_gutenberg_page_row_actions($actions, $post) {
61
 
62
+ if (!disable_gutenberg_enable_features()) return $actions;
63
 
64
  if (disable_gutenberg_whitelist($post->ID)) return $actions;
65
 
69
 
70
  if ('trash' === $post->post_status || !post_type_supports($post->post_type, 'editor')) return $actions;
71
 
72
+ $title = _draft_or_post_title($post->ID);
73
+
74
  $edit_url = get_edit_post_link($post->ID, 'raw');
75
 
76
  if (!$edit_url) return $actions;
77
 
78
+ $url = remove_query_arg(array('block-editor', 'classic-editor'), $edit_url);
79
 
80
+ //
81
+
82
+ $block_url = add_query_arg('block-editor', '', $url);
83
+
84
+ $block_text = __('Block Edit', 'disable-gutenberg');
85
+
86
+ $block_label = sprintf(__('Edit &#8220;%s&#8221; in the Block Editor', 'disable-gutenberg'), $title);
87
+
88
+ $block_action = sprintf('<a href="%s" aria-label="%s" title="%s">%s</a>', esc_url($block_url), esc_attr($block_label), esc_attr($block_label), esc_html($block_text));
89
+
90
+ //
91
+
92
+ $classic_url = add_query_arg('classic-editor', '', $url);
93
+
94
+ $classic_text = __('Classic Edit', 'disable-gutenberg');
95
+
96
+ $classic_label = sprintf(__('Edit &#8220;%s&#8221; in the Classic Editor', 'disable-gutenberg'), $title);
97
+
98
+ $classic_action = sprintf('<a href="%s" aria-label="%s" title="%s">%s</a>', esc_url($classic_url), esc_attr($classic_label), esc_attr($classic_label), esc_html($classic_text));
99
+
100
+ //
 
 
 
 
101
 
102
  $edit_offset = array_search('edit', array_keys($actions), true);
103
 
104
+ array_splice($actions, $edit_offset, 1, $block_action);
105
+
106
+ array_unshift($actions, $classic_action);
107
 
108
  return $actions;
109
 
168
 
169
 
170
 
171
+ function disable_gutenberg_enable_features() {
172
 
173
  $options = disable_gutenberg_get_options();
174
 
175
+ $enable = (isset($options['links-enable']) && !empty($options['links-enable'])) ? true : false;
176
 
177
+ return $enable;
178
 
179
  }
inc/plugin-frontend.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php // Frontend stuff..
2
+
3
+ function disable_gutenberg_wp_enqueue_scripts() {
4
+
5
+ $options = get_option('disable_gutenberg_options');
6
+
7
+ $enable = isset($options['styles-enable']) ? $options['styles-enable'] : false;
8
+
9
+ if (!$enable) wp_dequeue_style('wp-block-library');
10
+
11
+ }
inc/resources-enqueue.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  if (!defined('ABSPATH')) exit;
4
 
5
- function disable_gutenberg_enqueue_resources_admin() {
6
 
7
  $screen = get_current_screen();
8
 
@@ -26,7 +26,7 @@ function disable_gutenberg_enqueue_resources_admin() {
26
 
27
  }
28
 
29
- function disable_gutenberg_print_js_vars_admin() { ?>
30
 
31
  <script type="text/javascript">
32
  var
2
 
3
  if (!defined('ABSPATH')) exit;
4
 
5
+ function disable_gutenberg_admin_enqueue_scripts() {
6
 
7
  $screen = get_current_screen();
8
 
26
 
27
  }
28
 
29
+ function disable_gutenberg_admin_print_scripts() { ?>
30
 
31
  <script type="text/javascript">
32
  var
inc/settings-register.php CHANGED
@@ -52,14 +52,15 @@ function disable_gutenberg_register_settings() {
52
  add_settings_field('whitelist-slug', __('Whitelist Post Slugs', 'disable-gutenberg'), 'disable_gutenberg_callback_text', 'disable_gutenberg_options', 'settings_6', array('id' => 'whitelist-slug', 'label' => esc_html__('Post slugs that always should use the Block Editor', 'disable-gutenberg')));
53
  add_settings_field('whitelist-title', __('Whitelist Post Titles', 'disable-gutenberg'), 'disable_gutenberg_callback_text', 'disable_gutenberg_options', 'settings_6', array('id' => 'whitelist-title', 'label' => esc_html__('Post titles that always should use the Block Editor', 'disable-gutenberg')));
54
 
55
- add_settings_field('disable-nag', __('Disable Nag', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'disable-nag', 'label' => esc_html__('Disable "Try Gutenberg" nag', 'disable-gutenberg')));
56
- add_settings_field('whitelist', __('Whitelist', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'whitelist', 'label' => esc_html__('Display Whitelist settings', 'disable-gutenberg')));
57
- add_settings_field('hide-menu', __('Plugin Menu Item', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'hide-menu', 'label' => esc_html__('Hide this plugin&rsquo;s menu item', 'disable-gutenberg')));
58
- add_settings_field('hide-gut', __('Gutenberg Menu Item', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'hide-gut', 'label' => esc_html__('Hide Gutenberg plugin&rsquo;s menu item (for WP &lt; 5.0)', 'disable-gutenberg')));
59
- add_settings_field('disable-links', __('Disable "Classic" Links', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'disable-links', 'label' => esc_html__('Disable "Add New (Classic)" menu link and "Classic Editor" edit link', 'disable-gutenberg')));
60
- add_settings_field('acf-enable', __('ACF Support', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'acf-enable', 'label' => esc_html__('Enable Custom Fields Meta Box (ACF disables by default),', 'disable-gutenberg') .' <a target="_blank" rel="noopener noreferrer" href="https://m0n.co/acf">'. esc_html__('learn more', 'disable-gutenberg') .'</a>'));
61
- add_settings_field('reset_options', __('Reset Options', 'disable-gutenberg'), 'disable_gutenberg_callback_reset', 'disable_gutenberg_options', 'settings_7', array('id' => 'reset_options', 'label' => esc_html__('Restore default plugin options', 'disable-gutenberg')));
62
- add_settings_field('rate_plugin', __('Rate Plugin', 'disable-gutenberg'), 'disable_gutenberg_callback_rate', 'disable_gutenberg_options', 'settings_7', array('id' => 'rate_plugin', 'label' => esc_html__('Show support with a 5-star rating&nbsp;&raquo;', 'disable-gutenberg')));
 
63
 
64
  }
65
 
@@ -108,6 +109,9 @@ function disable_gutenberg_validate_options($input) {
108
  if (!isset($input['disable-nag'])) $input['disable-nag'] = null;
109
  $input['disable-nag'] = ($input['disable-nag'] == 1 ? 1 : 0);
110
 
 
 
 
111
  if (!isset($input['whitelist'])) $input['whitelist'] = null;
112
  $input['whitelist'] = ($input['whitelist'] == 1 ? 1 : 0);
113
 
@@ -117,8 +121,8 @@ function disable_gutenberg_validate_options($input) {
117
  if (!isset($input['hide-gut'])) $input['hide-gut'] = null;
118
  $input['hide-gut'] = ($input['hide-gut'] == 1 ? 1 : 0);
119
 
120
- if (!isset($input['disable-links'])) $input['disable-links'] = null;
121
- $input['disable-links'] = ($input['disable-links'] == 1 ? 1 : 0);
122
 
123
  if (!isset($input['acf-enable'])) $input['acf-enable'] = null;
124
  $input['acf-enable'] = ($input['acf-enable'] == 1 ? 1 : 0);
@@ -165,7 +169,7 @@ function disable_gutenberg_settings_section_6() {
165
 
166
  function disable_gutenberg_settings_section_7() {
167
 
168
- echo '<p class="g7g-display"><a class="g7g-toggle" href="#more-tools" title="'. esc_attr__('Toggle More Tools', 'disable-gutenberg') .'">'. esc_html__('Click here', 'disable-gutenberg') .'</a> '. esc_html__('to display more tools and options. Note: these options will continue to work even when hidden on this page.', 'disable-gutenberg') .'</p>';
169
 
170
  }
171
 
52
  add_settings_field('whitelist-slug', __('Whitelist Post Slugs', 'disable-gutenberg'), 'disable_gutenberg_callback_text', 'disable_gutenberg_options', 'settings_6', array('id' => 'whitelist-slug', 'label' => esc_html__('Post slugs that always should use the Block Editor', 'disable-gutenberg')));
53
  add_settings_field('whitelist-title', __('Whitelist Post Titles', 'disable-gutenberg'), 'disable_gutenberg_callback_text', 'disable_gutenberg_options', 'settings_6', array('id' => 'whitelist-title', 'label' => esc_html__('Post titles that always should use the Block Editor', 'disable-gutenberg')));
54
 
55
+ add_settings_field('disable-nag', __('Disable Nag', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'disable-nag', 'label' => esc_html__('Disable "Try Gutenberg" nag', 'disable-gutenberg')));
56
+ add_settings_field('styles-enable', __('Enable Frontend', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'styles-enable', 'label' => esc_html__('Enable frontend Gutenberg styles', 'disable-gutenberg')));
57
+ add_settings_field('whitelist', __('Whitelist Options', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'whitelist', 'label' => esc_html__('Display Whitelist settings', 'disable-gutenberg')));
58
+ add_settings_field('hide-menu', __('Plugin Menu Item', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'hide-menu', 'label' => esc_html__('Hide this plugin&rsquo;s menu item', 'disable-gutenberg')));
59
+ add_settings_field('hide-gut', __('Gutenberg Menu Item', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'hide-gut', 'label' => esc_html__('Hide Gutenberg plugin&rsquo;s menu item (for WP &lt; 5.0)', 'disable-gutenberg')));
60
+ add_settings_field('links-enable', __('Display Edit Links', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'links-enable', 'label' => esc_html__('Display "Add New (Classic)" menu link and Classic/Block edit links', 'disable-gutenberg')));
61
+ add_settings_field('acf-enable', __('ACF Support', 'disable-gutenberg'), 'disable_gutenberg_callback_checkbox', 'disable_gutenberg_options', 'settings_7', array('id' => 'acf-enable', 'label' => esc_html__('Enable Custom Fields Meta Box (ACF disables by default),', 'disable-gutenberg') .' <a target="_blank" rel="noopener noreferrer" href="https://m0n.co/acf">'. esc_html__('learn more', 'disable-gutenberg') .'</a>'));
62
+ add_settings_field('reset_options', __('Reset Options', 'disable-gutenberg'), 'disable_gutenberg_callback_reset', 'disable_gutenberg_options', 'settings_7', array('id' => 'reset_options', 'label' => esc_html__('Restore default plugin options', 'disable-gutenberg')));
63
+ add_settings_field('rate_plugin', __('Rate Plugin', 'disable-gutenberg'), 'disable_gutenberg_callback_rate', 'disable_gutenberg_options', 'settings_7', array('id' => 'rate_plugin', 'label' => esc_html__('Show support with a 5-star rating&nbsp;&raquo;', 'disable-gutenberg')));
64
 
65
  }
66
 
109
  if (!isset($input['disable-nag'])) $input['disable-nag'] = null;
110
  $input['disable-nag'] = ($input['disable-nag'] == 1 ? 1 : 0);
111
 
112
+ if (!isset($input['styles-enable'])) $input['styles-enable'] = null;
113
+ $input['styles-enable'] = ($input['styles-enable'] == 1 ? 1 : 0);
114
+
115
  if (!isset($input['whitelist'])) $input['whitelist'] = null;
116
  $input['whitelist'] = ($input['whitelist'] == 1 ? 1 : 0);
117
 
121
  if (!isset($input['hide-gut'])) $input['hide-gut'] = null;
122
  $input['hide-gut'] = ($input['hide-gut'] == 1 ? 1 : 0);
123
 
124
+ if (!isset($input['links-enable'])) $input['links-enable'] = null;
125
+ $input['links-enable'] = ($input['links-enable'] == 1 ? 1 : 0);
126
 
127
  if (!isset($input['acf-enable'])) $input['acf-enable'] = null;
128
  $input['acf-enable'] = ($input['acf-enable'] == 1 ? 1 : 0);
169
 
170
  function disable_gutenberg_settings_section_7() {
171
 
172
+ echo '<p class="g7g-display"><a class="g7g-toggle" href="#more-tools" title="'. esc_attr__('Toggle More Tools', 'disable-gutenberg') .'">'. esc_html__('Click here', 'disable-gutenberg') .'</a> '. esc_html__('to display more tools and options. Note: these options remain in effect even when hidden on this page.', 'disable-gutenberg') .'</p>';
173
 
174
  }
175
 
js/settings.js CHANGED
@@ -97,12 +97,14 @@ function disable_gutenberg_toggle_more($) {
97
  var row4 = table.find('tr:nth-child(4)');
98
  var row5 = table.find('tr:nth-child(5)');
99
  var row6 = table.find('tr:nth-child(6)');
 
100
 
101
  $(row2).hide();
102
  $(row3).hide();
103
  $(row4).hide();
104
  $(row5).hide();
105
  $(row6).hide();
 
106
 
107
  $('.g7g-toggle').click(function(e) {
108
  e.preventDefault();
@@ -111,6 +113,7 @@ function disable_gutenberg_toggle_more($) {
111
  $(row4).slideToggle();
112
  $(row5).slideToggle();
113
  $(row6).slideToggle();
 
114
  return false;
115
  });
116
 
97
  var row4 = table.find('tr:nth-child(4)');
98
  var row5 = table.find('tr:nth-child(5)');
99
  var row6 = table.find('tr:nth-child(6)');
100
+ var row7 = table.find('tr:nth-child(7)');
101
 
102
  $(row2).hide();
103
  $(row3).hide();
104
  $(row4).hide();
105
  $(row5).hide();
106
  $(row6).hide();
107
+ $(row7).hide();
108
 
109
  $('.g7g-toggle').click(function(e) {
110
  e.preventDefault();
113
  $(row4).slideToggle();
114
  $(row5).slideToggle();
115
  $(row6).slideToggle();
116
+ $(row7).slideToggle();
117
  return false;
118
  });
119
 
languages/disable-gutenberg.pot CHANGED
@@ -3,7 +3,7 @@ msgid ""
3
  msgstr ""
4
  "Project-Id-Version: Disable Gutenberg\n"
5
  "Report-Msgid-Bugs-To: \n"
6
- "POT-Creation-Date: 2018-12-10 22:02+0000\n"
7
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
8
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
9
  "Language-Team: \n"
@@ -15,51 +15,51 @@ msgstr ""
15
  "X-Generator: Loco https://localise.biz/"
16
 
17
  #. Name of the plugin
18
- #: disable-gutenberg.php:73
19
  msgid "Disable Gutenberg"
20
  msgstr ""
21
 
22
- #: disable-gutenberg.php:151
23
  msgid "Settings"
24
  msgstr ""
25
 
26
- #: disable-gutenberg.php:166
27
  msgid "Plugin Homepage"
28
  msgstr ""
29
 
30
- #: disable-gutenberg.php:167
31
  msgid "Homepage"
32
  msgstr ""
33
 
34
- #: disable-gutenberg.php:172
35
  msgid "Click here to rate and review this plugin on WordPress.org"
36
  msgstr ""
37
 
38
- #: disable-gutenberg.php:173
39
  msgid "Rate this plugin"
40
  msgstr ""
41
 
42
- #: disable-gutenberg.php:195
43
  msgid "requires WordPress "
44
  msgstr ""
45
 
46
- #: disable-gutenberg.php:196
47
  msgid " or higher, and has been deactivated! "
48
  msgstr ""
49
 
50
- #: disable-gutenberg.php:197
51
  msgid "Please return to the"
52
  msgstr ""
53
 
54
- #: disable-gutenberg.php:198
55
  msgid "WP Admin Area"
56
  msgstr ""
57
 
58
- #: disable-gutenberg.php:198
59
  msgid "to upgrade WordPress and try again."
60
  msgstr ""
61
 
62
- #: disable-gutenberg.php:218 disable-gutenberg.php:224
63
  msgid "Sorry, pal!"
64
  msgstr ""
65
 
@@ -132,109 +132,116 @@ msgid "Disable \"Try Gutenberg\" nag"
132
  msgstr ""
133
 
134
  #: inc/settings-register.php:56
135
- msgid "Whitelist"
136
  msgstr ""
137
 
138
  #: inc/settings-register.php:56
139
- msgid "Display Whitelist settings"
140
  msgstr ""
141
 
142
  #: inc/settings-register.php:57
143
- msgid "Plugin Menu Item"
144
  msgstr ""
145
 
146
  #: inc/settings-register.php:57
147
- msgid "Hide this plugin&rsquo;s menu item"
148
  msgstr ""
149
 
150
  #: inc/settings-register.php:58
151
- msgid "Gutenberg Menu Item"
152
  msgstr ""
153
 
154
  #: inc/settings-register.php:58
155
- msgid "Hide Gutenberg plugin&rsquo;s menu item (for WP &lt; 5.0)"
156
  msgstr ""
157
 
158
  #: inc/settings-register.php:59
159
- msgid "Disable \"Classic\" Links"
160
  msgstr ""
161
 
162
  #: inc/settings-register.php:59
163
- msgid ""
164
- "Disable \"Add New (Classic)\" menu link and \"Classic Editor\" edit link"
165
  msgstr ""
166
 
167
  #: inc/settings-register.php:60
168
- msgid "ACF Support"
169
  msgstr ""
170
 
171
  #: inc/settings-register.php:60
 
 
 
 
 
 
 
 
172
  msgid "Enable Custom Fields Meta Box (ACF disables by default),"
173
  msgstr ""
174
 
175
- #: inc/settings-register.php:60
176
  msgid "learn more"
177
  msgstr ""
178
 
179
- #: inc/settings-register.php:61
180
  msgid "Reset Options"
181
  msgstr ""
182
 
183
- #: inc/settings-register.php:61 inc/settings-register.php:225
184
  msgid "Restore default plugin options"
185
  msgstr ""
186
 
187
- #: inc/settings-register.php:62
188
  msgid "Rate Plugin"
189
  msgstr ""
190
 
191
- #: inc/settings-register.php:62 inc/settings-register.php:235
192
  msgid "Show support with a 5-star rating&nbsp;&raquo;"
193
  msgstr ""
194
 
195
- #: inc/settings-register.php:132
196
  msgid ""
197
  "Enable this setting to completely disable Gutenberg (and restore the Classic "
198
  "Editor). Or, disable this setting to display more options."
199
  msgstr ""
200
 
201
- #: inc/settings-register.php:138
202
  msgid "Select the user roles for which Gutenberg should be disabled."
203
  msgstr ""
204
 
205
- #: inc/settings-register.php:144
206
  msgid "Select the post types for which Gutenberg should be disabled."
207
  msgstr ""
208
 
209
- #: inc/settings-register.php:150
210
  msgid "Select the theme template files for which Gutenberg should be disabled."
211
  msgstr ""
212
 
213
- #: inc/settings-register.php:156
214
  msgid "Select the post IDs for which Gutenberg should be disabled."
215
  msgstr ""
216
 
217
- #: inc/settings-register.php:162
218
  msgid ""
219
  "Select the posts that always should use the Gutenberg Block Editor. Separate "
220
  "multiple values with commas."
221
  msgstr ""
222
 
223
- #: inc/settings-register.php:168
224
  msgid "Toggle More Tools"
225
  msgstr ""
226
 
227
- #: inc/settings-register.php:168
228
  msgid "Click here"
229
  msgstr ""
230
 
231
- #: inc/settings-register.php:168
232
  msgid ""
233
- "to display more tools and options. Note: these options will continue to work "
234
- "even when hidden on this page."
235
  msgstr ""
236
 
237
- #: inc/settings-register.php:234
238
  msgid "Please give a 5-star rating! A huge THANK YOU for your support!"
239
  msgstr ""
240
 
@@ -267,7 +274,7 @@ msgid "(Classic)"
267
  msgstr ""
268
 
269
  #: inc/plugin-features.php:84
270
- msgid "Block Editor"
271
  msgstr ""
272
 
273
  #: inc/plugin-features.php:86
@@ -275,11 +282,11 @@ msgstr ""
275
  msgid "Edit &#8220;%s&#8221; in the Block Editor"
276
  msgstr ""
277
 
278
- #: inc/plugin-features.php:96
279
- msgid "Classic Editor"
280
  msgstr ""
281
 
282
- #: inc/plugin-features.php:98
283
  #, php-format
284
  msgid "Edit &#8220;%s&#8221; in the Classic Editor"
285
  msgstr ""
3
  msgstr ""
4
  "Project-Id-Version: Disable Gutenberg\n"
5
  "Report-Msgid-Bugs-To: \n"
6
+ "POT-Creation-Date: 2018-12-12 01:13+0000\n"
7
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
8
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
9
  "Language-Team: \n"
15
  "X-Generator: Loco https://localise.biz/"
16
 
17
  #. Name of the plugin
18
+ #: disable-gutenberg.php:75
19
  msgid "Disable Gutenberg"
20
  msgstr ""
21
 
22
+ #: disable-gutenberg.php:157
23
  msgid "Settings"
24
  msgstr ""
25
 
26
+ #: disable-gutenberg.php:172
27
  msgid "Plugin Homepage"
28
  msgstr ""
29
 
30
+ #: disable-gutenberg.php:173
31
  msgid "Homepage"
32
  msgstr ""
33
 
34
+ #: disable-gutenberg.php:178
35
  msgid "Click here to rate and review this plugin on WordPress.org"
36
  msgstr ""
37
 
38
+ #: disable-gutenberg.php:179
39
  msgid "Rate this plugin"
40
  msgstr ""
41
 
42
+ #: disable-gutenberg.php:201
43
  msgid "requires WordPress "
44
  msgstr ""
45
 
46
+ #: disable-gutenberg.php:202
47
  msgid " or higher, and has been deactivated! "
48
  msgstr ""
49
 
50
+ #: disable-gutenberg.php:203
51
  msgid "Please return to the"
52
  msgstr ""
53
 
54
+ #: disable-gutenberg.php:204
55
  msgid "WP Admin Area"
56
  msgstr ""
57
 
58
+ #: disable-gutenberg.php:204
59
  msgid "to upgrade WordPress and try again."
60
  msgstr ""
61
 
62
+ #: disable-gutenberg.php:224 disable-gutenberg.php:230
63
  msgid "Sorry, pal!"
64
  msgstr ""
65
 
132
  msgstr ""
133
 
134
  #: inc/settings-register.php:56
135
+ msgid "Enable Frontend"
136
  msgstr ""
137
 
138
  #: inc/settings-register.php:56
139
+ msgid "Enable frontend Gutenberg styles"
140
  msgstr ""
141
 
142
  #: inc/settings-register.php:57
143
+ msgid "Whitelist Options"
144
  msgstr ""
145
 
146
  #: inc/settings-register.php:57
147
+ msgid "Display Whitelist settings"
148
  msgstr ""
149
 
150
  #: inc/settings-register.php:58
151
+ msgid "Plugin Menu Item"
152
  msgstr ""
153
 
154
  #: inc/settings-register.php:58
155
+ msgid "Hide this plugin&rsquo;s menu item"
156
  msgstr ""
157
 
158
  #: inc/settings-register.php:59
159
+ msgid "Gutenberg Menu Item"
160
  msgstr ""
161
 
162
  #: inc/settings-register.php:59
163
+ msgid "Hide Gutenberg plugin&rsquo;s menu item (for WP &lt; 5.0)"
 
164
  msgstr ""
165
 
166
  #: inc/settings-register.php:60
167
+ msgid "Display Edit Links"
168
  msgstr ""
169
 
170
  #: inc/settings-register.php:60
171
+ msgid "Display \"Add New (Classic)\" menu link and Classic/Block edit links"
172
+ msgstr ""
173
+
174
+ #: inc/settings-register.php:61
175
+ msgid "ACF Support"
176
+ msgstr ""
177
+
178
+ #: inc/settings-register.php:61
179
  msgid "Enable Custom Fields Meta Box (ACF disables by default),"
180
  msgstr ""
181
 
182
+ #: inc/settings-register.php:61
183
  msgid "learn more"
184
  msgstr ""
185
 
186
+ #: inc/settings-register.php:62
187
  msgid "Reset Options"
188
  msgstr ""
189
 
190
+ #: inc/settings-register.php:62 inc/settings-register.php:229
191
  msgid "Restore default plugin options"
192
  msgstr ""
193
 
194
+ #: inc/settings-register.php:63
195
  msgid "Rate Plugin"
196
  msgstr ""
197
 
198
+ #: inc/settings-register.php:63 inc/settings-register.php:239
199
  msgid "Show support with a 5-star rating&nbsp;&raquo;"
200
  msgstr ""
201
 
202
+ #: inc/settings-register.php:136
203
  msgid ""
204
  "Enable this setting to completely disable Gutenberg (and restore the Classic "
205
  "Editor). Or, disable this setting to display more options."
206
  msgstr ""
207
 
208
+ #: inc/settings-register.php:142
209
  msgid "Select the user roles for which Gutenberg should be disabled."
210
  msgstr ""
211
 
212
+ #: inc/settings-register.php:148
213
  msgid "Select the post types for which Gutenberg should be disabled."
214
  msgstr ""
215
 
216
+ #: inc/settings-register.php:154
217
  msgid "Select the theme template files for which Gutenberg should be disabled."
218
  msgstr ""
219
 
220
+ #: inc/settings-register.php:160
221
  msgid "Select the post IDs for which Gutenberg should be disabled."
222
  msgstr ""
223
 
224
+ #: inc/settings-register.php:166
225
  msgid ""
226
  "Select the posts that always should use the Gutenberg Block Editor. Separate "
227
  "multiple values with commas."
228
  msgstr ""
229
 
230
+ #: inc/settings-register.php:172
231
  msgid "Toggle More Tools"
232
  msgstr ""
233
 
234
+ #: inc/settings-register.php:172
235
  msgid "Click here"
236
  msgstr ""
237
 
238
+ #: inc/settings-register.php:172
239
  msgid ""
240
+ "to display more tools and options. Note: these options remain in effect even "
241
+ "when hidden on this page."
242
  msgstr ""
243
 
244
+ #: inc/settings-register.php:238
245
  msgid "Please give a 5-star rating! A huge THANK YOU for your support!"
246
  msgstr ""
247
 
274
  msgstr ""
275
 
276
  #: inc/plugin-features.php:84
277
+ msgid "Block Edit"
278
  msgstr ""
279
 
280
  #: inc/plugin-features.php:86
282
  msgid "Edit &#8220;%s&#8221; in the Block Editor"
283
  msgstr ""
284
 
285
+ #: inc/plugin-features.php:94
286
+ msgid "Classic Edit"
287
  msgstr ""
288
 
289
+ #: inc/plugin-features.php:96
290
  #, php-format
291
  msgid "Edit &#8220;%s&#8221; in the Classic Editor"
292
  msgstr ""
readme.txt CHANGED
@@ -10,8 +10,8 @@ Donate link: https://monzillamedia.com/donate.html
10
  Contributors: specialk
11
  Requires at least: 4.9
12
  Tested up to: 5.0
13
- Stable tag: 1.5.1
14
- Version: 1.5.1
15
  Requires PHP: 5.2.4
16
  Text Domain: disable-gutenberg
17
  Domain Path: /languages
@@ -54,6 +54,7 @@ Just activate and done! The default plugin settings are configured to hide all t
54
  * NEW! Option to enable Custom Fields Meta Box for ACF
55
  * NEW! Choose which editor to use for each post
56
  * NEW! Whitelist any post title, slug, or ID
 
57
 
58
  > Works same way as Classic Editor plugin, but can do a LOT more!
59
  > Lightweight and super fast, built with the WP API :)
@@ -260,6 +261,13 @@ Version 1.5 brings some great new features and improvements. Note that better Mu
260
 
261
  Cheers and Happy Holidays to all! :)
262
 
 
 
 
 
 
 
 
263
  **1.5.1 (2018/12/10)**
264
 
265
  * Fixes possible false negative with whitelist settings
10
  Contributors: specialk
11
  Requires at least: 4.9
12
  Tested up to: 5.0
13
+ Stable tag: 1.5.2
14
+ Version: 1.5.2
15
  Requires PHP: 5.2.4
16
  Text Domain: disable-gutenberg
17
  Domain Path: /languages
54
  * NEW! Option to enable Custom Fields Meta Box for ACF
55
  * NEW! Choose which editor to use for each post
56
  * NEW! Whitelist any post title, slug, or ID
57
+ * NEW! Option to disables frontend Gutenberg stylesheet
58
 
59
  > Works same way as Classic Editor plugin, but can do a LOT more!
60
  > Lightweight and super fast, built with the WP API :)
261
 
262
  Cheers and Happy Holidays to all! :)
263
 
264
+
265
+ **1.5.2 (2018/12/11)**
266
+
267
+ * Changes default option for the menu and edit links
268
+ * Adds option to disable frontend Gutenberg styles
269
+ * Updates default translation template
270
+
271
  **1.5.1 (2018/12/10)**
272
 
273
  * Fixes possible false negative with whitelist settings