Commit Graph

137 Commits

Author SHA1 Message Date
Peter Zimon
fca8941740
Updated integration modals buttons (#20502)
DES-27

Updated buttons in integrations from [Cancel] and [Save & close] to
[Close] and [Save] to be consistent with the rest of the Settings UI.
2024-07-01 17:29:53 +02:00
Peter Zimon
6378d7d66f
Unify "Save" and "Close" buttons in Settings (#20430)
DES-27

There are two patterns used in settings modals for action buttons:

1. [Cancel] and [Save & close] (sometimes it's [Cancel] and [OK],
inconsistently) — example: Staff details, Tier details, Navigation,
Recommendation
2. [Close] and [Save] — example: Design settings, Portal, Newsletter
details etc.

This is confusing and leaves people confused and uncertain about what's
going to happen in one or the other case.
2024-07-01 13:35:38 +02:00
Daniel Lockyer
fa430666bf 🐛 Fixed staff user modal not showing correct example URL
fix https://linear.app/tryghost/issue/ENG-928/regression-author-url-slug-preview-broken

- simple change to append the slug to the end of the example hint
- also added test
2024-07-01 10:03:22 +02:00
Sag
5dfee47fca
🐛 Fixed default recipients setting not showing label filters (#20480)
fixes https://linear.app/tryghost/issue/SLO-171

- problem: when the Default Recipient setting is set to "Specific
people" and is filtered by a label, we were not able to render the label
correctly
- cause: during the rendering, we look for labels by `id`, but they're
stored by `slug` in the database setting
`editor_default_email_recipients_filter`
- solution: allow to look by the relevant key, by introducing a
programmatic `key` to search for

Before the fix:
https://github.com/TryGhost/Ghost/assets/6225080/aed5fc31-6409-4986-aafe-557073c7f355


After the fix:
https://github.com/TryGhost/Ghost/assets/6225080/f35b2607-5f22-42be-b1bb-92f35ccc9ab7
2024-06-27 17:47:26 +02:00
Chris Raible
9891abd61c
Updated error message shown when trying to overwrite a default theme (#20301)
ref
https://linear.app/tryghost/issue/ONC-57/trying-to-overwrite-the-default-source-theme-crashes-ghost

- No functional change, just an update to the error message to follow
our writing guidelines for error messages
2024-05-31 21:01:44 +00:00
Chris Raible
680651aa58
🐛 Fixed admin error when trying to overwrite a default theme (#20299)
ref
https://linear.app/tryghost/issue/ONC-57/trying-to-overwrite-the-default-source-theme-crashes-ghost

- When attempting to overwrite a default theme (source or casper), admin
would crash because this is not allowed by the API and the error was not
handled
- This fixes that by showing a modal with an error message when the user
tries to overwrite a default theme, and instructs the user to rename the
zip file
2024-05-30 15:55:45 -07:00
Peter Zimon
8bc035ccb7
Update twitter.com to x.com (#20234)
DES-351

There's a frontend validation in Settings that rewrites the Twitter (X)
URL in social accounts to match the format: twitter.com. As of May 17, X
officially changed their domain to x.com so this validation is outdated.

---------

Co-authored-by: Ronald Langeveld <hi@ronaldlangeveld.com>
2024-05-22 10:00:13 +02:00
Peter Zimon
770f657ae9
Improve messaging and error handling (#20078)
ref DES-228

This PR updates messaging and error handling in order to make Ghost calmer and friendlier. High level summary of the changes:

- Removed all onBlur validation in Settings -> now it’s possible to just click around without being warned to fill mandatory fields
- Removed  lot of technical errors like `ValidationError: Validation (isEmpty) failed for locale`
- Completely removed the red background toast notifications, it was aggressive and raw esp. on the top
- Removed some unnecessary notifications (e.g. when removing a webhook, the removal already communicates the result)
- Now we show field errors on submitting forms, and in case of an error we show a “Retry” button in Settings too. This allowed to remove a lot of unnecessary error messages, like the big error message on the top, plus it’s consistent with the patterns outside Settings.
- Notification style is white now with filled color icons which makes everything much calmer and more refined.
- Removes redundant copy (e.g. "successful(ly)") from notifications

---------

Co-authored-by: Sodbileg Gansukh <sodbileg.gansukh@gmail.com>
2024-05-14 09:31:19 +02:00
Sag
6281e63411
🐛 Fixed error rendering when using a duplicate offer code (#20156)
closes https://linear.app/tryghost/issue/ONC-15

- when adding or editing an offer, the backend throws an error if the
offer code is already in use. This error was not being surfaced
correctly in Admin
2024-05-08 11:27:31 +02:00
Sodbileg Gansukh
eab5c8ba52
Fixed various design issues in Offers (#19922)
ref DES-101

- used the default TabView component on Offers list for better consistency
- added new property to TabView component which makes it possible to have extra content on the top right
- updated copy of the empty states
2024-04-29 13:00:55 +08:00
Peter Zimon
9f19e334c1
Improve technical errors (#20046)
ref DES-229

Some of the error messages in Ghost and more specifically in Settings
were very technical, e.g.
`ValidationError: Validation (isEmpty) failed for locale`

This PR deals with some of the occurances for a more human error
communication.
2024-04-24 08:42:22 +02:00
Chris Raible
b8ad03b0f3
Added PostHog to admin-x-settings trackEvent function (#20013)
ref https://linear.app/tryghost/issue/PA-53/add-posthog-tracking-to-trackevent-in-admin-x-settings-and-lexical

- There was a pre-existing `trackEvent` function in `admin-x-settings`
that was using Plausible for tracking events.
- This PR adds PostHog to the same function, any calls to `trackEvent`
will send the event name and properties to PostHog as well.
2024-04-11 19:35:30 -07:00
Ronald Langeveld
d12b79e036
🐛 Fixed First Promoter always showing Active (#20010)
ref https://github.com/TryGhost/Ghost/issues/19797

- Fixed FirstPromoter always showing Active in Integration Settings list
- This was due to the position of the variable in the array being in the
wrong positon and indexed incorrectly.
- Added additional testing to avoid it from cropping up again.
2024-04-11 13:09:12 +08:00
Peter Zimon
7dcddb2e75
Improved staff empty display (#19810)
ref https://linear.app/tryghost/issue/DES-84

- changed display to not show tabs when there's no staff users (only owner)
- automatically switch to Invites tab in the Staff section after sending an invite
- updated toast messages on failure

---------

Co-authored-by: Steve Larson <9larsons@gmail.com>
2024-03-27 08:21:38 -05:00
Princi Vershwal
2798a8cd09
ENG-767 Offers cannot be created if there are no active paid tiers (#19900) 2024-03-21 15:07:32 +05:30
Ronald Langeveld
19da5c6af4
Extracted Unsplash Selector from AdminX (#19849)
no issue

- Adds the unsplash selector as a standalone typescript package inside
the Koenig monorepo.
- Currently we have 3 versions of the Unsplash Selector. One in
Koenig-Lexical, one in AdminX and the original Ember version.
- We can now start phasing out the application coupled version of the
selector and replace it with the reusable version.
- We can now import it via npm to any React application.
- This commit removes the Unsplash components from AdminX and imports it
instead.

This is the second commit for this as the previous commit broke styles
due to normalise styles leaking into the Ember app. Disabling preflight
(https://github.com/TryGhost/Koenig/pull/1169) in Tailwind fixed it.
2024-03-12 22:40:33 +02:00
Ronald Langeveld
36f11a65a0
Revert "Extracted Unsplash Selector from AdminX (#19838)" (#19844)
no issue

- caused a styling regression, making changes then will merge again.
2024-03-12 15:35:09 +00:00
Ronald Langeveld
6719bcf46e
Extracted Unsplash Selector from AdminX (#19838)
no issue

- Adds the unsplash selector as a standalone typescript package inside
the Koenig monorepo.
- Currently we have 3 versions of the Unsplash Selector. One in
Koenig-Lexical, one in AdminX and the original Ember version.
- We can now start phasing out the application coupled version of the
selector and replace it with the reusable version.
- We can now import it via npm to any React application.
- This commit removes the Unsplash components from AdminX and imports it
instead.
2024-03-12 11:06:57 +00:00
Ronald Langeveld
8a67901355
Updated test to check for Unsplash button in Admin (#19814)
ref DES-167

https://linear.app/tryghost/issue/DES-167/🐛-unsplash-in-admin-x-not-styled-correctly
2024-03-06 14:54:37 +00:00
Peter Zimon
3ef8b53fad
Added "No search result" screen to Settings (#19672)
refs.
https://linear.app/tryghost/issue/DES-21/empty-screen-is-missing-for-search-in-settings

- Search is one of the most useful functions in Settings and currently
the screen when there's no result for a searchterm is just a plain white
screen. Very non user-friendly.
- This update gives us an opportunity to improve the overall visual
hierarchy and focus of Settings in general.

---------

Co-authored-by: Ronald Langeveld <hi@ronaldlangeveld.com>
2024-02-08 08:32:40 +01:00
Ronald Langeveld
0c95111f8e
🎨 Admin X - Offers (#19520)
no issue

- Offers rebuilt in React and now located in Settings.
2024-01-25 12:41:54 +00:00
Ronald Langeveld
94c7d9b21b
Revert "Changed request type to fetching iframe content in previews
refs https://ghost.slack.com/archives/C0568LN2CGJ/p1706018058495729
2024-01-23 14:33:38 +00:00
Djordje Vlaisavljevic
c4a800e97d
Fixed logic for displaying toast notifications when updating email address PROD-215
refs PROD-215

- Showing toast notification instead of modal to all users (even
self-hosted and legacy (Pro)) now
- More compact toast notification message
- Updated tests
2024-01-18 19:00:49 +00:00
Djordje Vlaisavljevic
501b1a2640
Updated design for sender and reply-to email address flow PROD-215 PROD-216
refs PROD-215 PROD-216

- Added toast notifications for successful sender and reply-to email
address change behind the flag, instead of the modal
- Updated email template for verifying new sender or reply-to email
2024-01-18 15:21:48 +00:00
Daniel Lockyer
57c5f92770 Reverted "🎨 Added Offers to the new Settings (#19493)"
This reverts commit c7d7b883cc.
2024-01-18 15:04:59 +01:00
Sag
0f17f9a937
Updated design of the reply-to field for custom sending domains (#19515)
fixes PROD-205
fixes PROD-219

- removed the right placeholder complexity
- the preview renders the current sender / reply-to address in
real-time, regardless of whether it's valid
- if the reply-to address does not match the custom sending domain, show
an inline error
2024-01-18 14:39:43 +01:00
Ronald Langeveld
c7d7b883cc
🎨 Added Offers to the new Settings (#19493)
no issue

- Removes flags for the new Offers in Admin X (Settings)
- Removes old Offers from the sidebar.
- See a new version of Offers in Settings. 🎨
2024-01-18 12:56:08 +00:00
Princi Vershwal
62a5b7d61a
Removed onBlur error feedback in Recommendation edit modal (#19382)
Fixes
[PROD-266](https://linear.app/tryghost/issue/PROD-266/remove-onblur-error-feedback-in-recommendation-edit-modal)
2023-12-14 13:09:55 +00:00
Peter Zimon
58d9b8e382
Update migration in settings (#19278)
refs.
7b40393d77

We're improving the usability and possibilities for publishers to
migrate from other platforms such as Substack, Medium or Mailchimp. This
PR applies changes to Ghost Settings to support the new flows, more
specifically:

- moves import and export functions out of Labs to its own setting,
directly available from search and the menu
- adds direct access to various platform migrations
- moves "Delete all content" to a dedicated setting group at the bottom
of all setting

---------

Co-authored-by: Jono Mingard <reason.koan@gmail.com>
2023-12-13 16:25:29 +01:00
Sodbileg Gansukh
c932e9d60e
Updated copy of the add offer link in the settings group (#19323) 2023-12-12 12:28:53 +07:00
Ronald Langeveld
4c09a96a3c
Changed request type to fetching iframe content in previews (#19307)
refs PROD-227

- Swapped out the request type from `POST` to `GET`.
2023-12-11 14:28:35 +00:00
Ronald Langeveld
181c5c0920
Changed code injection to full screen editor. (#19259)
fixes PROD-7
https://ghost.slack.com/archives/C0568LN2CGJ/p1701690959138659

- Changed the code injector editor to only use the full screen editor in
its own modal.

---------

Co-authored-by: Peter Zimon <peter.zimon@gmail.com>
2023-12-08 09:11:52 +02:00
Sag
a5dcae80e7
Updated copy during email verification in newsletter settings (#19265)
fixes PROD-202
2023-12-06 19:56:25 +00:00
Princi Vershwal
5a4d98e90d
Show Add offer button on settings screen if no offer is present (#19215)
Ref
[PROD-3](https://linear.app/tryghost/issue/PROD-3/settings-group-navigation-handling)
2023-12-06 04:31:48 +00:00
Simon Backx
ab21b8ae1d
Allowed custom/empty replyTo for newsletters with managed sending domain (#19183)
fixes GRO-75
fixes GRO-100

And allow them to be empty
2023-11-30 09:16:03 +00:00
Ronald Langeveld
2f43f58010
Fixed flaky Offers tests (#19170)
refs https://ghost.slack.com/archives/C02G9E68C/p1701258027793649

- missing an `await` before the `expect` in the test causing it to be potentially flaky.
2023-11-29 13:55:54 +02:00
Ronald Langeveld
d3b0a26e4d
Updated Acceptance Tests for Offers in Admin X (#19167)
no issue

- Updated acceptance testing for offers in AdminX
2023-11-29 10:32:31 +00:00
Simon Backx
a037ce3dde
Added calculated email address settings (#19115)
fixes GRO-73

We need to avoid duplicating the complex logic for determining the
default email address and the support email address. So these are now
exposed as calculated settings.
2023-11-23 13:07:15 +00:00
Jono M
a8083960d8
Added test examples to AdminX demo (#19116)
refs https://github.com/TryGhost/Product/issues/4182

Updated framework to include shared test config for easier app setup.
2023-11-23 12:59:48 +00:00
Sag
ff70ffec67
Updated newsletter settings UI for managed email (#19082)
refs GRO-59
refs GRO-56
refs GRO-52

- When email is managed without a custom domain, do not allow the Sender
Email address to be changed, but allow Reply-to address to be changed to
any address the publisher can verify
- When email is managed with a custom domain, allow both Sender and
Reply-to addresses to be changed without verification, but not their
domain names

---------

Co-authored-by: Djordje Vlaisavljevic <dzvlais@gmail.com>
2023-11-23 02:07:14 +00:00
Jono M
f19f32b132
Moved AdminX test config to framework package (#19096)
refs https://github.com/TryGhost/Product/issues/4180
2023-11-22 13:39:32 +00:00
Jono M
32dacd9ff7
Fixed provider ordering to prevent bugs loading modals on refresh (#19089)
refs https://github.com/TryGhost/Product/issues/4174
2023-11-22 07:51:10 +00:00
Princi Vershwal
c26b5256cf
Added tests for edit offer
Ref:
https://www.notion.so/ghost/Implement-edit-modal-7c4f1930d40243e887b37f2cb4701a1f
2023-11-09 23:58:49 +05:30
Princi Vershwal
1d8adc6e86
Added tests for offer list 2023-11-07 17:41:32 +05:30
Princi Vershwal
bf855e88fd
Wired up Offer list (#18889) 2023-11-07 14:02:27 +05:30
Simon Backx
fee402a340
🐛 Fixed adding recommendation with URL redirect breaking one-click-subscribe (#18863)
fixes https://github.com/TryGhost/Product/issues/4102

E.g. you recommend myghostsite.com, while that site redirects all
traffic to [www.myghostsite.com](#):

The redirect causes CORS issues, which means we cannot detect
one-click-subscribe support.
- This is fixed by moving the whole detection to the backend, which has
the additional benefit that we can update it in the background without
the frontend, and update it on every recommendation change.
- This change also fixes existing recommendations by doing a check on
boot (we can move this to a background job in the future).
2023-11-03 15:02:45 +01:00
Peter Zimon
6691f0da26
AdminX Settings UX improvements (#18741)
refs. https://github.com/TryGhost/Product/issues/4060

The new settings screen is too dense, lacks hierarchy and hard to scan. This update addresses some of the problems of the initial version:
- clear hierarchy in typography and larger spaces between sections to make the overall structure is easier to scan
- using icons in the sidebar to strengthen the groups + help visual thinkers to remember settings better + just to be a bit less serious
- updated colors for better contrast + orientation (bg on the sidebar)
- updated input fields to help focus on filling forms
- other small improvements for more consistency and simplicity

---------

Co-authored-by: Jono Mingard <reason.koan@gmail.com>
2023-10-25 16:37:58 +02:00
Sag
1b82efe5d2
Added Recommendations feature (#18743)
refs https://github.com/TryGhost/Product/issues/3744


Co-authored-by: Simon Backx <simon@ghost.org>
Co-authored-by: Djordje Vlaisavljevic <dzvlais@gmail.com>
2023-10-24 11:00:11 -03:00
Kevin Ansfield
9b1f79f601
Cleaned up lexicalEditor labs flag, switched Post model to lexical-by-default (#18607)
no issue

- flag is no longer used in Admin so we can clean it up in Core too
- updated Post model to set blank document to `lexical` field rather than `mobiledoc` as a default value
- switched over to returning `mobiledoc,lexical` as default formats in Admin API
2023-10-23 17:51:34 +01:00
Ronald Langeveld
ee4ef4438e
Fixed Stripe connect display name key (#18725)
no issue

- the stripe value is saved under the `stripe_connect_display_name`
column, yet Admin X was querying `stripe_connect_account_name` causing
it to be undefined.

---

<!-- Leave the line below if you'd like GitHub Copilot to generate a
summary from your commit -->
<!--
copilot:summary
-->
### <samp>🤖 Generated by Copilot at f0e6cb6</samp>

Renamed `stripe_connect_account_name` setting to
`stripe_connect_display_name` in the admin-x-settings app. This improves
clarity and consistency for the Stripe integration in the membership
settings.
2023-10-23 08:56:41 +00:00