Fabien 'egg' O'Carroll
34ddbcd52e
Fixed admin auth asset loading ( #15018 )
...
The copyStatic method relies on the dest directory existing, which is
done created the minify method. We've reordered the calls to fix the
issue, but we're still left with the copyStatic method being dependent
on the minify method. Adding the `@private` jsdoc tag removes these
from the public interface, so that the dependency is encapsulated in
this module via the `load` method.
We've also awaited the result of the copyStatic method to avoid
dangling promises.
2022-07-12 13:25:28 +01:00
Simon Backx
61e1ee07dc
Bumped Portal to 2.3.0 to include comment notification settings
...
refs https://github.com/TryGhost/Team/issues/1664
- This doesn't require a feature flag, as comments are disabled by default + UI is hidden if comments are disabled
2022-07-12 13:58:20 +02:00
Simon Backx
0292b4868b
Reduced minimum required test coverage for functions
...
refs https://ghost.slack.com/archives/C02G9E68C/p1657607789883059?thread_ts=1657522575.865029&cid=C02G9E68C
Tests are failing because of the minimum required test coverage for functions. We'll need to fix it up later.
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
34047737b8
Updated comments helper to inject comments-ui version
...
refs https://github.com/TryGhost/Team/issues/1664
This is required so that the comments ui can correctly load assets from unpkg
2022-07-12 10:24:02 +02:00
Kevin Ansfield
d05b94a975
Added build step for admin-auth asset files
...
refs https://github.com/TryGhost/Team/issues/1664
- ensures source files are copied to the correct place and minified on boot and when frontend src files are changed in development
2022-07-12 10:24:02 +02:00
Kevin Ansfield
6ea545afe1
Added comment-counts script
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
e1a3adea6a
Updated message handler for dynamic admin urls
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
a6842e8a20
Added support for blockquote in comments
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Peter Zimon
7a4ae08b44
Added accent color to helper
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Kevin Ansfield
129836f52e
Extracted email-related functionality out of base comments service file
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
9893147d58
Added <a> to comment html sanitizer
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
903b8a1105
Added initial comment_count helper
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
9ee003f8b2
Added initial counts api for comments
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
484e5102e2
Added comment for the add comment endpoint
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
96504008c1
Added member API for changing enable_comment_notifications and comments_enabled setting
...
refs https://github.com/TryGhost/Team/issues/1664
These changes are required for Portal to be able to edit the member notification preferences for comments, and to be able to know whether comments are enabled for the site.
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
6a8c6e9081
Exposed comments_enabled setting publicly
...
refs https://github.com/TryGhost/Team/issues/1664
This also means that themes have access to this setting
2022-07-12 10:24:02 +02:00
Peter Zimon
41a8134c40
Added avatar saturation parameter to comments helper
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Kevin Ansfield
379771ccc7
Stripped all HTML except <p> and <br> when saving comments
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Kevin Ansfield
38eb755056
Changed member name to "Anonymous" in emails when not set
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Kevin Ansfield
c63f3eb8c1
Added comment reply email notifications
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Peter Zimon
be69d83141
Added color scheme helper parameter
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Hannah Wolfe
14020f46d2
Handle comment replies in the browse API
...
refs https://github.com/TryGhost/Team/issues/1664
- replies are a sub-record inside of a comment
2022-07-12 10:24:02 +02:00
Hannah Wolfe
cf529111f6
Updated comment API to only return top-level comments
...
refs https://github.com/TryGhost/Team/issues/1664
- we will have a separate concept of returning replies
2022-07-12 10:24:02 +02:00
Simon Backx
0d4b3a2baa
Readded uuid to comment members relation output
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
7fa335d179
Added initial Admin API for Comments
...
refs https://github.com/TryGhost/Team/issues/1664
This allows a Comment to have its status changed to either 'hidden' or 'published'
2022-07-12 10:24:02 +02:00
Kevin Ansfield
70f57210b1
Wired up comment notification email data
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
876c1024c9
Added liked property to comments
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
54e7a6cec3
Added default comment relations
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Peter Zimon
ef989ed55c
Improved comment notification email template
...
refs https://github.com/TryGhost/Team/issues/1664
- added comment
- refined copy
2022-07-12 10:24:02 +02:00
Hannah Wolfe
e5e05c292c
Added basic test fixture structure for comments
...
refs https://github.com/TryGhost/Team/issues/1664
- includes a comment and a reply for now
2022-07-12 10:24:02 +02:00
Hannah Wolfe
caef9d74e0
Added mapper for comments API
...
refs https://github.com/TryGhost/Team/issues/1664
- ensure that the comment API returns a minimal and clean set of data and doesn't expose member details
2022-07-12 10:24:02 +02:00
Kevin Ansfield
a2ab9f7a20
Added support for plaintext email templates in comments service
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Peter Zimon
a1b224bec8
Updated copy for new comment email
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
e96ff3fa81
Added comments API like and unlike actions
...
refs https://github.com/TryGhost/Team/issues/1664
- Added comment-like model
- Added like endpoint
- Added unlike endpoint
- Added basic tests for liking and unliking comments
- Added permissions for liking and unliking
- Added migration for permissions
2022-07-12 10:24:02 +02:00
Kevin Ansfield
1b4f8f0c95
Added WIP author email notifications for new comments
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Kevin Ansfield
25c0b75426
Added comments API tests
...
refs https://github.com/TryGhost/Team/issues/1664
Note: we put it in the members-comments folder because some issue with test ordering
- refs https://ghost.slack.com/archives/C02G9E68C/p1657538586658649?thread_ts=1657522575.865029&cid=C02G9E68C
- There is something wrong with the url service reset when running multiple tests
- Currently we are doing a soft reset, this needs investigating
- Changing the order so that the comments API tests are executed after the content API tests, fixes the issue too.
Co-authored-by: Simon Backx <simon@ghost.org>
2022-07-12 10:24:02 +02:00
Hannah Wolfe
78c15933e6
Implemented soft delete for comments
...
refs https://github.com/TryGhost/Team/issues/1664
- comments are marked as deleted, rather than deleted completely
2022-07-12 10:24:02 +02:00
Hannah Wolfe
d4c8660323
Updated comments.add to use member id from cookie
...
refs https://github.com/TryGhost/Team/issues/1664
- make sure we only create comments for the currently logged in member
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
3e1e5b6760
Added adminUrl to comments helper script data
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
7d22384d7f
Passed post id to comments helper instead of comment id
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Simon Backx
87f714ef25
Added sentry dsn placeholder attribute to comments helper
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Hannah Wolfe
fc99176fdf
Moved comments api to members/api/comments
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Hannah Wolfe
f5ccec70b6
Use member cookie on comment API
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Hannah Wolfe
42fc272433
Added members permission system
...
refs https://github.com/TryGhost/Team/issues/1664
- the new member comments API needs members to have permissions to edit and delete their own posts
- added members as a provider, and then wired up permissible logic at the model level
2022-07-12 10:24:02 +02:00
Hannah Wolfe
00110e541e
Added basic comment CRUD model + API
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Kevin Ansfield
a5874f90fe
Added initial Comment model
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Fabien "egg" O'Carroll
ed7ce2c00f
Added initial auth frame
...
refs https://github.com/TryGhost/Team/issues/1664
This has no security features, we need to replace usage of "*" with the origin of
the frontend site.
2022-07-12 10:24:02 +02:00
Kevin Ansfield
e60ec64454
Added WIP frontend comments app
...
refs https://github.com/TryGhost/Team/issues/1664
2022-07-12 10:24:02 +02:00
Daniel Lockyer
1dd83e1a0f
✨ Added Ghost Explore endpoint
...
- this new endpoint returns a special set of data for use in Ghost Explore
2022-07-11 16:48:40 +01:00
renovate[bot]
4134a6ac4c
Update dependency luxon to v2.5.0
2022-07-11 05:29:16 +00:00