This commit addresses an issue that padding control in the email
an editor is rendered without a slider.
This change makes the padding control render the same as in TT4 theme
[MAILPOET-5714]
When checking pages after updating dependencies, I noticed that some buttons have strange colors.
For example, buttons on the "What would you like to create?" page for new newsletters.
I found that this was related to a change in wordpress/components styles.
The original colors were identical to the default WordPress admin color scheme,
so the buttons were ok when an admin used the default scheme, and in case they use a different scheme
the buttons still look like default (blue).
But after the update, all components on MailPoet pages that don't load WP color admin variables
had a strange purple color.
This commit fixes it by including CSS for admin color schemes into mailpoet-plugin.css which is loaded on every MailPoet admin page.
Note the mixin wordpress-admin-schemes() is included in many build styles for other wordpress packages (e.g. wordpress/block-editor)
so admin color schemes worked correctly on some MailPoet pages even before this change.
[MAILPOET-5714]
The dropdown component used for setting the automation name is based
on the document actions component from edit-site package. After the update,
the appearance changed significantly, and it was broken.
This commit adds CSS to restore the original look as before the update.
[MAILPOET-5714]
The currently supported values are 'firstElement' | boolean
Based on the JS doc and my testing, we need to use true
to hide the popup on click elsewhere or by ESC.
[MAILPOET-5714]
Overriding onClick: (setIsBusy?: Dispatch<SetStateAction<boolean>>) => void;
was causing TS errors when passing controls with the type ControlWithSetIsBusy to DropdownMenu.
The OptionButton that uses isBusy logic is used only in the Hero section at automation
Homepage. The setIsBusy function that was passed to control's onClick was not used.
In all other cases where we were passing controls to DrowdownMenu, we didn't set any isBusy state.
So I think it is safe to remove it.
[MAILPOET-5714]
The search functionality hasn't been implemented yet. The task is currently in backlog.
The control was added in an initial task but is hidden.
I decided to keep it so that I don't remove the translation and just add a dummy
onChange callback to prevent TS error.
[MAILPOET-5714]
These were needed for the types for stores used in the email editor
when it was based on the post editor. We switched to the custom editor
so we can remove those.
[MAILPOET-5714]
This commit fixes a warning:
"The 'useSelect' hook returns different values when called with the same state and parameters. This can lead to unnecessary rerenders."
The warning was coming from the BasicSettingsPanel component and was caused
by getAllAvailablePages selector, which returned a new array every time.
[MAILPOET-5714]
This commit sets all wordpress/* packages we list in package.json
to use tag wp-6.4, which should install the version used in WordPress 6.4
[MAILPOET-5714]