Commit Graph

68101 Commits

Author SHA1 Message Date
Mole
6668f3a867 V15: Add authorization to create (#18169)
* Add failing tests

* Re-add auth
2025-01-30 16:00:33 +01:00
Niels Lyngsø
c1f74f4aab Merge pull request #18094 from umbraco/v15/bugfix/offline-notifcation
Bugfix: show notification when offline
2025-01-30 14:51:53 +01:00
Jacob Overgaard
22d974e748 V15: Client should validate maxFileSize and allowed/disallowed file types from server configuration (#18163)
* feat: shows notification when no suitable media type is found

* chore: rearrange imports

* feat: use a forward ref to find the dropzone

* chore: rearrange imports

* chore(mock): send back correct header

* feat: avoid using the context consumer to get a token, but instead mimick the OpenAPI generator

* chore(mock): allow more file types

* chore(mock): create more upload fields

* chore(mock): also look for mediaPicker fields

* chore(mock): improve media mock db

* chore(mock): add missing endpoints

* chore(mock): update media data

* chore(mock): fix aliases for media grid and table

* chore(mock): add urls to media

* chore(mock): adds missing endpoint for imaging

* fix: reverse order of properties to overwrite existing status

* feat: listen to progress updates on upload and update the `progress` property

* feat: adds tracking of upload progress to placeholders

* feat: bind the progress number up on the temporary file badge to indicate upload status

* feat: optimises progress calculation and makes the badge bigger to be able to show the progress in percent

* feat: allow text to be normal

* chore: use correct localization

* feat: shows error status for anything that isn't waiting or complete

* feat: makes `progress` optional

* feat: adds repository+store for temporary file configuration

* chore(mock): adds mock endpoint for temporary file configuration

* feat: set progress for createTemporaryFiles

* feat: allows a `whitespace` option to notifications

* feat: validates uploads before trying to query the server

* feat: adds `formatBytes` function to format numbers

* chore: export all consts

* feat: exports bytes function

* feat: set decimals to default to 2, which works nicely with the Intl numberformat

* feat: use `formatBytes` to format the error message

* chore(mock): set max file size for mock to 1.4 GB

* feat: adds localization
2025-01-30 12:54:17 +00:00
Mole
1752be989d V15: Fix Url Preview (#18072)
* Make URL overview align with the old routing

This means including custom url providers, other URLS, etc.

* Move implementation to its own provider

* Handle could not get url

* Migrate intergration tests to new implementation
2025-01-29 13:59:58 +01:00
Jacob Overgaard
ab98ea58b5 V15: Show upload progress for dropped files in the Media Library (#18148)
* feat: shows notification when no suitable media type is found

* chore: rearrange imports

* feat: use a forward ref to find the dropzone

* chore: rearrange imports

* chore(mock): send back correct header

* feat: avoid using the context consumer to get a token, but instead mimick the OpenAPI generator

* chore(mock): allow more file types

* chore(mock): create more upload fields

* chore(mock): also look for mediaPicker fields

* chore(mock): improve media mock db

* chore(mock): add missing endpoints

* chore(mock): update media data

* chore(mock): fix aliases for media grid and table

* chore(mock): add urls to media

* chore(mock): adds missing endpoint for imaging

* fix: reverse order of properties to overwrite existing status

* feat: listen to progress updates on upload and update the `progress` property

* feat: adds tracking of upload progress to placeholders

* feat: bind the progress number up on the temporary file badge to indicate upload status

* feat: optimises progress calculation and makes the badge bigger to be able to show the progress in percent

* feat: allow text to be normal

* chore: use correct localization

* feat: shows error status for anything that isn't waiting or complete

* feat: makes `progress` optional
2025-01-29 11:02:29 +00:00
Andy Butland
bca74e0277 Pass user Id to audit when saving and deleting members. (#18120) 2025-01-29 10:14:34 +01:00
Mads Rasmussen
1e50714d1b Set document to readonly when a user is not allowed to create / update (#18076)
* split manifest file

* use const

* use const

* use const

* require permission to create or update to render save action

* require permission to update to render "save and preview"

* require permission to update + publish to render "save and publish"

* keep button as it is extendable

* keep buttons as they are extendable

* set readonly state based on user permission

* render readonly tag for invariant documents

* remove double array

* return permitted state in callback

* disable save button if all variants are read only

* rename private method

* split check on create vs update

* clear state when resetting the state

* add null check

* remove unused

* Update document-user-permission.condition.ts

* change translation to browse

* remove create permission
2025-01-29 09:06:58 +00:00
Mads Rasmussen
469fd14aff Bugfix: Content Picker Search - support allowed content types config (#18042)
* add option to interface

* pass config to picker

* add option to interface

* force type

* add request args to type

* pass allowed content types as request args

* add comments

* allow for passing type

* more type safety

* use correct types

* use correct types

* add js docs

* remove debugger + map to only pass id to server

* add js docs

* align naming

* add null check

* align types

* implement allowedContentTypes for member search

* fix imports

* add types for media search

* add and use const

* align picker interfaces

* align models

* add entity type

* filter for null value

* explicit naming

* rename field

* use query params

* Implement content type scoped search in item search controllers

* Fix bad naming

* generate server models

* wire up backend

* generate server models

* add selectable filter to member picker

* Update member-picker-modal.element.ts

* Fix indexed search for specific member and media types

* export consts

---------

Co-authored-by: kjac <kja@umbraco.dk>
2025-01-29 08:23:32 +00:00
Andy Butland
ad45494aa5 Fixes rollback of variant page name. (#18136) 2025-01-29 07:50:48 +01:00
Andy Butland
c8856bcf22 Obsolete unused configuration property. 2025-01-29 06:30:07 +01:00
Mads Rasmussen
675e9ab17f Merge branch 'v15/dev' into v15/bugfix/offline-notifcation 2025-01-28 18:32:30 +01:00
Mads Rasmussen
633cce5fd8 show online notification 2025-01-28 18:31:41 +01:00
Niels Lyngsø
f2b337a0be Merge pull request #18109 from umbraco/v15/bugfix/media-picker-mandatory-validation
Fix: media picker mandatory validation
2025-01-28 10:26:10 +01:00
Niels Lyngsø
c4ab3bd8e9 Merge pull request #18108 from umbraco/v15/bugfix/17372
Fix: Mandatory for Image Cropper (17372)
2025-01-28 10:13:41 +01:00
Andy Butland
f1e69dd16e Added a check that we have a route before attempting to include it in the other URLs for a published document. (#18135) 2025-01-28 10:10:08 +01:00
Jacob Overgaard
ea63d08989 V15: Media library crashes when uploading large files (#18113)
* chore(mock): adds endpoint handler for allowed media types

* feat: adds new event `UmbDropzoneSubmittedEvent`

* fix: do not await unnecessarily

* fix: simplify error checking

* fix: only proceed if array contains elements

* feat: adds support to render an error state

* fix: react to error state on temporary file badges

* fix: cancel events and simplify error check and react to any status changes

* feat: adds new tryXhrRequest function

* fix: use tryXhrRequest to upload all temporary files

* fix: use error types from hey-api as a temporary solution

* fix: changes limit from int32 to long (64-bit) to allow larger files to be uploaded

* fix: set default baseURL

* fix: use same unique

* fix: do not overwrite status

* fix: adds progress callback for tinymce

* generate openapi.json

* Revert "generate openapi.json"

This reverts commit 3c723e0155e571cb8db63d211c615617d11e38ba.

* Revert "fix: changes limit from int32 to long (64-bit) to allow larger files to be uploaded"

This reverts commit c883a455088207aae0c96910b6c1e610ee5c40f2.

* chore: generate OpenApi.json
2025-01-28 08:50:43 +00:00
Niels Lyngsø
f7f0891d3b remove nothing import 2025-01-28 09:26:07 +01:00
Niels Lyngsø
eeafb3cbc6 Merge pull request #18092 from umbraco/v15/feature/reject-validation-promise
Feature: Clean up validation messages
2025-01-28 09:23:03 +01:00
Niels Lyngsø
c72fa4866b Merge branch 'v15/dev' into v15/bugfix/media-picker-mandatory-validation 2025-01-28 09:14:29 +01:00
Niels Lyngsø
424eef4c93 fix min validation check + emptying cards 2025-01-28 08:50:35 +01:00
Andy Butland
151e0a89fb Refreshed display of check results after all checks are complete. 2025-01-28 08:45:42 +01:00
Niels Lyngsø
2755372f46 Merge branch 'v15/dev' into v15/bugfix/17372 2025-01-28 08:15:48 +01:00
Niels Lyngsø
677a8594df only check valueMissing if required 2025-01-28 08:15:07 +01:00
Lee Kelleher
d90002247d Feature: Tiptap: Generic markup support (#18124)
* Adds "HTML Global Attributes" Tiptap extension

This is to add `class`, `id` and `data-*` attributes
to any markup within Tiptap contents.

* Adds "Span" element Tiptap extension

to support generic markup modifications.

* Adds "Div" element Tiptap extension

to support generic markup modifications.

Also modifies "umbEmbeddedMedia" to check explicitly
for the `umb-embed-holder` class name. This is to differentiate
from the generic `div` tag.

* Adds "Rich Text Essentials" Tiptap extension

Previously this was a faux extension, but it is now real.

This extension adds the core extensions for Umbraco RTE support.
e.g. StarterKit, et al, and the new global attributes and generic elements.

* Reverts `elementName` constant
2025-01-27 12:29:44 +00:00
Mads Rasmussen
1e89b5a1e0 Bugfix: Align collection item entity actions with menu item entity actions (#18118) 2025-01-27 12:03:09 +01:00
Lee Kelleher
8f212aec3b Feature: Code Editor modal, adds pretty-print support (#18123)
* Reverts `elementName` constant

* Adds `formatOnLoad` option

* Code editor modal markup tidyup

* Wires up `formatOnLoad` with Tiptap's view-source action
2025-01-27 11:57:32 +01:00
jonat123
bc3881707e updated the link picker modal and the property editors using it. (#18059)
* updated the link picker modal and the property editors using it.

* updated the last language

* some minor updates to the code so that it uses the correct actions

* Minor change in the language key that is being used.

* use camel case

* use "add" and "update" without "link"

---------

Co-authored-by: Mads Rasmussen <madsr@hey.com>
2025-01-27 09:49:02 +00:00
jonat123
2648d17cb6 Updated the dialog label for User -> Assign Access -> Media Start nodes (#18043)
* Updated the dialog label User - Assign Access - Media Start nodes

* Minor change to the modal headline

* update based on review.

* updated the languages based on review

* updated based on review

* Small update based on review on PR

* use generic choose media for the media dialog

---------

Co-authored-by: Mads Rasmussen <madsr@hey.com>
2025-01-27 09:45:22 +00:00
Niels Lyngsø
380492145b remove sidebar padding bottom (#18087) 2025-01-24 22:35:17 +01:00
Niels Lyngsø
9c02fb419f implement with empty path instead of redirect (#18112) 2025-01-24 22:32:10 +01:00
Mads Rasmussen
55141df271 Update en.ts 2025-01-24 21:44:25 +01:00
Mole
c9758edfb1 V15: Add authorization to saves (#18111)
* Re-add authorization

* Add test plumbing

* Add test helper

* Add happy path test

* Remove usage of negation

* Minor DRYup of test code.

---------

Co-authored-by: Andy Butland <abutland73@gmail.com>
2025-01-24 13:45:56 +01:00
Niels Lyngsø
e6785d3223 media picker validation 2025-01-24 11:37:26 +01:00
Niels Lyngsø
c6c7d043dd implement focus for content picker 2025-01-24 11:37:11 +01:00
Niels Lyngsø
517f3c909c no need to set pristine cause it begin done by checkValidity 2025-01-24 11:37:00 +01:00
Niels Lyngsø
fb3609db0a allow for undefined 2025-01-24 11:36:40 +01:00
Niels Lyngsø
b8928bac0b fix observation controller instance property 2025-01-24 11:35:52 +01:00
Niels Lyngsø
4a6740bfd4 Merge branch 'v15/dev' into v15/bugfix/17372 2025-01-24 11:32:19 +01:00
Niels Lyngsø
c6f11ab4b2 implement validation for mandatory 2025-01-24 11:30:47 +01:00
jonat123
1d9704d8b1 Fixed wrong localization for button on image crops (#18106) 2025-01-24 09:51:23 +00:00
Andy Butland
1e5e9d4c24 Allowed retrieval of current user configuration when accessing user profile as a non-admin user (#18099)
* Allowed retrieval of current user configuration when accessing user profile as a non-admin user.

* Update src/Umbraco.Web.UI.Client/src/packages/user/user/repository/config/current-user-config.repository.ts

---------

Co-authored-by: Jacob Overgaard <752371+iOvergaard@users.noreply.github.com>
2025-01-24 09:41:03 +00:00
Niels Lyngsø
7b00033c42 Fix: 17764 (#18093)
* Add property value model type

* make the element a Form Control
2025-01-23 14:21:00 +00:00
Mads Rasmussen
1db821ffcb show notification when offline 2025-01-23 14:37:54 +01:00
Niels Lyngsø
ec508918d3 reject and clear messages 2025-01-23 14:36:26 +01:00
Nikolaj Geisle
776e7313d0 Merge branch 'release/15.2' into v15/dev 2025-01-23 11:08:50 +01:00
Niels Lyngsø
27aef0b435 fix test 2025-01-23 10:58:33 +01:00
Nikolaj Geisle
0562757114 Replace paths, so they are equal on every OS (#18071)
* Replace paths, so they are equal on every OS

* Don't use Path.Combine
2025-01-22 13:47:24 +01:00
Nikolaj Geisle
c847a111fe 15: Convert pagesize properly to skip and take (#18069)
* convert pagesize properly to skip and take

* Obsolete pagesize & pageIndex GetAll method
2025-01-22 10:39:26 +01:00
Andy Butland
98ff36b6a8 Validates and prevents save when providing a number outside of the configured range. (#17991)
* Validates and prevents save when providing a number outside of the configured range.

* Refactored to make use of `UmbFormControlMixin`

This flags the property layout container to be invalid (with prompt).
Adds localization keys.

* Corrected localization parameter order

---------

Co-authored-by: leekelleher <leekelleher@gmail.com>
2025-01-22 09:18:39 +00:00
Zeegaan
da07a24155 Don't treat warnings as error 2025-01-22 10:15:50 +01:00