Commit Graph

34422 Commits

Author SHA1 Message Date
renovate[bot]
c2e0514665 Update dependency vitest to v0.31.3 2023-06-01 11:09:06 +02:00
renovate[bot]
70960f27f6 Update dependency concurrently to v8.1.0 2023-06-01 11:08:55 +02:00
Rishabh
4883d73a0f Updated API service for admin-x
refs https://github.com/TryGhost/Team/issues/3151

The api service in admin-x was using hardcoded `x-ghost-version` as we did not have access to version value in the app so far. This change passes the ghost version from ember Admin app to Settings-X app via props, and refactors the api util to use the app version as a common header.

- Adds new services provider to pass common services for the app
- passes API as a service via context for the App
- refactors existing API usage to use api from context
2023-06-01 14:32:38 +05:30
Rishabh
667a673415 Added file upload component to admin-x
refs https://github.com/TryGhost/Team/issues/3318

- adds new file upload API
- adds new global file upload component with storybook
2023-06-01 14:32:38 +05:30
Simon Backx
92ca75eb5d Decreased required functions coverage for integration CI tests to 47%
no issue

Previous commits dropped coverage to below 48% on Node 16.
2023-06-01 10:45:21 +02:00
Simon Backx
a2a79cec0e Added support for yarn dev --signup
no issue

Added support for `--signup` to `yarn dev`. This will make sure that the signup form preview server is served (with rebuilding) and can be used in admin (instead of using the published version). This is also automatically started when using `yarn dev --all`, but with a twist:

