PluginProbe
Kit (formerly ConvertKit) – Email Newsletter, Email Marketing, Membership, Subscribers and Landing Pages / 2.7.4
Kit (formerly ConvertKit) – Email Newsletter, Email Marketing, Membership, Subscribers and Landing Pages v2.7.4
3.4.3 3.4.2 3.4.1 3.4.0 3.3.9 3.3.8 3.3.7 3.3.6 3.3.5 3.3.4 3.3.3 3.3.2 3.3.1 2.2.0 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.2.6 2.2.7 2.2.8 2.2.9 2.3.0 2.3.1 All 196 releases
← All changes | admin/class-convertkit-admin-tinymce.php +9 -13 2.3.22.7.4 View file →
@@ -59,11 +59,11 @@
59 59
60 60 // Define shortcode.
61 61 $shortcode = $shortcodes[ $shortcode_name ];
62 62
63 - // Show a message in the modal if no API Key is specified.
64 - if ( array_key_exists( 'has_api_key', $shortcode ) && ! $shortcode['has_api_key'] ) {
65 - $notice = $shortcode['no_api_key'];
63 + // Show a message in the modal if no Access Token is specified.
64 + if ( array_key_exists( 'has_access_token', $shortcode ) && ! $shortcode['has_access_token'] ) {
65 + $notice = $shortcode['no_access_token'];
66 66 require_once CONVERTKIT_PLUGIN_PATH . '/views/backend/tinymce/modal-notice.php';
67 67 die();
68 68 }
69 69
@@ -96,14 +96,14 @@
96 96 // Get shortcodes.
97 97 $shortcodes = convertkit_get_shortcodes();
98 98
99 99 // Bail if no shortcode are available.
100 - if ( ! is_array( $shortcodes ) || ! count( $shortcodes ) ) {
100 + if ( ! count( $shortcodes ) ) {
101 101 return;
102 102 }
103 103
104 104 // Enqueue Quicktag JS.
105 - wp_enqueue_script( 'convertkit-admin-quicktags', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/quicktags.js', array( 'jquery', 'quicktags' ), CONVERTKIT_PLUGIN_VERSION, true );
105 + wp_enqueue_script( 'convertkit-admin-quicktags', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/quicktags.js', array( 'quicktags' ), CONVERTKIT_PLUGIN_VERSION, true );
106 106
107 107 // Make shortcodes available as convertkit_quicktags JS variable.
108 108 wp_localize_script( 'convertkit-admin-quicktags', 'convertkit_quicktags', $shortcodes );
109 109
@@ -118,12 +118,8 @@
118 118
119 119 // Enqueue Quicktag CSS.
120 120 wp_enqueue_style( 'convertkit-admin-quicktags', CONVERTKIT_PLUGIN_URL . 'resources/backend/css/quicktags.css', array(), CONVERTKIT_PLUGIN_VERSION );
121 121
122 - // Enqueue WordPress JS and CSS.
123 - wp_enqueue_script( 'wp-color-picker' );
124 - wp_enqueue_style( 'wp-color-picker' );
125 -
126 122 // Output Backbone View Template.
127 123 add_action( 'wp_print_footer_scripts', array( $this, 'output_quicktags_modal' ) );
128 124 add_action( 'admin_print_footer_scripts', array( $this, 'output_quicktags_modal' ) );
129 125
@@ -142,16 +138,16 @@
142 138 // Get shortcodes.
143 139 $shortcodes = convertkit_get_shortcodes();
144 140
145 141 // Bail if no shortcodes are available.
146 - if ( ! is_array( $shortcodes ) || ! count( $shortcodes ) ) {
142 + if ( ! count( $shortcodes ) ) {
147 143 return $plugins;
148 144 }
149 145
150 146 // Enqueue TinyMCE CSS and JS.
151 147 wp_enqueue_script( 'convertkit-admin-tabs', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/tabs.js', array( 'jquery' ), CONVERTKIT_PLUGIN_VERSION, true );
152 - wp_enqueue_script( 'convertkit-admin-tinymce', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/tinymce.js', array( 'jquery' ), CONVERTKIT_PLUGIN_VERSION, true );
153 - wp_enqueue_script( 'convertkit-admin-modal', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/modal.js', array( 'jquery' ), CONVERTKIT_PLUGIN_VERSION, true );
148 + wp_enqueue_script( 'convertkit-admin-tinymce', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/tinymce.js', array(), CONVERTKIT_PLUGIN_VERSION, true );
149 + wp_enqueue_script( 'convertkit-admin-modal', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/modal.js', array(), CONVERTKIT_PLUGIN_VERSION, true );
154 150 wp_enqueue_style( 'convertkit-admin-tinymce', CONVERTKIT_PLUGIN_URL . 'resources/backend/css/tinymce.css', array(), CONVERTKIT_PLUGIN_VERSION );
155 151
156 152 // Register JS variable convertkit_admin_tinymce.nonce for AJAX calls.
157 153 wp_localize_script(
@@ -187,9 +183,9 @@
187 183 // Get shortcodes.
188 184 $shortcodes = convertkit_get_shortcodes();
189 185
190 186 // Bail if no shortcodes are available.
191 - if ( ! is_array( $shortcodes ) || ! count( $shortcodes ) ) {
187 + if ( ! count( $shortcodes ) ) {
192 188 return $buttons;
193 189 }
194 190
195 191 // Register each Shortcode as a TinyMCE Button.