Commit Graph

33376 Commits

Author SHA1 Message Date
Simon Backx
860048a89d Fixed snapshots 2023-03-22 17:03:11 +01:00
Simon Backx
46f305efaf Fixed hiding name if empty in email subscription box
no issue

Moved some CSS around because I moved the wrong code in the previous commit.
2023-03-22 16:51:56 +01:00
Simon Backx
55c281debf Reverted removeStyleTags from email-renderer
no issue

Some things break in some email clients with this new setting. Disabled it for now and moved the required css style to hide the member name row to @media all.
2023-03-22 16:40:35 +01:00
Simon Backx
24c5a45057 Added post excerpts to the latest posts email
refs https://github.com/TryGhost/Team/issues/2769

Truncates if it is too long (also for the title).
2023-03-22 16:11:08 +01:00
Sam Lord
661de46ae0 Fixed the reply-to address for newsletters in data generator
no issue

This makes it so that newsletters can be manipulated in Ghost Admin, otherwise Ember errors
2023-03-22 14:56:51 +00:00
Simon Backx
4eebf6612a Added image dimensions to the latest posts mobile version in email
fixes https://github.com/TryGhost/Team/issues/2799

Separate image dimensions for mobile and normal images.
2023-03-22 15:54:27 +01:00
Simon Backx
480c1a7004 Removed name from subscription details if missing
refs https://github.com/TryGhost/Team/issues/2736

If the name is not known for a member, we'll hide the name row in the subscription details in an email. This method is supported in most email clients, and requires the support of `<style>` in `<head>`.
2023-03-22 15:32:07 +01:00
Sanne de Vries
47e343ec18 Updated latest posts UI in email template
Refs https://github.com/TryGhost/Team/issues/2801
2023-03-22 15:16:55 +01:00
Simon Backx
b7361e2f1f Fixed email service test coverage for limitImageWidth
refs 74f25faf61

Changes weren't covered by unit tests.
2023-03-22 14:17:01 +01:00
Simon Backx
74f25faf61 Added restricted aspect ratio to latest posts in email
refs https://github.com/TryGhost/Team/issues/2799

Restricts aspect ratio of post feature images to 120x96, and crop them if needed for both Unsplash as local images.
2023-03-22 14:02:24 +01:00
Sam Lord
3718d4acda Enable labs in playwright tests
no issue

Allows us to write tests for features which are still in development.
2023-03-22 11:16:49 +00:00
Simon Backx
5058dc9d6c Added real dates in newsletter preview subscription box
refs https://github.com/TryGhost/Team/issues/2737

Show today date as member creation date, and today + 1 year for the expiry date in the example.
2023-03-22 11:56:50 +01:00
Sanne de Vries
58a973a215 Fixed latest post images not displaying in newsletter preview
Refs https://github.com/TryGhost/Team/issues/2768
2023-03-22 11:54:47 +01:00
Simon Backx
f17b939dbe Added name placeholder in subscription details box
refs https://github.com/TryGhost/Team/issues/2736

