File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ type AvatarsProps = {
19
19
onAvatarsClick ? : Function ,
20
20
onCounterClick ?: Function ,
21
21
onPlusClick ?: Function ,
22
+ withPlusButton ?: boolean ,
22
23
} ;
23
24
24
25
const tooltipClassName = css `
@@ -38,6 +39,7 @@ const Avatars = ({
38
39
onAvatarsClick,
39
40
onCounterClick,
40
41
onPlusClick,
42
+ withPlusButton,
41
43
...rest
42
44
} : AvatarsProps ) => {
43
45
return (
@@ -61,9 +63,12 @@ const Avatars = ({
61
63
< If condition = { users . length > 4 } >
62
64
< AvatarsCounterTag onClick = { onCounterClick } size = { size } > + { users . length - 4 } </ AvatarsCounterTag >
63
65
</ If >
64
- < AvatarsHandleTag onClick = { onPlusClick } size = { size } >
65
- < Icon name = "Plus" size = "xs" color = "PRIMARY" />
66
- </ AvatarsHandleTag >
66
+
67
+ < If condition = { ! ! withPlusButton } >
68
+ < AvatarsHandleTag onClick = { onPlusClick } size = { size } >
69
+ < Icon name = "Plus" size = "xs" color = "PRIMARY" />
70
+ </ AvatarsHandleTag >
71
+ </ If >
67
72
</ AvatarsTag >
68
73
) ;
69
74
} ;
Original file line number Diff line number Diff line change @@ -20,8 +20,8 @@ export default {
20
20
21
21
export const common = ( ) => (
22
22
< Column gap = "lg" >
23
- < Avatars size = "md" users = { USERS } />
24
- < Avatars users = { USERS } />
23
+ < Avatars size = "md" users = { USERS } withPlusButton />
24
+ < Avatars users = { USERS } withPlusButton />
25
25
</ Column >
26
26
) ;
27
27
You can’t perform that action at this time.
0 commit comments