Add inline class to MailPoet notices

The `inline` class is used to prevent moving notice by WP JavaScript (wp-admin/js/common.js) because it can break DOM, and events don't work anymore
[MAILPOET-4510]
This commit is contained in:
Jan Lysý
2022-07-28 09:44:03 +02:00
committed by Veljko V
parent 8d4799b050
commit c4cd053b34

View File

@@ -58,10 +58,11 @@ function Notice({
if (hidden) return null;
// inline class is used to prevent moving notice by WP JavaScript (wp-admin/js/common.js) because it can break DOM, and events don't work anymore
const content = (
<div
ref={elementRef}
className={`notice ${type} ${closable ? 'is-dismissible' : ''}`}
className={`notice inline ${type} ${closable ? 'is-dismissible' : ''}`}
>
{children}
{closable && (