Skip to content

Commit

Permalink
ref(js): useTheme in ActivityPlaceholder (#29182)
Browse files Browse the repository at this point in the history
  • Loading branch information
evanpurkhiser authored Oct 8, 2021
1 parent 2f58001 commit fa4fcf7
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions static/app/views/alerts/details/activity/activityPlaceholder.tsx
Original file line number Diff line number Diff line change
@@ -1,22 +1,25 @@
import {withTheme} from '@emotion/react';
import {useTheme} from '@emotion/react';
import styled from '@emotion/styled';

import ActivityItem from 'app/components/activity/item';
import space from 'app/styles/space';
import {Theme} from 'app/utils/theme';

export default withTheme(function ActivityPlaceholder(props: {theme: Theme}) {
function ActivityPlaceholder() {
const theme = useTheme();

return (
<ActivityItem
bubbleProps={{
backgroundColor: props.theme.backgroundSecondary,
borderColor: props.theme.backgroundSecondary,
backgroundColor: theme.backgroundSecondary,
borderColor: theme.backgroundSecondary,
}}
>
{() => <Placeholder />}
</ActivityItem>
);
});
}

export default ActivityPlaceholder;

const Placeholder = styled('div')`
padding: ${space(4)};
Expand Down

0 comments on commit fa4fcf7

Please sign in to comment.