PluginProbe
WDesignKit – AI Templates, Widget Builder & MCP Workflow / 1.0.21
WDesignKit – AI Templates, Widget Builder & MCP Workflow v1.0.21
2.6.6 2.6.5 2.6.4 2.6.3 2.6.2 2.6.1 2.6.0 2.5.5 2.5.4 2.5.3 2.5.2 2.5.1 2.5.0 2.4.0 2.3.3 2.3.2 2.3.1 1.0.10 1.0.11 1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 All 128 releases
← All changes | includes/admin/class-wdkit-enqueue.php +22 -10 1.0.141.0.21 View file →
@@ -96,22 +96,34 @@
96 96 *
97 97 * @since 1.0.0
98 98 */
99 99 protected function wdkit_use_editor() {
100 - global $current_screen;
100 + global $current_screen;
101 101
102 - $editor = 'wdkit';
103 - if ( isset( $_GET['action'] ) && 'elementor' === $_GET['action'] ) {
104 - $editor = 'elementor';
105 - }
102 + $editor = 'wdkit';
106 103
107 - if ( $current_screen->is_block_editor() && isset( $_GET['action'] ) && 'elementor' !== $_GET['action'] ) {
108 - $editor = 'gutenberg';
109 - }
104 + $action = ! empty( $_GET['action'] ) ? $_GET['action'] : '';
110 105
111 - return $editor;
112 - }
106 + if( $current_screen->is_block_editor() ){
113 107
108 + if ( array_key_exists('action', $_GET) && isset( $action ) ) {
109 + if ( 'elementor' === $action ) {
110 + $editor = 'elementor';
111 + } else if ( 'edit' === $action ) {
112 + $editor = 'gutenberg';
113 + }
114 + } else {
115 + $editor = 'gutenberg';
116 + }
117 + } else {
118 + if ( 'elementor' === $action ) {
119 + $editor = 'elementor';
120 + }
121 + }
122 +
123 + return $editor;
124 + }
125 +
114 126 /**
115 127 * Load Admin Scripts.
116 128 *
117 129 * @since 1.0.0