From a16f20b93ddea0597ac91cd9f7c1c830f89b74f6 Mon Sep 17 00:00:00 2001 From: Oluwaseun Olorunsola Date: Thu, 9 Jan 2025 14:40:13 +0100 Subject: [PATCH] Add more comments for clarification purposes MAILPOET-6365 --- .../js/src/mailpoet-email-editor-integration/index.scss | 1 + .../js/src/mailpoet-email-editor-integration/index.ts | 6 +++--- .../visual-editor/edit-template-blocks-notification.tsx | 4 +--- .../src/components/styles-sidebar/screens/screen-colors.tsx | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.scss b/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.scss index 004f6e69e1..1f1c6dd42f 100644 --- a/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.scss +++ b/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.scss @@ -1,5 +1,6 @@ // Core MailPoet styles. We need this here because the email editor does not register // under the mailpoet namespace and does not have access to the MailPoet plugin styles +// These styles are required by ReviewRequest (mailpoet/assets/js/src/review-request.tsx) feature // Settings // Global variables, config switches. Not producing any CSS. diff --git a/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.ts b/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.ts index 252c055bc6..90e39ffdf1 100644 --- a/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.ts +++ b/mailpoet/assets/js/src/mailpoet-email-editor-integration/index.ts @@ -24,9 +24,9 @@ const EVENTS_TO_TRACK = [ 'email_editor_events_rich_text_with_button_personalization_tags_shortcode_icon_clicked', // personalization_tags modal opened 'email_editor_events_personalization_tags_modal_tag_insert_button_clicked', // personalization_tags inserted 'email_editor_events_rich_text_with_button_input_field_updated', // either subject or preheader updated - 'email_editor_events_styles_sidebar_screen_typography_opened', // styles sidebar was seen - 'email_editor_events_styles_sidebar_screen_colors_opened', // styles sidebar was seen - 'email_editor_events_styles_sidebar_screen_layout_opened', // styles sidebar was seen + 'email_editor_events_styles_sidebar_screen_typography_opened', // styles sidebar-typography was seen + 'email_editor_events_styles_sidebar_screen_colors_opened', // styles sidebar-colors was seen + 'email_editor_events_styles_sidebar_screen_layout_opened', // styles sidebar-layout was seen 'email_editor_events_header_send_button_clicked', // Send button clicked 'email_editor_events_trash_modal_move_to_trash_button_clicked', // Move to trash button was clicked ]; diff --git a/packages/js/email-editor/src/components/block-editor/visual-editor/edit-template-blocks-notification.tsx b/packages/js/email-editor/src/components/block-editor/visual-editor/edit-template-blocks-notification.tsx index 9ab6c0cce8..7da268d748 100644 --- a/packages/js/email-editor/src/components/block-editor/visual-editor/edit-template-blocks-notification.tsx +++ b/packages/js/email-editor/src/components/block-editor/visual-editor/edit-template-blocks-notification.tsx @@ -45,9 +45,7 @@ export default function EditTemplateBlocksNotification( { contentRef } ) { return; } setIsDialogOpen( true ); - recordEventOnce( 'edit_template_blocks_notification_opened', { - templateId, - } ); + recordEventOnce( 'edit_template_blocks_notification_opened' ); }; const canvas = contentRef.current; diff --git a/packages/js/email-editor/src/components/styles-sidebar/screens/screen-colors.tsx b/packages/js/email-editor/src/components/styles-sidebar/screens/screen-colors.tsx index 426562ec40..c1f7400e0a 100644 --- a/packages/js/email-editor/src/components/styles-sidebar/screens/screen-colors.tsx +++ b/packages/js/email-editor/src/components/styles-sidebar/screens/screen-colors.tsx @@ -24,7 +24,7 @@ export function ScreenColors(): JSX.Element { const handleOnChange = ( newStyles ) => { updateStyles( newStyles ); - recordEvent( 'styles_sidebar_screen_colors_styles_updated' ); + recordEvent( 'styles_sidebar_screen_colors_styles_updated' ); // We can't log the updated color here because the onChange function returns the complete object. }; return (