| @@ -161,8 +161,18 @@ | ||
| 161 | 161 | '; |
| 162 | 162 | } |
| 163 | 163 | |
| 164 | 164 | /** |
| 165 | + * Wraps an embed in a pointer-events:none container for the Elementor editor, | |
| 166 | + * so the iframe cannot swallow the click Elementor needs to select the widget. | |
| 167 | + * | |
| 168 | + * @param string $embed The embed HTML to wrap. | |
| 169 | + */ | |
| 170 | + public static function wrap_embed_for_elementor_editor( $embed ) { | |
| 171 | + return '<div class="hubspot-embed-editor-preview" style="pointer-events:none;">' . $embed . '</div>'; | |
| 172 | + } | |
| 173 | + | |
| 174 | + /** | |
| 165 | 175 | * Generates 10 characters long string with random values |
| 166 | 176 | */ |
| 167 | 177 | private static function get_random_number_string() { |
| 168 | 178 | $result = ''; |