When the member doesn't have a name, we'll show 'not provided' for now.
2023-03-22 11:53:11 +01:00
Simon Backx
bc0126c54e
Added subscription status text in newsletters (#16442)
fixes https://github.com/TryGhost/Team/issues/2736

Shows the actual subscription status (expires on DD MMM YYYY) in every
email when show subscription details is enabled.
2023-03-22 11:52:41 +01:00
Sanne de Vries
c28b4c61d2 Added latest posts UI to newsletter preview
Refs https://github.com/TryGhost/Team/issues/2768
2023-03-22 11:06:08 +01:00
Sodbileg Gansukh
c3372f343a
Fixed Stripe connection modal button visibility (#16446)
closes https://github.com/TryGhost/Team/issues/2483

- the button is toggled depending on `stripeConnectIntegrationToken` which is a calculated value
- however, this calculated value isn't reset when Stripe is disconnected right away without closing the modal
- the reset action was already available and it's now passed to `StripeSettingsForm`, so that it can be called when Stripe is disconnected
2023-03-22 18:04:30 +08:00
Daniel Lockyer
559cfba648
Reduced coverage to accommodate Node 18 discrepancies
- it seems Node 18 produces slightly different coverage than other
  versions
- this commit lowers the coverage threshold until we build it up again
2023-03-22 09:59:55 +01:00
Daniel Lockyer
247163c710
Fixed tests for verification during batch sending
refs 59df99388c

- it seems the `getSignupEvents` method is now called twice during these
  tests
2023-03-22 09:44:01 +01:00
Sagar Gupta
7f92014c58 Added French (fr) translations
refs https://github.com/TryGhost/Team/issues/2795
- Used informal form ("tu")
2023-03-22 09:24:03 +01:00
Simon Backx
7c2b2d0f68
Added posts exporter implementation (#16467)
fixes https://github.com/TryGhost/Team/issues/2779
fixes https://github.com/TryGhost/Team/issues/2781

Needs some more manual testing, unit tests and E2E tests. But the
exporting is implemented and some columns are removed based on the site
settings.
2023-03-22 09:08:35 +01:00
Sodbileg Gansukh
818ea94e0e
Highlighted successful in the theme activation modal (#16454)
refs https://github.com/TryGhost/Team/issues/2713

- currently, it's not clear enough that if the theme activation was successful
- highlighting "successful" makes it easier to know the main action was successful even though there are errors to fix
2023-03-22 15:54:52 +08:00
Daniel Lockyer
eb5ed7dda8
Reformatted SUPPORTED_LOCALES array to new lines
refs https://github.com/TryGhost/Team/issues/2795

- this helps reduce conflicts when multiple PRs are coming in to add new
  languages
- I'd also like to enforce alphabetically sorted keys but I can't figure
  out the magic eslint incantation yet
2023-03-22 08:50:29 +01:00
Chris Raible
a5d3101ec9
🐛 Fixed broken editor breadcrumbs when opening a new post from analytics (#16463)
refs TryGhost/Team#2401

- Previously, if you opened a new post using the plus button on the sidebar while on a different post's analytics page, the breadcrumbs would point back to Analytics instead of the Posts list view. Going back to Analytics brought you back to the analytics page for the post you just created, which wasn't populating since it likely hadn't been published yet.
- This commit fixes the issue by setting fromAnalytics = false if transitioning to a new Post, even if the previous route was the analytics page.
2023-03-22 00:12:15 -07:00
Sodbileg Gansukh
91c4b3e53c Fixed broken favicon of some bookmark cards in emails
refs https://github.com/TryGhost/Team/issues/2617

- some sites have SVG favicons and it made bookmark card favicons look broken in some email clients as the SVG support is poor across email clients
- this fix simply hides the SVG favicons in emails
2023-03-22 13:41:43 +08:00
Sam Lord
59df99388c Made verification trigger depend on the number of members
no issue

This change makes the verification trigger behave closer to the original idea. As well as having a threshold to trigger email verification, the trigger should also rely on the number of "organic" / verified members. This means that large publications will not trigger the verification flow when they import members, but spammers / suspicious sites worth verifying will not have the organic member count to allow for larger imports.
2023-03-21 18:00:20 +00:00
Daniel Lockyer
6207766ce7
Migrated from nodemon to native Node --watch
fixes https://github.com/TryGhost/Toolbox/issues/493

- `nodemon` doesn't properly wait for graceful shutdown if there's a job
  running in Ghost when it tries to reload, so it ends up producing
  errors because two versions of Ghost are started
- Node 18 added a `--watch` flag, which reloads if any required file is
  changed
- switching from nodemon to this native feature should keep the
  core functionality the same but fix this edge case that disrupts the
  development flow
2023-03-21 15:57:41 +01:00
renovate[bot]
ca3ce032a4 Update sentry-javascript monorepo to v7.44.2 2023-03-21 15:10:15 +01:00
Aileen Nowak
b374bd4b94 Added user notification toggle for Milestone emails
refs https://www.notion.so/ghost/Marketing-Milestone-email-campaigns-1d2c9dee3cfa4029863edb16092ad5c4?pvs=4

- Added a toggle to disable and enable receiving Milestone emails behind a feature flag
2023-03-21 15:41:32 +02:00
Aileen Booker
8d290c4560
Milestone emails templates and sending implementation (#16318)
refs
https://www.notion.so/ghost/Marketing-Milestone-email-campaigns-1d2c9dee3cfa4029863edb16092ad5c4?pvs=4

- Added email template for milestones with using a configuration file
for different member milestone values, as we're sending different
content for each one
- Implement sending the email to users who have
`milestone-notifications` enabled, currently still behind a flag

Co-authored-by: Peter Zimon <peter.zimon@gmail.com>
2023-03-21 13:39:40 +00:00
renovate[bot]
be96c9d5d0
Update dependency i18next to v22.4.13 2023-03-21 10:46:44 +00:00
Sanne de Vries
792bfdb498 Added UI for subscription box in newsletters
Refs https://github.com/TryGhost/Team/issues/2738

- Added preview to email newsletter settings
- Added subscription box UI to email template
2023-03-21 11:40:04 +01:00
Rishabh
b8d79a850b Updated email subject copy for new mentions
refs https://github.com/TryGhost/Team/issues/2754

Updates email copy to be more descriptive and also avoid stacking in inbox.
2023-03-21 16:09:21 +05:30
Rishabh
0b7e09c986 Updated fallback for storing source site title
refs https://github.com/TryGhost/Team/issues/2754

Previously, we didn't have any backup for storing source site title and it could have stored as empty if missing. This change ensures the source site title is stored as site host instead as fallback if not present.
2023-03-21 16:09:21 +05:30
Rishabh
61a206c9eb Updated copy for mentions on Admin staff settings
refs https://github.com/TryGhost/Team/issues/2754
2023-03-21 16:09:21 +05:30
Rishabh
63edac090b Fixed incorrect usage of mentions report timestamp
refs https://github.com/TryGhost/Team/issues/2754

The name of the setting used for storing last timestamp of mentions report is `last_mentions_report_email_timestamp`, but in the code we incorrectly camel-cased it which meant we were not reading from and writing to the correct setting, and ended up sending a mentions report every few hours every time the job ran.
2023-03-21 16:09:21 +05:30
Simon Backx
a016f53b7e Added resolveMx stub to all E2E tests
refs https://ghost.slack.com/archives/C04TMVA1D7A/p1679391135060629
refs 1b0adcf4ab

The same issue when sending emails from E2E tests, where the tests timeout when resolving mx records for invalid domains.
2023-03-21 11:25:06 +01:00
Sodbileg Gansukh
9239fe497f Adjusted typography and spacing of the Stripe connect modal
refs https://github.com/TryGhost/Team/issues/2749
2023-03-21 17:48:37 +08:00
Simon Backx
db589b1ad4 Fixed random unit test failure for revue importer
refs https://github.com/TryGhost/Ghost/actions/runs/4477418718/jobs/7868921949

This test used the current time, and this resulted in a `AssertionError [ERR_ASSERTION]: '2023-03-21T09:28:29.837Z' == '2023-03-21T09:28:29.838Z'` in rare situations.
2023-03-21 10:46:13 +01:00
Simon Backx
0cc3164b25
Added export button to posts page with placeholder endpoint (#16456)
fixes https://github.com/TryGhost/Team/issues/2780 
refs https://github.com/TryGhost/Team/issues/2781

Adds an export button to the posts page in admin (behind feature flag). It downloads a
placeholder CSV via a real endpoint (`/posts/export`).
2023-03-21 10:24:56 +01:00
Daniel Lockyer
2096773310
Added missing @tryghost/posts-service dependency
- this is needed so we can link between packages in the monorepo when
  the packages are bundled
2023-03-21 08:24:25 +01:00
renovate[bot]
48e486509c Update dependency vite to v4.2.1 2023-03-21 07:36:34 +01:00
renovate[bot]
41e956fd55 Update vitest monorepo to v0.29.7 2023-03-21 07:36:13 +01:00
renovate[bot]
1f2df81ed1 Update sentry-javascript monorepo to v7.44.1 2023-03-21 07:35:45 +01:00
renovate[bot]
e1fa8560d5 Update dependency fs-extra to v11.1.1 2023-03-21 07:35:30 +01:00
Daniel Lockyer
0ec539f084
Switched browser tests back to standard CI machines
- these larger machines aren't giving us much benefit and cost more
  money, so we're better off with the standard machines right now
2023-03-20 21:34:18 +01:00
Simon Backx
a5dff4207e Moved posts service to its own package
fixes https://github.com/TryGhost/Team/issues/2778

It is easier to add extra classes using the latest patterns if it has its own package.
2023-03-20 16:06:42 +01:00
Elena Baidakova
aca8c5805c Improved members-actions e2e browser test
refs TryGhost/Team#2667
- Added notification check before checking that user successfully unsubscribed from all newsletters. It helps to make the test more stable
2023-03-20 18:48:35 +04:00
Simon Backx
07ec33fb3a
Added latest posts to email template (#16448)
refs https://github.com/TryGhost/Team/issues/2769

Needs some extra styling and design, this is only a minimal version
behind the feature flag.
2023-03-20 14:30:42 +01:00
Simon Backx
6d8388c5bb Fixed migration version for show latest posts
no issue

The migration was added to 5.39, but this was not correct. It should have been added to 5.40. This commit fixes moves the migration to the right folder. Running the migration twice locally will skip it because it detects the table is already correct.
2023-03-20 14:18:30 +01:00