Skip to content

fix: avoid Emotion SSR warning in Radix accordion - #7629

Merged
masenf merged 2 commits into
reflex-dev:mainfrom
harsh21234i:fix/7098-emotion-first-child
Oct 22, 2026
Merged

masenf merged 2 commits into
reflex-dev:mainfrom
harsh21234i:fix/7098-emotion-first-child

Conversation

@harsh21234i

@harsh21234i harsh21234i commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Description
Replace :first-child with :first-of-type in the Accordion item styles, including the ghost-variant selector. This avoids Emotion’s development-mode SSR warning while preserving the first-item styling.

Add a regression test and a Radix package bugfix fragment.

Closes #7098

Tests

  • Radix unit tests: 10 passed
  • Ruff lint and formatting: passed
  • Codespell: passed

View guided diff

@harsh21234i
harsh21234i requested a review from a team as a code owner October 21, 2026 19:10

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 3 files

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread packages/reflex-components-radix/news/7098.bugfix.md Outdated
@greptile-apps

greptile-apps Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge; no new actionable issues were found.

Summary

Replaces :first-child with :first-of-type in Radix Accordion styles, including the ghost variant, to avoid Emotion’s development-mode SSR warning.

  • Accordion first-item styles avoid Emotion's SSR warning.

Reviews (2) · Last reviewed commit: "Apply suggestion from @cubic-dev-ai[bot]" · Reviewed by Greptile

Comment thread tests/units/components/radix/test_accordion.py
@codspeed

codspeed Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Merging this PR will not alter performance

1 warning

⚠️ 11 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

✅ 148 untouched benchmarks


Comparing harsh21234i:fix/7098-emotion-first-child (f5c71fa) with main (973a524)

Open in CodSpeed

@masenf masenf added the on deck PRs lined up to review / merge next label Oct 21, 2026
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
@masenf
masenf enabled auto-merge (squash) October 22, 2026 00:32
@masenf
masenf merged commit 624e2dd into reflex-dev:main Oct 22, 2026
169 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

on deck PRs lined up to review / merge next

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Radix components emit Emotion first-child SSR errors on every dev page load

2 participants