* Adds `preview.js`
to replace the legacy `umbraco.websitepreview.min.js` script.
Updates the content's `Id` with `Key`.
* allow any protected route to render the backoffice
* optimise component so it doesn't need to observe its attributes and use the popover API to show it on top of the content
* handle case where the culture could be set to "invariant" - we just want to set the "lang" attribute to the default ui language
* convert 'end preview' into an api request and reset the style of the button
* minimize function
* move static text into constants
---------
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
* AB40660 - untangle the preview cookie from the auth cookie
* Clean up
* Allow anonymous to end preview sessions
* Some refinements
* update OpenApi.json
* Fix enter preview test
* correct tests to match new expectations of the preview cookie
* sync preview tests with correct expectations of access level
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
* Working import/export media/document types
* WIP
* Refactoring of import doctype/media types
- added analyze endpoint to extract relevant data without fully processing the file
- split up import endpoints into POST & PUT
- removed availableAtAction as the new endpoint allows clients to call the POST/PUT endpoints with confidence
- Added a new service that is responsible for turning temp files into Import compatible XML and being able to extracty partial information from it
* Wrap persistance access in scopes
* Typos, formatting, clean-up
* PR feedback
* update openapi spec
* Changed deleteFile flag to _temporaryFileService.EnlistDeleteIfScopeCompletes
* Itty bitty typo
* Moved magic cleanup into its own method so orchestration can decide when.
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: kjac <kja@umbraco.dk>
* Sends GUID instead of the numeric ID for SignalR Preview Hub
* Add possibility to set cookies as HttpOnly
* Set UMB_PREVIEW cookie as HttpOnly
* fixup! Add possibility to set cookies as HttpOnly
* Refactor ContentFinderByIdPath to more readable
* Create ContentFinderByKeyPath reusing logic from ContentFinderByIdPath
* Add a comment to DisableFindContentByIdPath setting
* Append new content finder
* Change ordering of content finders registrations
* Refactor with a base class
* Update/refactor and add tests regarding ContentFindersByIdentifier
* Fix comment
* Avoiding breaking change
* Make usages use non-obsolete implementation
* Fixed todo in config instead of use the one old legacy name even more. Also obsoleted the ContentFinderByIdPath
* add `preview` as an allowed backoffice client route
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Bjarke Berg <mail@bergmania.dk>
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
* Refactor user group endpoints to use reference by id models instead
* Update user endpoints to use reference by id models
* Update usergroup ids to ReferenceByIdModel
* Added endpoint and backing service for backoffice login providers and the status per user.
* Improve link login redirect forming and error handling
* Add responseModel and mapping instead of returning core model
* Moved unlink endpoint logic into a service
* Refactored ExternalLinkLoginCallback logic into BackofficeExternalLoginService method
* typo and minor code style improvements
* async method name alignment
* Add BackOfficeExternalLoginService tests
* Remove helper method that makes less sense that thought.
* Minor formatting, clean-up and conventions
* Replaced cookie authentication in link-login with a short lived secret
Applied PR feedback
* Update openapi
* Changed link login to a form endpoint
* fix broken comment link
* Do not store claimsprinciple in secret + comments
* update redirect paths
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: kjac <kja@umbraco.dk>
Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
* handle 403 and unknown error codes from the server
* resolve 2fa errors in repository
error handling was never being activated because this specific endpoint did not return api errors as it works exactly like the "authorize" endpoint, which is being called directly
* chore: add obsolete message to unused `SetupViewPath`
* chore: remove unused events
* add missing labels
* fix: send only 'error' back if the response is not ok
* chore: remove duplicate error handling for 500 errors
* fix: add hack to allow to submit the form on enter click
* Allow FileUpload and Imagecropper to upload files in the same way
* Fixed issue with backward compatibility
* Exclude from converter
* Bugfix if editorvalue is not a string
* Fix file upload value editor + clean up + throw explicitly if editor value is invalid
* Revert changes to FileUploadPropertyEditor - the stored property data format remains the file path
* Actually revert all changes to FileUploadPropertyEditor
* Also revert JsonValueConverter
* Cleanup remove unused equality methods
---------
Co-authored-by: kjac <kja@umbraco.dk>
* Revert "v14: Remove mentions of UmbracoApiController (#15863)"
This reverts commit 30e2dea57a.
* Obsolete UmbracoApiController
* Added a few more obsoletion messages
* Removed some of the reintroduced stuff again
* Add obsoletion to FrontEndRoutes controller
---------
Co-authored-by: kjac <kja@umbraco.dk>
* Use Attempt<string> result to display the unhealthy error message
* Update OpenApi.json
* Code readability improvements
* Add unittest covering the bug
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>
* bump from es2020 to es2022 for better javascript support
* remove the hardcoded "paths" in tsconfig and replace with the backoffice package
* import uui-css to have styling on the dev server
* change endpoint mock url
* cleanup unused code
* Move audit log endpoints to their respective silos and clean up
* Fix failing integration tests
* Using DateTimeOffset in management api and new methods in service layer
---------
Co-authored-by: kjac <kja@umbraco.dk>
* Added missing alias and Id to usergroup models
create/update/response/item
* Changed userGroup IsSystemGroup to more meaningfull fields
Also enforced the AliasCanBeChanged businessrule 🙈
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Mads Rasmussen <madsr@hey.com>
* Amend user start node handling
* Add "has root access" to current user endpoint
* Add document and media root access to user response model
* Update OpenApi.json
* Applied API suggestions
---------
Co-authored-by: Sven Geusens <sge@umbraco.dk>