Skip to content

DNM - Forcing a snapshot diff#112109

Open
rbro112 wants to merge 1 commit intomasterfrom
04-02-dnm_-_forcing_a_snapshot_diff
Open

DNM - Forcing a snapshot diff#112109
rbro112 wants to merge 1 commit intomasterfrom
04-02-dnm_-_forcing_a_snapshot_diff

Conversation

@rbro112
Copy link
Copy Markdown
Member

@rbro112 rbro112 commented Apr 2, 2026

Forcing a snapshot diff, just as an example

@rbro112 rbro112 requested a review from a team as a code owner April 2, 2026 15:49
Copy link
Copy Markdown
Member Author

rbro112 commented Apr 2, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Apr 2, 2026
@rbro112 rbro112 force-pushed the 04-02-dnm_-_forcing_a_snapshot_diff branch from 1b8743b to e113b00 Compare April 2, 2026 17:52
Comment on lines +293 to +295
surface: theme.tokens.interactive.chonky.embossed.success.background,
background: theme.tokens.interactive.chonky.embossed.success.chonk,
color: theme.tokens.interactive.chonky.embossed.success.content,
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.

Bug: The getButtonTheme function incorrectly returns success theme colors for the danger case, causing buttons for destructive actions to appear green instead of red.
Severity: HIGH

Suggested Fix

In the case 'danger': block within the getButtonTheme function, change the theme token references from theme.tokens.interactive.chonky.embossed.success back to theme.tokens.interactive.chonky.embossed.danger for the surface, background, and color properties.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: static/app/components/core/button/styles.tsx#L293-L295

Potential issue: In the `getButtonTheme` function, the `case 'danger':` block has been
modified to return theme tokens associated with 'success' instead of 'danger'. This will
cause all buttons with `priority="danger"`, which are used for destructive actions like
deleting projects or revoking keys, to be rendered with green "success" colors instead
of the expected red "danger" colors. This affects over 170 instances in the codebase,
creating a significant user experience and safety issue by visually misrepresenting the
consequence of critical actions.

Did we get this right? 👍 / 👎 to inform future reviews.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant