Skip to content

Fix/explorer sort dropdown auto close - #4481

Merged
ChristianHuehn merged 37 commits into
mainfrom
fix/explorer-sort-dropdown-auto-close
Jun 10, 2026
Merged

Fix/explorer sort dropdown auto close#4481
ChristianHuehn merged 37 commits into
mainfrom
fix/explorer-sort-dropdown-auto-close

Conversation

@ChristianHuehn

Copy link
Copy Markdown
Collaborator

{Meaningful title}

Please read the CONTRIBUTING.md before opening a PR.

Closes: #

Description

Descriptive pull request text, answering:

  • What problem/issue are you fixing?
  • What does this PR implement and how?

Definition of Done

A PR is only ready for merge once all the following acceptance criteria are fulfilled:

  • Changes have been manually tested
  • All TODOs related to this PR have been closed
  • There are automated tests for newly written code and bug fixes
  • All bugs discovered while working on this PR have been submitted as issues (if not already an open issue)
  • Documentation (GH-pages, analysis/visualization READMEs, parser READMEs, --help, etc.) has been updated (almost always necessary except for bug fixes)
  • CHANGELOG.md has been updated

Screenshots or gifs

christian-huehn-mw and others added 10 commits May 6, 2026 11:49
Migrate the daisyUI sort dropdown from pure-CSS focus-within to a
controlled signal pattern (isOpen + document:click HostListener),
matching MapSelector / DeltaSelector. The menu now closes after the
user picks a sort key, toggles the order, or clicks outside.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Replace the top ribbonBar, metricChooser, scenariosPanel and slider stack
with a new DaisyUI-based floating metrics bar (features/metricsBar/): per-axis
distribution histograms, color/edge segments, and native-popover search/settings.
Removes the @angular/material dependency from these surfaces and deletes the
superseded components.

Includes fixes from a multi-agent review of the change:
- visibleNodeMetricValues selector uses boundary-safe path matching so sibling
  folders sharing a path prefix are no longer pulled into the histogram
- nodeSelection.findTopLevelNode guards the empty-visible-nodes case
- metricColorRangeDiagram percentile calcs always return a finite value (no NaN)
- screenshot capture again subtracts the bottom bar height
- color range slider thumbs get slider ARIA roles + keyboard control; link
  Color/Height button gets an accessible label
- colorSettingsPopover cancels its pending debounce on destroy
- axisColorRamp normalises inverted color ranges
- shared settingsInput util (debounce constant + parse/validate helper)

Backfills unit specs across the new metrics bar components and the
visibleNodeMetricValues selector. Full suite: 363 suites / 2094 tests green.
Top metric labels were selected by rendered building height, but getHeightValue
inverts the rendered height when the height metric has inverted attribute
direction or 'invert height' is enabled (maxHeight - value). As a result the
lowest-value buildings were labeled instead of the highest (e.g. a file with
complexity 4 labeled while one with 223 was not).

Rank the height-mode label candidates by the height-metric value itself, so the
highest-value buildings are always labeled regardless of how height is rendered.
Behavior is unchanged for non-inverted metrics (rendered height already tracks
the value). Adds a regression test.
The active/hovered metric option in the select dropdown showed a primary-colored
ring and no fill, because the static bg-transparent class tied with bg-base-200 at
equal specificity and won. Drop the ring and move bg-transparent into the inactive
branch only, so the hovered/active option paints a solid grey (bg-base-200).
…vers

