0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2024-12-30 22:34:01 -05:00
Commit graph

40105 commits

Author SHA1 Message Date
Steve Larson
35edb30e18 f 2024-12-16 08:38:16 -06:00
Steve Larson
a60756b321 Added sentry logging to member lookup for link clicks
no ref
2024-12-10 13:56:08 -06:00
Kevin Ansfield
0f9449137f Fixed comment count in comments-ui when logged in as admin
closes https://linear.app/ghost/issue/PLG-297

- we were setting the comment count Admin API browse comments response meta pagination data which will never be correct because it only counts top-level comments for pagination purposes
- we have a public comment counts endpoint that is already fetched, there's no need to override that when using the Admin API because the overall count doesn't change across API's, even when the Admin API includes hidden comments because those don't impact the visible count
- updated test setup so the title and count is shown so it can be asserted against
- updated mocked api to correctly return count of all published comments+replies
2024-12-10 18:59:49 +00:00
Steve Larson
78c1d5bcf0
Added config for caching the member lookup for link clicks (#21855)
https://linear.app/ghost/issue/ENG-1850/
- added cache/memoized the member uuid lookup within the
LinkClickRepository (used by the LinkClickTrackingService)
- added repository tests for the save method which were absent

This one one of a series of options we're testing out in order to smooth
out the surge in requests following a newsletter send. Most of this
activity is due to link checkers, but Ghost still needs to spend time
processing the member lookup to know whether or not it is a valid id,
and memoizing this lookup could significantly improve throughput by
reducing DB contention.
2024-12-10 11:37:47 -06:00
Kevin Ansfield
1fb417b6a3 Fixed dropdown menu being cut off in comments-ui
closes https://linear.app/ghost/issue/PLG-273

- removed previous fix which only worked on last comment but not last reply
  - keeping track of last comment/reply spread a lot of domain knowledge around for a UI-only concern and wouldn't scale if we have other dropdowns in the future
- added `useOutOfViewportClasses` hook
  - accepts an object with top/bottom/right/left containing default and outOfViewPort classes
  - applies the correct classes using the DOM rather than React so that we avoid re-renders and associated flickering or broken rendering
2024-12-10 17:15:29 +00:00
Steve Larson
109c7b70ee
Added config flag to disable link click tracking (#21853)
no ref

This isn't needed at this time. We're doing some load testing to better
assess what piece is doing the most work, and this config flag lets us
shut off pieces of the redirect flow.
2024-12-10 16:08:58 +00:00
Ronald Langeveld
04f0b9fc3f
Fixed comment likes being incorrect when logged in as an Admin (#21833)
ref https://linear.app/ghost/issue/PLG-296/

When logged in as an Admin, comments-ui switches comment reads from the Members API over to the Admin API so that hidden comments can be displayed to allow moderation activities. However, the Admin API not using member authentication and CORS preventing the front-end members auth cookie being passed over to the Admin API domain meant that the logged-in member's likes were missing when fetching via the Admin API as there is no available reference to the logged in member.

This change works around the problem by introducing an `impersonate_member_uuid` param to the comments read/browse endpoints of the Admin API. When passed, the provided uuid is used to simulate that member being logged in so that likes are correctly shown.

- Introduced `impersonation_member_id` parameter to resolve issues with admin API not returning correct "liked" status for comments when an admin is logged in.
- Updated API endpoints in `comment-replies.js` and `comments.js` to handle `impersonation_member_id`.
- Adjusted `CommentsController` to validate and process the `impersonation_member_id` parameter before passing it to database queries.
- Enhanced test coverage to ensure proper handling of the new parameter and accurate "liked" status behavior.
2024-12-10 14:44:15 +00:00
Hannah Wolfe
ece7c93759
Updated stats page to use versioned endpoints (#21850)
ref https://github.com/TryGhost/Ghost/pull/21794

- We've now added versioning to all of our endpoints as of pr/21794
- This change updates the stats page to use the new versioned endpoints
- Currently, it's set to a global as all endpoints are on the same
version
- In future we may need this to be an array of versions for each
endpoint, but for now we're keeping it simple
2024-12-10 13:20:14 +00:00
Hannah Wolfe
34276f13a0
Fixed tinybird tests with versioning (#21849)
ref https://github.com/TryGhost/Ghost/pull/21794

- This was missed in the PR to add versioning to all the resources - the
endpoints are now different, and the tests don't run
- I've been struggling to deploy out my changes, and part of it is
because this is a wholesale change to having versions, where previously
we didn't
- This change brings the tests into line, so we can be certain that the
new endpoints with the versions work the same as the old
- TODO: really must get CI working for tinybird!
2024-12-10 13:04:24 +00:00
Hannah Wolfe
a0dc162b75
Improved robustness of unsafe deploy tb script (#21848)
- Previously the script would error out if a resource was missing e.g.
if a deploy had gone wrong
- That meant I frequently had to make further, manual changes
- These updates mean the script only attempts to delete a resource if it
is present
- Each type of resource is listed in an array and iterated over
- note there is no real difference between data and endpoint pipes, but
we need to manage them in order
- This should make the script much much more robust!
2024-12-10 12:49:24 +00:00
Sanne de Vries
9ffb05f922
Fixed excerpt display in post history modal (#21847)
REF
https://linear.app/ghost/issue/DES-1026/visual-bug-with-excerpt-in-post-history-modal
- The excerpt was not in line with the rest of the content.
- The excerpt divider was visible even when there was no excerpt.
2024-12-10 12:35:52 +00:00
renovate[bot]
c2c9ef71e7 Update dependency express to v4.21.2 2024-12-10 10:48:47 +01:00
Princi Vershwal
9476afb876
🔒 Limited permissions for uploaded files to 0644 (#21841)
Fixes
https://linear.app/ghost/issue/ENG-1010/uploaded-file-permission-security-improvement

- This commit ensures all files uploaded to Ghost via importer are set
with 0644 permissions to improve security.
- Uploaded files previously retained their original permissions, which
could leave them executable.
- This commit prevents files from being inadvertently executable.
2024-12-10 07:11:48 +00:00
renovate[bot]
c38e83d50d
Update dependency express-jwt to v8.5.1 (#21843)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [express-jwt](https://redirect.github.com/auth0/express-jwt) |
[`8.5.0` ->
`8.5.1`](https://renovatebot.com/diffs/npm/express-jwt/8.5.0/8.5.1) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/express-jwt/8.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/express-jwt/8.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/express-jwt/8.5.0/8.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/express-jwt/8.5.0/8.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>auth0/express-jwt (express-jwt)</summary>

###
[`v8.5.1`](c028e7098e...0dfe63b9a7)

[Compare
Source](c028e7098e...0dfe63b9a7)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "* * * * 1-5" (UTC), Automerge - At
any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/TryGhost/Ghost).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS40Mi40IiwidXBkYXRlZEluVmVyIjoiMzkuNDIuNCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-09 19:17:00 +00:00
renovate[bot]
140e11bd76
Update dependency express-jwt to v8.5.0 (#21840)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [express-jwt](https://redirect.github.com/auth0/express-jwt) |
[`8.4.1` ->
`8.5.0`](https://renovatebot.com/diffs/npm/express-jwt/8.4.1/8.5.0) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/express-jwt/8.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/express-jwt/8.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/express-jwt/8.4.1/8.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/express-jwt/8.4.1/8.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>auth0/express-jwt (express-jwt)</summary>

###
[`v8.5.0`](https://redirect.github.com/auth0/express-jwt/compare/v8.4.1...c028e7098ea3dbdd4684f6e4960564e38fccdb96)

[Compare
Source](https://redirect.github.com/auth0/express-jwt/compare/v8.4.1...c028e7098ea3dbdd4684f6e4960564e38fccdb96)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "* * * * 1-5" (UTC), Automerge - At
any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/TryGhost/Ghost).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS40Mi40IiwidXBkYXRlZEluVmVyIjoiMzkuNDIuNCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-09 16:52:18 +00:00
Kevin Ansfield
5ec9f59411 Removed unused useSecondUpdate hook in comments-ui
no issue

- left over after cleanup of secondary form code
2024-12-09 14:51:27 +00:00
Sanne de Vries
972cc82958
Prevented top-level comment input from closing when it has text (#21795)
REF https://linear.app/ghost/issue/PLG-298/

- When you're typing a comment, and exit the input field, it collapses into a non-editable state; you first have to click on it again to "open" the form. This means you can't select the text or instantly start typing again. When the input has a value, we should stop it from closing.
- added custom `useEditor` hook that wraps TipTap and exposes both the `editor` and `hasContent` props keeping logic out of the consuming components

---------

Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
2024-12-09 13:42:24 +00:00
Sodbileg Gansukh
b25f42fec6
Fixed flash of reply button when publishing a post (#21836)
ref DES-1027
2024-12-09 18:59:44 +08:00
renovate[bot]
75cece4da7
Update dependency dompurify to v3.2.3 (#21835)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [dompurify](https://redirect.github.com/cure53/DOMPurify) | [`3.2.2`
-> `3.2.3`](https://renovatebot.com/diffs/npm/dompurify/3.2.2/3.2.3) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/dompurify/3.2.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/dompurify/3.2.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/dompurify/3.2.2/3.2.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/dompurify/3.2.2/3.2.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>cure53/DOMPurify (dompurify)</summary>

###
[`v3.2.3`](https://redirect.github.com/cure53/DOMPurify/releases/tag/3.2.3):
DOMPurify 3.2.3

[Compare
Source](https://redirect.github.com/cure53/DOMPurify/compare/3.2.2...3.2.3)

- Fixed two conditional sanitizer bypasses discovered by
[@&#8203;parrot409](https://redirect.github.com/parrot409) and
[@&#8203;Slonser](https://x.com/slonser\_)
- Updated the attribute clobbering checks to prevent future bypasses,
thanks [@&#8203;parrot409](https://redirect.github.com/parrot409)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "* * * * 1-5" (UTC), Automerge - At
any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/TryGhost/Ghost).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS40Mi40IiwidXBkYXRlZEluVmVyIjoiMzkuNDIuNCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-09 10:08:05 +00:00
Ronald Langeveld
dbcbabb99a
Add comments loading state action (#21834)
ref https://github.com/TryGhost/Ghost/pull/21788#discussion_r1869802093

- Introduced `setCommentsIsLoading` action to handle the loading state
of comments dynamically.
- Updated `setOrder` function to dispatch the `setCommentsIsLoading`
action, ensuring proper UI feedback during asynchronous operations.
2024-12-09 16:09:14 +08:00
Ghost CI
2f7b151f15 Merged v5.104.1 into main 2024-12-08 23:54:29 +00:00
Ghost CI
21616745e5 v5.104.1 2024-12-08 23:54:28 +00:00
Steve Larson
8d4abb4e33 Fixed config ref for link click tracking logging (#21832)
no ref
2024-12-08 17:41:35 -06:00
Steve Larson
76aa5a4e45
Fixed config ref for link click tracking logging (#21832)
no ref
2024-12-08 23:37:08 +00:00
renovate[bot]
820018ec29
Update dependency @slack/webhook to v7.0.4 (#21825)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@slack/webhook](https://slack.dev/node-slack-sdk/webhook)
([source](https://redirect.github.com/slackapi/node-slack-sdk)) |
[`7.0.3` ->
`7.0.4`](https://renovatebot.com/diffs/npm/@slack%2fwebhook/7.0.3/7.0.4)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@slack%2fwebhook/7.0.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@slack%2fwebhook/7.0.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@slack%2fwebhook/7.0.3/7.0.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@slack%2fwebhook/7.0.3/7.0.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>slackapi/node-slack-sdk (@&#8203;slack/webhook)</summary>

###
[`v7.0.4`](https://redirect.github.com/slackapi/node-slack-sdk/releases/tag/%40slack/web-api%407.0.4):
@&#8203;slack/web-api@7.04

[Compare
Source](https://redirect.github.com/slackapi/node-slack-sdk/compare/@slack/webhook@7.0.3...@slack/webhook@7.0.4)

### What's Changed

We released a fix for the `oauth.v2.exchange` method argument type;
previously it did not require a `token`, which was incorrect. It now
requires a `token` parameter, which matches the expectations of this API
method.

### Full Changelog


[`ae755dc`](https://redirect.github.com/slackapi/node-slack-sdk/commit/ae755dc4)
web-api(fix): `oauth.v2.exchange` method requires a `token` parameter
([#&#8203;1779](https://redirect.github.com/slackapi/node-slack-sdk/issues/1779))
- thanks for reporting
[@&#8203;iggyray](https://redirect.github.com/iggyray)!

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "* * * * 1-5" (UTC), Automerge - At
any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/TryGhost/Ghost).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS40Mi40IiwidXBkYXRlZEluVmVyIjoiMzkuNDIuNCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-06 23:01:09 +00:00
Djordje Vlaisavljevic
4597abddff Improved grouped notifications UI
ref https://linear.app/ghost/issue/AP-625/implement-notification-grouping-for-follows-and-likes

- Improved handling for notification clicks of various types: single follower notification opens that follower in the drawer, multiple followers expands the followers list, liked post opens the article in the wide drawer, liked note opens the note in the narrow drawer
- Improved hover and click states for profile names, usernames and avatars. Now it's more obvious what's clickable, and clicking on any of these elements in any context opens that profile in the drawer.
- Created a handleProfileClick utility since we're using it in a lot of places.
- Removed unnecessary types
- Made the HTML structure more semantic
2024-12-06 17:04:39 +00:00
Ghost CI
de6efba68a v5.104.0 2024-12-06 15:05:47 +00:00
Ghost CI
3b9d4e16d2 🎨 Updated Source to v1.4.1 2024-12-06 15:05:47 +00:00
Ghost CI
9dce415624 🎨 Updated Casper to v5.8.1 2024-12-06 15:05:47 +00:00
Steve Larson
a5d6b65dde
Added Sentry logging for email link clicks w/ bad member uuid (#21821)
no ref

I've discovered email link checkers appear to be using
falsified/scrambled uuids when testing links for a given site. It's
difficult to check against all sites, so instead we'll log to Sentry to
confirm this is the case.

I've put this behind config because I believe it will create a LOT of
entries, and may burden an already burdened workflow during peak
traffic.
2024-12-06 13:48:38 +00:00
Djordje Vlaisavljevic
becfc5013c
Improved spacing and alignment in notifications (#21820)
ref https://linear.app/ghost/issue/AP-625/implement-notification-grouping-for-follows-and-likes

Co-authored-by: Peter Zimon <peter.zimon@gmail.com>
2024-12-06 13:14:41 +00:00
Djordje Vlaisavljevic
e7a9b2a720
Made similar notifications appear grouped together (#21805)
ref https://linear.app/ghost/issue/AP-625/implement-notification-grouping-for-follows-and-likes

- Added basic frontend grouping for Follow and Like notifications, so the page is easier to scan through. For each loaded batch of notifications we check if they can be grouped (all follows get grouped, all likes for a certain post get grouped) and then merge those grouped pages of notifications.
- Improved UI for notifications, with notification type icons for each group.
- Added a utility for truncating text.
2024-12-05 21:52:03 +00:00
Sanne de Vries
9350ccf1db Removed hover effect on replied-to refs for unpublished comments
REF https://linear.app/ghost/issue/PLG-294/remove-link-from-replied-to-[hiddenremoved]
2024-12-05 18:02:38 +00:00
Kevin Ansfield
7e60172027 Removed link from replied-to ref when deleted/hidden
closes https://linear.app/ghost/issue/PLG-294

- making the `replied to: [removed]` text a link was a bit confusing because clicking it does nothing
- if the replied-to comment doesn't exist (e.g. hidden/deleted and not returned in API response) or has been unpublished we replace the `<a>` with a `<span>` to remove the link behaviour
2024-12-05 18:02:38 +00:00
Kevin Ansfield
0651d7178b Extracted <RepliedToSnippet> component from <CommentHeader>
no issue

- keeps logic inside `<CommentHeader>` single-purpose
- allows for cleaner code when adding logic to remove the link when the replied-to comment is removed
- switched `queryByText` to `getByText` in the test to make debugging easier, the latter will print the current DOM if it fails to find an element

# Conflicts:
#	apps/comments-ui/src/components/content/Comment.tsx
2024-12-05 18:02:38 +00:00
Sanne de Vries
f06de99410
Added highlight animation when scrolling to replied-to comment (#21781)
REF https://linear.app/ghost/issue/PLG-284

When clicking on a replied-to reference, you scroll up to the parent comment. To guide the eye, the parent comment is highlighted with a yellow background.

- added `dispatchAction` to the `ActionHandler` function call arguments, allowing actions to call other actions
- added `commentIdToHighlight` app context state and associated `highlightComment` action to set it
- updated `Comment` (and related sub-components) to match `commentIdToHighlight` when rendering to determine whether to apply highlighting of comment contents
- for the highlight, `<mark>` is used to wrap any paragraphs inside the comment contents and appropriate tailwind highlight animation classes applied
  - uses the inline `<mark>` element so that background highlight only applies to the text bounding boxes rather than the entire wrapping element

---------

Co-authored-by: Ronald Langeveld <hi@ronaldlangeveld.com>
2024-12-05 17:46:16 +00:00
Steve Larson
428eebeaf8
Added custom font support for themes (#21817)
ref [DES-949](https://linear.app/tryghost/issue/DES-949/

177e604501

This adds custom fonts feature allowing users to select heading and body
fonts for their themes from a curated list. This allows publishers to
have more control over their brand, and allows themes to have a wider
range of styles to appeal to different audiences.

Without custom fonts support, themes will continue to work as normal,
but users won't be able to customize their typography. As for the
official themes, all of them will support custom fonts.
2024-12-05 16:39:41 +00:00
renovate[bot]
4a91c08328
Update dependency webpack to v5.97.1 (#21814)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [webpack](https://redirect.github.com/webpack/webpack) | [`5.97.0` ->
`5.97.1`](https://renovatebot.com/diffs/npm/webpack/5.97.0/5.97.1) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/webpack/5.97.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/webpack/5.97.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/webpack/5.97.0/5.97.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/webpack/5.97.0/5.97.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>webpack/webpack (webpack)</summary>

###
[`v5.97.1`](https://redirect.github.com/webpack/webpack/releases/tag/v5.97.1)

[Compare
Source](https://redirect.github.com/webpack/webpack/compare/v5.97.0...v5.97.1)

##### Bug Fixes

-   Performance regression
-   Sub define key should't be renamed when it's a defined variable

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "* * * * 1-5" (UTC), Automerge - At
any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/TryGhost/Ghost).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS40Mi40IiwidXBkYXRlZEluVmVyIjoiMzkuNDIuNCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-05 14:41:39 +00:00
Daniel Lockyer
67e6a48c3f Removed trailing Admin model for Collections
ref https://linear.app/ghost/issue/ENG-1805/remove-collections-code

- this was still lingering around because I forgot to delete it in the
  initial commit
2024-12-05 15:28:27 +01:00
Sanne de Vries
379fc19ad5
Added content visibility flag to beta features list (#21809)
No ref
2024-12-05 10:46:25 +00:00
renovate[bot]
bd9fd1587c
Pin dependency dompurify to 3.2.2 (#21808)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [dompurify](https://redirect.github.com/cure53/DOMPurify) |
dependencies | pin | [`^3.2.2` ->
`3.2.2`](https://renovatebot.com/diffs/npm/dompurify/3.2.2/3.2.2) |

Add the preset `:preserveSemverRanges` to your config if you don't want
to pin your dependencies.

---

### Configuration

📅 **Schedule**: Branch creation - "* * * * 1-5" (UTC), Automerge - At
any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/TryGhost/Ghost).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS40Mi40IiwidXBkYXRlZEluVmVyIjoiMzkuNDIuNCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-05 09:50:39 +00:00
Sag
a686d64029
🔒 Fixed SVG sanitization for staff profile pictures (#21798)
closes https://linear.app/ghost/issue/ENG-1506

- when uploading a SVG image as staff profile picture, we previously had
a validation against malicious `<script>` tags or `on*` attributes
- this has proven to be unsufficient, as malicious scripts can be added
via other tags (e.g. `<foreignObject>`) and other attributes (e.g.
`xlink:href`)
- we now satinize SVGs using the DOMPurify library during validation
- if the file is invalid and cannot be sanitized, we show an error to
the user
- also added support for sanitizing `.svgz` files
2024-12-05 17:36:04 +08:00
Fabien 'egg' O'Carroll
aecc32e151
Added staging db testing requirement (#21807)
We've agreed that all database changes going forward must be testing at
least on staging
2024-12-05 07:15:33 +00:00
Steve Larson
3da2a9f64e
Added flag to disable lastSeenAt updater for member link clicks (#21802)
ref https://linear.app/ghost/issue/ENG-1814

This provides a way for us, if needed, to disable the least important piece of the member click event cascade.
2024-12-04 10:53:01 -06:00
Daniel Lockyer
4c13f188ce Removed Collections code from Admin
ref https://linear.app/ghost/issue/ENG-1805/remove-collections-code

- we're removing this feature as it's not finished to the degree we
  would like, so this commit removes all references to it from Admin in
  order to keep things clean
2024-12-04 17:36:40 +01:00
Hannah Wolfe
ed6c57e2a0
Updated stale bot's issue timer
- Currently, stale bot is configured to mark issues as stale after 120 days, and close them 7 days later
- The intent is to close anything 4 months old or more, so setting the timer to 113 days means it accounts for the extra 7
2024-12-04 15:38:47 +00:00
Princi Vershwal
8bc723c641
Removed unnecessary forUpdate from linkSubscription method
Closes https://linear.app/ghost/issue/ENG-1758/product-row-locking-in-linksubscription-causes-slowness-in-high-signup

- The method used a FOR UPDATE query when fetching the Ghost product despite never updating that row. 
- In this case, we're only reading the default product to link it with a subscription - we're not actually modifying the default product itself. The operation is read-only in nature, therefore, the forUpdate lock is unnecessary
- The actual update to the product happens later in the code when we call this._productRepository.update() with the stripe price data, and that operation has its own transaction handling and locking mechanisms
2024-12-04 08:05:29 +00:00
Sodbileg Gansukh
ea0e598bf2
Added custom fonts feature check (#21738)
ref DES-1011

- previously, we were hiding the old font settings from the official themes without checking if they support the custom fonts or not
- now we use the gscan warning info to check this — only when there's support, we hide the settings which means users with the older version will get the old settings back
- also added two new tests for this procedure
2024-12-04 13:42:44 +08:00
Ronald Langeveld
7c1d7080e9
Bumped comments-ui to 0.24.1 (#21797)
ref PLG-293
2024-12-04 02:48:20 +00:00
Ronald Langeveld
55dc9d997f
Added loading state when ordering comments (#21788)
PLG-280

- Added a loading state implementation when changing the ordering of
comments.
- This improves the overall UX particularly with slower connections.
- Due to the nature of how comments and ordering are handled, we
approached it with a simple state that determines whether it's done
loading or not around the API query.

---------

Co-authored-by: Sanne de Vries <sannedv@protonmail.com>
2024-12-04 10:16:58 +08:00