Commit Graph

934 Commits

Author SHA1 Message Date
Djordje Vlaisavljevic
88c9ee8a34 Changed copy for removing recommendations
refs https://github.com/TryGhost/Product/issues/3899
2023-09-20 14:46:26 +01:00
Djordje Vlaisavljevic
1bfedcfd00 Moved Preview above the form
refs https://github.com/TryGhost/Product/issues/3857
2023-09-20 14:46:26 +01:00
Djordje Vlaisavljevic
9dea3d344a Commented out "Recommending you" stats while we're in QA
no refs
2023-09-20 14:46:26 +01:00
Djordje Vlaisavljevic
8f5ac0620b Added Ghost favicon to recommendations with 1-click subscribe
refs https://github.com/TryGhost/Product/issues/3902
2023-09-20 14:46:26 +01:00
Djordje Vlaisavljevic
cfea7a2822 Added Ghost favicon
refs https://github.com/TryGhost/Product/issues/3902
2023-09-20 14:46:26 +01:00
Peter Zimon
97cbd33159
Fixed footer padding bug in AdminX modals (#18249)
refs. https://github.com/TryGhost/Product/issues/3349
2023-09-20 12:49:24 +00:00
Peter Zimon
0b07c44797
AdminX searchfield keyboard shortcut (#18244)
refs. https://github.com/TryGhost/Product/issues/3349

- it's a bit cumbersome to always click in the searchfield to use it.
`/` is a standard keyboard shortcut to focus on a searchfield in
apps. Also, by auto-focusing on the searchfield it's even faster to find
settings.
2023-09-20 14:32:18 +02:00
Peter Zimon
b4bcc193a4
Updated history staff search (#18108)
refs. https://github.com/TryGhost/Product/issues/3349

- newsletter searchfield was showing a "Clear" button once it had content. It needed to be using standard React dropdown instead
- modals needed an option to make the header sticky so it's more versatile. It's now used in the History modal

---------

Co-authored-by: Jono Mingard <reason.koan@gmail.com>
2023-09-20 12:28:29 +02:00
Daniel Lockyer
71a072ee66 Deleted Vite SVG from Admin-X-Settings
- this is no longer needed and is left over from the initial Vite setup
2023-09-20 11:01:47 +02:00
Mark Stosberg
7fa083d774
🐛 Fixed escaping search terms that contain special characters (#18151)
fixes https://github.com/TryGhost/Ghost/issues/18133

Before, Sodo Search was not escaping search input before using the search terms in a regular expression, so using special characters could result in an invalid regular expression which would crash JavaScript.

As regular expressions date back to Perl, so does a standard solution for this, which called quotemeta in Perl. It doesn't exist 1:1 in JavaScript, but StackOverflow had the answer: stackoverflow.com/questions/6318710/javascript-equivalent-of-perls-q-e-or-quotemeta

So a line of code is added to escape the special characters in the regex for passing them through. This is the same code that the quotemeta module on NPM would use.
2023-09-20 10:17:21 +02:00
Daniel Lockyer
d46aab5b43 Optimized bundle size of @tryghost/limit-service
refs https://ghost.slack.com/archives/C0568LN2CGJ/p1695149803260239
refs 290bc71d6a

- previous versions of `@tryghost/limit-service` did a full import of
  lodash, which would bloat the bundle size, especially when we only use
  a few of its functions
- I've since fixed that and this commit bumps Ghost to the smaller
  version
2023-09-20 09:54:07 +02:00
renovate[bot]
c055179765 Update dependency vite-plugin-svgr to v3.3.0 2023-09-20 08:41:57 +02:00
Jono M
3928b628ca
Update labs settings in Ember when changed in AdminX (#18231)
refs https://github.com/TryGhost/Product/issues/3832
2023-09-19 18:48:47 +00:00
Jono M
64d7c73b00
Optimised bundle size and configuration in AdminX (#18227)
refs https://github.com/TryGhost/Product/issues/3832

---

### <samp>🤖 Generated by Copilot at eaad533</samp>

Refactored the code for modal components in the admin-x-settings app to
improve performance, readability, type-safety, and compatibility. Used
dynamic import, default import, `import.meta.glob`, and type aliases to
simplify the logic of importing and rendering modal components. Applied
the type alias `RoutingModalProps` to all modal components to ensure
consistent and safe props.
2023-09-19 16:54:01 +00:00
Peter Zimon
1b004af184
AdminX UI bugfixes and refinements (#18195)
refs. https://github.com/TryGhost/Product/issues/3349

- updated tiers archive/activate pattern to it less prominent
- update newsletter archive/activate pattern to it less prominent
- fixed react-select z-index bug
- fixed Stripe disconnect copy error bug
- set max-height to embeddable signup form sidebar to avoid jumping when color picker is visible

---------

Co-authored-by: Jono Mingard <reason.koan@gmail.com>
2023-09-19 17:12:52 +02:00
Djordje Vlaisavljevic
85484c20af Updated recommendation list design in portal
refs https://github.com/TryGhost/Product/issues/3898
2023-09-19 15:39:33 +01:00
Djordje Vlaisavljevic
4e04b8c2d2 Updated "Your recommendations" list design
refs https://github.com/TryGhost/Product/issues/3786
2023-09-19 15:39:33 +01:00
renovate[bot]
66f17cc82e Update tiptap monorepo to v2.1.10 2023-09-19 15:15:21 +02:00
Djordje Vlaisavljevic
f9fbcb3376 Added a hint to try to avoid long descriptions
refs https://github.com/TryGhost/Product/issues/3888
2023-09-19 13:07:32 +01:00
Djordje Vlaisavljevic
8af7b022fd Added a badge to "Your recommendation" items that have 1-click subscribe
refs  https://github.com/TryGhost/Product/issues/3888
2023-09-19 13:07:32 +01:00
Peter Zimon
09a36a81d1
AdminX mobile updates (#18137)
refs. https://github.com/TryGhost/Product/issues/3349
2023-09-19 12:09:38 +02:00
Daniel Lockyer
f705dda314 Updated Admin-X bundling process
refs https://github.com/TryGhost/DevOps/issues/80

- as part of moving Admin-X-Setting towards GA, we want to change it from
  loading the settings externally via a CDN, to bundling it in with
  Admin
- the bulk of the changes here are removing the config in Ghost, setting
  up the copy to the Admin assets dir, and loading the new path in Admin
- several other changes have come along the way as I've cleaned up
  unneeded code
2023-09-19 11:31:55 +02:00
Jono M
bd013ed18c
Fixed minor AdminX logic issues (#18209)
refs https://github.com/TryGhost/Product/issues/3832

---

### <samp>🤖 Generated by Copilot at fd2a023</samp>

This pull request improves the UI and UX of the admin settings app by
fixing some bugs, enhancing some components, and adding some logic to
handle different feature states. It affects the `ColorPickerField`,
`Toggle`, `EnableNewsletters`, `TierDetailModal`, `Modal`, and
`DefaultRecipients` components, as well as the files
`ColorPickerField.tsx`, `Toggle.tsx`, `EnableNewsletters.tsx`,
`TierDetailModal.tsx`, `Modal.tsx`, and `DefaultRecipients.tsx`.
2023-09-19 08:56:11 +01:00
renovate[bot]
530492635f Update dependency @types/react to v18.2.22 2023-09-19 08:30:58 +02:00
renovate[bot]
8cfff3743b Update dependency postcss to v8.4.30 2023-09-19 08:09:20 +02:00
Sag
3b1fcb6c16
Added fixed height to avoid jumps in the Recommendations settings (#18184)
closes https://github.com/TryGhost/Product/issues/3881

We observe the height of the recommendation table, and keep it fixed between pages — so that the UX is smoother when navigating between pages.
2023-09-18 17:43:57 +02:00
Jono M
343535116c
Updated select to use react-select (#18164)
refs https://github.com/TryGhost/Product/issues/3832

---

### <samp>🤖 Generated by Copilot at adffb67</samp>

This file updates the global form select component to use a custom
`ReactSelect` component with better performance and style.
2023-09-18 14:51:59 +01:00
Djordje Vlaisavljevic
308a76faf3 Removed "Remove" button from recommendation list
refs https://github.com/TryGhost/Product/issues/3899
2023-09-18 14:49:04 +01:00
Djordje Vlaisavljevic
a66d811236 Added "Remove" button to "Edit recommendation" modal
refs https://github.com/TryGhost/Product/issues/3899
2023-09-18 14:49:04 +01:00
Djordje Vlaisavljevic
6822c6db24 Added "Subscribe" button to Ghost-site previews
refs https://github.com/TryGhost/Product/issues/3857
2023-09-18 14:49:04 +01:00
Sag
7c2316de59
Added a timeout when adding a recommendation (#18204)
closes https://github.com/TryGhost/Product/issues/3896

- added a timeout option to the useFetchApi() helper, to abort a fetch request after x seconds
- when adding a recommendation, we make two network calls: 1) check whether it's a Ghost site or not, 2) if not, fetch site metadata via embed. Now both of these calls have a timeout of 5 sec, which means a total waiting time of 5 seconds max. for a Ghost site, 10 seconds max. for a non-Ghost site
2023-09-18 15:12:54 +02:00
Jono M
79cd49c01b
Improved AdminX design settings experience (#18180)
refs https://github.com/TryGhost/Product/issues/3832

---

### <samp>🤖 Generated by Copilot at 60bbe0a</samp>

This pull request improves the performance and readability of the site
design and theme settings UI. It refactors the modal navigation logic,
the color picker field component, and the theme preview component. It
also removes unnecessary dependencies and props from the modal
components, and adds a new `DesignAndThemeModal` component to handle the
modal switching.
2023-09-18 12:09:26 +01:00
Djordje Vlaisavljevic
cce7152d72 Fixed spacing issue
refs https://github.com/TryGhost/Product/issues/3857
2023-09-18 11:55:02 +01:00
Djordje Vlaisavljevic
d443befd16 Added recommendation URL to "Edit recommendation" modal
refs https://github.com/TryGhost/Product/issues/3857
2023-09-18 11:55:02 +01:00
Peter Zimon
3043c27d5a
AdminX UI fixes (#18167)
refs. https://github.com/TryGhost/Product/issues/3349
2023-09-15 18:35:16 +02:00
Simon Backx
d26c0c7995 Released Portal v2.36.0 2023-09-15 16:47:12 +02:00
Simon Backx
05b3f66132 Released @tryghost/admin-x-settings v0.0.20 2023-09-15 16:46:13 +02:00
Djordje Vlaisavljevic
3884c1c36d Added a hint when adding a recommendation for a Ghost site
refs https://github.com/TryGhost/Product/issues/3888
2023-09-15 15:37:19 +01:00
Simon Backx
ff61b33049 Grouped recommendations in Portal
fixes https://github.com/TryGhost/Product/issues/3893
2023-09-15 16:23:36 +02:00
Simon Backx
9a4c0ba33b Fixed counting subscribe after click on RecommendationsPage
fixes https://github.com/TryGhost/Product/issues/3892

After a user visited a site, we should still a subscribe that happens later.
2023-09-15 16:23:36 +02:00
renovate[bot]
ccf508e8f7 Update tiptap monorepo to v2.1.10 2023-09-15 14:12:47 +00:00
Simon Backx
4e2710ada2 Added stats to recommendations endpoints
fixes https://github.com/TryGhost/Product/issues/3854
fixes https://github.com/TryGhost/Product/issues/3864
2023-09-15 15:57:27 +02:00
Sag
6e68c43f78
Added uniqueness validation for the recommendation URL (#18163)
closes https://github.com/TryGhost/Product/issues/3818

- in Admin, when adding a recommendation, the URL is compared against all existing ones. If the URL is already recommended, the publisher is shown an error: "A recommendation with this URL already exists.". Protocol, www, query parameters and hash fragments are ignored during the URL comparison.
- on the backend, there is another uniqueness validation for the recommendation URL. This check is redundant when adding a recommendation from Admin, but helps to keep data integrity when recommendations are added through other paths (e.g. via the API)
2023-09-15 13:14:47 +00:00
Daniel Lockyer
caab89ff4d Reverted flexsearch to v0.7.21
refs https://github.com/TryGhost/Ghost/pull/18151
refs 1cbbe91a63

- something has broken within 0.7.31 and it's causing an error on the
  frontend
- this commit reverts the dependency back to the previous version
- also cleans up the dependency from announcement-bar, where it is not
  used
2023-09-15 15:07:57 +02:00
Djordje Vlaisavljevic
4fc03e5f25
Improved Table component and its storybook (#18169)
refs https://github.com/TryGhost/Product/issues/3890

- Made Table and its children semantic
- Updated Table and TableRow storybooks with new examples
- Fixed smaller visual bugs
2023-09-15 12:09:19 +00:00
renovate[bot]
d5bcd42496 Update dependency @storybook/testing-library to v0.2.1 2023-09-15 11:15:56 +02:00
Jono M
3bf24cd4a2
Fixed Lexical editors being marked as dirty on load (#18159)
refs https://github.com/TryGhost/Product/issues/3832

---

This pull request improves the user experience and the data quality of
the newsletter settings form. It adds a feature to disable the save
button when there are no changes, and to show feedback on the save
status. It also fixes a bug in the `HtmlEditor` component that causes
unwanted style attributes to be added to the newsletter content.
2023-09-15 10:07:14 +01:00
Ronald Langeveld
851504030c
Added Support Email verification modals to Admin X (#18152)
refs
https://www.notion.so/ghost/df5bdea8f7ea4aca9d25eceb6a1bf34c?v=be2f15b6b58b4c27a0e11374282bead0&p=163762d9513a4e6dbd60c28e19228fdc&pm=s

- Added a modal to confirm that the new support email has been verified.
- to achieve that a couple of adjustments had to be made
- Updated the RoutingProvider to handle routes with query params.
- Added a new useQueryParams hook to grab query params where needed.
- wired up the email verification api.
- added feature flags / labs logic to the core package with the new URL and updated test.

---

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

This pull request adds email verification functionality for the support
email address in the portal settings. It fixes a bug in the routing
provider, adds a new API function, a new custom hook, and a new modal
component to handle the verification process. It also updates the
settings query with the verified email address.
2023-09-15 16:00:24 +07:00
Daniel Lockyer
8b0de7e6e4 Temporarily increased timeout for Comments-UI web server init
refs https://github.com/TryGhost/Product/issues/3867

- this helps avoid flaky tests before we investigate further
2023-09-15 10:48:08 +02:00
renovate[bot]
9730229968 Update sentry-javascript monorepo to v7.69.0 2023-09-15 10:33:55 +02:00