- Extract MetricSegmentBase shared by the area/height segments (#44).
- Extract a reusable cc-settings-popover-shell container used by the area,
  height, color and edge settings popovers (#47); all popover ids, anchors,
  testids and width behavior preserved.
- parseNumberInput now uses parseFloat so numeric settings inputs accept decimals.
- Fix the Color 'Reset thresholds' button resetting delta map colors as a
  side effect; it now resets only dynamicSettings.colorRange.
…elect e2e

Strengthen dispatch and popover-wiring coverage across the metric segments,
toggles and settings popovers; add the settings-popover-shell spec, parseFloat
decimal cases, visibleNodeMetricValues selector edge cases, and a Playwright e2e
for the metric-select flow (unverified locally — needs a build + Chrome).
setLabels ranked the top-N labels by sorting every leaf building on each render
(O(n log n)). Replace the full sort with a partial top-N selection
(selectTopNByValue) that keeps an n-sized window in one pass — identical result
and ordering, but avoids sorting thousands of buildings to pick a handful of
labels. Behaviour (rank by height-metric value) is unchanged.
…another

selectBuilding overwrote the selected reference and colored the new building but
never reset the previously selected one, so its highlight lingered. Two parts:

- Reset the previously selected building's color when switching selection.
- Invalidate the mesh's incremental highlight cache (_prevHighlightedIds) on any
  selection change, so the next highlight pass does a full recompute. Without this,
  the just-deselected building kept its bright default color against the dimmed
  focus state (the selected building is always skipped by the incremental diff),
  which is why it only cleared after repeatedly hovering elsewhere.
…architecture

The metrics bar lived under features/ but accessed the ngrx Store directly from
components and imported the scenarios feature internals, failing the
dependency-cruiser architecture lint (21 errors) that CI gates on.

Mirror the labelSettings architecture: add per-slice stores/ (the only layer that
imports @ngrx/store) and delegating services/, move feature-local selectors into
selectors/, and route every component through the services instead of injecting
Store. Access the scenarios feature via its facade. Behavior is unchanged.

Architecture lint: 0 errors (was 21). Full suite: 365 suites / 2128 tests green.
@coderabbitai

coderabbitai Bot commented Jun 2, 2026

Copy link
Copy Markdown

Important

Review skipped

Too many files!

This PR contains 300 files, which is 150 over the limit of 150.

To get a review, narrow the scope:
• coderabbit review --type committed # exclude uncommitted changes
• coderabbit review --dir # limit to a subdirectory
• coderabbit review --base # compare against a closer base

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 344f9f47-3d52-48d5-b3e5-611dc28099a8

📥 Commits

Reviewing files that changed from the base of the PR and between a97bb47 and b8800b2.

📒 Files selected for processing (300)
  • .npmrc
  • mise.toml
  • plans/2026-05-07-floating-metrics-bar.md
  • plans/2026-05-12-align-metric-settings-popover-style.md
  • plans/2026-05-13-redesign-color-settings-popover.md
  • plans/2026-05-22-metrics-bar-distributions.md
  • plans/2026-05-29-address-metricsbar-review-findings.md
  • plans/2026-05-29-metricsbar-manual-qa-findings.md
  • plans/2026-06-09-max-effort-pr-review.md
  • plans/2026-06-10-manual-qa-findings.md
  • plans/2026-06-10-max-review-findings.md
  • visualization/.npmrc
  • visualization/CHANGELOG.md
  • visualization/app/app.scss
  • visualization/app/codeCharta/codeCharta.component.html
  • visualization/app/codeCharta/codeCharta.component.ts
  • visualization/app/codeCharta/codeCharta.model.ts
  • visualization/app/codeCharta/features/3dPrint/components/export3DMapButton/export3DMapButton.component.ts
  • visualization/app/codeCharta/features/3dPrint/components/export3DMapDialog/export3DMapDialog.component.ts
  • visualization/app/codeCharta/features/3dPrint/facade.ts
  • visualization/app/codeCharta/features/3dPrint/stores/colorMode.store.ts
  • visualization/app/codeCharta/features/bottomBar/components/bottomBar/bottomBar.component.ts
  • visualization/app/codeCharta/features/labelSettings/components/labelSettingsButton/labelSettingsButton.component.html
  • visualization/app/codeCharta/features/labelSettings/components/labelSettingsButton/labelSettingsButton.component.ts
  • visualization/app/codeCharta/features/labelSettings/components/labelSettingsPanel/labelSettingsPanel.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/areaSegment/areaSegment.component.html
  • visualization/app/codeCharta/features/metricsBar/components/areaSegment/areaSegment.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/areaSegment/areaSegment.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/areaSettingsPopover/areaSettingsPopover.component.html
  • visualization/app/codeCharta/features/metricsBar/components/areaSettingsPopover/areaSettingsPopover.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/areaSettingsPopover/areaSettingsPopover.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/axisCard/axisCard.component.html
  • visualization/app/codeCharta/features/metricsBar/components/axisCard/axisCard.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/axisCard/axisCard.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/axisCard/axisCardHeader.component.html
  • visualization/app/codeCharta/features/metricsBar/components/axisCard/axisCardHeader.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSegment/colorSegment.component.html
  • visualization/app/codeCharta/features/metricsBar/components/colorSegment/colorSegment.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSegment/colorSegment.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/colorSettingsPopover.component.html
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/colorSettingsPopover.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/colorSettingsPopover.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/metricColorRangeDiagram.component.html
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/metricColorRangeDiagram.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/metricColorRangeDiagram.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/metricColorRangeSlider.component.html
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/metricColorRangeSlider.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/metricColorRangeSlider.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/rangeSliderLabels.component.html
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/rangeSliderLabels.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/rangeSliderLabels.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/utils/SliderRangePosition.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/colorSettingsPopover/utils/SliderRangePosition.ts
  • visualization/app/codeCharta/features/metricsBar/components/edgeSegment/edgeSegment.component.html
  • visualization/app/codeCharta/features/metricsBar/components/edgeSegment/edgeSegment.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/edgeSegment/edgeSegment.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/edgeSettingsPopover/edgeMetricToggle.component.html
  • visualization/app/codeCharta/features/metricsBar/components/edgeSettingsPopover/edgeMetricToggle.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/edgeSettingsPopover/edgeMetricToggle.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/edgeSettingsPopover/edgeSettingsPopover.component.html
  • visualization/app/codeCharta/features/metricsBar/components/edgeSettingsPopover/edgeSettingsPopover.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/edgeSettingsPopover/edgeSettingsPopover.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/heightSegment/heightSegment.component.html
  • visualization/app/codeCharta/features/metricsBar/components/heightSegment/heightSegment.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/heightSegment/heightSegment.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/heightSettingsPopover/heightSettingsPopover.component.html
  • visualization/app/codeCharta/features/metricsBar/components/heightSettingsPopover/heightSettingsPopover.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/heightSettingsPopover/heightSettingsPopover.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/labelsScenariosSegment/labelsScenariosSegment.component.html
  • visualization/app/codeCharta/features/metricsBar/components/labelsScenariosSegment/labelsScenariosSegment.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/labelsScenariosSegment/labelsScenariosSegment.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/linkColorHeightButton/linkColorHeightButton.component.html
  • visualization/app/codeCharta/features/metricsBar/components/linkColorHeightButton/linkColorHeightButton.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/linkColorHeightButton/linkColorHeightButton.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricMetaValue/metricChooserType.component.html
  • visualization/app/codeCharta/features/metricsBar/components/metricMetaValue/metricChooserType.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricMetaValue/metricChooserType.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricMetaValue/metricMetaValue.component.html
  • visualization/app/codeCharta/features/metricsBar/components/metricMetaValue/metricMetaValue.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricMetaValue/metricMetaValue.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSegment/metricSegment.component.html
  • visualization/app/codeCharta/features/metricsBar/components/metricSegment/metricSegment.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSegment/metricSegment.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/filterMetricDataBySearchTerm.pipe.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/filterMetricDataBySearchTerm.pipe.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/metricSelectOption.component.html
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/metricSelectOption.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/metricSelectPopover.component.html
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/metricSelectPopover.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricSelectPopover/metricSelectPopover.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricsBar/metricsBar.component.html
  • visualization/app/codeCharta/features/metricsBar/components/metricsBar/metricsBar.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricsBar/metricsBar.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricsBar/metricsBar.e2e.ts
  • visualization/app/codeCharta/features/metricsBar/components/metricsBar/metricsBar.po.ts
  • visualization/app/codeCharta/features/metricsBar/components/settingsPopoverShell/settingsPopoverShell.component.html
  • visualization/app/codeCharta/features/metricsBar/components/settingsPopoverShell/settingsPopoverShell.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/settingsPopoverShell/settingsPopoverShell.component.ts
  • visualization/app/codeCharta/features/metricsBar/components/sliderNumberInput/sliderNumberInput.component.html
  • visualization/app/codeCharta/features/metricsBar/components/sliderNumberInput/sliderNumberInput.component.spec.ts
  • visualization/app/codeCharta/features/metricsBar/components/sliderNumberInput/sliderNumberInput.component.ts
  • visualization/app/codeCharta/features/metricsBar/facade.ts
  • visualization/app/codeCharta/features/metricsBar/selectors/createAttributeTypeSelector.selector.spec.ts
  • visualization/app/codeCharta/features/metricsBar/selectors/createAttributeTypeSelector.selector.ts
  • visualization/app/codeCharta/features/metricsBar/selectors/edgeAndColors.selectors.ts
  • visualization/app/codeCharta/features/metricsBar/selectors/metricColorRangeColors.selector.ts
  • visualization/app/codeCharta/features/metricsBar/selectors/metricColorRangeValues.selector.ts
  • visualization/app/codeCharta/features/metricsBar/services/amountOfBuildingsWithSelectedEdgeMetric.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/amountOfEdgePreviews.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/areaMetric.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/attributeDescriptors.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/attributeTypes.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/colorMetric.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/colorMode.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/colorRange.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/edgeHeight.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/edgeMetric.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/enableFloorLabels.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/heightMetric.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/invertArea.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/invertHeight.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/isDeltaState.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/isEdgeMetricVisible.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/isHeightAndColorMetricLinked.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/mapColors.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/margin.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/metricData.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/nodeSelection.service.spec.ts
  • visualization/app/codeCharta/features/metricsBar/services/nodeSelection.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/primaryMetrics.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/scaling.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/selectedColorMetricData.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/showIncomingEdges.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/showOnlyBuildingsWithEdges.service.ts
  • visualization/app/codeCharta/features/metricsBar/services/showOutgoingEdges.service.ts
  • visualization/app/codeCharta/features/metricsBar/stores/amountOfBuildingsWithSelectedEdgeMetric.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/amountOfEdgePreviews.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/areaMetric.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/attributeDescriptors.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/attributeTypes.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/colorMetric.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/colorMode.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/colorRange.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/edgeHeight.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/edgeMetric.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/enableFloorLabels.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/heightMetric.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/invertArea.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/invertHeight.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/isDeltaState.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/isEdgeMetricVisible.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/isHeightAndColorMetricLinked.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/mapColors.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/margin.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/metricData.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/nodeSelection.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/primaryMetrics.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/scaling.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/selectedColorMetricData.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/showIncomingEdges.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/showOnlyBuildingsWithEdges.store.ts
  • visualization/app/codeCharta/features/metricsBar/stores/showOutgoingEdges.store.ts
  • visualization/app/codeCharta/features/metricsBar/util/settingsInput.ts
  • visualization/app/codeCharta/features/navBar/components/deltaSelector/deltaSelector.component.html
  • visualization/app/codeCharta/features/navBar/components/mapSelector/mapSelector.component.html
  • visualization/app/codeCharta/features/navBar/components/print3DButton/print3DButton.component.ts
  • visualization/app/codeCharta/features/scenarios/components/applyScenarioDialog/applyScenarioDialog.component.spec.ts
  • visualization/app/codeCharta/features/scenarios/components/scenariosPanel/scenariosPanel.component.html
  • visualization/app/codeCharta/features/scenarios/components/scenariosPanel/scenariosPanel.component.spec.ts
  • visualization/app/codeCharta/features/scenarios/components/scenariosPanel/scenariosPanel.component.ts
  • visualization/app/codeCharta/features/scenarios/facade.ts
  • visualization/app/codeCharta/features/sidebarExplorer/components/explorerTreeItemIcon/explorerTreeItemIcon.component.ts
  • visualization/app/codeCharta/features/sidebarExplorer/components/explorerTreeItemName/explorerTreeItemName.component.html
  • visualization/app/codeCharta/features/sidebarExplorer/components/explorerTreeItemName/explorerTreeItemName.component.spec.ts
  • visualization/app/codeCharta/features/sidebarExplorer/components/explorerTreeItemName/explorerTreeItemName.component.ts
  • visualization/app/codeCharta/features/sidebarExplorer/components/explorerTreeLevel/explorerTreeLevel.component.ts
  • visualization/app/codeCharta/features/sidebarExplorer/components/sidebarExplorer/sidebarExplorer.component.ts
  • visualization/app/codeCharta/features/sidebarExplorer/selectors/sidebarExplorer.selectors.spec.ts
  • visualization/app/codeCharta/features/sidebarExplorer/selectors/sidebarExplorer.selectors.ts
  • visualization/app/codeCharta/features/sidebarExplorer/stores/areaMetric.store.spec.ts
  • visualization/app/codeCharta/features/sidebarExplorer/stores/areaMetric.store.ts
  • visualization/app/codeCharta/features/viewCubeToolbox/services/screenshot.service.ts
  • visualization/app/codeCharta/state/effects/addBlacklistItemsIfNotResultsInEmptyMap/addBlacklistItemsIfNotResultsInEmptyMap.effect.ts
  • visualization/app/codeCharta/state/effects/addBlacklistItemsIfNotResultsInEmptyMap/resultsInEmptyMap.ts
  • visualization/app/codeCharta/state/selectors/accumulatedData/metricData/edgeMetricData.calculator.spec.ts
  • visualization/app/codeCharta/state/selectors/accumulatedData/metricData/edgeMetricData.calculator.ts
  • visualization/app/codeCharta/state/selectors/accumulatedData/metricData/nodeMetricData.calculator.spec.ts
  • visualization/app/codeCharta/state/selectors/accumulatedData/metricData/nodeMetricData.calculator.ts
  • visualization/app/codeCharta/state/selectors/accumulatedData/metricData/sortedNodeEdgeMetricsMap.selector.ts
  • visualization/app/codeCharta/state/selectors/searchedNodes/getNodesByGitignorePath.ts
  • visualization/app/codeCharta/state/store/appSettings/mapColors/mapColors.reducer.spec.ts
  • visualization/app/codeCharta/state/store/appSettings/mapColors/mapColors.reducer.ts
  • visualization/app/codeCharta/state/store/fileSettings/blacklist/blacklistMatcher.selector.spec.ts
  • visualization/app/codeCharta/state/store/fileSettings/blacklist/blacklistMatcher.selector.ts
  • visualization/app/codeCharta/ui/attributeSideBar/attributeSideBar.component.scss
  • visualization/app/codeCharta/ui/codeMap/arrow/utils/edgePreviewNodes.selector.ts
  • visualization/app/codeCharta/ui/codeMap/codeMap.component.ts
  • visualization/app/codeCharta/ui/codeMap/codeMap.mouseEvent.service.ts
  • visualization/app/codeCharta/ui/codeMap/codeMap.render.service.spec.ts
  • visualization/app/codeCharta/ui/codeMap/codeMap.render.service.ts
  • visualization/app/codeCharta/ui/codeMap/rendering/codeMapMesh.spec.ts
  • visualization/app/codeCharta/ui/codeMap/rendering/codeMapMesh.ts
  • visualization/app/codeCharta/ui/codeMap/threeViewer/threeSceneService.spec.ts
  • visualization/app/codeCharta/ui/codeMap/threeViewer/threeSceneService.ts
  • visualization/app/codeCharta/ui/colorPickerForMapColor/colorPickerForMapColor.component.ts
  • visualization/app/codeCharta/ui/dialogs/confirmationDialog/confirmationDialog.component.html
  • visualization/app/codeCharta/ui/dialogs/confirmationDialog/confirmationDialog.component.ts
  • visualization/app/codeCharta/ui/dialogs/dialogs.ts
  • visualization/app/codeCharta/ui/metricChooser/metricChooser.component.html
  • visualization/app/codeCharta/ui/metricChooser/metricChooser.component.scss
  • visualization/app/codeCharta/ui/metricChooser/metricChooser.component.spec.ts
  • visualization/app/codeCharta/ui/metricChooser/metricChooser.component.ts
  • visualization/app/codeCharta/ui/metricChooser/metricChooserType/metricChooserType.component.html
  • visualization/app/codeCharta/ui/metricChooser/metricChooserType/metricChooserType.component.spec.ts
  • visualization/app/codeCharta/ui/metricChooser/metricChooserType/metricChooserType.component.ts
  • visualization/app/codeCharta/ui/metricChooser/metricChooserValue/metricChooserValue.component.html
  • visualization/app/codeCharta/ui/metricChooser/metricChooserValue/metricChooserValue.component.scss
  • visualization/app/codeCharta/ui/metricChooser/metricChooserValue/metricChooserValue.component.spec.ts
  • visualization/app/codeCharta/ui/metricChooser/metricChooserValue/metricChooserValue.component.ts
  • visualization/app/codeCharta/ui/metricChooser/nodeSelection.service.ts
  • visualization/app/codeCharta/ui/resetSettingsButton/resetSettingsButton.component.html
  • visualization/app/codeCharta/ui/resetSettingsButton/resetSettingsButton.component.scss
  • visualization/app/codeCharta/ui/resetSettingsButton/resetSettingsButton.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/areaMetricChooser/areaMetricChooser.component.html
  • visualization/app/codeCharta/ui/ribbonBar/areaMetricChooser/areaMetricChooser.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/areaMetricChooser/areaMetricChooser.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/areaSettingsPanel/areaSettingsPanel.component.html
  • visualization/app/codeCharta/ui/ribbonBar/areaSettingsPanel/areaSettingsPanel.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/areaSettingsPanel/areaSettingsPanel.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/areaSettingsPanel/areaSettingsPanel.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorMetricChooser/colorMetricChooser.component.html
  • visualization/app/codeCharta/ui/ribbonBar/colorMetricChooser/colorMetricChooser.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorMetricChooser/colorMetricChooser.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/colorSettingsPanel.component.html
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/colorSettingsPanel.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/colorSettingsPanel.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/colorSettingsPanel.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeDiagram/metricColorRangeDiagram.component.html
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeDiagram/metricColorRangeDiagram.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeDiagram/metricColorRangeDiagram.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeSlider/metricColorRangeSlider.component.html
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeSlider/metricColorRangeSlider.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeSlider/metricColorRangeSlider.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeSlider/metricColorRangeSlider.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeSlider/rangeSliderLabels/rangeSliderLabels.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/metricColorRangeSlider/rangeSliderLabels/rangeSliderLabels.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/colorSettingsPanel/selectors/metricColorRangeColors.selector.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeMetricChooser/edgeChooser.e2e.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeMetricChooser/edgeChooser.po.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeMetricChooser/edgeMetricChooser.component.html
  • visualization/app/codeCharta/ui/ribbonBar/edgeMetricChooser/edgeMetricChooser.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/edgeMetricChooser/edgeMetricChooser.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeMetricChooser/edgeMetricChooser.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeMetricToggle/edgeMetricToggle.component.html
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeMetricToggle/edgeMetricToggle.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeMetricToggle/edgeMetricToggle.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeSettingsPanel.component.html
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeSettingsPanel.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeSettingsPanel.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/edgeSettingsPanel/edgeSettingsPanel.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/heightMetricChooser/heightMetricChooser.component.html
  • visualization/app/codeCharta/ui/ribbonBar/heightMetricChooser/heightMetricChooser.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/heightMetricChooser/heightMetricChooser.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/heightSettingsPanel/heightSettingsPanel.component.html
  • visualization/app/codeCharta/ui/ribbonBar/heightSettingsPanel/heightSettingsPanel.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/heightSettingsPanel/heightSettingsPanel.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/heightSettingsPanel/heightSettingsPanel.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/heightSettingsPanel/selectors/isLabelsSliderDisabled.selector.ts
  • visualization/app/codeCharta/ui/ribbonBar/linkColorMetricToHeightMetricButton/linkColorMetricToHeightMetricButton.component.html
  • visualization/app/codeCharta/ui/ribbonBar/linkColorMetricToHeightMetricButton/linkColorMetricToHeightMetricButton.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/linkColorMetricToHeightMetricButton/linkColorMetricToHeightMetricButton.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/linkColorMetricToHeightMetricButton/linkColorMetricToHeightMetricButton.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBar.component.html
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBar.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBar.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBar.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBar.e2e.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBar.po.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarMenuButton/ribbonBarMenuButton.component.html
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarMenuButton/ribbonBarMenuButton.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarMenuButton/ribbonBarMenuButton.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarPanel/ribbonBarPanel.component.html
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarPanel/ribbonBarPanel.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarPanel/ribbonBarPanel.component.spec.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarPanel/ribbonBarPanel.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarPanel/ribbonBarPanelSettings.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/ribbonBarPanel/ribbonBarPanelSettings.component.ts
  • visualization/app/codeCharta/ui/ribbonBar/roundedBox/roundedBox.component.html
  • visualization/app/codeCharta/ui/ribbonBar/roundedBox/roundedBox.component.scss
  • visualization/app/codeCharta/ui/ribbonBar/roundedBox/roundedBox.component.ts
  • visualization/app/codeCharta/ui/slider/slider.component.html
  • visualization/app/codeCharta/ui/slider/slider.component.scss
  • visualization/app/codeCharta/ui/slider/slider.component.spec.ts
  • visualization/app/codeCharta/ui/slider/slider.component.ts
  • visualization/app/codeCharta/util/algorithm/streetLayout/streetLayoutGenerator.spec.ts
  • visualization/app/codeCharta/util/algorithm/streetLayout/streetLayoutGenerator.ts
  • visualization/app/codeCharta/util/algorithm/treeMapLayout/treeMapHelper.ts
  • visualization/app/codeCharta/util/blacklist/blacklistMatcher.spec.ts
  • visualization/app/codeCharta/util/blacklist/blacklistMatcher.ts
  • visualization/app/codeCharta/util/codeMapHelper.ts

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/explorer-sort-dropdown-auto-close

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

ChristianHuehn and others added 19 commits June 2, 2026 20:25
…and improve metrics-bar a11y

Reuse returnIgnore in createBlacklistMatcher and the explorer rule counts so
flatten/exclude matching mirrors NodeDecorator, including negated !-rules.
Only line-through flattened files (not folders) in the explorer tree.
Replace the color range slider's role=slider divs with native range inputs.
Extract helpers in histogramBins and visibleNodeMetricValues selectors.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…and mid-typing values

- parseNumberInput no longer overwrites the input element while typing, so
  intermediate out-of-range values (the "4" while typing "45") survive; adds
  an optional round flag for integer-only settings
- extract shared cc-slider-number-input control used by the area, height and
  edge settings popovers: debounced commits, step rounding, display
  normalization on change, and no stale intermediate commits when retyping
  the current value
- selectTopNByValue floors fractional n and ranks NaN below real values
  instead of crashing or blocking the top-N window
- edgePreviewNodes selector floors fractional amountOfEdgePreviews
- debounce util gains flush() and cancel()

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…tate and ramp colors

- measure the color-range slider track width instead of assuming a fixed
  395px, so thumbs stay on the track on narrow viewports
- abort thumb drags when the popover is light-dismissed mid-drag and clean
  up document listeners on destroy instead of dispatching a garbage range
- step arrow-key and typed threshold changes from the pending value so
  repeated presses within the debounce window accumulate
- track color inversion with an explicit flag in mapColors state so the
  Invert Colors checkbox stays meaningful after colors are customized
- flush the pending color range on popover destroy instead of discarding
  it, and use the shared debounce util instead of a hand-rolled timer
- extract getColorByMetricValue as the single classification used by the
  3D map and the axis color ramp: bins at the thresholds now match their
  buildings, and the ramp respects the selected color mode

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
createBlacklistMatcher is now the single engine for blacklist rules, used by
NodeDecorator, both layouts, the metric calculators, the file explorer counts
and selection cleanup, so they can never disagree on what a rule affects:

- isExcludedLeaf applies NodeDecorator's leaf-only exclude semantics,
  including negated !-rules
- isExcludedSubtree is the only folder-level check; it ignores negated rules,
  so the street layout no longer prunes folder subtrees that still contain
  non-excluded leaves
- isPathBlacklisted/isPathHiddenOrExcluded use the shared matcher instead of
  raw gitignore semantics, so selection cleanup agrees with what
  NodeDecorator removes from the map
- NodeDecorator's private engine copy is deleted; the explorer's per-rule
  counts get back the combined-engine prefilter for positive rules
- delete unused isNodeExcludedOrFlattened

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…bar migration

- keep the edge metric chooser usable while edges are hidden (dim instead of
  disable) and restore the sum/median aggregation indicator next to hovered
  edge values
- initialize keyboard navigation in the metric select popover on the
  currently selected metric so Enter right after opening is a no-op
- guard METRIC_ALIASES lookups with Object.hasOwn so metrics named like
  Object prototype members cannot break the metric list
- position settings popovers via JS next to their anchor in browsers
  without CSS Anchor Positioning (Firefox) instead of viewport-centered
- wrap metrics-bar segments in real boxes so divide-x separators paint
  (segment hosts are display:contents)
- render one full histogram bin for metrics where min equals max so a
  populated metric is distinguishable from no data
- metricChooserType uses the tested createAttributeTypeSelector instead of
  re-implementing the aggregation logic inline
- metricsBar spec: histogram test now feeds visibleNodeMetricValuesSelector
  (what the component actually reads) and asserts rendered bars

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ing state

- clearSelection nulls the selection before the highlight repaint so the
  just-deselected building cannot keep its stale selection color
- remap the selected building onto the new mesh on mesh swap (or drop it
  when the building is gone) instead of keeping a stale old-mesh reference
- top labels rank by rendered building height again, and the color-label
  branch reuses selectTopNByValue instead of sorting all matching leaves
- hovering a folder outside the focused subtree no longer rebuilds the
  metrics-bar histograms from buildings that are not rendered
- screenshots measure the bottom bar via its inner footer (the host box is
  always zero-height), so the capture actually crops the bottom bar

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- visibleNodeMetricValues keys on the derived hovered-folder path, so leaf
  hovers (10-30/s while sweeping) no longer re-walk the whole map; it also
  collects only the displayed area/height/color metrics and drops the
  unused sum
- topLevelNode depends on area/height metric instead of the whole
  dynamicSettings slice, so search keystrokes and margin drags no longer
  re-run the full layout for a fallback display value
- color range diagram computes percentiles with one sort instead of an
  O(unique x N) scan, redraws only the colored areas for thumb-only
  changes, and defers all work while its popover is closed
- metric select popovers render their option list lazily on open instead
  of keeping ~300 buttons per popover in the DOM
- selection clicks update the highlight diff incrementally (repaint the
  formerly selected building) instead of invalidating the cache and
  re-uploading the full color buffer

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…er shells

- delete the unused AccumulatedData/DynamicSettings/HoveredNode/SelectedNode
  store+service mirror pairs (zero consumers)
- rename the duplicate root singletons: sidebarExplorer's AreaMetricStore to
  ExplorerAreaMetricStore and 3dPrint's ColorModeStore (which forces
  ColorMode.absolute) to Export3DColorModeStore, so auto-imports cannot mix
  them up with the metricsBar stores
- remove never-called setters setIsEdgeMetricVisible,
  setIsHeightAndColorMetricLinked and setMapColors from store and service
- metric select popover and the labels/scenarios segment use
  SettingsPopoverShellComponent instead of hand-rolled popover markup (which
  had already drifted), gaining the Firefox positioning fallback
- visibleNodeMetricValues uses the shared isLeaf helper
- fix the two remaining spec type errors so tsc --noEmit is clean

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
A failing assertion in the settings popover specs could previously skip the
inline jest.useRealTimers() call and leak fake timers into the rest of the
test file.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Also check in the max-effort review plan and findings plan; all findings are
fixed except F48 (store/service layer collapse), which is deferred as a team
decision.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
… type

The new boolean inversion flags on MapColors widened the template-indexed
access in cc-color-picker-for-map-color to string | boolean, which only the
AOT template check catches. Restrict mapColorFor to color-valued keys.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
… top-N selection

Benchmarked against the pre-refactor implementations with 200k nodes:

- BlacklistMatcher gains classify(path, isLeaf) that transforms the path once
  and uses plain loops instead of Array.some closures; NodeDecorator and the
  explorer counts use it, removing the ~10% decoration-pass regression the
  shared-matcher refactor had introduced (now at parity, ~500ms for 200k
  nodes x 6 rules, with folders still skipping negated exclude engines)
- selectTopNByValue caches the window's boundary value so the common case
  (item not in the top n) costs one comparison instead of re-reading the
  boundary item (2.2ms -> 1.4ms for 200k items)

Verified unchanged results and confirmed the earlier wins: percentile ranks
2928ms -> 14ms (100k values), per-rule explorer counts 985ms -> 466ms.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Retyping the value that was already pending skipped re-arming the timer, so
the commit could fire mid-typing. The number inputs now push the debounce
window out on each keystroke; the label settings panel also drops a pending
intermediate value when typing returns to the committed one.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…r segments

Design decision after seeing them render; also reverts the wrapper divs that
only existed to give divide-x real boxes to paint between.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The displayed metric values follow hovered ?? selected ?? top level, but the
histograms only knew hover and focus: after selecting a folder floor the
value stayed pinned while the histograms fell back to the whole map. The
histogram prefix now mirrors the same precedence (selected leaves are
ignored, and a selection outside the focused subtree cannot widen the view).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…trap tasks

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The per-axis histograms and the color ramp did not add enough value to
justify their surface: delete the axisDistribution and axisColorRamp
components and the histogramBins util with their specs. The segments keep
the hovered/selected metric value and the min/max range of the rendered
buildings (still narrowing to the focused, hovered or selected subtree).

- rename DistributionSegmentComponent to MetricSegmentComponent, since the
  distribution was the only thing the name referred to
- visibleNodeMetricValues collects only min/max per metric, no longer the
  full value arrays the histograms binned
- the color segment derives its min/max labels from the global color metric
  data alone and drops the ramp's colorMode/mapColors/colorRange wiring

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…layer

metricChooserType injected the ngrx Store directly, which violates the
feature-only-stores-can-import-ngrx-store dependency-cruiser rule that
failed CI. The createAttributeTypeSelector is now exposed via
AttributeTypesStore/-Service like every other selector in the feature.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
christian-huehn-mw and others added 8 commits June 10, 2026 12:54
… segments

The row was the histograms' axis labeling and is not needed without them.
With it gone the whole visibleNodeMetricValues selector/store/service chain
and MetricSegmentBase have no consumers left and are deleted; the segments
show only the hovered/selected metric value.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Bumps transitive dev dependencies (fast-xml-parser family, postcss, nanoid,
qs, ws, xmldom and others) to patched versions. The three newly added
transitive packages (@nodable/entities, xml-naming, anynum) are part of the
fast-xml-parser author's package family and were verified against the
registry and their tarball contents (no install scripts, no suspicious
code). The remaining high advisory is electron itself, which only an
across-major bump (audit fix --force) would address.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Dependency lifecycle scripts (preinstall/install/postinstall) are the main
npm supply-chain attack vector; with ignore-scripts=true in .npmrc they can
no longer execute code during npm install. Audit of both lockfiles: no root
dependency has an install script, and all native visualization dependencies
(esbuild, lmdb, @parcel/watcher, msgpackr-extract, unrs-resolver, fsevents)
ship prebuilt platform packages whose install scripts are only fallbacks.
The two real exceptions are handled explicitly:

- electron: script/ensureElectron.js downloads the binary on demand before
  npm run start / npm run package (this also repairs installs where
  node_modules/electron/path.txt is missing)
- husky: git hooks are set up via npm run prepare, wired into the mise
  install task

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- extract the per-rule counting loops out of buildRulesWithCount to get its
  cognitive complexity under the threshold (S3776)
- make the NaN guards on floored limits explicit (Number.isNaN || <= 0)
  instead of the negated comparison Sonar flags (S1940) — plain <= 0 alone
  would let NaN through
- use entries.at(-1) for the last resize observer entry (S7755)
- drop a type assertion that querySelector("footer") already implies (S4325)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
… code

- selectTopNByValue/parseNumberInput: named helpers (rankNaNBelowEveryValue,
  collectTopWindow, clamp) instead of comment blocks
- codeMapMesh: extract invalidateDiffCacheWhenPresentationModeChanged and
  repaintFormerlySelectedWhenSelectionChanged
- metric alias lookup uses a Map, removing the hasOwn guard and its comment
- metricMetaValue builds one display view model from small pure functions;
  the template shrinks to a single state switch
- explorer counts read the decorated isFlattened/isExcluded flags directly
  (they are re-decorated on every blacklist change, so the matcher round
  trip was redundant); the rule-count prefilter comment became
  buildRuleEnginesMatchingNodeDecorator

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- extract cc-axis-card-header (label + settings cog) and share the card
  content between the clickable and static variants via one template
  instead of duplicating it per branch
- extract cc-metric-select-option so the popover template is the search
  field plus a list, with the option row markup in its own component

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
codeMapHelper had grown into a grab-bag. The gitignore-based blacklist
machinery (transformPath, returnIgnore, addRulePatternsToEngine, the
BlacklistMatcher and the isPathBlacklisted/isPathHiddenOrExcluded helpers)
now lives in util/blacklist/blacklistMatcher.ts next to the other blacklist
utilities; codeMapHelper keeps only the generic code-map node helpers.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The li now lives in the parent list, the option component renders only the
button — fixes the Sonar item-tag warning and the invalid ul nesting.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@sonarqubecloud

Copy link
Copy Markdown

@ChristianHuehn
ChristianHuehn merged commit 5652c67 into main Jun 10, 2026
8 checks passed
@ChristianHuehn
ChristianHuehn deleted the fix/explorer-sort-dropdown-auto-close branch June 10, 2026 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants