closes https://github.com/TryGhost/Team/issues/535
To ensure accent color is always set for a site, this updates brand settings screen and launch wizard to not allow empty accent color to be set or updated, adding the relevant error on the page which needs to be fixed before saving or continuing on the screens.
- Shows error message for empty accent color on brand settings and launch wizard
- Shows error message for invalid accent color on brand settings and launch wizard
- Blocks save and continue with invalid/empty accent color on brand settings and launch wizard
Co-authored-by: Peter Zimon <zimo@ghost.org>
closes https://github.com/TryGhost/Team/issues/506
- launch wizard and brand settings both shared the same design and behaviour for customising brand settings but used duplicated code that had diverged
- extracted the more up-to-date behaviour from the launch wizard into a component
- updated brand settings and launch wizard to use the new component
changes to brand settings modal behaviour:
- preview is no longer interactive
- switches to using iframe contents replacement instead of `postMessage`
no issue
- trigger modal close once save task has finished
- reset unsaved changes when closing the modal (eg, cancel button clicked)
- removed unused code that had been copied over from an old controller
- the new preview mode doesn't require settings to be saved in advance
- TODO: prevent interaction with the iframe a la portal
Notes:
- this works by sending a post message to the frontend with a custom header
- generated HTML is loaded into the iframe using postMessage
- we can possibly write the HTML direct to the iframe - something to experiment with later
no issue
Updated settings navigation to a completely redesigned flow for Ghost 4.0 🎉
Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
Co-authored-by: Fabien O'Carroll <fabien@allou.is>
Co-authored-by: Rish <zrishabhgarg@gmail.com>