If you only run `yarn dev --all`, it will only build and watch the production build of the signup form. If you use `yarn dev --signup` or `yarn dev --all --signup` it will also serve the demo app on `http://localhost:6173`.
2023-06-01 10:20:37 +02:00
Simon Backx
7e27d3f3e8
Added signup form attribution (#16899)
fixes https://github.com/TryGhost/Team/issues/3331

This adds attribution tracking to the signup form. It sends a newly
created url history when sending the signup API call, this url history
will get translated to a proper attribution and saved on the backend. We
send a history with only a single item that contains the referrer
source, medium and path of the Embed form.

This also makes some changes to the E2E tests so that the tests run
in an https environment instead of about:blank.
2023-06-01 10:18:11 +02:00
Naz
e8220b1387
Added DEL /collections/:id/posts/:post_id to Admin API
refs https://github.com/TryGhost/Team/issues/3260

- We need a way to remove posts form collections without fetching the whole collection's content. This API method allows to remove posts from manual collections by collection id and post id.
- As a response it returns up to date collection state without the removed post.
2023-06-01 14:59:05 +07:00
renovate[bot]
2edaf2c42c Update dependency vitest to v0.31.2 2023-06-01 09:44:15 +02:00
Naz
253f144501 Fixed fromDTO collection mapping
refs https://github.com/TryGhost/Team/issues/3260

- Whenever properties of the DTO are undefined they should be removed to avoid unintentional empty assignments to the stored collection
2023-06-01 14:25:49 +07:00
Naz
a0a7c3a61b Added coverage to all editable collection properties
refs https://github.com/TryGhost/Team/issues/3260

- Made sure we have sufficient coverage for all editable properties of the collection to avoid sneaky bugs
2023-06-01 14:25:49 +07:00
Naz
5d16425428 Fixed description editing in collections service
refs https://github.com/TryGhost/Team/issues/3260

- Fixed broken functionality after a refactor
2023-06-01 14:25:49 +07:00
Fabien "egg" O'Carroll
93bad82a24 Wired up adding post to collections to API 2023-06-01 14:25:49 +07:00
Fabien "egg" O'Carroll
b48a1d0a57 Implemented adding posts to collections; 2023-06-01 14:25:49 +07:00
Fabien "egg" O'Carroll
bd4fac451c Update CollectionsService to remove CollectionPost usage 2023-06-01 14:25:49 +07:00
Fabien "egg" O'Carroll
27f60b4ab5 Added logic for adding posts to collection
Also removes concept of CollectionPost in an effort to simplify the structure
2023-06-01 14:25:49 +07:00
Fabien "egg" O'Carroll
917ab0a79e Added CollectionRepository
This defines the interface required by the CollectionsService
2023-06-01 14:25:49 +07:00
Fabien "egg" O'Carroll
5282c4a72b Update eslint and c8 to support using TS interfaces
This will allow us to define the repository interface
2023-06-01 14:25:49 +07:00
Naz
a0c36e16d0 Added "addPost" method do collections module
refs https://github.com/TryGhost/Team/issues/3260

- The method allows to append individual posts to the collection
2023-06-01 14:25:49 +07:00
Naz
bf5becfb22 Added POST /collections/:id/posts to Admin API
refs https://github.com/TryGhost/Team/issues/3260

- We need a way to append posts to collections without sending over all of the posts that are already in the collection
- The API would receive post_id and collection_id as required fields and will optionally take in sort_order to control the ordering in the manual collection
2023-06-01 14:25:49 +07:00
Sodbileg Gansukh
116e09af95 Show the mobile nav only when logged in
closes https://github.com/TryGhost/Team/issues/3134

- the mobile nav was showing for 404 pages when not logged in
- this adds an additional check, so that the nav is only shown when user is logged in, not only when the user is not contributor
2023-06-01 15:23:47 +08:00
Chris Raible
c0b3aab4f2
Removed postHistory flag and updated post history logic (#16908)
no issue

- Removed the postHistory flag from labs
- Post History will be saved and displayed for all lexical posts,
regardless of whether the lexicalEditor flag is currently set
- Post History will still not be displayed for any mobiledoc posts
- With this change, the logic is simplified as we don't have to worry
about flags, but only the content in the given post (mobiledoc vs
lexical)
- If someone toggles the lexicalEditor flag on, creates a new post, then
toggles the lexicalEditor off, we still want Post History to work for
the existing lexical post
2023-05-31 23:45:29 -07:00
Daniel Lockyer
0833cfe872
Updated lockfile 2023-06-01 08:12:22 +02:00
Sodbileg Gansukh
e4415e9109 Fixed product card image stretching issue
refs https://github.com/TryGhost/Team/issues/3329

- product card images have explicit width and height attributes in the markup now, and the image needs auto height for that reason
- without it, the images will lose its original aspect ratio for themes without the auto height images
2023-06-01 12:10:13 +08:00
Sodbileg Gansukh
3ab851e3aa Optimized Inter in the Admin
closes https://github.com/TryGhost/Team/issues/3257

- replaces the TTF with WOFF2 which is more compressed version
- adds a font file for italic style specifically so that the italic text is rendered consistently across different browsers
2023-06-01 11:56:27 +08:00
Jono Mingard
c63b0e1a1a Fixed signup form e2e tests to check new colour options
refs https://github.com/TryGhost/Team/issues/3338
2023-06-01 14:55:03 +12:00
Jono Mingard
80b9030805 Updated signup form to support configuring background and button color
refs https://github.com/TryGhost/Team/issues/3338

* background and button color can be passed in the script tag dataset
* text color is calculated automatically from background/button color
2023-06-01 14:43:57 +12:00
Jono M
257d84a4b1
Added storybook to signup form (#16898)
refs https://github.com/TryGhost/Team/issues/3299
2023-06-01 11:22:43 +12:00
Djordje Vlaisavljevic
bbdb90f1d6 Updated feedback form copy
refs https://github.com/TryGhost/Team/issues/3264
2023-05-31 21:56:37 +01:00
Fabien 'egg' O'Carroll
32f4861176
Bumped eslint-plugin-ghost (#16906)
- This includes changes to support PascalCase filenames for interfaces
- Also bumps newer packages to use the latest version to avoid conflicts
with the underlying eslint-plugin-filenames package
2023-05-31 16:36:32 -04:00
Peter Zimon
04d68b2e47 Added static user invite dialog to AdminX
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 22:31:35 +02:00
Peter Zimon
c865ab00f4 Added static tabs for design settings in AdminX
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 22:30:03 +02:00
Rishabh
664f4ebedd Updated save sequence for settings group in admin-x
refs https://github.com/TryGhost/Team/issues/3151

- updated save sequence for setting groups where edit button is hidden by default
- shows `Saved` for couple of seconds before disappearing on saving such setting groups
- adds save sequence for default recipient setting group
2023-06-01 00:29:09 +05:30
Rishabh
9ca82490c2 Added save states for setting groups in admin-x
refs https://github.com/TryGhost/Team/issues/3151

- adds Save -> Saving -> Saved sequence to save buttons on all setting groups
- uses common hook state to manage state across all Settings
2023-05-31 22:03:35 +05:30
Rishabh
19b2112f8b Updated wiring for user detail modal in admin-x
refs https://github.com/TryGhost/Team/issues/3151

- updates role info for user details modal for owner user, hides option to change role for owner
- adds saving/saved state for user detail modal
- removes alerts from invite and detail modal
- adds wiring for remaining user detail modal settings
2023-05-31 22:03:35 +05:30
Naz
87df8754ee Moved bookshelf posts repository to core
refs https://github.com/TryGhost/Team/issues/3260

- Moved the posts bookshelf repository into core codebase where it should belong.
2023-05-31 22:55:35 +07:00
Naz
4fe9e5fac0 Added posts editing to collections in Admin API
refs https://github.com/TryGhost/Team/issues/3260

- Allows to manually manage posts assigned to collections through Collections Admin API
2023-05-31 22:55:35 +07:00
Naz
66d489b8b3 Added Posts relation support to collections package
refs https://github.com/TryGhost/Team/issues/3260

- Adds "posts" relation to Collection entity to manage posts belonging to the collection
2023-05-31 22:55:35 +07:00
Naz
c7954fa695 Refactored basic edit test case
refs https://github.com/TryGhost/Team/issues/3260

- We need to have a reusable collection to edit throughout the describe, so we don't do repeatable work over and over
2023-05-31 22:55:35 +07:00
Naz
988f7e69c2 Grouped edit collection test cases
refs https://github.com/TryGhost/Team/issues/3260

- Cleanup before adding more test cases to the suite
2023-05-31 22:55:35 +07:00
Peter Zimon
8c02d963c4 Fixed button interface bug
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 13:59:14 +02:00
Peter Zimon
13c629e6b3 Added static brand tab in AdminX Design settings
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 13:58:21 +02:00
Fabien 'egg' O'Carroll
8b85f936fc
Added static DropdownMenu component to Admin X DS (#16896)
refs https://github.com/TryGhost/Team/issues/3328

<!--
copilot:summary
-->
### <samp>🤖 Generated by Copilot at 8a276bc</samp>

This pull request adds a new DropdownMenu component to the admin-x-ds
global library. It also includes a storybook file to showcase the
component's usage and appearance.

---------

Co-authored-by: Djordje Vlaisavljevic <dzvlais@gmail.com>
2023-05-31 12:49:40 +01:00
Daniel Lockyer
d07a3177bf
Updated lockfile 2023-05-31 11:07:27 +02:00
Mysterious_Dev
84a0029101
Updated French translations (#16870)
refs https://github.com/TryGhost/Team/issues/2795
2023-05-31 11:06:33 +02:00
Ronald Langeveld
c53bd499c7
Added typescript declerations to i18n (#16894)
refs https://github.com/TryGhost/Team/issues/3307

Added TypeScript support and a new namespace for the `i18n` module. This
enables type checking and localisation for the new signup form component and future typescript projects that may need to add i18n support.
2023-05-31 10:37:21 +02:00
Peter Zimon
53ed8078ca Added desktop window chrome to design preview
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 09:59:01 +02:00
Gary Lai
ae7311e74f
Added Traditional Chinese translations (#16786)
refs https://github.com/TryGhost/Team/issues/2795
2023-05-31 09:52:42 +02:00
Peter Zimon
99798ad06b Added a backdrop blur to modals in AdminX
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 09:42:10 +02:00
Peter Zimon
f2f3e2a22d Added window chrome comp. to AdminX Design System
refs. https://github.com/TryGhost/Team/issues/3328
2023-05-31 09:36:50 +02:00