File tree Expand file tree Collapse file tree 1 file changed +15
-21
lines changed Expand file tree Collapse file tree 1 file changed +15
-21
lines changed Original file line number Diff line number Diff line change 6
6
FaXTwitter ,
7
7
FaYoutube ,
8
8
} from "react-icons/fa6"
9
- import { Box , Flex , Icon } from "@chakra-ui/react"
9
+
10
+ import { Flex } from "./ui/flex"
10
11
11
12
const socialColors = {
12
13
reddit : "#ff4301" ,
@@ -30,25 +31,18 @@ type SocialListItemProps = {
30
31
socialIcon : keyof typeof icons
31
32
}
32
33
33
- const SocialListItem = ( { children, socialIcon } : SocialListItemProps ) => (
34
- < Flex w = "100%" py = "2" px = "0" align = "center" >
35
- < Icon
36
- as = { icons [ socialIcon ] }
37
- pe = { 3 }
38
- boxSize = { 10 }
39
- color = { socialColors [ socialIcon ] }
40
- />
41
- < Box
42
- fontStyle = "italic"
43
- sx = { {
44
- "> a" : {
45
- fontStyle : "normal" ,
46
- } ,
47
- } }
48
- >
49
- { children }
50
- </ Box >
51
- </ Flex >
52
- )
34
+ const SocialListItem = ( { children, socialIcon } : SocialListItemProps ) => {
35
+ const SocialIcon = icons [ socialIcon ]
36
+
37
+ return (
38
+ < Flex className = "w-full items-center px-0 py-2" >
39
+ < SocialIcon
40
+ className = "size-10 shrink-0 pe-3"
41
+ style = { { color : socialColors [ socialIcon ] } }
42
+ />
43
+ < div className = "italic [&>a]:not-italic" > { children } </ div >
44
+ </ Flex >
45
+ )
46
+ }
53
47
54
48
export default SocialListItem
You can’t perform that action at this time.
0 commit comments