Skip to content

fix(dashboards): Fix system activity avatar sizing and dark mode#107598

Merged
edwardgou-sentry merged 3 commits intomasterfrom
egou/fix/system-activity-avatar-not-respecting-size-prop
Feb 4, 2026
Merged

fix(dashboards): Fix system activity avatar sizing and dark mode#107598
edwardgou-sentry merged 3 commits intomasterfrom
egou/fix/system-activity-avatar-not-respecting-size-prop

Conversation

@edwardgou-sentry
Copy link
Contributor

@edwardgou-sentry edwardgou-sentry commented Feb 4, 2026

  • Fixed system activity avatar to respect the size prop by applying width/height to the Flex container
  • Drops using useInvertedTheme to allow using the correct theme colours on system avatar

The ActivityAvatar component was passing numeric size values directly to
Flex width/height props, which require string values with units. This
caused the system avatar (Sentry icon) for prebuilt dashboards to not
respect the size prop correctly.

Changed width and height from `size` to `${size}px` to properly apply
the size prop when rendering system avatars.
The system activity avatar (Sentry icon for prebuilt dashboards) was
using useInvertedTheme which caused incorrect colors in dark mode:

- Light mode: used dark theme → displayed correctly ✓
- Dark mode: used light theme → light colors on dark page ✗

Fixed by removing the ThemeProvider wrapper with invertedTheme. The
Flex component now uses the current theme's tokens directly, which are
already designed to have proper contrast in both light and dark modes.
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Feb 4, 2026
@edwardgou-sentry edwardgou-sentry requested a review from a team February 4, 2026 16:06
Copy link
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

@edwardgou-sentry edwardgou-sentry merged commit a5f7429 into master Feb 4, 2026
59 checks passed
@edwardgou-sentry edwardgou-sentry deleted the egou/fix/system-activity-avatar-not-respecting-size-prop branch February 4, 2026 16:42
jaydgoss pushed a commit that referenced this pull request Feb 12, 2026
…7598)

- Fixed system activity avatar to respect the `size` prop by applying
width/height to the Flex container
- Drops using `useInvertedTheme` to allow using the correct theme
colours on system avatar
dcramer pushed a commit that referenced this pull request Feb 17, 2026
…7598)

- Fixed system activity avatar to respect the `size` prop by applying
width/height to the Flex container
- Drops using `useInvertedTheme` to allow using the correct theme
colours on system avatar
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.

2 participants