* Support tree expansion in generic Duplicate To modal
* Add expansion prop to tree picker modal types
* Apply expansion from data to picker context
* move to action: populate tree picker expansion with ancestors
* Pass tree expansion to duplicate document modal
* Extract ancestor fetching into private method
* Use UmbDocumentTreeRepository directly
* Exclude self from ancestor results
* make name more explicit
* Guard ancestor fetch and simplify expansion
* Only set treeExpansion when ancestors exist
* fix type issues
* Parallelize ancestor and pickable filter fetch
* Use getter for treeExpansion; remove unused imports
* Ensure requests to fetch ancestors after retrieving search results are batched to avoid a single query exceeding the maximum URL length.
* Guard against undefined ancestor entries from a failed batch
batchTryExecute resolves each chunk via tryExecute, which never rejects, so
a per-chunk failure comes back as a fulfilled result carrying an error and
leaves an undefined hole in the amalgamated data without surfacing an error.
Detect that before mapping and return an explicit error instead of throwing.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Assert ancestor id uniqueness and silence direct-api lint rule
Strengthen the batching tests to assert every search-result id is requested
exactly once (Set size), not just that the total count matches. Add the
no-direct-api-import disable on the controller's api callback, matching the
existing url data sources, since the call is wrapped by the controller.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Addessed Codescene warnings.
---------
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Prevent empty domain cache during concurrent initialization.
* Addressed code review comments and added further comment to the code.
* Use Lock object.
* Include currently missing management API tests in the CI build.
* Fixed failing tests.
* Revert the pipeline updates.
* Addressed code review feedback.
* Delivery API: return inline {} schema for unconstrained property types
ContentTypeSchemaTransformer now checks the raw STJ schema via JsonSchemaExporter before
calling GetOrCreateSchemaAsync. STJ generates boolean true for unconstrained types (JsonNode,
object, types with custom converters), which the pipeline converts to {}. When the raw schema
is true, an inline {} is returned without registering a named component - a named component
adds no value and misleads API consumers into thinking a concrete model shape exists.
* Delivery API: add Plain JSON property to contract test sample types
Adds a Plain JSON property to the sample article page content type used by the OpenAPI contract
tests. This exercises the unconstrained-type fix: the property should appear as inline {} in the
schema, not as a named JsonNode component. Updates the expected contract to reflect the new
property.
* Re-generate typed-schemas-with-sample-types.json
For some reason the previous change got formatted differently, so it was displaying more changes than it should.
* Simplify comments
* Delivery API: guard unconstrained type check with JsonTypeInfoKind.None
* perf(tree): coalesce concurrent identical tree data requests
The tree data request manager hit the network on every call, so multiple
concurrent consumers (sidebar tree, breadcrumb structure, pickers) each
fetched the same data independently — e.g. three identical tree/document/root
requests per document-workspace load.
Apply the existing UmbManagementApiInFlightRequestCache (already used by the
item and detail request managers) to the tree request manager via a shared
static cache, coalescing concurrent identical root/children/ancestors/siblings
calls into a single in-flight request, cleared on settle (in-flight only, so
no stale-cache risk). The document tree opts in; other trees are unchanged
until they pass a cache.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* test(tree): cover request coalescing; address review feedback
- Add focused tests: concurrent identical root requests share one call,
the in-flight entry is cleared on settle, and no cache means no coalescing.
- Build the cache key lazily (only when a cache is wired) so non-opted-in
trees keep the original lightweight path.
- Constrain the #coalesce generic to drop the cast on cache.set.
- Document the new inflightRequestCache arg; trim the comment to one line.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Tolerate invalid data type configuration when getting the editor value storage type.
* Add logging in case of error.
* Resolve warning.
* Removed exception from warning (it's not useful).
* Log an error instead of a warning.
* Menu Structure: Guard against use-after-destroy in async structure request
When navigating to a trashed item, the IS_NOT_TRASHED condition initially
permits the standard menu structure context, which is then destroyed once the
workspace confirms the item is trashed. The in-flight async #requestStructure()
could resume after destruction and call setValue() on a completed subject,
throwing "_subject is undefined".
Guard the state mutations with the framework's existing _host-cleared-on-destroy
signal, and handle the previously fire-and-forget #requestStructure() promises so
a teardown mid-request is silently abandoned rather than surfacing as an uncaught
rejection. Applied to both the variant and non-variant menu structure base
contexts.
* Menu Structure: Make #requestStructure non-throwing instead of catching at call sites
Per PR review feedback: replace the blanket .catch(() => {}) wrappers with
early returns inside #requestStructure(). The _host guard already prevents
post-destroy state mutation; the throws only fire for can't-happen missing
observable states and were producing unhandled rejections with no caller
able to act on them.
* Added console warning, if the host is still available
* Block Grid: Guard validator against torn-down manager on navigation
The form-control mixin's updated() hook runs validators when the element
re-renders during teardown. If navigation has already disposed _manager,
checkBlockTypeConfigurationValidity would throw "Cannot read properties
of undefined (reading 'getContentTypeKeyOfContentKey')".
Early-return as valid when the manager is gone and use optional chaining
on the per-entry lookup as a safety net.
* Removed optional chaining of `_manager`
As `_manager` has already been checked.
* Reverting the `_manager` optional chaining
As TypeScript compiler doesn't like it, (inside the `filter` callback).
* Update uploaded media file name to a friendly name.
* Correct test description for acronym handling.
The case JUST-A-FILE.jpg verifies all-uppercase words are preserved
as acronyms, not that lowercase words get lowercased.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
* Match server-side StripFileExtension semantics in toFriendlyName.
The TypeScript helper previously delegated to getFileExtension, which
diverges from the C# StripFileExtension on two edge cases:
- a trailing dot ("file.") is stripped by the server but not the client
- an "extension" containing whitespace is preserved by the server but
stripped by the client
Inlined a stripFileExtension helper that mirrors the C# rules exactly,
making the "keep in sync" cross-reference accurate. Added tests for both
divergent cases and replaced the contrived leading/trailing whitespace
test with a realistic interior-whitespace case.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
* Add parity test for trailing-whitespace extension span.
Restores the ' spaced-name.jpg ' case as a parity test against
StripFileExtension's "extension containing whitespace is preserved"
rule. Output is 'Spaced Name.Jpg' (Jpg title-cased, matching the
server's TextInfo.ToTitleCase behaviour on the now-unstripped extension).
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
* Handle getContext rejection in ensureMediaNameFromFile.
getContext rejects on timeout when the dataset context never resolves;
callers used void ensureMediaNameFromFile(...) so an unhandled rejection
would bubble. Catch the rejection and treat it as an absent context.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
Disable OpenAPI XML documentation source generator
Due to the amount of XML documentation in this solution, the OpenAPI XML documentation source generator produces too many lines of code in a single method (GenerateCacheEntries), which causes a StackOverflowException when running on IIS. The fix disables the analyzer globally via Directory.Build.props.
* Creating notification objects and status
* Adjusting service and tracker to support cancelable notifications
* Adding Operation Status Results to base controller.
* Adding notification support to the delete controller.
* Integration tests
* Changes in accordance to CR
* Changes in accordance to code review
* Fixed further use of obsolete methods in tests.
* Added comment explaining why messages on create or update cancellation are suppressed.
---------
Co-authored-by: Andy Butland <abutland73@gmail.com>
* Added constant setting for element folder permission
* Added api helper for element folder
* Added api helper for user group with element folder permission
* Added ui helper for element folder permission in user group
* Added tests for element folder permission
* Added locator for restore element
* Added api helper for Combined element + element folder permission methods
* Added more tests for restore element folder
* Make tests run in the pipeline
* Fixed comments
* Reverted npm command
* Updated createEmptyElementType
* Updated tests due to test helper changes
* Added ui helper for not applicable message for element type
* Added tests for showing message for non-applicable Element Type settings
* Added tests for preventing disabling isElement when elements of that type exist
* Make tests run in the pipeline
* Fixed comments
* Update tests/Umbraco.Tests.AcceptanceTest/tests/DefaultConfig/Settings/DocumentType/DocumentTypeSettingsTab.spec.ts
Co-authored-by: Andreas Zerbst <73799582+andr317c@users.noreply.github.com>
* Reverted npm command
---------
Co-authored-by: Andreas Zerbst <73799582+andr317c@users.noreply.github.com>
* Adds conditions to Document Recycle Bin
that the user must have "Read" permission.
* Directly imports Media Recycle Bin condition
this will remove an extra fetch request.
* Add SonarCloud CI workflow
Adds a manual-dispatch GitHub Actions workflow for SonarQube Cloud
analysis (build, unit test coverage, scan). Moves file_header_template
and SA1636/SA1633 suppression from .editorconfig comments and
.globalconfig into the active .editorconfig .NET language conventions
section, removing the duplicated suppression from .globalconfig.
* Remove branch filter from pull_request trigger in SonarCloud workflow
Runs analysis on all PRs regardless of target branch.
* Adjust sonarcloud gh action based on feedback
* Add .sonarqube to .gitignore
* Attempt to split build and analysis in order to be able to run in PRs from forks
* Adjust SonarCloud workflows
* Rename SonarCloud workflows to reflect their actual purpose
* Remove sonar.coverage.exclusions
* Include .github in sonar analysis
* Include build directory in sonar analysis
* Apply sonarcloud workflow fixes from test branch
* Remove setup-dotnet step from upload workflow
* Use default branch from context instead of hardcoded main in analysis workflow
* Update checkout action to v6 in upload workflow
* Add actions: read permission to upload workflow
* Enable SCM integration in upload workflow