Load user styles in the email editor properly

[MAILPOET-6335]
This commit is contained in:
Rostislav Wolny
2024-12-10 15:57:53 +01:00
committed by Aschepikov
parent 0f7009438c
commit fdc0d15b63
4 changed files with 9 additions and 1 deletions

View File

@ -6,6 +6,7 @@ interface Window {
cdn_url: string;
is_premium_plugin_active: boolean;
current_wp_user_email: string;
user_theme_post_id: number;
urls: {
listings: string;
};

View File

@ -25,7 +25,7 @@ export function getInitialState(): State {
editorSettings: getEditorSettings(),
theme: getEditorTheme(),
styles: {
globalStylesPostId: 153, // Todo - fetch from DB
globalStylesPostId: window.MailPoetEmailEditor.user_theme_post_id,
},
autosaveInterval: 60,
cdnUrl: getCdnUrl(),