Changeset 3337204
- Timestamp:
- 07/31/2025 10:46:21 AM (7 months ago)
- Location:
- convertkit
- Files:
-
- 6 deleted
- 40 edited
- 1 copied
-
tags/2.8.7 (copied) (copied from convertkit/trunk)
-
tags/2.8.7/CHANGELOG.md (modified) (1 diff)
-
tags/2.8.7/includes/blocks/class-convertkit-block-broadcasts.php (modified) (7 diffs)
-
tags/2.8.7/includes/blocks/class-convertkit-block-form-trigger.php (modified) (6 diffs)
-
tags/2.8.7/includes/blocks/class-convertkit-block-form.php (modified) (5 diffs)
-
tags/2.8.7/includes/blocks/class-convertkit-block-product.php (modified) (6 diffs)
-
tags/2.8.7/includes/blocks/class-convertkit-block.php (modified) (2 diffs)
-
tags/2.8.7/includes/blocks/form/block.json (modified) (1 diff)
-
tags/2.8.7/includes/class-convertkit-ajax.php (modified) (1 diff)
-
tags/2.8.7/includes/class-convertkit-cache-plugins.php (modified) (1 diff)
-
tags/2.8.7/includes/class-convertkit-output-restrict-content.php (modified) (1 diff)
-
tags/2.8.7/includes/class-convertkit-output.php (modified) (2 diffs)
-
tags/2.8.7/includes/class-convertkit-resource-forms.php (modified) (4 diffs)
-
tags/2.8.7/includes/integrations/divi/class-convertkit-divi-module.php (modified) (1 diff)
-
tags/2.8.7/includes/integrations/elementor/class-convertkit-elementor-widget.php (modified) (1 diff)
-
tags/2.8.7/includes/widgets/class-ck-widget-form.php (modified) (1 diff)
-
tags/2.8.7/languages/convertkit.pot (modified) (14 diffs)
-
tags/2.8.7/readme.txt (modified) (2 diffs)
-
tags/2.8.7/resources/backend/js/gutenberg-block-broadcasts.js (deleted)
-
tags/2.8.7/resources/backend/js/gutenberg-block-form-trigger.js (deleted)
-
tags/2.8.7/resources/backend/js/gutenberg-block-product.js (deleted)
-
tags/2.8.7/resources/backend/js/gutenberg.js (modified) (1 diff)
-
tags/2.8.7/resources/frontend/js/convertkit.js (modified) (1 diff)
-
tags/2.8.7/wp-convertkit.php (modified) (2 diffs)
-
trunk/CHANGELOG.md (modified) (1 diff)
-
trunk/includes/blocks/class-convertkit-block-broadcasts.php (modified) (7 diffs)
-
trunk/includes/blocks/class-convertkit-block-form-trigger.php (modified) (6 diffs)
-
trunk/includes/blocks/class-convertkit-block-form.php (modified) (5 diffs)
-
trunk/includes/blocks/class-convertkit-block-product.php (modified) (6 diffs)
-
trunk/includes/blocks/class-convertkit-block.php (modified) (2 diffs)
-
trunk/includes/blocks/form/block.json (modified) (1 diff)
-
trunk/includes/class-convertkit-ajax.php (modified) (1 diff)
-
trunk/includes/class-convertkit-cache-plugins.php (modified) (1 diff)
-
trunk/includes/class-convertkit-output-restrict-content.php (modified) (1 diff)
-
trunk/includes/class-convertkit-output.php (modified) (2 diffs)
-
trunk/includes/class-convertkit-resource-forms.php (modified) (4 diffs)
-
trunk/includes/integrations/divi/class-convertkit-divi-module.php (modified) (1 diff)
-
trunk/includes/integrations/elementor/class-convertkit-elementor-widget.php (modified) (1 diff)
-
trunk/includes/widgets/class-ck-widget-form.php (modified) (1 diff)
-
trunk/languages/convertkit.pot (modified) (14 diffs)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/resources/backend/js/gutenberg-block-broadcasts.js (deleted)
-
trunk/resources/backend/js/gutenberg-block-form-trigger.js (deleted)
-
trunk/resources/backend/js/gutenberg-block-product.js (deleted)
-
trunk/resources/backend/js/gutenberg.js (modified) (1 diff)
-
trunk/resources/frontend/js/convertkit.js (modified) (1 diff)
-
trunk/wp-convertkit.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
convertkit/tags/2.8.7/CHANGELOG.md
r3289504 r3337204 1 ### 2.8.7 2025-07-31 2 * Added: Blocks: Form: Margin, padding and background color options 3 * Added: Debug: Forms: `data-kit-source-post-id` attribute to scripts when Debugging enabled 4 * Added: JS: Emit `kit_subscriber_id_removed_from_url` event when the `ck_subscriber_id` is removed from a URL 5 * Fix: Debloat Plugin: Exclude Forms from Debloat's Defer and Delay JS 6 * Fix: Classic Widgets: Form: Uncaught error: Call to undefined method `ConvertKit_Resource_Forms::output_select_field_all` 7 * Fix: Blocks: Refactored and removed unnecessary duplicate render callback functions in the block editor 8 9 ### 2.8.6.1 2025-07-23 10 * Fix: Form Trigger: Revert running `script` tags through `wp_kses`, as WordPress.com strip the script tag 11 12 ### 2.8.6 2025-07-23 13 * Fix: Form Block: Correctly style "No Content" message when selecting a modal form 14 * Fix: Member Content: Display all Posts if filter = All content 15 16 ### 2.8.5 2025-07-17 17 * Fix: Broadcasts, Form Trigger and Product Blocks: Improve rendering accuracy between block editor and frontend site 18 * Fix: Sanitization and security enhancements 19 20 ### 2.8.4 2025-07-10 21 * Added: Broadcasts Block: Display order option 22 * Added: Broadcasts, Form Trigger and Product Blocks: Use `get_block_wrapper_attributes` for block `class` and `style` attributes 23 * Added: Broadcasts, Form Trigger and Product Blocks: Typography options 24 * Added: Broadcasts, Form Trigger and Product Blocks: Margin and padding options 25 26 ### 2.8.3 2025-07-03 27 * Added: Member Content: `All member-only content` option added to filter dropdown in Posts and Pages tables 28 * Fix: Member Content: Replace `Members only` with `member-only` 29 * Fix: Automatically refresh Access Token when expired 30 31 ### 2.8.2 2025-05-28 32 * Fix: Broadcasts: Remove emoijs from Permalink whem importing Broadcasts to WordPress Posts 33 * Fix: Coding Standards: Use `wp_doing_cron` function, instead of `DOING_CRON` constant 34 1 35 ### 2.8.1 2025-05-07 2 36 * Added: Member Content: Permits Apple, DuckDuckGo, OpenAI Search, Perplexity and Yandex to crawl Member Content if the Permit Search Engine Crawlers option is enabled -
convertkit/tags/2.8.7/includes/blocks/class-convertkit-block-broadcasts.php
r3329966 r3337204 28 28 add_filter( 'convertkit_blocks', array( $this, 'register' ) ); 29 29 30 // Enqueue scripts and styles for this Gutenberg Block in the editor view.31 add_action( 'convertkit_gutenberg_enqueue_scripts', array( $this, 'enqueue_scripts_editor' ) );32 33 30 // Enqueue scripts and styles for this Gutenberg Block in the editor and frontend views. 34 31 add_action( 'convertkit_gutenberg_enqueue_scripts_editor_and_frontend', array( $this, 'enqueue_scripts' ) ); … … 38 35 add_action( 'wp_ajax_nopriv_convertkit_broadcasts_render', array( $this, 'render_ajax' ) ); 39 36 add_action( 'wp_ajax_convertkit_broadcasts_render', array( $this, 'render_ajax' ) ); 40 41 }42 43 /**44 * Enqueues scripts for this Gutenberg Block in the editor view.45 *46 * @since 2.0.147 */48 public function enqueue_scripts_editor() {49 50 wp_enqueue_script( 'convertkit-gutenberg-block-broadcasts', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/gutenberg-block-broadcasts.js', array( 'convertkit-gutenberg' ), CONVERTKIT_PLUGIN_VERSION, true );51 37 52 38 } … … 118 104 119 105 return array( 120 'title' => __( 'Kit Broadcasts', 'convertkit' ),121 'description' => __( 'Displays a list of your Kit broadcasts.', 'convertkit' ),122 'icon' => 'resources/backend/images/block-icon-broadcasts.svg',123 'category' => 'convertkit',124 'keywords' => array(106 'title' => __( 'Kit Broadcasts', 'convertkit' ), 107 'description' => __( 'Displays a list of your Kit broadcasts.', 'convertkit' ), 108 'icon' => 'resources/backend/images/block-icon-broadcasts.svg', 109 'category' => 'convertkit', 110 'keywords' => array( 125 111 __( 'ConvertKit', 'convertkit' ), 126 112 __( 'Kit', 'convertkit' ), … … 130 116 131 117 // Function to call when rendering as a block or a shortcode on the frontend web site. 132 'render_callback' => array( $this, 'render' ),118 'render_callback' => array( $this, 'render' ), 133 119 134 120 // Shortcode: TinyMCE / QuickTags Modal Width and Height. 135 'modal' => array(121 'modal' => array( 136 122 'width' => 650, 137 123 'height' => 455, … … 139 125 140 126 // Shortcode: Include a closing [/shortcode] tag when using TinyMCE or QuickTag Modals. 141 'shortcode_include_closing_tag' => false,127 'shortcode_include_closing_tag' => false, 142 128 143 129 // Gutenberg: Block Icon in Editor. 144 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-broadcasts.svg' ),130 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-broadcasts.svg' ), 145 131 146 132 // Gutenberg: Example image showing how this block looks when choosing it in Gutenberg. 147 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-broadcasts.png',133 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-broadcasts.png', 148 134 149 135 // Help descriptions, displayed when no Access Token / resources exist and this block/shortcode is added. 150 'no_access_token' => array(136 'no_access_token' => array( 151 137 'notice' => __( 'Not connected to Kit.', 'convertkit' ), 152 138 'link' => convertkit_get_setup_wizard_plugin_link(), … … 154 140 'instruction_text' => __( 'Connect your Kit account at Settings > Kit, and then refresh this page to configure broadcasts to display.', 'convertkit' ), 155 141 ), 156 'no_resources' => array(142 'no_resources' => array( 157 143 'notice' => __( 'No broadcasts exist in Kit.', 'convertkit' ), 158 144 'link' => convertkit_get_new_broadcast_url(), … … 161 147 ), 162 148 163 // Gutenberg: JS function to call when rendering the block preview in the Gutenberg editor.164 // If not defined, render_callback above will be used.165 'gutenberg_preview_render_callback' => 'convertKitGutenbergBroadcastsBlockRenderPreview',166 167 149 // Whether an API Key exists in the Plugin, and are the required resources (broadcasts) available. 168 150 // If no API Key is specified in the Plugin's settings, render the "No API Key" output. 169 'has_access_token' => $settings->has_access_and_refresh_token(),170 'has_resources' => $posts->exist(),151 'has_access_token' => $settings->has_access_and_refresh_token(), 152 'has_resources' => $posts->exist(), 171 153 ); 172 154 -
convertkit/tags/2.8.7/includes/blocks/class-convertkit-block-form-trigger.php
r3329966 r3337204 28 28 add_filter( 'convertkit_blocks', array( $this, 'register' ) ); 29 29 30 // Enqueue scripts and styles for this Gutenberg Block in the editor view.31 add_action( 'convertkit_gutenberg_enqueue_scripts', array( $this, 'enqueue_scripts_editor' ) );32 33 30 // Enqueue scripts and styles for this Gutenberg Block in the editor and frontend views. 34 31 add_action( 'convertkit_gutenberg_enqueue_styles_editor_and_frontend', array( $this, 'enqueue_styles' ) ); 35 36 }37 38 /**39 * Enqueues scripts for this Gutenberg Block in the editor view.40 *41 * @since 2.2.042 */43 public function enqueue_scripts_editor() {44 45 wp_enqueue_script( 'convertkit-gutenberg-block-form-trigger', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/gutenberg-block-form-trigger.js', array( 'convertkit-gutenberg' ), CONVERTKIT_PLUGIN_VERSION, true );46 32 47 33 } … … 88 74 89 75 return array( 90 'title' => __( 'Kit Form Trigger', 'convertkit' ),91 'description' => __( 'Displays a modal, sticky bar or slide in form to display when the button is pressed.', 'convertkit' ),92 'icon' => 'resources/backend/images/block-icon-formtrigger.svg',93 'category' => 'convertkit',94 'keywords' => array(76 'title' => __( 'Kit Form Trigger', 'convertkit' ), 77 'description' => __( 'Displays a modal, sticky bar or slide in form to display when the button is pressed.', 'convertkit' ), 78 'icon' => 'resources/backend/images/block-icon-formtrigger.svg', 79 'category' => 'convertkit', 80 'keywords' => array( 95 81 __( 'ConvertKit', 'convertkit' ), 96 82 __( 'Kit', 'convertkit' ), … … 99 85 100 86 // Function to call when rendering as a block or a shortcode on the frontend web site. 101 'render_callback' => array( $this, 'render' ),87 'render_callback' => array( $this, 'render' ), 102 88 103 89 // Shortcode: TinyMCE / QuickTags Modal Width and Height. 104 'modal' => array(90 'modal' => array( 105 91 'width' => 500, 106 92 'height' => 282, … … 108 94 109 95 // Shortcode: Include a closing [/shortcode] tag when using TinyMCE or QuickTag Modals. 110 'shortcode_include_closing_tag' => false,96 'shortcode_include_closing_tag' => false, 111 97 112 98 // Gutenberg: Block Icon in Editor. 113 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-formtrigger.svg' ),99 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-formtrigger.svg' ), 114 100 115 101 // Gutenberg: Example image showing how this block looks when choosing it in Gutenberg. 116 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-formtrigger.png',102 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-formtrigger.png', 117 103 118 104 // Help descriptions, displayed when no API key / resources exist and this block/shortcode is added. 119 'no_access_token' => array(105 'no_access_token' => array( 120 106 'notice' => __( 'Not connected to Kit.', 'convertkit' ), 121 107 'link' => convertkit_get_setup_wizard_plugin_link(), … … 123 109 'instruction_text' => __( 'Connect your Kit account at Settings > Kit, and then refresh this page to select a form.', 'convertkit' ), 124 110 ), 125 'no_resources' => array(111 'no_resources' => array( 126 112 'notice' => __( 'No modal, sticky bar or slide in forms exist in Kit.', 'convertkit' ), 127 113 'link' => convertkit_get_new_form_url(), … … 129 115 'instruction_text' => __( 'Add a non-inline form to your Kit account, and then refresh this page to select a form.', 'convertkit' ), 130 116 ), 131 'gutenberg_help_description' => __( 'Select a Form using the Form option in the Gutenberg sidebar.', 'convertkit' ), 132 133 // Gutenberg: JS function to call when rendering the block preview in the Gutenberg editor.134 // If not defined, render_callback above will be used.135 'gutenberg_ preview_render_callback' => 'convertKitGutenbergFormTriggerBlockRenderPreview',117 118 // The attribute to check if a value exists when rendering the block in the editor, 119 // and the message to display if no value exists. 120 'gutenberg_help_description' => __( 'Select a Form using the Form option in the Gutenberg sidebar.', 'convertkit' ), 121 'gutenberg_help_description_attribute' => 'form', 136 122 137 123 // Whether an API Key exists in the Plugin, and are the required resources (non-inline forms) available. 138 124 // If no API Key is specified in the Plugin's settings, render the "No API Key" output. 139 'has_access_token' => $settings->has_access_and_refresh_token(),140 'has_resources' => $convertkit_forms->non_inline_exist(),125 'has_access_token' => $settings->has_access_and_refresh_token(), 126 'has_resources' => $convertkit_forms->non_inline_exist(), 141 127 ); 142 128 -
convertkit/tags/2.8.7/includes/blocks/class-convertkit-block-form.php
r3227192 r3337204 187 187 ), 188 188 189 // get_supports() style, color and typography attributes. 190 'style' => array( 191 'type' => 'object', 192 ), 193 'backgroundColor' => array( 194 'type' => 'string', 195 ), 196 189 197 // Always required for Gutenberg. 190 198 'is_gutenberg_example' => array( 191 199 'type' => 'boolean', 192 200 'default' => false, 201 ), 202 ); 203 204 } 205 206 /** 207 * Returns this block's supported built-in Attributes. 208 * 209 * @since 1.9.7.4 210 * 211 * @return array Supports 212 */ 213 public function get_supports() { 214 215 return array( 216 'className' => true, 217 'color' => array( 218 'link' => false, 219 'background' => true, 220 'text' => false, 221 ), 222 'spacing' => array( 223 'margin' => true, 224 'padding' => true, 193 225 ), 194 226 ); … … 292 324 public function render( $atts ) { 293 325 326 global $post; 327 328 $post_id = is_a( $post, 'WP_Post' ) ? $post->ID : 0; 329 294 330 // Check if the Block Visibility Plugin permits displaying this block. 295 331 if ( ! $this->is_block_visible( $atts ) ) { … … 329 365 // Get Form HTML. 330 366 $forms = new ConvertKit_Resource_Forms( 'output_form' ); 331 $form = $forms->get_html( $form_id );367 $form = $forms->get_html( $form_id, $post_id ); 332 368 333 369 // If an error occured, it might be that we're requesting a Form ID that exists in ConvertKit … … 339 375 340 376 // Get Form HTML again. 341 $form = $forms->get_html( $form_id );377 $form = $forms->get_html( $form_id, $post_id ); 342 378 } 343 379 … … 371 407 } 372 408 409 // Build HTML. 410 // For the block editor, don't include compiled CSS classes and styles, 411 // as the block editor will add these to the parent container. 412 // Otherwise the block will render incorrectly with double padding, double margins etc. 413 // If there's no Form HTML, it's a non-inline form, so don't render any output. 414 if ( ! $this->is_block_editor_request() && ! empty( $form ) ) { 415 $form = sprintf( 416 '<div class="%s" style="%s">%s</div>', 417 implode( ' ', map_deep( $this->get_css_classes(), 'sanitize_html_class' ) ), 418 implode( ';', map_deep( $this->get_css_styles( $atts ), 'esc_attr' ) ), 419 $form 420 ); 421 } 422 373 423 /** 374 424 * Filter the block's content immediately before it is output. -
convertkit/tags/2.8.7/includes/blocks/class-convertkit-block-product.php
r3329966 r3337204 28 28 add_filter( 'convertkit_blocks', array( $this, 'register' ) ); 29 29 30 // Enqueue scripts and styles for this Gutenberg Block in the editor view.31 add_action( 'convertkit_gutenberg_enqueue_scripts', array( $this, 'enqueue_scripts_editor' ) );32 33 30 // Enqueue scripts and styles for this Gutenberg Block in the editor and frontend views. 34 31 add_action( 'convertkit_gutenberg_enqueue_scripts_editor_and_frontend', array( $this, 'enqueue_scripts' ) ); 35 32 add_action( 'convertkit_gutenberg_enqueue_styles_editor_and_frontend', array( $this, 'enqueue_styles' ) ); 36 37 }38 39 /**40 * Enqueues scripts for this Gutenberg Block in the editor view.41 *42 * @since 1.9.8.543 */44 public function enqueue_scripts_editor() {45 46 wp_enqueue_script( 'convertkit-gutenberg-block-product', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/gutenberg-block-product.js', array( 'convertkit-gutenberg' ), CONVERTKIT_PLUGIN_VERSION, true );47 33 48 34 } … … 110 96 111 97 return array( 112 'title' => __( 'Kit Product', 'convertkit' ),113 'description' => __( 'Displays a button to purchase a Kit product.', 'convertkit' ),114 'icon' => 'resources/backend/images/block-icon-product.svg',115 'category' => 'convertkit',116 'keywords' => array(98 'title' => __( 'Kit Product', 'convertkit' ), 99 'description' => __( 'Displays a button to purchase a Kit product.', 'convertkit' ), 100 'icon' => 'resources/backend/images/block-icon-product.svg', 101 'category' => 'convertkit', 102 'keywords' => array( 117 103 __( 'ConvertKit', 'convertkit' ), 118 104 __( 'Kit', 'convertkit' ), … … 121 107 122 108 // Function to call when rendering as a block or a shortcode on the frontend web site. 123 'render_callback' => array( $this, 'render' ),109 'render_callback' => array( $this, 'render' ), 124 110 125 111 // Shortcode: TinyMCE / QuickTags Modal Width and Height. 126 'modal' => array(112 'modal' => array( 127 113 'width' => 600, 128 114 'height' => 518, … … 130 116 131 117 // Shortcode: Include a closing [/shortcode] tag when using TinyMCE or QuickTag Modals. 132 'shortcode_include_closing_tag' => false,118 'shortcode_include_closing_tag' => false, 133 119 134 120 // Gutenberg: Block Icon in Editor. 135 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-product.svg' ),121 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-product.svg' ), 136 122 137 123 // Gutenberg: Example image showing how this block looks when choosing it in Gutenberg. 138 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-product.png',124 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-product.png', 139 125 140 126 // Help descriptions, displayed when no Access Token / resources exist and this block/shortcode is added. 141 'no_access_token' => array(127 'no_access_token' => array( 142 128 'notice' => __( 'Not connected to Kit.', 'convertkit' ), 143 129 'link' => convertkit_get_setup_wizard_plugin_link(), … … 145 131 'instruction_text' => __( 'Connect your Kit account at Settings > Kit, and then refresh this page to select a product.', 'convertkit' ), 146 132 ), 147 'no_resources' => array(133 'no_resources' => array( 148 134 'notice' => __( 'No products exist in Kit.', 'convertkit' ), 149 135 'link' => convertkit_get_new_product_url(), … … 152 138 ), 153 139 154 // Gutenberg: Help descriptions, displayed when no settings defined for a newly added Block. 155 'gutenberg_help_description' => __( 'Select a Product using the Product option in the Gutenberg sidebar.', 'convertkit' ), 156 157 // Gutenberg: JS function to call when rendering the block preview in the Gutenberg editor. 158 // If not defined, render_callback above will be used. 159 'gutenberg_preview_render_callback' => 'convertKitGutenbergProductBlockRenderPreview', 140 // Gutenberg: Help description, displayed when the defined attribute has not been set for the block. 141 'gutenberg_help_description' => __( 'Select a Product using the Product option in the Gutenberg sidebar.', 'convertkit' ), 142 'gutenberg_help_description_attribute' => 'product', 160 143 161 144 // Whether an Access Token exists in the Plugin, and are the required resources (products) available. 162 145 // If no Access Token is specified in the Plugin's settings, render the "Not Connected" output. 163 'has_access_token' => $settings->has_access_and_refresh_token(),164 'has_resources' => $convertkit_products->exist(),146 'has_access_token' => $settings->has_access_and_refresh_token(), 147 'has_resources' => $convertkit_products->exist(), 165 148 ); 166 149 -
convertkit/tags/2.8.7/includes/blocks/class-convertkit-block.php
r3329966 r3337204 261 261 */ 262 262 public function get_css_classes( $additional_classes = array() ) { 263 264 // To avoid errors in get_block_wrapper_attributes() in non-block themes using the shortcode, 265 // tell WordPress that a block is being rendered. 266 // The attributes don't matter, as we send them to the render() function. 267 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line 268 WP_Block_Supports::$block_to_render = array( 269 'blockName' => 'convertkit/' . $this->get_name(), 270 'attrs' => array(), 271 'innerBlocks' => array(), 272 'innerHTML' => '', 273 'innerContent' => array(), 274 ); 275 } 263 276 264 277 // Get the block wrapper attributes string. … … 306 319 public function get_css_styles( $atts ) { 307 320 321 // To avoid errors in get_block_wrapper_attributes() in non-block themes using the shortcode, 322 // tell WordPress that a block is being rendered. 323 // The attributes don't matter, as we send them to the render() function. 324 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line 325 WP_Block_Supports::$block_to_render = array( 326 'blockName' => 'convertkit/' . $this->get_name(), 327 'attrs' => array(), 328 'innerBlocks' => array(), 329 'innerHTML' => '', 330 'innerContent' => array(), 331 ); 332 } 333 308 334 $styles = array(); 309 335 -
convertkit/tags/2.8.7/includes/blocks/form/block.json
r3160977 r3337204 24 24 }, 25 25 "supports": { 26 "className": true 26 "className": true, 27 "color": { 28 "link": false, 29 "background": true, 30 "text": false 31 }, 32 "spacing": { 33 "margin": true, 34 "padding": true 35 } 27 36 }, 28 37 "editorScript": "convertkit-gutenberg" -
convertkit/tags/2.8.7/includes/class-convertkit-ajax.php
r3251976 r3337204 41 41 * 42 42 * Typically used when a refresh button in a block has been pressed when 43 * convertKitGutenbergDisplayBlockNoticeWithLink() is called, because either43 * displayNoticeWithLink() is called, because either 44 44 * no Access Token is specified, or no resources exist in ConvertKit. 45 45 * -
convertkit/tags/2.8.7/includes/class-convertkit-cache-plugins.php
r3186945 r3337204 53 53 add_filter( 'convertkit_resource_forms_output_script', array( $this, 'autoptimize_exclude_js_defer' ) ); 54 54 55 // Debloat: Exclude Forms from Delay Load JS. 56 add_filter( 'debloat/defer_js_excludes', array( $this, 'exclude_hosts_from_minification' ) ); 57 add_filter( 'debloat/delay_js_excludes', array( $this, 'exclude_hosts_from_minification' ) ); 58 55 59 // Jetpack Boost: Exclude Forms from JS defer. 56 60 add_filter( 'convertkit_output_script_footer', array( $this, 'jetpack_boost_exclude_js_defer' ) ); -
convertkit/tags/2.8.7/includes/class-convertkit-output-restrict-content.php
r3329966 r3337204 1324 1324 // Display the Form. 1325 1325 $forms = new ConvertKit_Resource_Forms( 'restrict_content' ); 1326 $form = $forms->get_html( $this->resource_id );1326 $form = $forms->get_html( $this->resource_id, $post_id ); 1327 1327 1328 1328 // If scripts are enabled, output the email login form in a modal, which will be displayed -
convertkit/tags/2.8.7/includes/class-convertkit-output.php
r3333065 r3337204 312 312 313 313 // Get Form HTML. 314 $form = $this->forms->get_html( $form_id );314 $form = $this->forms->get_html( $form_id, $post_id ); 315 315 316 316 // If an error occured, it could be because the specified Form ID for the Post either: … … 336 336 337 337 // Get Form HTML. 338 $form = $this->forms->get_html( $form_id );338 $form = $this->forms->get_html( $form_id, $post_id ); 339 339 340 340 // If an error occured again, the default form doesn't exist in this ConvertKit account. -
convertkit/tags/2.8.7/includes/class-convertkit-resource-forms.php
r3329966 r3337204 475 475 * @since 1.9.6 476 476 * 477 * @param int $id Form ID. 477 * @param int $id Form ID. 478 * @param int $post_id Post ID that requested the Form. 478 479 * @return WP_Error|string 479 480 */ 480 public function get_html( $id ) {481 public function get_html( $id, $post_id = 0 ) { 481 482 482 483 // Cast ID to integer. … … 500 501 } 501 502 503 // Initialize Settings. 504 $settings = new ConvertKit_Settings(); 505 502 506 // If no uid is present in the Form API data, this is a legacy form that's served by directly fetching the HTML 503 507 // from forms.kit.com. 504 508 if ( ! isset( $this->resources[ $id ]['uid'] ) ) { 505 // Initialize Settings.506 $settings = new ConvertKit_Settings();507 508 509 // Bail if no Access Token is specified in the Plugin Settings. 509 510 if ( ! $settings->has_access_token() ) { … … 537 538 add_filter( 538 539 'convertkit_output_scripts_footer', 539 function ( $scripts ) use ( $id ) { 540 541 $scripts[] = array( 540 function ( $scripts ) use ( $id, $post_id, $settings ) { 541 542 // Build script. 543 $script = array( 542 544 'async' => true, 543 545 'data-uid' => $this->resources[ $id ]['uid'], 544 546 'src' => $this->resources[ $id ]['embed_js'], 545 547 ); 548 549 // If debugging is enabled, add the post ID to the script. 550 if ( $settings->debug_enabled() ) { 551 $script['data-kit-source-post-id'] = $post_id; 552 } 553 554 // Add the script to the scripts array. 555 $scripts[] = $script; 546 556 547 557 return $scripts; … … 575 585 'src' => $this->resources[ $id ]['embed_js'], 576 586 ); 587 588 // If debugging is enabled, add the post ID to the script. 589 if ( $settings->debug_enabled() ) { 590 $script['data-kit-source-post-id'] = $post_id; 591 } 577 592 578 593 /** -
convertkit/tags/2.8.7/includes/integrations/divi/class-convertkit-divi-module.php
r3329966 r3337204 186 186 public function render( $unprocessed_props, $content, $render_slug ) { // phpcs:ignore Generic.CodeAnalysis.UnusedFunctionParameter 187 187 188 // To avoid errors in get_block_wrapper_attributes(), tell WordPress that a block is being rendered.189 // The attributes don't matter, as we send them to the render() function.190 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line191 WP_Block_Supports::$block_to_render = array(192 'blockName' => 'convertkit/' . $this->block_name,193 'attrs' => array(),194 'innerBlocks' => array(),195 'innerHTML' => '',196 'innerContent' => array(),197 );198 }199 200 188 // Render using Block class' render() function. 201 189 // Output is already escaped in render() function. -
convertkit/tags/2.8.7/includes/integrations/elementor/class-convertkit-elementor-widget.php
r3329966 r3337204 261 261 } 262 262 263 // To avoid errors in get_block_wrapper_attributes(), tell WordPress that a block is being rendered.264 // The attributes don't matter, as we send them to the render() function.265 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line266 WP_Block_Supports::$block_to_render = array(267 'blockName' => 'convertkit/' . $this->get_block_name(),268 'attrs' => array(),269 'innerBlocks' => array(),270 'innerHTML' => '',271 'innerContent' => array(),272 );273 }274 275 263 // Render using Block class' render() function. 276 264 // Output is already escaped in render() function. -
convertkit/tags/2.8.7/includes/widgets/class-ck-widget-form.php
r3329966 r3337204 79 79 <label for="<?php echo esc_attr( $this->get_field_id( 'form' ) ); ?>"><?php esc_html_e( 'Form', 'convertkit' ); ?></label> 80 80 <?php 81 $forms->output_select_field_all(81 echo $forms->get_select_field_all( // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped 82 82 esc_attr( $this->get_field_name( 'form' ) ), 83 83 esc_attr( $this->get_field_id( 'form' ) ), -
convertkit/tags/2.8.7/languages/convertkit.pot
r3332639 r3337204 3 3 msgid "" 4 4 msgstr "" 5 "Project-Id-Version: Kit (formerly ConvertKit) 2.8. 6\n"5 "Project-Id-Version: Kit (formerly ConvertKit) 2.8.7\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/convertkit\n" 7 7 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" … … 10 10 "Content-Type: text/plain; charset=UTF-8\n" 11 11 "Content-Transfer-Encoding: 8bit\n" 12 "POT-Creation-Date: 2025-07- 23T04:52:18+00:00\n"12 "POT-Creation-Date: 2025-07-31T03:05:55+00:00\n" 13 13 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 14 14 "X-Generator: WP-CLI 2.11.0\n" … … 37 37 #: admin/class-convertkit-admin-settings.php:113 38 38 #: admin/class-convertkit-admin-settings.php:132 39 #: includes/blocks/class-convertkit-block-broadcasts.php:1 2639 #: includes/blocks/class-convertkit-block-broadcasts.php:112 40 40 #: includes/blocks/class-convertkit-block-content.php:63 41 #: includes/blocks/class-convertkit-block-form-trigger.php: 9641 #: includes/blocks/class-convertkit-block-form-trigger.php:82 42 42 #: includes/blocks/class-convertkit-block-form.php:112 43 #: includes/blocks/class-convertkit-block-product.php:1 1843 #: includes/blocks/class-convertkit-block-product.php:104 44 44 #: includes/integrations/contactform7/class-convertkit-contactform7-admin-section.php:139 45 45 #: includes/integrations/elementor/class-convertkit-elementor.php:70 … … 141 141 #: admin/section/class-convertkit-admin-section-broadcasts.php:33 142 142 #: admin/section/class-convertkit-admin-section-broadcasts.php:202 143 #: includes/blocks/class-convertkit-block-broadcasts.php:1 27143 #: includes/blocks/class-convertkit-block-broadcasts.php:113 144 144 msgid "Broadcasts" 145 145 msgstr "" … … 283 283 284 284 #: admin/section/class-convertkit-admin-section-general.php:58 285 #: includes/blocks/class-convertkit-block-broadcasts.php:3 96285 #: includes/blocks/class-convertkit-block-broadcasts.php:378 286 286 #: includes/blocks/class-convertkit-block-content.php:147 287 #: includes/blocks/class-convertkit-block-form-trigger.php:2 96288 #: includes/blocks/class-convertkit-block-form.php:2 59289 #: includes/blocks/class-convertkit-block-product.php:3 41287 #: includes/blocks/class-convertkit-block-form-trigger.php:282 288 #: includes/blocks/class-convertkit-block-form.php:291 289 #: includes/blocks/class-convertkit-block-product.php:324 290 290 msgid "General" 291 291 msgstr "" … … 809 809 810 810 #: includes/block-formatters/class-convertkit-block-formatter-form-link.php:77 811 #: includes/blocks/class-convertkit-block-form-trigger.php: 90811 #: includes/blocks/class-convertkit-block-form-trigger.php:76 812 812 msgid "Kit Form Trigger" 813 813 msgstr "" … … 818 818 819 819 #: includes/block-formatters/class-convertkit-block-formatter-form-link.php:143 820 #: includes/blocks/class-convertkit-block-form-trigger.php: 97821 #: includes/blocks/class-convertkit-block-form-trigger.php:2 52820 #: includes/blocks/class-convertkit-block-form-trigger.php:83 821 #: includes/blocks/class-convertkit-block-form-trigger.php:238 822 822 #: includes/blocks/class-convertkit-block-form.php:113 823 #: includes/blocks/class-convertkit-block-form.php:2 28823 #: includes/blocks/class-convertkit-block-form.php:260 824 824 #: includes/integrations/contactform7/class-convertkit-contactform7-admin-section.php:86 825 825 #: includes/integrations/forminator/class-convertkit-forminator-admin-section.php:73 … … 848 848 849 849 #: includes/block-formatters/class-convertkit-block-formatter-product-link.php:134 850 #: includes/blocks/class-convertkit-block-product.php:1 19851 #: includes/blocks/class-convertkit-block-product.php:2 83850 #: includes/blocks/class-convertkit-block-product.php:105 851 #: includes/blocks/class-convertkit-block-product.php:266 852 852 #: views/backend/post/meta-box.php:203 853 853 #: views/backend/setup-wizard/convertkit-restrict-content-setup/content-2.php:112 … … 859 859 msgstr "" 860 860 861 #: includes/blocks/class-convertkit-block-broadcasts.php:1 20861 #: includes/blocks/class-convertkit-block-broadcasts.php:106 862 862 msgid "Kit Broadcasts" 863 863 msgstr "" 864 864 865 #: includes/blocks/class-convertkit-block-broadcasts.php:1 21865 #: includes/blocks/class-convertkit-block-broadcasts.php:107 866 866 msgid "Displays a list of your Kit broadcasts." 867 867 msgstr "" 868 868 869 #: includes/blocks/class-convertkit-block-broadcasts.php:1 25869 #: includes/blocks/class-convertkit-block-broadcasts.php:111 870 870 #: includes/blocks/class-convertkit-block-content.php:62 871 #: includes/blocks/class-convertkit-block-form-trigger.php: 95871 #: includes/blocks/class-convertkit-block-form-trigger.php:81 872 872 #: includes/blocks/class-convertkit-block-form.php:111 873 #: includes/blocks/class-convertkit-block-product.php:1 17873 #: includes/blocks/class-convertkit-block-product.php:103 874 874 msgid "ConvertKit" 875 875 msgstr "" 876 876 877 #: includes/blocks/class-convertkit-block-broadcasts.php:1 28877 #: includes/blocks/class-convertkit-block-broadcasts.php:114 878 878 msgid "Posts" 879 879 msgstr "" 880 880 881 #: includes/blocks/class-convertkit-block-broadcasts.php:1 51882 #: includes/blocks/class-convertkit-block-form-trigger.php:1 20881 #: includes/blocks/class-convertkit-block-broadcasts.php:137 882 #: includes/blocks/class-convertkit-block-form-trigger.php:106 883 883 #: includes/blocks/class-convertkit-block-form.php:136 884 #: includes/blocks/class-convertkit-block-product.php:1 42884 #: includes/blocks/class-convertkit-block-product.php:128 885 885 msgid "Not connected to Kit." 886 886 msgstr "" 887 887 888 #: includes/blocks/class-convertkit-block-broadcasts.php:1 53889 #: includes/blocks/class-convertkit-block-form-trigger.php:1 22888 #: includes/blocks/class-convertkit-block-broadcasts.php:139 889 #: includes/blocks/class-convertkit-block-form-trigger.php:108 890 890 #: includes/blocks/class-convertkit-block-form.php:138 891 #: includes/blocks/class-convertkit-block-product.php:1 44891 #: includes/blocks/class-convertkit-block-product.php:130 892 892 msgid "Click here to connect your Kit account." 893 893 msgstr "" 894 894 895 #: includes/blocks/class-convertkit-block-broadcasts.php:1 54895 #: includes/blocks/class-convertkit-block-broadcasts.php:140 896 896 msgid "Connect your Kit account at Settings > Kit, and then refresh this page to configure broadcasts to display." 897 897 msgstr "" 898 898 899 #: includes/blocks/class-convertkit-block-broadcasts.php:1 57899 #: includes/blocks/class-convertkit-block-broadcasts.php:143 900 900 msgid "No broadcasts exist in Kit." 901 901 msgstr "" 902 902 903 #: includes/blocks/class-convertkit-block-broadcasts.php:1 59903 #: includes/blocks/class-convertkit-block-broadcasts.php:145 904 904 msgid "Click here to send your first broadcast." 905 905 msgstr "" 906 906 907 #: includes/blocks/class-convertkit-block-broadcasts.php:1 60907 #: includes/blocks/class-convertkit-block-broadcasts.php:146 908 908 msgid "Add a broadcast to your Kit account, and then refresh this page to configure broadcasts to display." 909 909 msgstr "" 910 910 911 #: includes/blocks/class-convertkit-block-broadcasts.php: 300911 #: includes/blocks/class-convertkit-block-broadcasts.php:282 912 912 msgid "Display as grid" 913 913 msgstr "" 914 914 915 #: includes/blocks/class-convertkit-block-broadcasts.php: 302915 #: includes/blocks/class-convertkit-block-broadcasts.php:284 916 916 msgid "If enabled, displays broadcasts in a grid, instead of a list." 917 917 msgstr "" 918 918 919 #: includes/blocks/class-convertkit-block-broadcasts.php:287 920 msgid "Display order" 921 msgstr "" 922 923 #: includes/blocks/class-convertkit-block-broadcasts.php:290 924 msgid "Date, Broadcast" 925 msgstr "" 926 927 #: includes/blocks/class-convertkit-block-broadcasts.php:291 928 msgid "Broadcast, Date" 929 msgstr "" 930 931 #: includes/blocks/class-convertkit-block-broadcasts.php:295 932 msgid "Date format" 933 msgstr "" 934 919 935 #: includes/blocks/class-convertkit-block-broadcasts.php:305 920 msgid "Display order" 921 msgstr "" 922 923 #: includes/blocks/class-convertkit-block-broadcasts.php:308 924 msgid "Date, Broadcast" 936 msgid "Display images" 925 937 msgstr "" 926 938 927 939 #: includes/blocks/class-convertkit-block-broadcasts.php:309 928 msgid " Broadcast, Date"940 msgid "Display descriptions" 929 941 msgstr "" 930 942 931 943 #: includes/blocks/class-convertkit-block-broadcasts.php:313 932 msgid "Date format" 933 msgstr "" 934 935 #: includes/blocks/class-convertkit-block-broadcasts.php:323 936 msgid "Display images" 937 msgstr "" 938 939 #: includes/blocks/class-convertkit-block-broadcasts.php:327 940 msgid "Display descriptions" 944 msgid "Display read more links" 945 msgstr "" 946 947 #: includes/blocks/class-convertkit-block-broadcasts.php:317 948 msgid "Read more label" 949 msgstr "" 950 951 #: includes/blocks/class-convertkit-block-broadcasts.php:319 952 msgid "The label to display for the \"read more\" link below each broadcast." 953 msgstr "" 954 955 #: includes/blocks/class-convertkit-block-broadcasts.php:322 956 msgid "Number of posts" 957 msgstr "" 958 959 #: includes/blocks/class-convertkit-block-broadcasts.php:329 960 msgid "Display pagination" 941 961 msgstr "" 942 962 943 963 #: includes/blocks/class-convertkit-block-broadcasts.php:331 944 msgid "Display read more links" 945 msgstr "" 946 947 #: includes/blocks/class-convertkit-block-broadcasts.php:335 948 msgid "Read more label" 949 msgstr "" 950 951 #: includes/blocks/class-convertkit-block-broadcasts.php:337 952 msgid "The label to display for the \"read more\" link below each broadcast." 953 msgstr "" 954 955 #: includes/blocks/class-convertkit-block-broadcasts.php:340 956 msgid "Number of posts" 964 msgid "If the number of broadcasts exceeds the \"Number of posts\" settings above, previous/next pagination links will be displayed." 965 msgstr "" 966 967 #: includes/blocks/class-convertkit-block-broadcasts.php:334 968 msgid "Newer posts label" 969 msgstr "" 970 971 #: includes/blocks/class-convertkit-block-broadcasts.php:336 972 msgid "The label to display for the link to newer broadcasts." 973 msgstr "" 974 975 #: includes/blocks/class-convertkit-block-broadcasts.php:339 976 msgid "Older posts label" 977 msgstr "" 978 979 #: includes/blocks/class-convertkit-block-broadcasts.php:341 980 msgid "The label to display for the link to older broadcasts." 957 981 msgstr "" 958 982 959 983 #: includes/blocks/class-convertkit-block-broadcasts.php:347 960 msgid "Display pagination"961 msgstr ""962 963 #: includes/blocks/class-convertkit-block-broadcasts.php:349964 msgid "If the number of broadcasts exceeds the \"Number of posts\" settings above, previous/next pagination links will be displayed."965 msgstr ""966 967 #: includes/blocks/class-convertkit-block-broadcasts.php:352968 msgid "Newer posts label"969 msgstr ""970 971 #: includes/blocks/class-convertkit-block-broadcasts.php:354972 msgid "The label to display for the link to newer broadcasts."973 msgstr ""974 975 #: includes/blocks/class-convertkit-block-broadcasts.php:357976 msgid "Older posts label"977 msgstr ""978 979 #: includes/blocks/class-convertkit-block-broadcasts.php:359980 msgid "The label to display for the link to older broadcasts."981 msgstr ""982 983 #: includes/blocks/class-convertkit-block-broadcasts.php:365984 984 msgid "Link color" 985 985 msgstr "" 986 986 987 #: includes/blocks/class-convertkit-block-broadcasts.php:3 69988 #: includes/blocks/class-convertkit-block-form-trigger.php:2 67989 #: includes/blocks/class-convertkit-block-product.php: 312987 #: includes/blocks/class-convertkit-block-broadcasts.php:351 988 #: includes/blocks/class-convertkit-block-form-trigger.php:253 989 #: includes/blocks/class-convertkit-block-product.php:295 990 990 msgid "Background color" 991 991 msgstr "" 992 992 993 #: includes/blocks/class-convertkit-block-broadcasts.php:3 73994 #: includes/blocks/class-convertkit-block-form-trigger.php:2 71995 #: includes/blocks/class-convertkit-block-product.php: 316993 #: includes/blocks/class-convertkit-block-broadcasts.php:355 994 #: includes/blocks/class-convertkit-block-form-trigger.php:257 995 #: includes/blocks/class-convertkit-block-product.php:299 996 996 msgid "Text color" 997 997 msgstr "" 998 998 999 #: includes/blocks/class-convertkit-block-broadcasts.php: 408999 #: includes/blocks/class-convertkit-block-broadcasts.php:390 1000 1000 msgid "Pagination" 1001 1001 msgstr "" 1002 1002 1003 #: includes/blocks/class-convertkit-block-broadcasts.php: 4171003 #: includes/blocks/class-convertkit-block-broadcasts.php:399 1004 1004 msgid "Styles" 1005 1005 msgstr "" 1006 1006 1007 #: includes/blocks/class-convertkit-block-broadcasts.php:4 441007 #: includes/blocks/class-convertkit-block-broadcasts.php:426 1008 1008 msgid "Read more" 1009 1009 msgstr "" 1010 1010 1011 #: includes/blocks/class-convertkit-block-broadcasts.php:4 471011 #: includes/blocks/class-convertkit-block-broadcasts.php:429 1012 1012 msgid "Previous" 1013 1013 msgstr "" 1014 1014 1015 #: includes/blocks/class-convertkit-block-broadcasts.php:4 481015 #: includes/blocks/class-convertkit-block-broadcasts.php:430 1016 1016 msgid "Next" 1017 1017 msgstr "" 1018 1018 1019 #: includes/blocks/class-convertkit-block-broadcasts.php:4 941019 #: includes/blocks/class-convertkit-block-broadcasts.php:476 1020 1020 msgid "No Broadcasts exist in Kit." 1021 1021 msgstr "" … … 1044 1044 msgstr "" 1045 1045 1046 #: includes/blocks/class-convertkit-block-form-trigger.php: 911046 #: includes/blocks/class-convertkit-block-form-trigger.php:77 1047 1047 msgid "Displays a modal, sticky bar or slide in form to display when the button is pressed." 1048 1048 msgstr "" 1049 1049 1050 #: includes/blocks/class-convertkit-block-form-trigger.php:1 231050 #: includes/blocks/class-convertkit-block-form-trigger.php:109 1051 1051 #: includes/blocks/class-convertkit-block-form.php:139 1052 1052 msgid "Connect your Kit account at Settings > Kit, and then refresh this page to select a form." 1053 1053 msgstr "" 1054 1054 1055 #: includes/blocks/class-convertkit-block-form-trigger.php:1 261055 #: includes/blocks/class-convertkit-block-form-trigger.php:112 1056 1056 msgid "No modal, sticky bar or slide in forms exist in Kit." 1057 1057 msgstr "" 1058 1058 1059 #: includes/blocks/class-convertkit-block-form-trigger.php:1 281059 #: includes/blocks/class-convertkit-block-form-trigger.php:114 1060 1060 msgid "Click here to create a form." 1061 1061 msgstr "" 1062 1062 1063 #: includes/blocks/class-convertkit-block-form-trigger.php:1 291063 #: includes/blocks/class-convertkit-block-form-trigger.php:115 1064 1064 msgid "Add a non-inline form to your Kit account, and then refresh this page to select a form." 1065 1065 msgstr "" 1066 1066 1067 #: includes/blocks/class-convertkit-block-form-trigger.php:1 311067 #: includes/blocks/class-convertkit-block-form-trigger.php:120 1068 1068 #: includes/blocks/class-convertkit-block-form.php:149 1069 1069 msgid "Select a Form using the Form option in the Gutenberg sidebar." 1070 1070 msgstr "" 1071 1071 1072 #: includes/blocks/class-convertkit-block-form-trigger.php:2 561072 #: includes/blocks/class-convertkit-block-form-trigger.php:242 1073 1073 msgid "The modal, sticky bar or slide in form to display when the button is pressed. To embed a form, use the Kit Form block instead." 1074 1074 msgstr "" 1075 1075 1076 #: includes/blocks/class-convertkit-block-form-trigger.php:2 591077 #: includes/blocks/class-convertkit-block-product.php:2 891076 #: includes/blocks/class-convertkit-block-form-trigger.php:245 1077 #: includes/blocks/class-convertkit-block-product.php:272 1078 1078 msgid "Button Text" 1079 1079 msgstr "" 1080 1080 1081 #: includes/blocks/class-convertkit-block-form-trigger.php:2 611082 #: includes/blocks/class-convertkit-block-product.php:2 911081 #: includes/blocks/class-convertkit-block-form-trigger.php:247 1082 #: includes/blocks/class-convertkit-block-product.php:274 1083 1083 msgid "The text to display for the button." 1084 1084 msgstr "" 1085 1085 1086 #: includes/blocks/class-convertkit-block-form-trigger.php:3 191086 #: includes/blocks/class-convertkit-block-form-trigger.php:305 1087 1087 #: includes/class-convertkit-settings-restrict-content.php:229 1088 1088 #: includes/integrations/contactform7/class-convertkit-contactform7-admin-section.php:84 … … 1094 1094 1095 1095 #. translators: ConvertKit Form ID 1096 #: includes/blocks/class-convertkit-block-form-trigger.php:4 191097 #: includes/class-convertkit-resource-forms.php:49 61096 #: includes/blocks/class-convertkit-block-form-trigger.php:405 1097 #: includes/class-convertkit-resource-forms.php:497 1098 1098 msgid "Kit Form ID %s does not exist on Kit." 1099 1099 msgstr "" 1100 1100 1101 1101 #. translators: ConvertKit Form ID 1102 #: includes/blocks/class-convertkit-block-form-trigger.php:4 311102 #: includes/blocks/class-convertkit-block-form-trigger.php:417 1103 1103 msgid "Kit Form ID %s has no uid property." 1104 1104 msgstr "" 1105 1105 1106 1106 #. translators: ConvertKit Form ID 1107 #: includes/blocks/class-convertkit-block-form-trigger.php:4 411107 #: includes/blocks/class-convertkit-block-form-trigger.php:427 1108 1108 msgid "Kit Form ID %s has no embed_js property." 1109 1109 msgstr "" … … 1146 1146 msgstr "" 1147 1147 1148 #: includes/blocks/class-convertkit-block-product.php: 1121148 #: includes/blocks/class-convertkit-block-product.php:98 1149 1149 msgid "Kit Product" 1150 1150 msgstr "" 1151 1151 1152 #: includes/blocks/class-convertkit-block-product.php: 1131152 #: includes/blocks/class-convertkit-block-product.php:99 1153 1153 msgid "Displays a button to purchase a Kit product." 1154 1154 msgstr "" 1155 1155 1156 #: includes/blocks/class-convertkit-block-product.php:1 451156 #: includes/blocks/class-convertkit-block-product.php:131 1157 1157 msgid "Connect your Kit account at Settings > Kit, and then refresh this page to select a product." 1158 1158 msgstr "" 1159 1159 1160 #: includes/blocks/class-convertkit-block-product.php:1 481160 #: includes/blocks/class-convertkit-block-product.php:134 1161 1161 msgid "No products exist in Kit." 1162 1162 msgstr "" 1163 1163 1164 #: includes/blocks/class-convertkit-block-product.php:1 501164 #: includes/blocks/class-convertkit-block-product.php:136 1165 1165 msgid "Click here to create your first product." 1166 1166 msgstr "" 1167 1167 1168 #: includes/blocks/class-convertkit-block-product.php:1 511168 #: includes/blocks/class-convertkit-block-product.php:137 1169 1169 msgid "Add a product to your Kit account, and then refresh this page to select a product." 1170 1170 msgstr "" 1171 1171 1172 #: includes/blocks/class-convertkit-block-product.php:1 551172 #: includes/blocks/class-convertkit-block-product.php:141 1173 1173 msgid "Select a Product using the Product option in the Gutenberg sidebar." 1174 1174 msgstr "" 1175 1175 1176 #: includes/blocks/class-convertkit-block-product.php:2 941176 #: includes/blocks/class-convertkit-block-product.php:277 1177 1177 msgid "Discount Code" 1178 1178 msgstr "" 1179 1179 1180 #: includes/blocks/class-convertkit-block-product.php:2 961180 #: includes/blocks/class-convertkit-block-product.php:279 1181 1181 msgid "Optional: A discount code to include. Must be defined in the Kit Product." 1182 1182 msgstr "" 1183 1183 1184 #: includes/blocks/class-convertkit-block-product.php:2 991184 #: includes/blocks/class-convertkit-block-product.php:282 1185 1185 msgid "Load checkout step" 1186 1186 msgstr "" 1187 1187 1188 #: includes/blocks/class-convertkit-block-product.php: 3011188 #: includes/blocks/class-convertkit-block-product.php:284 1189 1189 msgid "If enabled, immediately loads the checkout screen, instead of the Kit Product description." 1190 1190 msgstr "" 1191 1191 1192 #: includes/blocks/class-convertkit-block-product.php: 3041192 #: includes/blocks/class-convertkit-block-product.php:287 1193 1193 msgid "Disable modal on mobile" 1194 1194 msgstr "" 1195 1195 1196 #: includes/blocks/class-convertkit-block-product.php: 3061196 #: includes/blocks/class-convertkit-block-product.php:289 1197 1197 msgid "Recommended if the Kit Product is a digital download being purchased on mobile, to ensure the subscriber can immediately download the PDF once purchased." 1198 1198 msgstr "" 1199 1199 1200 #: includes/blocks/class-convertkit-block-product.php:3 671200 #: includes/blocks/class-convertkit-block-product.php:350 1201 1201 msgid "Buy my product" 1202 1202 msgstr "" … … 1276 1276 msgstr "" 1277 1277 1278 #: includes/class-convertkit-resource-forms.php:51 21278 #: includes/class-convertkit-resource-forms.php:513 1279 1279 msgid "Kit Legacy Form could not be fetched as no Access Token specified in Plugin Settings" 1280 1280 msgstr "" … … 1475 1475 msgstr "" 1476 1476 1477 #: includes/integrations/elementor/class-convertkit-elementor-widget.php:2 951477 #: includes/integrations/elementor/class-convertkit-elementor-widget.php:283 1478 1478 msgid "No blocks are registered. Register blocks using the `convertkit_blocks` filter." 1479 1479 msgstr "" 1480 1480 1481 1481 #. translators: %1$s: Block name, %2$s: Elementor Widget name 1482 #: includes/integrations/elementor/class-convertkit-elementor-widget.php: 3041482 #: includes/integrations/elementor/class-convertkit-elementor-widget.php:292 1483 1483 msgid "Block %1$s is not registered. Register using the `convertkit_blocks` filter, and ensure the Elementor Widget for this block has its `slug` property set to %2$s." 1484 1484 msgstr "" -
convertkit/tags/2.8.7/readme.txt
r3333065 r3337204 6 6 Tested up to: 6.8 7 7 Requires PHP: 7.1 8 Stable tag: 2.8. 6.18 Stable tag: 2.8.7 9 9 License: GPLv3 or later 10 10 License URI: https://www.gnu.org/licenses/gpl-3.0.html … … 162 162 == Changelog == 163 163 164 ### 2.8.7 2025-07-31 165 * Added: Blocks: Form: Margin, padding and background color options 166 * Added: Debug: Forms: `data-kit-source-post-id` attribute to scripts when Debugging enabled 167 * Added: JS: Emit `kit_subscriber_id_removed_from_url` event when the `ck_subscriber_id` is removed from a URL 168 * Fix: Debloat Plugin: Exclude Forms from Debloat's Defer and Delay JS 169 * Fix: Classic Widgets: Form: Uncaught error: Call to undefined method `ConvertKit_Resource_Forms::output_select_field_all` 170 * Fix: Blocks: Refactored and removed unnecessary duplicate render callback functions in the block editor 171 164 172 ### 2.8.6.1 2025-07-23 165 173 * Fix: Form Trigger: Revert running `script` tags through `wp_kses`, as WordPress.com strip the script tag -
convertkit/tags/2.8.7/resources/backend/js/gutenberg.js
r3270754 r3337204 393 393 // use the block's PHP's render() function. 394 394 preview = window[ block.gutenberg_preview_render_callback ]( block, props ); 395 } else { 396 // If no settings have been defined for this block, return a prompt to tell the editor 397 // what to do. 398 if ( typeof block.gutenberg_help_description_attribute !== 'undefined' && props.attributes[ block.gutenberg_help_description_attribute ] === '' ) { 399 preview = convertKitGutenbergDisplayBlockNotice( block.name, block.gutenberg_help_description ); 400 } else { 401 // Use the block's PHP's render() function by calling the ServerSideRender component. 402 preview = wp.element.createElement( 403 wp.serverSideRender, 404 { 405 block: 'convertkit/' + block.name, 406 attributes: props.attributes, 407 408 // This is only output in the Gutenberg editor, so must be slightly different from the inner class name used to 409 // apply styles with i.e. convertkit-block.name. 410 className: 'convertkit-ssr-' + block.name, 411 } 412 ); 413 } 395 414 } 396 415 -
convertkit/tags/2.8.7/resources/frontend/js/convertkit.js
r3234366 r3337204 116 116 window.history.replaceState( null, title, url_object.pathname + params + url_object.hash ); 117 117 118 // Emit custom event with the removed subscriber ID. 119 convertKitEmitCustomEvent( 120 'kit_subscriber_id_removed_from_url', 121 { 122 id: ck_subscriber_id 123 } 124 ); 125 118 126 } 119 127 -
convertkit/tags/2.8.7/wp-convertkit.php
r3333065 r3337204 10 10 * Plugin URI: https://kit.com/ 11 11 * Description: Display Kit (formerly ConvertKit) email subscription forms, landing pages, products, broadcasts and more. 12 * Version: 2.8. 6.112 * Version: 2.8.7 13 13 * Author: Kit 14 14 * Author URI: https://kit.com/ … … 28 28 define( 'CONVERTKIT_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); 29 29 define( 'CONVERTKIT_PLUGIN_PATH', __DIR__ ); 30 define( 'CONVERTKIT_PLUGIN_VERSION', '2.8. 6.1' );30 define( 'CONVERTKIT_PLUGIN_VERSION', '2.8.7' ); 31 31 define( 'CONVERTKIT_OAUTH_CLIENT_ID', 'HXZlOCj-K5r0ufuWCtyoyo3f688VmMAYSsKg1eGvw0Y' ); 32 32 define( 'CONVERTKIT_OAUTH_CLIENT_REDIRECT_URI', 'https://app.kit.com/wordpress/redirect' ); -
convertkit/trunk/CHANGELOG.md
r3289504 r3337204 1 ### 2.8.7 2025-07-31 2 * Added: Blocks: Form: Margin, padding and background color options 3 * Added: Debug: Forms: `data-kit-source-post-id` attribute to scripts when Debugging enabled 4 * Added: JS: Emit `kit_subscriber_id_removed_from_url` event when the `ck_subscriber_id` is removed from a URL 5 * Fix: Debloat Plugin: Exclude Forms from Debloat's Defer and Delay JS 6 * Fix: Classic Widgets: Form: Uncaught error: Call to undefined method `ConvertKit_Resource_Forms::output_select_field_all` 7 * Fix: Blocks: Refactored and removed unnecessary duplicate render callback functions in the block editor 8 9 ### 2.8.6.1 2025-07-23 10 * Fix: Form Trigger: Revert running `script` tags through `wp_kses`, as WordPress.com strip the script tag 11 12 ### 2.8.6 2025-07-23 13 * Fix: Form Block: Correctly style "No Content" message when selecting a modal form 14 * Fix: Member Content: Display all Posts if filter = All content 15 16 ### 2.8.5 2025-07-17 17 * Fix: Broadcasts, Form Trigger and Product Blocks: Improve rendering accuracy between block editor and frontend site 18 * Fix: Sanitization and security enhancements 19 20 ### 2.8.4 2025-07-10 21 * Added: Broadcasts Block: Display order option 22 * Added: Broadcasts, Form Trigger and Product Blocks: Use `get_block_wrapper_attributes` for block `class` and `style` attributes 23 * Added: Broadcasts, Form Trigger and Product Blocks: Typography options 24 * Added: Broadcasts, Form Trigger and Product Blocks: Margin and padding options 25 26 ### 2.8.3 2025-07-03 27 * Added: Member Content: `All member-only content` option added to filter dropdown in Posts and Pages tables 28 * Fix: Member Content: Replace `Members only` with `member-only` 29 * Fix: Automatically refresh Access Token when expired 30 31 ### 2.8.2 2025-05-28 32 * Fix: Broadcasts: Remove emoijs from Permalink whem importing Broadcasts to WordPress Posts 33 * Fix: Coding Standards: Use `wp_doing_cron` function, instead of `DOING_CRON` constant 34 1 35 ### 2.8.1 2025-05-07 2 36 * Added: Member Content: Permits Apple, DuckDuckGo, OpenAI Search, Perplexity and Yandex to crawl Member Content if the Permit Search Engine Crawlers option is enabled -
convertkit/trunk/includes/blocks/class-convertkit-block-broadcasts.php
r3329966 r3337204 28 28 add_filter( 'convertkit_blocks', array( $this, 'register' ) ); 29 29 30 // Enqueue scripts and styles for this Gutenberg Block in the editor view.31 add_action( 'convertkit_gutenberg_enqueue_scripts', array( $this, 'enqueue_scripts_editor' ) );32 33 30 // Enqueue scripts and styles for this Gutenberg Block in the editor and frontend views. 34 31 add_action( 'convertkit_gutenberg_enqueue_scripts_editor_and_frontend', array( $this, 'enqueue_scripts' ) ); … … 38 35 add_action( 'wp_ajax_nopriv_convertkit_broadcasts_render', array( $this, 'render_ajax' ) ); 39 36 add_action( 'wp_ajax_convertkit_broadcasts_render', array( $this, 'render_ajax' ) ); 40 41 }42 43 /**44 * Enqueues scripts for this Gutenberg Block in the editor view.45 *46 * @since 2.0.147 */48 public function enqueue_scripts_editor() {49 50 wp_enqueue_script( 'convertkit-gutenberg-block-broadcasts', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/gutenberg-block-broadcasts.js', array( 'convertkit-gutenberg' ), CONVERTKIT_PLUGIN_VERSION, true );51 37 52 38 } … … 118 104 119 105 return array( 120 'title' => __( 'Kit Broadcasts', 'convertkit' ),121 'description' => __( 'Displays a list of your Kit broadcasts.', 'convertkit' ),122 'icon' => 'resources/backend/images/block-icon-broadcasts.svg',123 'category' => 'convertkit',124 'keywords' => array(106 'title' => __( 'Kit Broadcasts', 'convertkit' ), 107 'description' => __( 'Displays a list of your Kit broadcasts.', 'convertkit' ), 108 'icon' => 'resources/backend/images/block-icon-broadcasts.svg', 109 'category' => 'convertkit', 110 'keywords' => array( 125 111 __( 'ConvertKit', 'convertkit' ), 126 112 __( 'Kit', 'convertkit' ), … … 130 116 131 117 // Function to call when rendering as a block or a shortcode on the frontend web site. 132 'render_callback' => array( $this, 'render' ),118 'render_callback' => array( $this, 'render' ), 133 119 134 120 // Shortcode: TinyMCE / QuickTags Modal Width and Height. 135 'modal' => array(121 'modal' => array( 136 122 'width' => 650, 137 123 'height' => 455, … … 139 125 140 126 // Shortcode: Include a closing [/shortcode] tag when using TinyMCE or QuickTag Modals. 141 'shortcode_include_closing_tag' => false,127 'shortcode_include_closing_tag' => false, 142 128 143 129 // Gutenberg: Block Icon in Editor. 144 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-broadcasts.svg' ),130 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-broadcasts.svg' ), 145 131 146 132 // Gutenberg: Example image showing how this block looks when choosing it in Gutenberg. 147 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-broadcasts.png',133 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-broadcasts.png', 148 134 149 135 // Help descriptions, displayed when no Access Token / resources exist and this block/shortcode is added. 150 'no_access_token' => array(136 'no_access_token' => array( 151 137 'notice' => __( 'Not connected to Kit.', 'convertkit' ), 152 138 'link' => convertkit_get_setup_wizard_plugin_link(), … … 154 140 'instruction_text' => __( 'Connect your Kit account at Settings > Kit, and then refresh this page to configure broadcasts to display.', 'convertkit' ), 155 141 ), 156 'no_resources' => array(142 'no_resources' => array( 157 143 'notice' => __( 'No broadcasts exist in Kit.', 'convertkit' ), 158 144 'link' => convertkit_get_new_broadcast_url(), … … 161 147 ), 162 148 163 // Gutenberg: JS function to call when rendering the block preview in the Gutenberg editor.164 // If not defined, render_callback above will be used.165 'gutenberg_preview_render_callback' => 'convertKitGutenbergBroadcastsBlockRenderPreview',166 167 149 // Whether an API Key exists in the Plugin, and are the required resources (broadcasts) available. 168 150 // If no API Key is specified in the Plugin's settings, render the "No API Key" output. 169 'has_access_token' => $settings->has_access_and_refresh_token(),170 'has_resources' => $posts->exist(),151 'has_access_token' => $settings->has_access_and_refresh_token(), 152 'has_resources' => $posts->exist(), 171 153 ); 172 154 -
convertkit/trunk/includes/blocks/class-convertkit-block-form-trigger.php
r3329966 r3337204 28 28 add_filter( 'convertkit_blocks', array( $this, 'register' ) ); 29 29 30 // Enqueue scripts and styles for this Gutenberg Block in the editor view.31 add_action( 'convertkit_gutenberg_enqueue_scripts', array( $this, 'enqueue_scripts_editor' ) );32 33 30 // Enqueue scripts and styles for this Gutenberg Block in the editor and frontend views. 34 31 add_action( 'convertkit_gutenberg_enqueue_styles_editor_and_frontend', array( $this, 'enqueue_styles' ) ); 35 36 }37 38 /**39 * Enqueues scripts for this Gutenberg Block in the editor view.40 *41 * @since 2.2.042 */43 public function enqueue_scripts_editor() {44 45 wp_enqueue_script( 'convertkit-gutenberg-block-form-trigger', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/gutenberg-block-form-trigger.js', array( 'convertkit-gutenberg' ), CONVERTKIT_PLUGIN_VERSION, true );46 32 47 33 } … … 88 74 89 75 return array( 90 'title' => __( 'Kit Form Trigger', 'convertkit' ),91 'description' => __( 'Displays a modal, sticky bar or slide in form to display when the button is pressed.', 'convertkit' ),92 'icon' => 'resources/backend/images/block-icon-formtrigger.svg',93 'category' => 'convertkit',94 'keywords' => array(76 'title' => __( 'Kit Form Trigger', 'convertkit' ), 77 'description' => __( 'Displays a modal, sticky bar or slide in form to display when the button is pressed.', 'convertkit' ), 78 'icon' => 'resources/backend/images/block-icon-formtrigger.svg', 79 'category' => 'convertkit', 80 'keywords' => array( 95 81 __( 'ConvertKit', 'convertkit' ), 96 82 __( 'Kit', 'convertkit' ), … … 99 85 100 86 // Function to call when rendering as a block or a shortcode on the frontend web site. 101 'render_callback' => array( $this, 'render' ),87 'render_callback' => array( $this, 'render' ), 102 88 103 89 // Shortcode: TinyMCE / QuickTags Modal Width and Height. 104 'modal' => array(90 'modal' => array( 105 91 'width' => 500, 106 92 'height' => 282, … … 108 94 109 95 // Shortcode: Include a closing [/shortcode] tag when using TinyMCE or QuickTag Modals. 110 'shortcode_include_closing_tag' => false,96 'shortcode_include_closing_tag' => false, 111 97 112 98 // Gutenberg: Block Icon in Editor. 113 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-formtrigger.svg' ),99 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-formtrigger.svg' ), 114 100 115 101 // Gutenberg: Example image showing how this block looks when choosing it in Gutenberg. 116 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-formtrigger.png',102 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-formtrigger.png', 117 103 118 104 // Help descriptions, displayed when no API key / resources exist and this block/shortcode is added. 119 'no_access_token' => array(105 'no_access_token' => array( 120 106 'notice' => __( 'Not connected to Kit.', 'convertkit' ), 121 107 'link' => convertkit_get_setup_wizard_plugin_link(), … … 123 109 'instruction_text' => __( 'Connect your Kit account at Settings > Kit, and then refresh this page to select a form.', 'convertkit' ), 124 110 ), 125 'no_resources' => array(111 'no_resources' => array( 126 112 'notice' => __( 'No modal, sticky bar or slide in forms exist in Kit.', 'convertkit' ), 127 113 'link' => convertkit_get_new_form_url(), … … 129 115 'instruction_text' => __( 'Add a non-inline form to your Kit account, and then refresh this page to select a form.', 'convertkit' ), 130 116 ), 131 'gutenberg_help_description' => __( 'Select a Form using the Form option in the Gutenberg sidebar.', 'convertkit' ), 132 133 // Gutenberg: JS function to call when rendering the block preview in the Gutenberg editor.134 // If not defined, render_callback above will be used.135 'gutenberg_ preview_render_callback' => 'convertKitGutenbergFormTriggerBlockRenderPreview',117 118 // The attribute to check if a value exists when rendering the block in the editor, 119 // and the message to display if no value exists. 120 'gutenberg_help_description' => __( 'Select a Form using the Form option in the Gutenberg sidebar.', 'convertkit' ), 121 'gutenberg_help_description_attribute' => 'form', 136 122 137 123 // Whether an API Key exists in the Plugin, and are the required resources (non-inline forms) available. 138 124 // If no API Key is specified in the Plugin's settings, render the "No API Key" output. 139 'has_access_token' => $settings->has_access_and_refresh_token(),140 'has_resources' => $convertkit_forms->non_inline_exist(),125 'has_access_token' => $settings->has_access_and_refresh_token(), 126 'has_resources' => $convertkit_forms->non_inline_exist(), 141 127 ); 142 128 -
convertkit/trunk/includes/blocks/class-convertkit-block-form.php
r3227192 r3337204 187 187 ), 188 188 189 // get_supports() style, color and typography attributes. 190 'style' => array( 191 'type' => 'object', 192 ), 193 'backgroundColor' => array( 194 'type' => 'string', 195 ), 196 189 197 // Always required for Gutenberg. 190 198 'is_gutenberg_example' => array( 191 199 'type' => 'boolean', 192 200 'default' => false, 201 ), 202 ); 203 204 } 205 206 /** 207 * Returns this block's supported built-in Attributes. 208 * 209 * @since 1.9.7.4 210 * 211 * @return array Supports 212 */ 213 public function get_supports() { 214 215 return array( 216 'className' => true, 217 'color' => array( 218 'link' => false, 219 'background' => true, 220 'text' => false, 221 ), 222 'spacing' => array( 223 'margin' => true, 224 'padding' => true, 193 225 ), 194 226 ); … … 292 324 public function render( $atts ) { 293 325 326 global $post; 327 328 $post_id = is_a( $post, 'WP_Post' ) ? $post->ID : 0; 329 294 330 // Check if the Block Visibility Plugin permits displaying this block. 295 331 if ( ! $this->is_block_visible( $atts ) ) { … … 329 365 // Get Form HTML. 330 366 $forms = new ConvertKit_Resource_Forms( 'output_form' ); 331 $form = $forms->get_html( $form_id );367 $form = $forms->get_html( $form_id, $post_id ); 332 368 333 369 // If an error occured, it might be that we're requesting a Form ID that exists in ConvertKit … … 339 375 340 376 // Get Form HTML again. 341 $form = $forms->get_html( $form_id );377 $form = $forms->get_html( $form_id, $post_id ); 342 378 } 343 379 … … 371 407 } 372 408 409 // Build HTML. 410 // For the block editor, don't include compiled CSS classes and styles, 411 // as the block editor will add these to the parent container. 412 // Otherwise the block will render incorrectly with double padding, double margins etc. 413 // If there's no Form HTML, it's a non-inline form, so don't render any output. 414 if ( ! $this->is_block_editor_request() && ! empty( $form ) ) { 415 $form = sprintf( 416 '<div class="%s" style="%s">%s</div>', 417 implode( ' ', map_deep( $this->get_css_classes(), 'sanitize_html_class' ) ), 418 implode( ';', map_deep( $this->get_css_styles( $atts ), 'esc_attr' ) ), 419 $form 420 ); 421 } 422 373 423 /** 374 424 * Filter the block's content immediately before it is output. -
convertkit/trunk/includes/blocks/class-convertkit-block-product.php
r3329966 r3337204 28 28 add_filter( 'convertkit_blocks', array( $this, 'register' ) ); 29 29 30 // Enqueue scripts and styles for this Gutenberg Block in the editor view.31 add_action( 'convertkit_gutenberg_enqueue_scripts', array( $this, 'enqueue_scripts_editor' ) );32 33 30 // Enqueue scripts and styles for this Gutenberg Block in the editor and frontend views. 34 31 add_action( 'convertkit_gutenberg_enqueue_scripts_editor_and_frontend', array( $this, 'enqueue_scripts' ) ); 35 32 add_action( 'convertkit_gutenberg_enqueue_styles_editor_and_frontend', array( $this, 'enqueue_styles' ) ); 36 37 }38 39 /**40 * Enqueues scripts for this Gutenberg Block in the editor view.41 *42 * @since 1.9.8.543 */44 public function enqueue_scripts_editor() {45 46 wp_enqueue_script( 'convertkit-gutenberg-block-product', CONVERTKIT_PLUGIN_URL . 'resources/backend/js/gutenberg-block-product.js', array( 'convertkit-gutenberg' ), CONVERTKIT_PLUGIN_VERSION, true );47 33 48 34 } … … 110 96 111 97 return array( 112 'title' => __( 'Kit Product', 'convertkit' ),113 'description' => __( 'Displays a button to purchase a Kit product.', 'convertkit' ),114 'icon' => 'resources/backend/images/block-icon-product.svg',115 'category' => 'convertkit',116 'keywords' => array(98 'title' => __( 'Kit Product', 'convertkit' ), 99 'description' => __( 'Displays a button to purchase a Kit product.', 'convertkit' ), 100 'icon' => 'resources/backend/images/block-icon-product.svg', 101 'category' => 'convertkit', 102 'keywords' => array( 117 103 __( 'ConvertKit', 'convertkit' ), 118 104 __( 'Kit', 'convertkit' ), … … 121 107 122 108 // Function to call when rendering as a block or a shortcode on the frontend web site. 123 'render_callback' => array( $this, 'render' ),109 'render_callback' => array( $this, 'render' ), 124 110 125 111 // Shortcode: TinyMCE / QuickTags Modal Width and Height. 126 'modal' => array(112 'modal' => array( 127 113 'width' => 600, 128 114 'height' => 518, … … 130 116 131 117 // Shortcode: Include a closing [/shortcode] tag when using TinyMCE or QuickTag Modals. 132 'shortcode_include_closing_tag' => false,118 'shortcode_include_closing_tag' => false, 133 119 134 120 // Gutenberg: Block Icon in Editor. 135 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-product.svg' ),121 'gutenberg_icon' => convertkit_get_file_contents( CONVERTKIT_PLUGIN_PATH . '/resources/backend/images/block-icon-product.svg' ), 136 122 137 123 // Gutenberg: Example image showing how this block looks when choosing it in Gutenberg. 138 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-product.png',124 'gutenberg_example_image' => CONVERTKIT_PLUGIN_URL . 'resources/backend/images/block-example-product.png', 139 125 140 126 // Help descriptions, displayed when no Access Token / resources exist and this block/shortcode is added. 141 'no_access_token' => array(127 'no_access_token' => array( 142 128 'notice' => __( 'Not connected to Kit.', 'convertkit' ), 143 129 'link' => convertkit_get_setup_wizard_plugin_link(), … … 145 131 'instruction_text' => __( 'Connect your Kit account at Settings > Kit, and then refresh this page to select a product.', 'convertkit' ), 146 132 ), 147 'no_resources' => array(133 'no_resources' => array( 148 134 'notice' => __( 'No products exist in Kit.', 'convertkit' ), 149 135 'link' => convertkit_get_new_product_url(), … … 152 138 ), 153 139 154 // Gutenberg: Help descriptions, displayed when no settings defined for a newly added Block. 155 'gutenberg_help_description' => __( 'Select a Product using the Product option in the Gutenberg sidebar.', 'convertkit' ), 156 157 // Gutenberg: JS function to call when rendering the block preview in the Gutenberg editor. 158 // If not defined, render_callback above will be used. 159 'gutenberg_preview_render_callback' => 'convertKitGutenbergProductBlockRenderPreview', 140 // Gutenberg: Help description, displayed when the defined attribute has not been set for the block. 141 'gutenberg_help_description' => __( 'Select a Product using the Product option in the Gutenberg sidebar.', 'convertkit' ), 142 'gutenberg_help_description_attribute' => 'product', 160 143 161 144 // Whether an Access Token exists in the Plugin, and are the required resources (products) available. 162 145 // If no Access Token is specified in the Plugin's settings, render the "Not Connected" output. 163 'has_access_token' => $settings->has_access_and_refresh_token(),164 'has_resources' => $convertkit_products->exist(),146 'has_access_token' => $settings->has_access_and_refresh_token(), 147 'has_resources' => $convertkit_products->exist(), 165 148 ); 166 149 -
convertkit/trunk/includes/blocks/class-convertkit-block.php
r3329966 r3337204 261 261 */ 262 262 public function get_css_classes( $additional_classes = array() ) { 263 264 // To avoid errors in get_block_wrapper_attributes() in non-block themes using the shortcode, 265 // tell WordPress that a block is being rendered. 266 // The attributes don't matter, as we send them to the render() function. 267 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line 268 WP_Block_Supports::$block_to_render = array( 269 'blockName' => 'convertkit/' . $this->get_name(), 270 'attrs' => array(), 271 'innerBlocks' => array(), 272 'innerHTML' => '', 273 'innerContent' => array(), 274 ); 275 } 263 276 264 277 // Get the block wrapper attributes string. … … 306 319 public function get_css_styles( $atts ) { 307 320 321 // To avoid errors in get_block_wrapper_attributes() in non-block themes using the shortcode, 322 // tell WordPress that a block is being rendered. 323 // The attributes don't matter, as we send them to the render() function. 324 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line 325 WP_Block_Supports::$block_to_render = array( 326 'blockName' => 'convertkit/' . $this->get_name(), 327 'attrs' => array(), 328 'innerBlocks' => array(), 329 'innerHTML' => '', 330 'innerContent' => array(), 331 ); 332 } 333 308 334 $styles = array(); 309 335 -
convertkit/trunk/includes/blocks/form/block.json
r3160977 r3337204 24 24 }, 25 25 "supports": { 26 "className": true 26 "className": true, 27 "color": { 28 "link": false, 29 "background": true, 30 "text": false 31 }, 32 "spacing": { 33 "margin": true, 34 "padding": true 35 } 27 36 }, 28 37 "editorScript": "convertkit-gutenberg" -
convertkit/trunk/includes/class-convertkit-ajax.php
r3251976 r3337204 41 41 * 42 42 * Typically used when a refresh button in a block has been pressed when 43 * convertKitGutenbergDisplayBlockNoticeWithLink() is called, because either43 * displayNoticeWithLink() is called, because either 44 44 * no Access Token is specified, or no resources exist in ConvertKit. 45 45 * -
convertkit/trunk/includes/class-convertkit-cache-plugins.php
r3186945 r3337204 53 53 add_filter( 'convertkit_resource_forms_output_script', array( $this, 'autoptimize_exclude_js_defer' ) ); 54 54 55 // Debloat: Exclude Forms from Delay Load JS. 56 add_filter( 'debloat/defer_js_excludes', array( $this, 'exclude_hosts_from_minification' ) ); 57 add_filter( 'debloat/delay_js_excludes', array( $this, 'exclude_hosts_from_minification' ) ); 58 55 59 // Jetpack Boost: Exclude Forms from JS defer. 56 60 add_filter( 'convertkit_output_script_footer', array( $this, 'jetpack_boost_exclude_js_defer' ) ); -
convertkit/trunk/includes/class-convertkit-output-restrict-content.php
r3329966 r3337204 1324 1324 // Display the Form. 1325 1325 $forms = new ConvertKit_Resource_Forms( 'restrict_content' ); 1326 $form = $forms->get_html( $this->resource_id );1326 $form = $forms->get_html( $this->resource_id, $post_id ); 1327 1327 1328 1328 // If scripts are enabled, output the email login form in a modal, which will be displayed -
convertkit/trunk/includes/class-convertkit-output.php
r3333065 r3337204 312 312 313 313 // Get Form HTML. 314 $form = $this->forms->get_html( $form_id );314 $form = $this->forms->get_html( $form_id, $post_id ); 315 315 316 316 // If an error occured, it could be because the specified Form ID for the Post either: … … 336 336 337 337 // Get Form HTML. 338 $form = $this->forms->get_html( $form_id );338 $form = $this->forms->get_html( $form_id, $post_id ); 339 339 340 340 // If an error occured again, the default form doesn't exist in this ConvertKit account. -
convertkit/trunk/includes/class-convertkit-resource-forms.php
r3329966 r3337204 475 475 * @since 1.9.6 476 476 * 477 * @param int $id Form ID. 477 * @param int $id Form ID. 478 * @param int $post_id Post ID that requested the Form. 478 479 * @return WP_Error|string 479 480 */ 480 public function get_html( $id ) {481 public function get_html( $id, $post_id = 0 ) { 481 482 482 483 // Cast ID to integer. … … 500 501 } 501 502 503 // Initialize Settings. 504 $settings = new ConvertKit_Settings(); 505 502 506 // If no uid is present in the Form API data, this is a legacy form that's served by directly fetching the HTML 503 507 // from forms.kit.com. 504 508 if ( ! isset( $this->resources[ $id ]['uid'] ) ) { 505 // Initialize Settings.506 $settings = new ConvertKit_Settings();507 508 509 // Bail if no Access Token is specified in the Plugin Settings. 509 510 if ( ! $settings->has_access_token() ) { … … 537 538 add_filter( 538 539 'convertkit_output_scripts_footer', 539 function ( $scripts ) use ( $id ) { 540 541 $scripts[] = array( 540 function ( $scripts ) use ( $id, $post_id, $settings ) { 541 542 // Build script. 543 $script = array( 542 544 'async' => true, 543 545 'data-uid' => $this->resources[ $id ]['uid'], 544 546 'src' => $this->resources[ $id ]['embed_js'], 545 547 ); 548 549 // If debugging is enabled, add the post ID to the script. 550 if ( $settings->debug_enabled() ) { 551 $script['data-kit-source-post-id'] = $post_id; 552 } 553 554 // Add the script to the scripts array. 555 $scripts[] = $script; 546 556 547 557 return $scripts; … … 575 585 'src' => $this->resources[ $id ]['embed_js'], 576 586 ); 587 588 // If debugging is enabled, add the post ID to the script. 589 if ( $settings->debug_enabled() ) { 590 $script['data-kit-source-post-id'] = $post_id; 591 } 577 592 578 593 /** -
convertkit/trunk/includes/integrations/divi/class-convertkit-divi-module.php
r3329966 r3337204 186 186 public function render( $unprocessed_props, $content, $render_slug ) { // phpcs:ignore Generic.CodeAnalysis.UnusedFunctionParameter 187 187 188 // To avoid errors in get_block_wrapper_attributes(), tell WordPress that a block is being rendered.189 // The attributes don't matter, as we send them to the render() function.190 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line191 WP_Block_Supports::$block_to_render = array(192 'blockName' => 'convertkit/' . $this->block_name,193 'attrs' => array(),194 'innerBlocks' => array(),195 'innerHTML' => '',196 'innerContent' => array(),197 );198 }199 200 188 // Render using Block class' render() function. 201 189 // Output is already escaped in render() function. -
convertkit/trunk/includes/integrations/elementor/class-convertkit-elementor-widget.php
r3329966 r3337204 261 261 } 262 262 263 // To avoid errors in get_block_wrapper_attributes(), tell WordPress that a block is being rendered.264 // The attributes don't matter, as we send them to the render() function.265 if ( class_exists( 'WP_Block_Supports' ) && is_null( WP_Block_Supports::$block_to_render ) ) { // @phpstan-ignore-line266 WP_Block_Supports::$block_to_render = array(267 'blockName' => 'convertkit/' . $this->get_block_name(),268 'attrs' => array(),269 'innerBlocks' => array(),270 'innerHTML' => '',271 'innerContent' => array(),272 );273 }274 275 263 // Render using Block class' render() function. 276 264 // Output is already escaped in render() function. -
convertkit/trunk/includes/widgets/class-ck-widget-form.php
r3329966 r3337204 79 79 <label for="<?php echo esc_attr( $this->get_field_id( 'form' ) ); ?>"><?php esc_html_e( 'Form', 'convertkit' ); ?></label> 80 80 <?php 81 $forms->output_select_field_all(81 echo $forms->get_select_field_all( // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped 82 82 esc_attr( $this->get_field_name( 'form' ) ), 83 83 esc_attr( $this->get_field_id( 'form' ) ), -
convertkit/trunk/languages/convertkit.pot
r3332639 r3337204 3 3 msgid "" 4 4 msgstr "" 5 "Project-Id-Version: Kit (formerly ConvertKit) 2.8. 6\n"5 "Project-Id-Version: Kit (formerly ConvertKit) 2.8.7\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/convertkit\n" 7 7 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" … … 10 10 "Content-Type: text/plain; charset=UTF-8\n" 11 11 "Content-Transfer-Encoding: 8bit\n" 12 "POT-Creation-Date: 2025-07- 23T04:52:18+00:00\n"12 "POT-Creation-Date: 2025-07-31T03:05:55+00:00\n" 13 13 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" 14 14 "X-Generator: WP-CLI 2.11.0\n" … … 37 37 #: admin/class-convertkit-admin-settings.php:113 38 38 #: admin/class-convertkit-admin-settings.php:132 39 #: includes/blocks/class-convertkit-block-broadcasts.php:1 2639 #: includes/blocks/class-convertkit-block-broadcasts.php:112 40 40 #: includes/blocks/class-convertkit-block-content.php:63 41 #: includes/blocks/class-convertkit-block-form-trigger.php: 9641 #: includes/blocks/class-convertkit-block-form-trigger.php:82 42 42 #: includes/blocks/class-convertkit-block-form.php:112 43 #: includes/blocks/class-convertkit-block-product.php:1 1843 #: includes/blocks/class-convertkit-block-product.php:104 44 44 #: includes/integrations/contactform7/class-convertkit-contactform7-admin-section.php:139 45 45 #: includes/integrations/elementor/class-convertkit-elementor.php:70 … … 141 141 #: admin/section/class-convertkit-admin-section-broadcasts.php:33 142 142 #: admin/section/class-convertkit-admin-section-broadcasts.php:202 143 #: includes/blocks/class-convertkit-block-broadcasts.php:1 27143 #: includes/blocks/class-convertkit-block-broadcasts.php:113 144 144 msgid "Broadcasts" 145 145 msgstr "" … … 283 283 284 284 #: admin/section/class-convertkit-admin-section-general.php:58 285 #: includes/blocks/class-convertkit-block-broadcasts.php:3 96285 #: includes/blocks/class-convertkit-block-broadcasts.php:378 286 286 #: includes/blocks/class-convertkit-block-content.php:147 287 #: includes/blocks/class-convertkit-block-form-trigger.php:2 96288 #: includes/blocks/class-convertkit-block-form.php:2 59289 #: includes/blocks/class-convertkit-block-product.php:3 41287 #: includes/blocks/class-convertkit-block-form-trigger.php:282 288 #: includes/blocks/class-convertkit-block-form.php:291 289 #: includes/blocks/class-convertkit-block-product.php:324 290 290 msgid "General" 291 291 msgstr "" … … 809 809 810 810 #: includes/block-formatters/class-convertkit-block-formatter-form-link.php:77 811 #: includes/blocks/class-convertkit-block-form-trigger.php: 90811 #: includes/blocks/class-convertkit-block-form-trigger.php:76 812 812 msgid "Kit Form Trigger" 813 813 msgstr "" … … 818 818 819 819 #: includes/block-formatters/class-convertkit-block-formatter-form-link.php:143 820 #: includes/blocks/class-convertkit-block-form-trigger.php: 97821 #: includes/blocks/class-convertkit-block-form-trigger.php:2 52820 #: includes/blocks/class-convertkit-block-form-trigger.php:83 821 #: includes/blocks/class-convertkit-block-form-trigger.php:238 822 822 #: includes/blocks/class-convertkit-block-form.php:113 823 #: includes/blocks/class-convertkit-block-form.php:2 28823 #: includes/blocks/class-convertkit-block-form.php:260 824 824 #: includes/integrations/contactform7/class-convertkit-contactform7-admin-section.php:86 825 825 #: includes/integrations/forminator/class-convertkit-forminator-admin-section.php:73 … … 848 848 849 849 #: includes/block-formatters/class-convertkit-block-formatter-product-link.php:134 850 #: includes/blocks/class-convertkit-block-product.php:1 19851 #: includes/blocks/class-convertkit-block-product.php:2 83850 #: includes/blocks/class-convertkit-block-product.php:105 851 #: includes/blocks/class-convertkit-block-product.php:266 852 852 #: views/backend/post/meta-box.php:203 853 853 #: views/backend/setup-wizard/convertkit-restrict-content-setup/content-2.php:112 … … 859 859 msgstr "" 860 860 861 #: includes/blocks/class-convertkit-block-broadcasts.php:1 20861 #: includes/blocks/class-convertkit-block-broadcasts.php:106 862 862 msgid "Kit Broadcasts" 863 863 msgstr "" 864 864 865 #: includes/blocks/class-convertkit-block-broadcasts.php:1 21865 #: includes/blocks/class-convertkit-block-broadcasts.php:107 866 866 msgid "Displays a list of your Kit broadcasts." 867 867 msgstr "" 868 868 869 #: includes/blocks/class-convertkit-block-broadcasts.php:1 25869 #: includes/blocks/class-convertkit-block-broadcasts.php:111 870 870 #: includes/blocks/class-convertkit-block-content.php:62 871 #: includes/blocks/class-convertkit-block-form-trigger.php: 95871 #: includes/blocks/class-convertkit-block-form-trigger.php:81 872 872 #: includes/blocks/class-convertkit-block-form.php:111 873 #: includes/blocks/class-convertkit-block-product.php:1 17873 #: includes/blocks/class-convertkit-block-product.php:103 874 874 msgid "ConvertKit" 875 875 msgstr "" 876 876 877 #: includes/blocks/class-convertkit-block-broadcasts.php:1 28877 #: includes/blocks/class-convertkit-block-broadcasts.php:114 878 878 msgid "Posts" 879 879 msgstr "" 880 880 881 #: includes/blocks/class-convertkit-block-broadcasts.php:1 51882 #: includes/blocks/class-convertkit-block-form-trigger.php:1 20881 #: includes/blocks/class-convertkit-block-broadcasts.php:137 882 #: includes/blocks/class-convertkit-block-form-trigger.php:106 883 883 #: includes/blocks/class-convertkit-block-form.php:136 884 #: includes/blocks/class-convertkit-block-product.php:1 42884 #: includes/blocks/class-convertkit-block-product.php:128 885 885 msgid "Not connected to Kit." 886 886 msgstr "" 887 887 888 #: includes/blocks/class-convertkit-block-broadcasts.php:1 53889 #: includes/blocks/class-convertkit-block-form-trigger.php:1 22888 #: includes/blocks/class-convertkit-block-broadcasts.php:139 889 #: includes/blocks/class-convertkit-block-form-trigger.php:108 890 890 #: includes/blocks/class-convertkit-block-form.php:138 891 #: includes/blocks/class-convertkit-block-product.php:1 44891 #: includes/blocks/class-convertkit-block-product.php:130 892 892 msgid "Click here to connect your Kit account." 893 893 msgstr "" 894 894 895 #: includes/blocks/class-convertkit-block-broadcasts.php:1 54895 #: includes/blocks/class-convertkit-block-broadcasts.php:140 896 896 msgid "Connect your Kit account at Settings > Kit, and then refresh this page to configure broadcasts to display." 897 897 msgstr "" 898 898 899 #: includes/blocks/class-convertkit-block-broadcasts.php:1 57899 #: includes/blocks/class-convertkit-block-broadcasts.php:143 900 900 msgid "No broadcasts exist in Kit." 901 901 msgstr "" 902 902 903 #: includes/blocks/class-convertkit-block-broadcasts.php:1 59903 #: includes/blocks/class-convertkit-block-broadcasts.php:145 904 904 msgid "Click here to send your first broadcast." 905 905 msgstr "" 906 906 907 #: includes/blocks/class-convertkit-block-broadcasts.php:1 60907 #: includes/blocks/class-convertkit-block-broadcasts.php:146 908 908 msgid "Add a broadcast to your Kit account, and then refresh this page to configure broadcasts to display." 909 909 msgstr "" 910 910 911 #: includes/blocks/class-convertkit-block-broadcasts.php: 300911 #: includes/blocks/class-convertkit-block-broadcasts.php:282 912 912 msgid "Display as grid" 913 913 msgstr "" 914 914 915 #: includes/blocks/class-convertkit-block-broadcasts.php: 302915 #: includes/blocks/class-convertkit-block-broadcasts.php:284 916 916 msgid "If enabled, displays broadcasts in a grid, instead of a list." 917 917 msgstr "" 918 918 919 #: includes/blocks/class-convertkit-block-broadcasts.php:287 920 msgid "Display order" 921 msgstr "" 922 923 #: includes/blocks/class-convertkit-block-broadcasts.php:290 924 msgid "Date, Broadcast" 925 msgstr "" 926 927 #: includes/blocks/class-convertkit-block-broadcasts.php:291 928 msgid "Broadcast, Date" 929 msgstr "" 930 931 #: includes/blocks/class-convertkit-block-broadcasts.php:295 932 msgid "Date format" 933 msgstr "" 934 919 935 #: includes/blocks/class-convertkit-block-broadcasts.php:305 920 msgid "Display order" 921 msgstr "" 922 923 #: includes/blocks/class-convertkit-block-broadcasts.php:308 924 msgid "Date, Broadcast" 936 msgid "Display images" 925 937 msgstr "" 926 938 927 939 #: includes/blocks/class-convertkit-block-broadcasts.php:309 928 msgid " Broadcast, Date"940 msgid "Display descriptions" 929 941 msgstr "" 930 942 931 943 #: includes/blocks/class-convertkit-block-broadcasts.php:313 932 msgid "Date format" 933 msgstr "" 934 935 #: includes/blocks/class-convertkit-block-broadcasts.php:323 936 msgid "Display images" 937 msgstr "" 938 939 #: includes/blocks/class-convertkit-block-broadcasts.php:327 940 msgid "Display descriptions" 944 msgid "Display read more links" 945 msgstr "" 946 947 #: includes/blocks/class-convertkit-block-broadcasts.php:317 948 msgid "Read more label" 949 msgstr "" 950 951 #: includes/blocks/class-convertkit-block-broadcasts.php:319 952 msgid "The label to display for the \"read more\" link below each broadcast." 953 msgstr "" 954 955 #: includes/blocks/class-convertkit-block-broadcasts.php:322 956 msgid "Number of posts" 957 msgstr "" 958 959 #: includes/blocks/class-convertkit-block-broadcasts.php:329 960 msgid "Display pagination" 941 961 msgstr "" 942 962 943 963 #: includes/blocks/class-convertkit-block-broadcasts.php:331 944 msgid "Display read more links" 945 msgstr "" 946 947 #: includes/blocks/class-convertkit-block-broadcasts.php:335 948 msgid "Read more label" 949 msgstr "" 950 951 #: includes/blocks/class-convertkit-block-broadcasts.php:337 952 msgid "The label to display for the \"read more\" link below each broadcast." 953 msgstr "" 954 955 #: includes/blocks/class-convertkit-block-broadcasts.php:340 956 msgid "Number of posts" 964 msgid "If the number of broadcasts exceeds the \"Number of posts\" settings above, previous/next pagination links will be displayed." 965 msgstr "" 966 967 #: includes/blocks/class-convertkit-block-broadcasts.php:334 968 msgid "Newer posts label" 969 msgstr "" 970 971 #: includes/blocks/class-convertkit-block-broadcasts.php:336 972 msgid "The label to display for the link to newer broadcasts." 973 msgstr "" 974 975 #: includes/blocks/class-convertkit-block-broadcasts.php:339 976 msgid "Older posts label" 977 msgstr "" 978 979 #: includes/blocks/class-convertkit-block-broadcasts.php:341 980 msgid "The label to display for the link to older broadcasts." 957 981 msgstr "" 958 982 959 983 #: includes/blocks/class-convertkit-block-broadcasts.php:347 960 msgid "Display pagination"961 msgstr ""962 963 #: includes/blocks/class-convertkit-block-broadcasts.php:349964 msgid "If the number of broadcasts exceeds the \"Number of posts\" settings above, previous/next pagination links will be displayed."965 msgstr ""966 967 #: includes/blocks/class-convertkit-block-broadcasts.php:352968 msgid "Newer posts label"969 msgstr ""970 971 #: includes/blocks/class-convertkit-block-broadcasts.php:354972 msgid "The label to display for the link to newer broadcasts."973 msgstr ""974 975 #: includes/blocks/class-convertkit-block-broadcasts.php:357976 msgid "Older posts label"977 msgstr ""978 979 #: includes/blocks/class-convertkit-block-broadcasts.php:359980 msgid "The label to display for the link to older broadcasts."981 msgstr ""982 983 #: includes/blocks/class-convertkit-block-broadcasts.php:365984 984 msgid "Link color" 985 985 msgstr "" 986 986 987 #: includes/blocks/class-convertkit-block-broadcasts.php:3 69988 #: includes/blocks/class-convertkit-block-form-trigger.php:2 67989 #: includes/blocks/class-convertkit-block-product.php: 312987 #: includes/blocks/class-convertkit-block-broadcasts.php:351 988 #: includes/blocks/class-convertkit-block-form-trigger.php:253 989 #: includes/blocks/class-convertkit-block-product.php:295 990 990 msgid "Background color" 991 991 msgstr "" 992 992 993 #: includes/blocks/class-convertkit-block-broadcasts.php:3 73994 #: includes/blocks/class-convertkit-block-form-trigger.php:2 71995 #: includes/blocks/class-convertkit-block-product.php: 316993 #: includes/blocks/class-convertkit-block-broadcasts.php:355 994 #: includes/blocks/class-convertkit-block-form-trigger.php:257 995 #: includes/blocks/class-convertkit-block-product.php:299 996 996 msgid "Text color" 997 997 msgstr "" 998 998 999 #: includes/blocks/class-convertkit-block-broadcasts.php: 408999 #: includes/blocks/class-convertkit-block-broadcasts.php:390 1000 1000 msgid "Pagination" 1001 1001 msgstr "" 1002 1002 1003 #: includes/blocks/class-convertkit-block-broadcasts.php: 4171003 #: includes/blocks/class-convertkit-block-broadcasts.php:399 1004 1004 msgid "Styles" 1005 1005 msgstr "" 1006 1006 1007 #: includes/blocks/class-convertkit-block-broadcasts.php:4 441007 #: includes/blocks/class-convertkit-block-broadcasts.php:426 1008 1008 msgid "Read more" 1009 1009 msgstr "" 1010 1010 1011 #: includes/blocks/class-convertkit-block-broadcasts.php:4 471011 #: includes/blocks/class-convertkit-block-broadcasts.php:429 1012 1012 msgid "Previous" 1013 1013 msgstr "" 1014 1014 1015 #: includes/blocks/class-convertkit-block-broadcasts.php:4 481015 #: includes/blocks/class-convertkit-block-broadcasts.php:430 1016 1016 msgid "Next" 1017 1017 msgstr "" 1018 1018 1019 #: includes/blocks/class-convertkit-block-broadcasts.php:4 941019 #: includes/blocks/class-convertkit-block-broadcasts.php:476 1020 1020 msgid "No Broadcasts exist in Kit." 1021 1021 msgstr "" … … 1044 1044 msgstr "" 1045 1045 1046 #: includes/blocks/class-convertkit-block-form-trigger.php: 911046 #: includes/blocks/class-convertkit-block-form-trigger.php:77 1047 1047 msgid "Displays a modal, sticky bar or slide in form to display when the button is pressed." 1048 1048 msgstr "" 1049 1049 1050 #: includes/blocks/class-convertkit-block-form-trigger.php:1 231050 #: includes/blocks/class-convertkit-block-form-trigger.php:109 1051 1051 #: includes/blocks/class-convertkit-block-form.php:139 1052 1052 msgid "Connect your Kit account at Settings > Kit, and then refresh this page to select a form." 1053 1053 msgstr "" 1054 1054 1055 #: includes/blocks/class-convertkit-block-form-trigger.php:1 261055 #: includes/blocks/class-convertkit-block-form-trigger.php:112 1056 1056 msgid "No modal, sticky bar or slide in forms exist in Kit." 1057 1057 msgstr "" 1058 1058 1059 #: includes/blocks/class-convertkit-block-form-trigger.php:1 281059 #: includes/blocks/class-convertkit-block-form-trigger.php:114 1060 1060 msgid "Click here to create a form." 1061 1061 msgstr "" 1062 1062 1063 #: includes/blocks/class-convertkit-block-form-trigger.php:1 291063 #: includes/blocks/class-convertkit-block-form-trigger.php:115 1064 1064 msgid "Add a non-inline form to your Kit account, and then refresh this page to select a form." 1065 1065 msgstr "" 1066 1066 1067 #: includes/blocks/class-convertkit-block-form-trigger.php:1 311067 #: includes/blocks/class-convertkit-block-form-trigger.php:120 1068 1068 #: includes/blocks/class-convertkit-block-form.php:149 1069 1069 msgid "Select a Form using the Form option in the Gutenberg sidebar." 1070 1070 msgstr "" 1071 1071 1072 #: includes/blocks/class-convertkit-block-form-trigger.php:2 561072 #: includes/blocks/class-convertkit-block-form-trigger.php:242 1073 1073 msgid "The modal, sticky bar or slide in form to display when the button is pressed. To embed a form, use the Kit Form block instead." 1074 1074 msgstr "" 1075 1075 1076 #: includes/blocks/class-convertkit-block-form-trigger.php:2 591077 #: includes/blocks/class-convertkit-block-product.php:2 891076 #: includes/blocks/class-convertkit-block-form-trigger.php:245 1077 #: includes/blocks/class-convertkit-block-product.php:272 1078 1078 msgid "Button Text" 1079 1079 msgstr "" 1080 1080 1081 #: includes/blocks/class-convertkit-block-form-trigger.php:2 611082 #: includes/blocks/class-convertkit-block-product.php:2 911081 #: includes/blocks/class-convertkit-block-form-trigger.php:247 1082 #: includes/blocks/class-convertkit-block-product.php:274 1083 1083 msgid "The text to display for the button." 1084 1084 msgstr "" 1085 1085 1086 #: includes/blocks/class-convertkit-block-form-trigger.php:3 191086 #: includes/blocks/class-convertkit-block-form-trigger.php:305 1087 1087 #: includes/class-convertkit-settings-restrict-content.php:229 1088 1088 #: includes/integrations/contactform7/class-convertkit-contactform7-admin-section.php:84 … … 1094 1094 1095 1095 #. translators: ConvertKit Form ID 1096 #: includes/blocks/class-convertkit-block-form-trigger.php:4 191097 #: includes/class-convertkit-resource-forms.php:49 61096 #: includes/blocks/class-convertkit-block-form-trigger.php:405 1097 #: includes/class-convertkit-resource-forms.php:497 1098 1098 msgid "Kit Form ID %s does not exist on Kit." 1099 1099 msgstr "" 1100 1100 1101 1101 #. translators: ConvertKit Form ID 1102 #: includes/blocks/class-convertkit-block-form-trigger.php:4 311102 #: includes/blocks/class-convertkit-block-form-trigger.php:417 1103 1103 msgid "Kit Form ID %s has no uid property." 1104 1104 msgstr "" 1105 1105 1106 1106 #. translators: ConvertKit Form ID 1107 #: includes/blocks/class-convertkit-block-form-trigger.php:4 411107 #: includes/blocks/class-convertkit-block-form-trigger.php:427 1108 1108 msgid "Kit Form ID %s has no embed_js property." 1109 1109 msgstr "" … … 1146 1146 msgstr "" 1147 1147 1148 #: includes/blocks/class-convertkit-block-product.php: 1121148 #: includes/blocks/class-convertkit-block-product.php:98 1149 1149 msgid "Kit Product" 1150 1150 msgstr "" 1151 1151 1152 #: includes/blocks/class-convertkit-block-product.php: 1131152 #: includes/blocks/class-convertkit-block-product.php:99 1153 1153 msgid "Displays a button to purchase a Kit product." 1154 1154 msgstr "" 1155 1155 1156 #: includes/blocks/class-convertkit-block-product.php:1 451156 #: includes/blocks/class-convertkit-block-product.php:131 1157 1157 msgid "Connect your Kit account at Settings > Kit, and then refresh this page to select a product." 1158 1158 msgstr "" 1159 1159 1160 #: includes/blocks/class-convertkit-block-product.php:1 481160 #: includes/blocks/class-convertkit-block-product.php:134 1161 1161 msgid "No products exist in Kit." 1162 1162 msgstr "" 1163 1163 1164 #: includes/blocks/class-convertkit-block-product.php:1 501164 #: includes/blocks/class-convertkit-block-product.php:136 1165 1165 msgid "Click here to create your first product." 1166 1166 msgstr "" 1167 1167 1168 #: includes/blocks/class-convertkit-block-product.php:1 511168 #: includes/blocks/class-convertkit-block-product.php:137 1169 1169 msgid "Add a product to your Kit account, and then refresh this page to select a product." 1170 1170 msgstr "" 1171 1171 1172 #: includes/blocks/class-convertkit-block-product.php:1 551172 #: includes/blocks/class-convertkit-block-product.php:141 1173 1173 msgid "Select a Product using the Product option in the Gutenberg sidebar." 1174 1174 msgstr "" 1175 1175 1176 #: includes/blocks/class-convertkit-block-product.php:2 941176 #: includes/blocks/class-convertkit-block-product.php:277 1177 1177 msgid "Discount Code" 1178 1178 msgstr "" 1179 1179 1180 #: includes/blocks/class-convertkit-block-product.php:2 961180 #: includes/blocks/class-convertkit-block-product.php:279 1181 1181 msgid "Optional: A discount code to include. Must be defined in the Kit Product." 1182 1182 msgstr "" 1183 1183 1184 #: includes/blocks/class-convertkit-block-product.php:2 991184 #: includes/blocks/class-convertkit-block-product.php:282 1185 1185 msgid "Load checkout step" 1186 1186 msgstr "" 1187 1187 1188 #: includes/blocks/class-convertkit-block-product.php: 3011188 #: includes/blocks/class-convertkit-block-product.php:284 1189 1189 msgid "If enabled, immediately loads the checkout screen, instead of the Kit Product description." 1190 1190 msgstr "" 1191 1191 1192 #: includes/blocks/class-convertkit-block-product.php: 3041192 #: includes/blocks/class-convertkit-block-product.php:287 1193 1193 msgid "Disable modal on mobile" 1194 1194 msgstr "" 1195 1195 1196 #: includes/blocks/class-convertkit-block-product.php: 3061196 #: includes/blocks/class-convertkit-block-product.php:289 1197 1197 msgid "Recommended if the Kit Product is a digital download being purchased on mobile, to ensure the subscriber can immediately download the PDF once purchased." 1198 1198 msgstr "" 1199 1199 1200 #: includes/blocks/class-convertkit-block-product.php:3 671200 #: includes/blocks/class-convertkit-block-product.php:350 1201 1201 msgid "Buy my product" 1202 1202 msgstr "" … … 1276 1276 msgstr "" 1277 1277 1278 #: includes/class-convertkit-resource-forms.php:51 21278 #: includes/class-convertkit-resource-forms.php:513 1279 1279 msgid "Kit Legacy Form could not be fetched as no Access Token specified in Plugin Settings" 1280 1280 msgstr "" … … 1475 1475 msgstr "" 1476 1476 1477 #: includes/integrations/elementor/class-convertkit-elementor-widget.php:2 951477 #: includes/integrations/elementor/class-convertkit-elementor-widget.php:283 1478 1478 msgid "No blocks are registered. Register blocks using the `convertkit_blocks` filter." 1479 1479 msgstr "" 1480 1480 1481 1481 #. translators: %1$s: Block name, %2$s: Elementor Widget name 1482 #: includes/integrations/elementor/class-convertkit-elementor-widget.php: 3041482 #: includes/integrations/elementor/class-convertkit-elementor-widget.php:292 1483 1483 msgid "Block %1$s is not registered. Register using the `convertkit_blocks` filter, and ensure the Elementor Widget for this block has its `slug` property set to %2$s." 1484 1484 msgstr "" -
convertkit/trunk/readme.txt
r3333065 r3337204 6 6 Tested up to: 6.8 7 7 Requires PHP: 7.1 8 Stable tag: 2.8. 6.18 Stable tag: 2.8.7 9 9 License: GPLv3 or later 10 10 License URI: https://www.gnu.org/licenses/gpl-3.0.html … … 162 162 == Changelog == 163 163 164 ### 2.8.7 2025-07-31 165 * Added: Blocks: Form: Margin, padding and background color options 166 * Added: Debug: Forms: `data-kit-source-post-id` attribute to scripts when Debugging enabled 167 * Added: JS: Emit `kit_subscriber_id_removed_from_url` event when the `ck_subscriber_id` is removed from a URL 168 * Fix: Debloat Plugin: Exclude Forms from Debloat's Defer and Delay JS 169 * Fix: Classic Widgets: Form: Uncaught error: Call to undefined method `ConvertKit_Resource_Forms::output_select_field_all` 170 * Fix: Blocks: Refactored and removed unnecessary duplicate render callback functions in the block editor 171 164 172 ### 2.8.6.1 2025-07-23 165 173 * Fix: Form Trigger: Revert running `script` tags through `wp_kses`, as WordPress.com strip the script tag -
convertkit/trunk/resources/backend/js/gutenberg.js
r3270754 r3337204 393 393 // use the block's PHP's render() function. 394 394 preview = window[ block.gutenberg_preview_render_callback ]( block, props ); 395 } else { 396 // If no settings have been defined for this block, return a prompt to tell the editor 397 // what to do. 398 if ( typeof block.gutenberg_help_description_attribute !== 'undefined' && props.attributes[ block.gutenberg_help_description_attribute ] === '' ) { 399 preview = convertKitGutenbergDisplayBlockNotice( block.name, block.gutenberg_help_description ); 400 } else { 401 // Use the block's PHP's render() function by calling the ServerSideRender component. 402 preview = wp.element.createElement( 403 wp.serverSideRender, 404 { 405 block: 'convertkit/' + block.name, 406 attributes: props.attributes, 407 408 // This is only output in the Gutenberg editor, so must be slightly different from the inner class name used to 409 // apply styles with i.e. convertkit-block.name. 410 className: 'convertkit-ssr-' + block.name, 411 } 412 ); 413 } 395 414 } 396 415 -
convertkit/trunk/resources/frontend/js/convertkit.js
r3234366 r3337204 116 116 window.history.replaceState( null, title, url_object.pathname + params + url_object.hash ); 117 117 118 // Emit custom event with the removed subscriber ID. 119 convertKitEmitCustomEvent( 120 'kit_subscriber_id_removed_from_url', 121 { 122 id: ck_subscriber_id 123 } 124 ); 125 118 126 } 119 127 -
convertkit/trunk/wp-convertkit.php
r3333065 r3337204 10 10 * Plugin URI: https://kit.com/ 11 11 * Description: Display Kit (formerly ConvertKit) email subscription forms, landing pages, products, broadcasts and more. 12 * Version: 2.8. 6.112 * Version: 2.8.7 13 13 * Author: Kit 14 14 * Author URI: https://kit.com/ … … 28 28 define( 'CONVERTKIT_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); 29 29 define( 'CONVERTKIT_PLUGIN_PATH', __DIR__ ); 30 define( 'CONVERTKIT_PLUGIN_VERSION', '2.8. 6.1' );30 define( 'CONVERTKIT_PLUGIN_VERSION', '2.8.7' ); 31 31 define( 'CONVERTKIT_OAUTH_CLIENT_ID', 'HXZlOCj-K5r0ufuWCtyoyo3f688VmMAYSsKg1eGvw0Y' ); 32 32 define( 'CONVERTKIT_OAUTH_CLIENT_REDIRECT_URI', 'https://app.kit.com/wordpress/redirect' );
Note: See TracChangeset
for help on using the changeset viewer.