Use WP's style engine for formatting style arrays to string

[MAILPOET-5798]
This commit is contained in:
Rostislav Wolny
2024-04-09 14:31:34 +02:00
committed by Rostislav Wolný
parent 50df6c3d4e
commit 15e0c3fa4d
5 changed files with 10 additions and 10 deletions

View File

@@ -27,7 +27,7 @@ class FlexLayoutRenderer {
if ($key > 0) {
$styles['padding-left'] = $flexGap;
}
$outputHtml .= '<td class="layout-flex-item" style="' . esc_html($settingsController->convertStylesToString($styles)) . '">' . render_block($block) . '</td>';
$outputHtml .= '<td class="layout-flex-item" style="' . esc_html(\WP_Style_Engine::compile_css($styles, '')) . '">' . render_block($block) . '</td>';
}
$outputHtml .= '</tr></table></div>
<!--[if mso | IE]></td></tr></table><![endif]-->';