Commit Graph

29385 Commits

Author SHA1 Message Date
Daniel Lockyer
b226b03f09
Renamed Audit Log to History
refs https://github.com/TryGhost/Toolbox/issues/356

- this commit updates the route to `/settings/history` and moves all the
  files to their new name so we can avoid further cleanup down the line
2022-09-06 11:49:29 +01:00
Daniel Lockyer
a3abb60395
Updated master branch links to main
- we switched the branch names a while back but these were never updated
2022-09-06 11:49:29 +01:00
Naz
920a3aeb4c
Fixed adapter-related unit test
refs 37dd187fe6
refs c36575627d/ghost/core/core/server/data/importer/handlers/image.js (L16)

- The tests were failing because they were stubbing a "generic" adapter, instead of the one which the module under test was using (see referenced code to see what I mean)
2022-09-06 18:46:32 +08:00
Naz
c36575627d
Fixed unit test
refs 37dd187fe6

- The referenced commit lacked cleanup after module removal
2022-09-06 18:11:22 +08:00
Ronald Langeveld
dac3fff90f
🐛 Fixed incorrect member count on sidebar (#15330)
refshttps://github.com/TryGhost/Team/issues/1738

- Changed sidebar member count to use new API endpoint data.
- Added separate function for getting member count.
- changed `_fetchCountsTask` to use new `/stats/member_count/` endpoint
- updated @task to calculate total members from endpoint data.
2022-09-06 12:08:16 +02:00
Naz
d0c45cbe9e
Increased adapter manager test coverage
refs https://github.com/TryGhost/Toolbox/issues/384

- Boyscouting while having the context loaded. Getting to those 100% coverages one day!
2022-09-06 17:51:57 +08:00
Naz
a96a7340c0
Added JSDoc to adapter options resolver
refs https://github.com/TryGhost/Toolbox/issues/384

- Added jsdoc for intellisence/typechecking
- Cleaned up the naming of returned values to resemble the usecases a bit better
2022-09-06 17:51:57 +08:00
Naz
28791bd6bf
Fixed typo 2022-09-06 17:51:57 +08:00
Naz
67df9a6105
Removed unused adapterType variable
refs https://github.com/TryGhost/Toolbox/issues/384

- The adapter manager can parse the adapter type internally from the "type:feature" syntax, so there's no need to pass it around.
2022-09-06 17:51:57 +08:00
Naz
1fc8c8d671
Added more explicit adapter config syntax
refs https://github.com/TryGhost/Toolbox/issues/384

- Existing adapter config was based on the notion there can only be one configuration per one adapter class. With adapter cache now allowing instantiating multiple adapter instances with the same base class it opened up a possibility to have shared configuration for a base class and then extend/override it in "feature" configurations (see tests in this commit for specific examples)
2022-09-06 17:51:57 +08:00
Naz
37dd187fe6
Added adapter caching based on features
refs https://github.com/TryGhost/Toolbox/issues/384

- Adapter cache was not able to store multiple object instances derived from same Base class. This created a need to create boilerplate "shell" classes inheriting from the Base class, e.g.: ImageSizeCacheSyncInMemory etc.
- Having feature-based adapter instance caching in the adapter manager allows to simplify configuration and reuse the "base class" instead of creating artificial "shell" classes.
- For example with this change both image sizes and settings caches will create separate cache instances deriving from default "Memory" class. Less code, less configuration!
2022-09-06 17:51:57 +08:00
Naz
0f86a05ed4
Added ":" syntax to adapter manager
refs https://github.com/TryGhost/Toolbox/issues/384

- The syntax using a colon ":" separator has been successfully used to enable multiple adapters. The adapter manager can benefit from same convention to enable more elastic adapter cache - have multiple instances of adapters from same base class
2022-09-06 17:51:57 +08:00
Naz
2f2033e7c5
Improved adapter manager JSDoc
refs https://github.com/TryGhost/Toolbox/issues/384

- The config is an optional parameter as not all class constructors necessarily have have to have configuration values
2022-09-06 17:51:57 +08:00
Naz
a0d0c38aaf
Fixed typo complementary -> complimentary 2022-09-06 17:51:56 +08:00
Peter Zimon
ca8bfc397c Fixed linting error 2022-09-06 11:25:54 +02:00
Hakim Razalan
2ffd76b994
🐛 Fixed archived tiers appearing in Portal Links UI (#15351)
closes #15293

- added additional active:true filter to tier fetching query to filter only get paid and active tiers.
2022-09-06 10:25:19 +01:00
Hannah Wolfe
db6fb2d6d0
Removed unused fixture tasks
- these old concepts aren't used anymore
2022-09-06 10:18:55 +01:00
Peter Zimon
cb644b3fd7 Restructured Audit log IA
refs. https://github.com/TryGhost/Toolbox/issues/356

- renamed page to “History” now to make it less technical
- moved the history page out to the Advanced section in Settings to increase discoverability
- moved the About section from General settings to a modal because that technical data was not connected to General settings
2022-09-06 11:18:07 +02:00
Daniel Lockyer
e0f86cb1cb
Merged v5.13.1 into main
v5.13.1
2022-09-06 10:12:54 +01:00
Ghost CI
da1997d96e v5.13.1 2022-09-06 09:53:23 +01:00
Rishabh
a8368a261c 🐛 Fixed paid subscription alert showing incorrect offer amount
closes https://github.com/TryGhost/Team/issues/1876

- the offer portion of new paid subscription alert was showing the wrong amount as the value is denoted in cents and needs conversion
- the value shown was 100x as the actual amount needs to be transformed (X/100)
2022-09-06 14:04:21 +05:30
Daniel Lockyer
79368f565f
Fixed Tier events being created when Posts are edited
refs https://github.com/TryGhost/Team/issues/1875

- due to an misbehavior in our model layer, when `tiers` is set on a Post, it'll
  trigger a save of the Tier, and this produces an extra event in the
  `actions` table
- mapping the Tier(s) to just the ID prevents bookshelf-relations from
  editing the Tier and thus prevents the extra event
- also fixed tests which were implicitly assuming supplying a slug to a
  post would create the product
2022-09-05 17:19:27 +01:00
Peter Zimon
a27342c8ae Added link to membership for tiers in Audit log
refs. https://github.com/TryGhost/Toolbox/issues/356

- link to Membership settings was missing for tier related events
2022-09-05 16:20:26 +02:00
Peter Zimon
5a83b77202 Updated copy in Audit log
refs. https://github.com/TryGhost/Toolbox/issues/356

- the term 'products' was used in the Audit log list which was inconsistent with the rest of the UI ('tiers')
2022-09-05 16:09:10 +02:00
Peter Zimon
0e156d2d68 Refined Audit log
refs. https://github.com/TryGhost/Toolbox/issues/356

- member label was too granular and small piece of information to justify a complete "Member" category, so we ignored to fetch the member label related events for now and removed the "Member" category from the filter list
- the term "users" wasn't consistent with the rest of the UI, changed it to "staff"
2022-09-05 16:01:36 +02:00
Daniel Lockyer
064e91fb2d
Added pull_request event type to label actions workflow triggers
refs https://github.com/TryGhost/Toolbox/issues/381

- we want to start collecting events from pull requests so we can label
  and reply upon certain events
- this adds the `closed` and `labeled` events to the workflow triggers
2022-09-05 11:53:46 +01:00
renovate[bot]
167f2d577a
Update dependency ember-concurrency to v2.3.4 (#15357)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-05 10:56:21 +01:00
Daniel Lockyer
75ec41cbe2 Fixed typo in CI workflow if-statement
- apparently I should only use single quotes here?
2022-09-05 10:15:44 +01:00
Daniel Lockyer
6f5dbf7820
Fixed submitting multiple coverage reports per test run
refs https://github.com/TryGhost/Toolbox/issues/395

- I think we regressed somewhere along the line here, but we seem to be
  submitting two test coverage reports for the Admin tests and the unit
  tests
- I'm not sure if this fixes the random issues we've been seeing with
  -5%/+14% coverage bumps but it should clean this issue up first
2022-09-05 10:06:12 +01:00
Hannah Wolfe
f1bc8026b7
Removed unused resetRoles method
- working on cleaning up our fixture mechanism and making it easier to understand
2022-09-05 09:32:54 +01:00
renovate[bot]
a967a8f930
Update metascraper to v5.30.4 2022-09-02 19:09:45 +00:00
Kevin Ansfield
034812ac02 Dropped use of @classic decorator in adapters
refs https://github.com/TryGhost/Ghost/issues/14101

- `@classic` decorator is not required on adapter classes
- small cleanup of Octane migration code
2022-09-02 19:14:40 +01:00
James Morris
4373369a51 Updated lint todo file 2022-09-02 19:05:13 +01:00
James Morris
dd65c99104 Made longer URLs scrollable on hover for Email CTA and Button modules in the editor
no issue
2022-09-02 18:39:41 +01:00
Sanne de Vries
f765b019c5 Updated lint todo file 2022-09-02 17:08:13 +01:00
Sanne de Vries
a2fc31aa0a Cleaned up icon styles
Refs https://www.notion.so/ghost/Unify-icons-across-Admin-7e3d124d5db34c63beccca029af595e7

- Reduced duplicate plus icons
- Replaced fill trash, info and pen icons by stroke icons
- Removed fill styles from default button classes
- Removed launch-wizard css
2022-09-02 16:56:02 +01:00
Peter Zimon
84854aa201 Fixed Header card letter spacing
no refs.

- after switching to Inter the letter spacing of header cards were too wide which caused the fake cursor to be blinking inside the placeholder
2022-09-02 17:35:52 +02:00
renovate[bot]
8c91f7b7d4 Update sentry-javascript monorepo to v7.12.1 2022-09-02 16:27:26 +01:00
Ghost CI
27704794d4 v5.13.0 2022-09-02 16:00:27 +01:00
Simon Backx
2e85ae98be
🐛 Fixed sending emails from email domain that includes www subdomain (#15348)
fixes https://github.com/TryGhost/Team/issues/1855
fixes https://github.com/TryGhost/Team/issues/1866

This commit moves all duplicate methods to get the support email address to a single location. Also methods to get the default email domain are moved.

For the location, I initially wanted to put it at the settings service. But that service doesn't feel like the right place. Instead I created a new settings helpers service. This service takes the settingsCache, urlUtils and config and calculates some special 'calculated' settings based on those:

- Support email methods
- Stripe (active) keys / stripe connected (also removed some duplicate code that calculated the keys in a couple of places)
- All the calculated settings are moved to the settings helpers

I'm not 100% confident in whether this is the right place to put the helpers. Suggestions are welcome.
2022-09-02 16:57:59 +02:00
Simon Backx
51ddc39fa7 Updated snapshots of email preview tests
refs dd2bfb8c0e
2022-09-02 16:19:28 +02:00
Daniel Lockyer
dd2bfb8c0e
Merged v5.12.4 into main
v5.12.4
2022-09-02 15:13:37 +01:00
Ghost CI
c02646b31d v5.12.4 2022-09-02 15:04:07 +01:00
Simon Backx
999b111fce
🐛 Fixed paid email preview stopped working in emails (#15356)
fixes https://github.com/TryGhost/Team/issues/1870

Disables email sanitization that was enabled earlier because this bug is more important and urgent.

The recently introduced email sanitzation removes HTML comments from the post html.
- This breaks the email paid preview, because it depends on the `<!--members-only-->` comment.
- Breaks the Outlook comments `<!--[if !mso !vml]-->`

This commit reverts this change.
2022-09-02 15:49:39 +02:00
Kevin Ansfield
0152eeb600 Added capture of product card image width/height
refs https://github.com/TryGhost/Team/issues/1873

- the code for storing the image width/height in the card payload was commented out
- uncommented and renamed to match the payload attr names
2022-09-02 14:44:37 +01:00
Sanne de Vries
594e2ccb08 Removed all launch-wizard related code
No issue

- With the onboarding flow redesign, the launch wizard can no longer be accessed and is therefore deleted.
2022-09-02 13:20:01 +01:00
Sanne de Vries
0b8b530efb Fixed invisible X icon on internal tags in PSM
No issue
2022-09-02 13:10:42 +01:00
renovate[bot]
49578f0661
Update dependency reframe.js to v4.0.1 (#15346)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-02 12:35:39 +01:00
Rishabh Garg
3751b22f18
Refined email alert templates for members (#15352)
- removed extra email field when name is missing
- updated initial to use first letter of email
2022-09-02 16:26:01 +05:30
James Morris
d5094fe235 Improved formatting of multiple authors for newsletters
- No longer showing all authors together, but using & others over 2

no issue
2022-09-02 11:48:30 +01:00