Skip to content

ref(issueDetails): Break circular dependency between sidebar and detectorSection - #127477

Merged
ryan953 merged 4 commits into
masterfrom
seer/ref/break-sidebar-detector-section-cycle
Oct 15, 2026
Merged

ryan953 merged 4 commits into
masterfrom
seer/ref/break-sidebar-detector-section-cycle

Conversation

@sentry

@sentry sentry Bot commented Oct 14, 2026 •

Copy link
Copy Markdown
Contributor

sidebar.tsx exported SidebarSectionTitle, and detectorSection.tsx, mergedSidebarSection.tsx, and similarIssuesSidebarSection.tsx imported it back while sidebar.tsx imported them, creating circular dependencies. The shared export is removed: all three sections render <SidebarSection.Title variant="primary"> directly, with the detector section wrapping it in <Container marginBottom="md"> for spacing.

To support that, SidebarSection.Title is now built on Heading (as="h6", size="md", variant="muted" by default) instead of a styled h6, and callers can pass variant to change the color. This clears its @sentry/scraps/prefer-primitives suppression. A small styled layer keeps display: flex with a gap, because release sidebar titles such as "Adoption Stage" and "Sessions Adopted" carry a trailing InfoTip or icon that must stay vertically centered.

Review focus: Heading uses medium font weight and text-box-trim, so the titles in the release details sidebar and the issue details sidebar (Merged Issues, Similar Issues, detector section) may render slightly differently. No feature flags.

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

Fixes CODING-CONVENTIONS-8ZM
Fixes CODING-CONVENTIONS-8ZZ
Fixes CODING-CONVENTIONS-906

@sentry <feedback>: Autofix iterates on these changes
@sentry stop iterating: Autofix stops iterating on this run

@sentry
sentry Bot requested a review from a team as a code owner October 14, 2026 22:40
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Oct 14, 2026
SidebarSection.Title was a styled h6, which the scraps prefer-primitives
rule flags. It now renders Heading as an h6 at size md with the muted
variant, keeping a styled layer only for the flex layout that centers
trailing InfoTips and icons, and the top margin.

The lint violation is gone, so the sidebarSection.tsx entry is removed
from oxlint-suppressions.json.
…variant

SidebarSection.Title now accepts a Heading variant, so the primary color
no longer needs a styled override. Merged and Similar Issues render
SidebarSection.Title directly, and detectorSection keeps a local styled
title that only adds the bottom margin.
Heading has no margin props, so the detector title's bottom spacing now
comes from a Container marginBottom rather than a local styled wrapper.
@ryan953 ryan953 added the Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests label Oct 15, 2026
@ryan953
ryan953 enabled auto-merge (squash) October 15, 2026 03:46
@ryan953
ryan953 merged commit 04dbdd9 into master Oct 15, 2026
95 of 96 checks passed
@ryan953
ryan953 deleted the seer/ref/break-sidebar-detector-section-cycle branch October 15, 2026 03:50

This branch was successfully deployed

1 active deployment
Preview — 00c9859e Deployed Oct 15, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components Trigger: getsentry tests Once code is reviewed: apply label to PR to trigger getsentry tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant