Skip to content

Commit 8d0f7e1

Browse files
authored
Merge pull request #8845 from ImMiguelP/chakra-postmergebanner
refactor: postmergebanner to chakra
2 parents c974a73 + da0edd9 commit 8d0f7e1

File tree

1 file changed

+15
-20
lines changed

1 file changed

+15
-20
lines changed
Lines changed: 15 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,30 @@
11
import React from "react"
2-
import styled from "@emotion/styled"
32
import BannerNotification from "../BannerNotification"
43
import Translation from "../Translation"
54

65
import { TranslationKey } from "../../utils/translations"
7-
8-
const StyledBannerNotification = styled(BannerNotification)`
9-
display: flex;
10-
z-index: 1;
11-
justify-content: center;
12-
p {
13-
max-width: 100ch;
14-
margin: 0;
15-
padding: 0;
16-
}
17-
a {
18-
text-decoration: underline;
19-
}
20-
text-align: center;
21-
`
6+
import { Center, Text } from "@chakra-ui/react"
227

238
export interface IProps {
249
translationString: TranslationKey
2510
}
2611

2712
const PostMergeBanner: React.FC<IProps> = ({ translationString }) => (
28-
<StyledBannerNotification shouldShow={true}>
29-
<p>
13+
<Center
14+
as={BannerNotification}
15+
shouldShow={true}
16+
zIndex={1}
17+
textAlign="center"
18+
sx={{
19+
a: {
20+
"text-decoration": "underline",
21+
},
22+
}}
23+
>
24+
<Text maxW="100ch" m={0} p={0}>
3025
<Translation id={translationString} />
31-
</p>
32-
</StyledBannerNotification>
26+
</Text>
27+
</Center>
3328
)
3429

3530
export default PostMergeBanner

0 commit comments

Comments
 (0)