mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-11 03:24:16 +00:00
support small
This commit is contained in:
parent
358508b760
commit
0125d107cd
@ -54,7 +54,13 @@ export default (props) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return <div
|
return <div
|
||||||
className={classnames("userPreview", { ["clickable"]: typeof props.onClick === "function" })}
|
className={classnames(
|
||||||
|
"userPreview",
|
||||||
|
{
|
||||||
|
["clickable"]: typeof props.onClick === "function",
|
||||||
|
["small"]: props.small
|
||||||
|
}
|
||||||
|
)}
|
||||||
>
|
>
|
||||||
<div className="avatar" onClick={handleOnClick}>
|
<div className="avatar" onClick={handleOnClick}>
|
||||||
<Image
|
<Image
|
||||||
|
@ -1,8 +1,11 @@
|
|||||||
.userPreview {
|
.userPreview {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
|
gap: 10px;
|
||||||
|
|
||||||
svg {
|
svg {
|
||||||
fill: var(--app-color);
|
fill: var(--app-color);
|
||||||
margin-left: 6px;
|
margin-left: 6px;
|
||||||
@ -12,13 +15,25 @@
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&.small {
|
||||||
|
font-size: 0.8em;
|
||||||
|
|
||||||
|
gap: 7px;
|
||||||
|
|
||||||
|
.avatar {
|
||||||
|
width: 30px;
|
||||||
|
height: 30px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.avatar {
|
.avatar {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|
||||||
margin-right: 10px;
|
align-self: center;
|
||||||
|
justify-self: center;
|
||||||
|
|
||||||
width: 40px;
|
width: 40px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
@ -28,6 +43,8 @@
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
transform: translate(0, 3px);
|
||||||
|
|
||||||
img {
|
img {
|
||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
|
|
||||||
@ -45,17 +62,21 @@
|
|||||||
align-items: flex-start;
|
align-items: flex-start;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|
||||||
text-align: start;
|
|
||||||
|
|
||||||
width: fit-content;
|
width: fit-content;
|
||||||
|
height: fit-content;
|
||||||
|
|
||||||
color: var(--background-color-contrast);
|
color: var(--background-color-contrast);
|
||||||
|
|
||||||
h1 {
|
h1 {
|
||||||
align-self: start;
|
|
||||||
|
|
||||||
color: var(--background-color-contrast);
|
color: var(--background-color-contrast);
|
||||||
font-size: 1.1rem;
|
font-size: 1em;
|
||||||
|
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
span {
|
||||||
|
color: var(--text-color);
|
||||||
|
font-size: 0.8em;
|
||||||
|
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user