File tree Expand file tree Collapse file tree 4 files changed +16
-10
lines changed
src/Components/AuthorCard Expand file tree Collapse file tree 4 files changed +16
-10
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @programmer_network/yail" ,
3
- "version" : " 1.0.152 " ,
3
+ "version" : " 1.0.153 " ,
4
4
"description" : " Programmer Network's official UI library for React" ,
5
5
"author" : " Aleksandar Grbic - (https://programmer.network)" ,
6
6
"publishConfig" : {
Original file line number Diff line number Diff line change 3
3
exports [` AuthorCard component > renders correctly 1` ] = `
4
4
<DocumentFragment >
5
5
<div
6
- class = " border border-primary-text-color p-6"
6
+ class = " border-2 border-primary-text-color/20 p-6 rounded-lg "
7
7
>
8
8
<div
9
9
class = " flex flex-col items-center gap-4 md:flex-row"
@@ -24,13 +24,13 @@ exports[`AuthorCard component > renders correctly 1`] = `
24
24
</div >
25
25
</div >
26
26
<div >
27
- <h3
28
- class = " text-xs md:text-2xl font-bold text-primary mb-4 !mb-0"
27
+ <h2
28
+ class = " text-lg md:text-3xl font-bold text-primary mb-4 !mb-0"
29
29
>
30
30
John Doe
31
- </h3 >
31
+ </h2 >
32
32
<p
33
- class = " mb-2 text-primary-text-color !text-base "
33
+ class = " mb-2 text-primary-text-color !text-lg "
34
34
>
35
35
An expert in the field.
36
36
</p >
Original file line number Diff line number Diff line change
1
+ import classNames from "classnames" ;
1
2
import React from "react" ;
2
3
3
4
import Avatar from "Components/Avatar" ;
4
- import { H3 , Paragraph } from "Components/Typography" ;
5
+ import { H2 , Paragraph } from "Components/Typography" ;
5
6
6
7
import { IAuthorCardProps } from "./types" ;
7
8
8
9
const AuthorCard : React . FC < IAuthorCardProps > = ( {
9
10
name,
10
11
avatar,
11
12
about,
13
+ className,
12
14
onClick
13
15
} ) => {
14
16
return (
15
17
< div
16
- className = 'border border-primary-text-color p-6'
18
+ className = { classNames (
19
+ "border-2 border-primary-text-color/20 p-6 rounded-lg" ,
20
+ className
21
+ ) }
17
22
onClick = { ( ) => ( onClick ? onClick ( { name, avatar, about } ) : undefined ) }
18
23
>
19
24
< div className = 'flex flex-col items-center gap-4 md:flex-row' >
20
25
< div className = 'hidden md:block' >
21
26
< Avatar src = { avatar } size = { 75 } />
22
27
</ div >
23
28
< div >
24
- < H3 className = '!mb-0' > { name } </ H3 >
25
- < Paragraph className = '!text-base ' > { about } </ Paragraph >
29
+ < H2 className = '!mb-0' > { name } </ H2 >
30
+ < Paragraph className = '!text-lg ' > { about } </ Paragraph >
26
31
</ div >
27
32
</ div >
28
33
</ div >
Original file line number Diff line number Diff line change @@ -3,4 +3,5 @@ export interface IAuthorCardProps {
3
3
avatar ?: string ;
4
4
about : string ;
5
5
onClick ?: ( author : { name : string ; avatar ?: string ; about : string } ) => void ;
6
+ className ?: string ;
6
7
}
You can’t perform that action at this time.
0 commit comments