14487 Commits

Author SHA1 Message Date
HichamELBSI
24106a1c69 chore(admin): convert auditLogs page to TS 2023-12-13 11:49:05 +01:00
Josh
240feaeb04
refactor(admin): remove some contexts and use redux instead (#19040)
* refactor(admin): move to use slice over reducer

* refactor(admin): theme into redux

* refactor(admin): remove Admin context

* chore: move api tokens context to its edit view

* chore: move injection zones up to appropriate folders

we never use shared anyway.

* chore: move Configuration to single feature file

* refactor(admin): move language to redux

* chore: add tests for redux slice
2023-12-13 10:04:43 +00:00
Jamie Howard
0d8a6e7cd6
(content-manager): types for data mapper service (#18887) 2023-12-12 15:47:23 +00:00
Madhuri Sandbhor
17801215c6
Feat(blocks): move blocks (#18852)
* feat: updated useDragAndDrop hook to enable DND for blocks where path is not a number but number[], wrapped renderElement with Dnd component to have ability to move blocks around in editor

* fix: useDragandDrop hook updated to accept number[] for moving heirarchy of nodes, cmd/ctrl + shift + up/down arrow to move blocks around using keyboard, set live text on moving blocks for accessibility

* fix: when node is dragged downwards inside list convert it to list-item

* fix: index type updated

* style: margin added to preview block as droppable area needs some height to drop the item

* refactor: updated context, code optimisation, added necessary comments

* docs: updated use-drag-and-drop hook doc

* fix: type NonSelectorBlock

* Revert "fix: type NonSelectorBlock"

This reverts commit c3cb3c15442ba0008c650cbe38e993b0aa44817c.

* fix: block value type

* fix: type of onMoveItem() in useKeyboardDragAndDrop

* fix: selection issue resolved, ondragstart styling updated, grab cursor added back, missing comments added

* update: VisuallyHidden with aria-hidden attr added

* fix: minor fix

* update: link block dropped from dnd, test cases updated

* fix: if list node is empty after dragging remove it, drag handle aligned at the start

* update: link is inline block so skip wrapping dnd component

* Update: comment

Co-authored-by: Rémi de Juvigny <8087692+remidej@users.noreply.github.com>

* fix: types updated, disabled state managed for drag item

* update: IconButton is used for drag handler, refered getAttributesToClear from utils

* update: on drop blocks are moved, updated useDragAndDrop hook and related changes, instead of blue line showing border box around drop target for now

* update: canDrag, canDrop options removed, as its not required for onDropItem()

* fix: dragging is enabled only on drag button

* fix: quote block padding and margin reduced

* update: useDragAndDrop hook doc

* update: useDragAndDrop hook doc with onDropItem usage

* update: drop placeholder added

* fix: missing condition check added

* update: useDragAndDrop hook doc

* update: useDragAndDrop and useKeyboardDragAndDrop hook converted to TS, styling changes related to list and quote

* fix: types updated for useDragAndDrop hook, tooltip disabled for drag button

* fix: mock event typecasted as its not possible to add all required props for type event

* fix: deleted useDragAndDrop js file

* fix: drag handle is made visible on hover, hide on selection change

* fix: history undo

* fix: dragging block into list-item, drop item at right position

* fix: placeholder margin adjusted for list items

* fix: cloned drag item extracted

* fix: dragging list-item out of block downward

* chore: refactor dnd hook to use generics (#18994)

* fix: required block types exported, manual id creation replaced with useId

* update: drag handle top margin added for few headings

* fix: extended useDropAndDropOptions callback types, comments updated

* fix: drag handle top margin added for all required blocks, selection bug fixed

* fix: reordering between different list-items

---------

Co-authored-by: Rémi de Juvigny <8087692+remidej@users.noreply.github.com>
Co-authored-by: Josh <37798644+joshuaellis@users.noreply.github.com>
2023-12-12 15:51:37 +01:00
Josh
c8f63ff188
refactor(cm): remove collection-type form wrappers (#19036)
* refactor(cm): remove collection-type form wrappers

* fix: bad import in DeleteLink

* test(e2e): tweak url we expect to wait for
2023-12-12 14:22:47 +00:00
markkaylor
5bfbd8c659
refactor(content-releases): update findMany actions (#19006) 2023-12-12 10:43:39 +01:00
Alexandre Bodin
8bf56b0d72 chore(strapi/strapi): simplify code 2023-12-12 09:57:35 +01:00
Alexandre Bodin
495fe3fe78 chore(content-manager): update test and snapshot 2023-12-12 09:48:49 +01:00
Josh
d23325640d
chore(cm): convert list-view to TS (#19016)
* chore(cm): convert list-view to TS

* chore: fix broken tests

* chore: remove separate recursive paths and unify
2023-12-11 18:51:25 +00:00
Fernando Chávez
32d0c4f02d
feat(content-releases): Delete a Release (#19000)
* feat(content-releases): delete a release endpoint

* feat(content-releases): delete actions when deleting a release

* feat(content-releases): apply mark's feedback

* feat(content-releases): use transaction for delete a release
2023-12-11 19:03:53 +01:00
Alexandre BODIN
1b654d7f4f
Merge pull request #18927 from strapi/v5/core-split 2023-12-11 07:29:25 -08:00
Jean-Sébastien Herbaux
438091e28a
Merge pull request #19011 from strapi/fix/types/es-relation-input 2023-12-11 15:04:27 +01:00
Jamie Howard
1f94748146
fix: wrapAxiosInstance.test (#18382) 2023-12-11 12:23:15 +00:00
Jamie Howard
a8709d897e
[content-manager] types for metrics service (#19014) 2023-12-11 10:56:40 +00:00
Jamie Howard
748e479a5d
[content-manager] types for uid service (#18910) 2023-12-11 10:49:15 +00:00
Jamie Howard
6f2783dadd
[content-manager] types for permissions service (#19015) 2023-12-11 10:48:25 +00:00
Convly
01b53828d6 chore: rename mocks to literals for clarity 2023-12-11 11:40:16 +01:00
Josh
46e6ffbb44
feat(strapi): add experimental plugin init command (#18970) 2023-12-11 09:53:59 +00:00
Josh
626dc81cda Merge branch 'develop' into v5/main 2023-12-08 16:31:21 +00:00
Convly
af0176cf2e feat: add positional arguments to xMany relations, split attributes files 2023-12-08 17:03:39 +01:00
Mark Kaylor
24e6b11e8e Merge branch 'main' of github.com:strapi/strapi into feature/content-releases 2023-12-08 14:07:43 +01:00
Convly
e9c8c97196 chore: simplify the logic for relations' input 2023-12-08 11:21:16 +01:00
Convly
d74bbdbd7f fix: add support for relation reordering APIs and objects 2023-12-08 11:13:08 +01:00
markkaylor
6eaefa820c
feat(content-releases): list releases with content type entry (#18999) 2023-12-08 10:44:49 +01:00
Fernando Chávez
35f56a0444
feat(core): add feature flags (#18871)
Co-authored-by: Alexandre BODIN <alexandrebodin@users.noreply.github.com>
Co-authored-by: Josh <37798644+joshuaellis@users.noreply.github.com>
2023-12-08 09:19:31 +01:00
Alexandre Bodin
f0bbaa2bc9 chore: fix pkg json to make them yalc compat 2023-12-07 18:27:34 -08:00
Jamie Howard
40ef34cbcd
(content-manager): types for component service (#18869) 2023-12-07 11:58:14 +00:00
markkaylor
7ff846c468
feat(content-releases): add findManyForContentTypeEntry (#18976) 2023-12-07 10:28:45 +01:00
Fernando Chávez
1cab7003f9
feat(content-releases): publish a release (#18973)
* feat(content-releases): publish a release

* feat(content-releases): publish is enabled if you have releases publish permissions

* chore(content-releases): Mark's feedback

* Update packages/core/content-releases/server/src/services/release.ts

Co-authored-by: markkaylor <mark.kaylor@strapi.io>

---------

Co-authored-by: markkaylor <mark.kaylor@strapi.io>
2023-12-07 09:35:57 +01:00
Josh
8248335ad3 fix: use empty string for default id so we don't try to stringify undefined 2023-12-06 22:41:51 +01:00
Josh
a7b1360f24 fix(cm): export some types for building 2023-12-06 22:41:51 +01:00
HichamELBSI
59a6b3828b chore(admin): convert review workflows page to TS (fix feedback) 2023-12-06 22:41:51 +01:00
HichamELBSI
31c6013e13 chore(admin): convert review workflows page to TS 2023-12-06 22:41:51 +01:00
Josh
ac7ce4ebf2
chore(content-manager): convert cm app shell to TS (#18985) 2023-12-06 16:51:55 +00:00
Josh
e85a23d937
fix(permissions): circular dependency (#18986)
* fix(permissions): circular dependency

* Apply suggestions from code review

Co-authored-by: Ben Irvin <ben@innerdvations.com>

* Apply suggestions from code review

Co-authored-by: Jean-Sébastien Herbaux <jean-sebastien.herbaux@epitech.eu>

---------

Co-authored-by: Ben Irvin <ben@innerdvations.com>
Co-authored-by: Jean-Sébastien Herbaux <jean-sebastien.herbaux@epitech.eu>
2023-12-06 08:47:11 +00:00
Bassel Kanso
8e2421b559
Merge pull request #18966 from strapi/fix/deep-populate-dynamiczone
fix deep query populate issue on dynamic zone
2023-12-05 19:57:16 +02:00
Josh
295178369f
chore(cm): convert recursive layouts to TS (#18983) 2023-12-05 16:03:14 +00:00
Josh
327b3dcd83
fix(content-manager): add memoization to params object to stop recursion (#18982) 2023-12-05 15:29:09 +00:00
markkaylor
f803c8a5b6
feat(content-releases): add delete release action endpoint (#18943) 2023-12-05 11:00:29 +01:00
Jen Tak
5fc763775e
Register logger middleware before errors middleware (#16921)
In the examples and project templates the "errors" middleware which turn
thrown errors into HTTP responses is registered before the "logger"
middleware. This causes any errors thrown in controllers to pierce
through the logger middleware resulting in these requests not being
logged.

Eg. when a controller throws a ValidationError the resulting HTTP 400
request is not logged at all.

Change the order of middleware registration so that the logger is
'above' the errors middleware and has a chance to log *all* requests.

Co-authored-by: DMehaffy <derrickmehaffy@gmail.com>
2023-12-05 09:28:41 +01:00
Alexandre Bodin
25f085aafc Merge branch 'v5/main' into v5/core-split 2023-12-04 21:49:23 -08:00
Josh
f1dd5cc8ee
chore(content-manager): convert the editview to typescript (#18948) 2023-12-04 16:00:50 +00:00
Ben Irvin
24dabd281e
chore: update knex to 3.0.1 (#18936) 2023-12-04 16:17:10 +01:00
markkaylor
76f8b2fb15
feat(content-releases): add endpoint to update a release action (#18946) 2023-12-04 14:14:00 +01:00
Simone
b4936e04a9
feat(content-releases): Edit Release (#18956)
* first draft implementation edit release

* add dialog unit test

* add permission to the edit button

* add permissions type and remove old unit test

* add createAction to the PermissionMap

* fix type errors

* fix unit test

* fix lint error

* fix review comments

* change state naming

* change dialog to modal
2023-12-04 13:58:29 +01:00
Ben Irvin
c38881e08d
chore: update typescript to 5.3.2 (#18938) 2023-12-04 11:47:05 +01:00
Fernando Chávez
9b4c03b10b
chore(content-releases): Add entries to content-releases' actions (#18918)
* chore(content-releases): add entries to content releases actions

* chore(content-releases): add entries relation to findMany content-release's actions

* chore(content-releases): improve findOne with actions code

* chore(Content-releases): remi feedback

* chore(content-releases): fix getReleaseActions response type

* chore(content-releases): change findOne and findActions endpoints

* chore(content-releases): fix error in release's tests

* chore(content-releases): use queryBuilder from strapi.db

* chore(content-releases): use queryBuilder from strapi.db
2023-12-04 10:10:51 +01:00
Bassel Kanso
d58362aec0 fix deep query populate issue on dynamic zone 2023-12-01 12:43:12 +02:00
Alexandre Bodin
b373446907 Merge branch 'v5/main' into v5/core-split 2023-12-01 10:29:58 +01:00
Alexandre Bodin
83daf0117c Merge branch 'develop' into v5/main 2023-12-01 10:29:48 +01:00