Commit e5295b1 1 parent f7190ba commit e5295b1 Copy full SHA for e5295b1
File tree 2 files changed +12
-8
lines changed
2 files changed +12
-8
lines changed Original file line number Diff line number Diff line change @@ -18,12 +18,15 @@ const SocialLinks: React.FC<{}> = () => {
18
18
>
19
19
< Button
20
20
onClick = { ( ) => window . open ( s . value ) }
21
- className = "group border-transparent group-hover:border-indigo-500 h-16 w-16 transition-colors duration-200 relative overflow-hidden bg-slide mr-2 "
21
+ className = "group border-transparent group-hover:border-indigo-500 transition-colors duration-200 relative overflow-hidden bg-slide"
22
22
sx = { {
23
- borderRadius : "999px" ,
23
+ width : "4rem" ,
24
+ height : "4rem" ,
25
+ borderRadius : "50%" ,
26
+ mr : "8px" ,
24
27
} }
25
28
>
26
- < SocialIcon id = { s . id } className = "fill-indigo-500 w-10 h-10 " />
29
+ < SocialIcon id = { s . id } size = "large" className = "fill-indigo-500" />
27
30
</ Button >
28
31
</ Tooltip >
29
32
) ) }
Original file line number Diff line number Diff line change @@ -55,14 +55,15 @@ export const SOCIAL_ICONS = {
55
55
56
56
export type SocialIconId = keyof typeof SOCIAL_ICONS ;
57
57
58
- export const SocialIcon : React . FC < { id : string ; className ?: string } > = ( {
59
- id,
60
- className,
61
- } ) => {
58
+ export const SocialIcon : React . FC < {
59
+ id : string ;
60
+ className ?: string ;
61
+ size ?: "small" | "medium" | "large" ;
62
+ } > = ( { id, className, size } ) => {
62
63
if ( ! id ) throw new Error ( "ContactId is required" ) ;
63
64
let Icon = SOCIAL_ICONS [ id as SocialIconId ] ;
64
65
if ( ! Icon ) throw new Error ( `'${ id } ' doesn't have any icon` ) ;
65
- return < Icon className = { className } color = "primary" /> ;
66
+ return < Icon className = { className } fontSize = { size } color = "primary" /> ;
66
67
} ;
67
68
export const DEV_TOOLS : {
68
69
[ key : string ] : ( props : SVGProps < SVGSVGElement > ) => JSX . Element ;
You can’t perform that action at this time.
0 commit comments