Commit Graph

28969 Commits

Author SHA1 Message Date
Daniel Lockyer
2a07b94bd4
Fixed small boot time regression due to lack of dependency lazyloading
- when I extracted `mailgun-client` to a separate package, I
  accidentally removed the lazyloading for the `mailgun-js` library,
  which takes a non-negligible amount of time to require on boot
- this fixes that by moving the require into the function where it's
  used
2022-08-15 10:10:26 +02:00
renovate[bot]
7f5d95ffff Update @tryghost 2022-08-15 10:08:46 +02:00
renovate[bot]
7d3f5d3165 Update dependency eslint to v8.22.0 2022-08-15 10:07:34 +02:00
Daniel Lockyer
d2eda5cf51 Extracted oembed service to separate package
refs https://github.com/TryGhost/Toolbox/issues/363

- the oembed service is completely standalone and could do with some
  individual unit tests
- moving it out to a package allows us to draw the boundaries better and
  allows us to remove some dependencies from the core package.json
2022-08-15 10:07:06 +02:00
Daniel Lockyer
dfbe8ee296 Removed Sentry from oembed service
- I'm not sure if we gain anything here except noise
- it was added after a bug in the oembed service but it was regarding
  oembed-parser and not metascraper
2022-08-15 10:07:06 +02:00
Djordje Vlaisavljevic
577b30c4f6 Updated .lint-todo 2022-08-15 09:36:47 +02:00
Djordje Vlaisavljevic
713635b49f Fixed tier modal when free trial not enabled
refs https://github.com/TryGhost/Team/issues/1791
2022-08-14 13:59:37 +02:00
renovate[bot]
5250dd9a12 Update dependency cssnano to v5.1.13 2022-08-13 11:20:27 +02:00
Djordje Vlaisavljevic
ab97216c3f Updated tier modal design
refs https://github.com/TryGhost/Team/issues/1791
2022-08-12 18:24:05 +02:00
Daniel Lockyer
54baa8d71e v5.9.1 2022-08-12 17:11:31 +01:00
Daniel Lockyer
b7ea57e2da
🐛 Fixed packaging issue with missing component
refs bf254b9c6a

- this was missing from the referenced commit in order to import the
  package into Ghost core
