Skip to content

Collection: Introduce Collection Item Ref extension type - #20994

Merged
leekelleher merged 26 commits into
mainfrom
v17/collection-item-ref-extension
Dec 2, 2025
Merged

Collection: Introduce Collection Item Ref extension type#20994
leekelleher merged 26 commits into
mainfrom
v17/collection-item-ref-extension

Apply suggestion from @Copilot

06d6cd4
Select commit
Loading
Failed to load commit list.
CodeScene Delta Analysis / CodeScene Code Health Review (main) failed Dec 2, 2025 in 40s

CodeScene PR Check

Quality Gate Failed

Gates Failed
Enforce advisory code health rules (2 files with Complex Conditional, Complex Method)

Gates Passed
3 Quality Gates Passed

See analysis details in CodeScene

Reason for failure
Enforce advisory code health rules Violations Code Health Impact
document-grid-collection-card.element.ts 1 advisory rule 9.50 Suppress
user-collection-item-card.element.ts 1 advisory rule 10.00 → 9.69 Suppress

Quality Gate Profile: Clean Code Collective
Want more control? Customize Code Health rules or catch issues early with our IDE extension and CLI tool.

Details

🚩 Declining Code Health (highest to lowest):

  • Complex Method document-grid-collection-card.element.ts: UmbDocumentGridCollectionCardElement.getPropertyValueByAlias
  • Complex Conditional user-collection-item-card.element.ts: UmbUserCollectionItemCardElement.loadUserGroups

Annotations

Check warning on line 54 in src/Umbraco.Web.UI.Client/src/packages/user/user/collection/item/user-collection-item-card.element.ts

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Conditional

UmbUserCollectionItemCardElement.loadUserGroups has 1 complex conditionals with 2 branches, threshold = 2. A complex conditional is an expression inside a branch (e.g. if, for, while) which consists of multiple, logical operators such as AND/OR. The more logical operators in an expression, the more severe the code smell.

Check warning on line 75 in src/Umbraco.Web.UI.Client/src/packages/documents/documents/collection/item/document-grid-collection-card.element.ts

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Code Health Review (main)

❌ New issue: Complex Method

UmbDocumentGridCollectionCardElement.getPropertyValueByAlias has a cyclomatic complexity of 18, threshold = 9. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.