Remove styles data added to templates REST API response

We no longer need to send CSS for every template because we use global styles
live from the editor.
[MAILPOET-6335]
This commit is contained in:
Rostislav Wolny
2024-12-12 14:08:12 +01:00
committed by Aschepikov
parent bc10ae7216
commit c64e4caf27
6 changed files with 0 additions and 144 deletions

View File

@@ -1,42 +0,0 @@
<?php
/**
* This file is part of the MailPoet plugin.
*
* @package MailPoet\EmailEditor
*/
declare(strict_types = 1);
namespace MailPoet\EmailEditor\Engine\Templates;
/**
* Integration test for the Template Preview class
*/
class Template_Preview_Test extends \MailPoetTest {
/**
* Template preview.
*
* @var Template_Preview
*/
private Template_Preview $template_preview;
/**
* Set up before each test
*/
public function _before() {
parent::_before();
$this->template_preview = $this->di_container->get( Template_Preview::class );
}
/**
* Test it Generates CSS for preview of email theme
*
* @return void
*/
public function testItCanGetThemePreviewCss(): void {
$result = $this->template_preview->get_email_theme_preview_css();
verify( $result )->stringContainsString( 'Styles for the email editor.' );
verify( $result )->stringContainsString( 'is-layout-email-flex' );
verify( $result )->stringContainsString( '.is-root-container { width: 660px; margin: 0 auto; }' ); // Styles for both the email editor and renderer.
}
}