2022-08-12 17:48:40 +02:00
Daniel Lockyer
b06b7c5ddd v5.9.0 2022-08-12 16:00:29 +01:00
Daniel Lockyer
02c9f287fb 🎨 Updated Casper to v5.3.0 2022-08-12 16:00:29 +01:00
Simon Backx
27df4e536f
Added native comments (#15223)
no issue

- Removes the comments lab flag (bumping it to GA).
- Bumps comments-ui to v0.8
2022-08-12 16:06:06 +02:00
Aileen Nowak
77e4be6b81 Updated tests to incl. host limit cases for core integrations
- added core and builtin integrations to test fixtures
- allowed passing a custom api key id to generate JWT
- updated admin key auth test to make successful request with a `core` integration, which doesn't work atm because relations are not returned
2022-08-12 14:18:44 +01:00
Aileen Nowak
5ac779f86b Added core type integrations to API serializer 2022-08-12 14:18:44 +01:00
Aileen Nowak
0e284edbad Allowed core integrations to work with Admin API 2022-08-12 14:18:44 +01:00
Aileen Nowak
c813e5d96e Added migrations to change Ghost Explore integration type
no issue

- The previous integration type is insufficient and we need to utilise a new type `core`
2022-08-12 14:18:44 +01:00
James Morris
44aa5336d6 Updated the comments version to 0.7.0
no issue
2022-08-12 14:11:46 +01:00
Simon Backx
7ddfa9a195 Readded limit to replies relation
no issue

Was accidentally committed with previous commit.
2022-08-12 14:49:43 +02:00
Simon Backx
5c75997685 Fixed options not being passed to loaded replies
fixes https://github.com/TryGhost/Team/issues/1787

- Options were not passed
- The member context variable was not passed to the count helper
- Liked was always false for replies
2022-08-12 14:41:29 +02:00
Rishabh
60cd54dda3 Added auto focus on name when creating new tier
closes https://github.com/TryGhost/Team/issues/1785
2022-08-12 16:24:44 +05:30
Rishabh
00f2c73d93 Added auto generated offer code for new offers
closes https://github.com/TryGhost/Team/issues/1784

- auto generates offer code for new offers from name, same as display name
- stops auto generation as soon as offer code is manually edited once
2022-08-12 16:20:26 +05:30
Daniel Lockyer
7ea1c2591b
Added metric collection for URL service initialization time
- this should help us get more visibility into the URL service and the
  effect it has on bootup time
2022-08-12 11:08:42 +02:00
Rishabh
d4860e7fe3 Fixed typo for free trial flag
refs https://github.com/TryGhost/Team/issues/1726
2022-08-12 14:21:54 +05:30
Daniel Lockyer
8574bcd30a Refactored api-framework to use optional chaining
- this makes the code more readable and succinct
2022-08-12 10:16:01 +02:00
Daniel Lockyer
8247242610 Added tests to HTTP module of api-framework
- this file was mostly just missing tests for the other content
  disposition types, which are easily added
- bumps coverage of this file to 100%
2022-08-12 10:16:01 +02:00
Daniel Lockyer
c017174c9a Lazily executed calculating headers in API framework
- if the API controller endpoint is a function, we early return as we
  expect the function to handle the response but we still ended up
  calculating the headers beforehand, only to be thrown away
- this commit moves the header fetching code down in the flow so it's
  only executed when needed
- this doesn't really have a big effect for us because 99% of our
  controllers follow the object pattern
2022-08-12 10:16:01 +02:00
Djordje Vlaisavljevic
0f0d21e074 Updated font weight
refs https://github.com/TryGhost/Team/issues/1724
2022-08-12 09:44:33 +02:00
Daniel Lockyer
5f514a7d1b
Improved functionality of yarn setup
- we need to initialize the submodules in case they weren't done when
  cloning, otherwise Casper will be missing
- we can avoid doing an initial build because it'll get wiped when we do
  `yarn dev` anyway
2022-08-12 09:36:48 +02:00
renovate[bot]
ea39ee3269 Update dependency @tryghost/logging to v2.2.4 2022-08-11 20:13:21 +02:00
Fabien 'egg' O'Carroll
ae8cd7c0f4
Fixed comment replies limiting (#15217)
The limit applies to the replies relation is applies globally when
fetching a collection, which means only 3 replies in total will be
fetched across all comments.

This patches the findPage method to manually fetch the replies and
replies adjacent relations manually on each comment, applying the limit
on a comment-by-comment basis.

This is not optimised as we currently still make the initial request for
relations.
2022-08-11 17:58:43 +01:00
Djordje Vlaisavljevic
a0ce5b4b7e Updated spacing
refs https://github.com/TryGhost/Team/issues/1726
2022-08-11 18:38:03 +02:00
renovate[bot]
9b7604b999 Update sentry-javascript monorepo to v7.10.0 2022-08-11 18:03:48 +02:00
Daniel Lockyer
537714cb6c Moved API documentation to api-framework README
- it's better suited here given this package is now the API framework
2022-08-11 17:44:59 +02:00
Daniel Lockyer
348924d431 Updated API framework debug and test names
- these tests have moved from `core/` so the names are no longer
  relevant
2022-08-11 17:44:59 +02:00
Daniel Lockyer
687e68d5de Extracted shared API framework to separate package
refs https://github.com/TryGhost/Toolbox/issues/363

- this API framework is standalone and should be pulled out into a
  separate package so we can define its boundaries more clearly, and
  promote better testing of smaller parts
2022-08-11 17:44:59 +02:00
Daniel Lockyer
9aa5eab5ed Fixed internal shared framework requires
- these requires go outside of the shared folder, and then back in to
  the index.js
- this is confusing and won't work when we pull this code out of core
- this commit cleans up the requires to make them more explicit
2022-08-11 17:44:59 +02:00
Daniel Lockyer
dc0cec56ea Moved settings mappers from shared frame to endpoints
- I'm still not sure where these are meant to be but they don't really
  belong in shared and I'm about to pull that folder out into a separate
  package
2022-08-11 17:44:59 +02:00
Djordje Vlaisavljevic
8daa4afc34 Updated tier preview price terms design
refs https://github.com/TryGhost/Team/issues/1726
2022-08-11 17:13:36 +02:00
Djordje Vlaisavljevic
49abd41af8 Updated button group design
refs https://github.com/TryGhost/Team/issues/1726
2022-08-11 17:06:12 +02:00
Daniel Lockyer
7d52ae52cf Deleted concept of external user
refs https://github.com/TryGhost/Toolbox/issues/363

- AFAICT, this is an outdated and unused concept from when subscribers
  were a thing, but members are now how we do things, and this is causing code
  to linger around that we don't need
2022-08-11 16:05:00 +02:00
Daniel Lockyer
120dee86b3
Refactored permissions.canThis to class structure
- updates the file to modern classes given that Ghost/Node supports them
2022-08-11 15:35:56 +02:00
Djordje Vlaisavljevic
28a69ec5c6 Switched word to lowercase
refs https://github.com/TryGhost/Team/issues/1726
2022-08-11 14:30:22 +02:00
Djordje Vlaisavljevic
2a8c414717 Revert "Switched word to lowercase"
This reverts commit fd69f7fbcc.
2022-08-11 14:27:10 +02:00
Djordje Vlaisavljevic
fd69f7fbcc Switched word to lowercase
refs https://github.com/TryGhost/Team/issues/1726
2022-08-11 14:19:58 +02:00
Daniel Lockyer
42e722d627
Moved Cache-Control middleware to separate package
refs https://github.com/TryGhost/Toolbox/issues/363

- this middleware is standalone and I suspect we're going to be touching
  it further when we work on Ghost's caching in the near future
2022-08-11 14:14:20 +02:00
Rishabh
18cd104510 Updated default trial days on new offer
refs https://github.com/TryGhost/Team/issues/1726

- updates default trial days to 7 for new offers
2022-08-11 17:40:56 +05:30
Rishabh
ae7f39168b Refined member free trial details for canceled subs
refs https://github.com/TryGhost/Team/issues/1726

- shows canceled info for free trial subscriptions on member detail page
2022-08-11 15:47:39 +05:30
Daniel Lockyer
6fc4aa8c4b
Reworked testing and documentation for email-analytics-provider-mailgun
- the tests here were no longer relevant because they were more testing
  things that have been moved to `mailgun-client`
- this commit cleans up the tests to ensure we're passing the correct
  parameters to the mailgun client package
- also adds jsdoc on all the functions and maintains 100% code coverage
2022-08-11 10:30:12 +02:00