Skip to content

refactor(site): migrate some components from emotion to tailwind#24182

Merged
aslilac merged 3 commits intomainfrom
de-emotion-css-props
Apr 9, 2026
Merged

refactor(site): migrate some components from emotion to tailwind#24182
aslilac merged 3 commits intomainfrom
de-emotion-css-props

Conversation

@aslilac
Copy link
Copy Markdown
Member

@aslilac aslilac commented Apr 8, 2026

Replace Emotion css prop and useTheme with Tailwind utility classes in 4 components that had no MUI dependency — only Emotion styling.

  • DividerWithText: Emotion Interpolation<Theme> styles → Tailwind flex/border/text utilities
  • TimelineDateRow: Emotion css tagged template + useTheme → Tailwind with arbitrary variant selectors
  • SelectedTemplate: Emotion Interpolation<Theme> styles → Tailwind layout/color utilities
  • TemplateDocsPage: Emotion useTheme + css prop → Tailwind (was already partially migrated)

Theme token mapping used throughout:

Emotion Tailwind
theme.palette.background.paper bg-surface-primary
theme.palette.divider border-border
theme.palette.text.secondary text-content-secondary

Net: -82 lines, +19 lines. Four fewer files importing from @emotion/react.

🤖 Generated by Coder Agents

Replace Emotion css prop and useTheme with Tailwind utility classes in
DividerWithText, TimelineDateRow, SelectedTemplate, and TemplateDocsPage.

Theme token mapping:
- theme.palette.background.paper → bg-surface-primary
- theme.palette.divider → border-border
- theme.palette.text.secondary → text-content-secondary
@aslilac aslilac changed the title refactor(site): migrate Emotion css props to Tailwind in 4 components refactor(site): migrate some components from emotion to tailwind Apr 9, 2026
@aslilac aslilac marked this pull request as ready for review April 9, 2026 16:04
@aslilac aslilac requested a review from jeremyruppel April 9, 2026 16:05
Comment thread site/src/components/Timeline/TimelineDateRow.tsx
@aslilac aslilac merged commit 9d6557d into main Apr 9, 2026
32 checks passed
@aslilac aslilac deleted the de-emotion-css-props branch April 9, 2026 16:33
@github-actions github-actions bot locked and limited conversation to collaborators Apr 9, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants