Skip to content

Commit 60d0528

Browse files
ref(js): Convert UnlinkedAlert to a FC (#34632)
1 parent 9c1919f commit 60d0528

File tree

1 file changed

+14
-17
lines changed

1 file changed

+14
-17
lines changed

static/app/views/settings/account/notifications/unlinkedAlert.tsx

Lines changed: 14 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import {Component} from 'react';
21
import styled from '@emotion/styled';
32

43
import Alert from 'sentry/components/alert';
@@ -9,23 +8,21 @@ type Props = {
98
organizations: OrganizationSummary[];
109
};
1110

12-
class UnlinkedAlert extends Component<Props> {
13-
render() {
14-
const {organizations} = this.props;
15-
return (
16-
<StyledAlert type="warning" showIcon>
17-
{t(
18-
'You\'ve selected Slack as your delivery method, but do not have a linked account for the following organizations. You\'ll receive email notifications instead until you type "/sentry link" into your Slack workspace to link your account. If slash commands are not working, please re-install the Slack integration.'
19-
)}
20-
<ul>
21-
{organizations.map(organization => (
22-
<li key={organization.id}>{organization.slug}</li>
23-
))}
24-
</ul>
25-
</StyledAlert>
26-
);
27-
}
11+
function UnlinkedAlert({organizations}: Props) {
12+
return (
13+
<StyledAlert type="warning" showIcon>
14+
{t(
15+
'You\'ve selected Slack as your delivery method, but do not have a linked account for the following organizations. You\'ll receive email notifications instead until you type "/sentry link" into your Slack workspace to link your account. If slash commands are not working, please re-install the Slack integration.'
16+
)}
17+
<ul>
18+
{organizations.map(organization => (
19+
<li key={organization.id}>{organization.slug}</li>
20+
))}
21+
</ul>
22+
</StyledAlert>
23+
);
2824
}
25+
2926
const StyledAlert = styled(Alert)`
3027
margin: 20px 0px;
3128
`;

0 commit comments

Comments
 (0)