gitea/web_src/css/modules/comment.css
silverwind b92c142c97
Clean up various avatar dimensions (#24701)
Clean up a few cases where avatar dimensions were overwritten via CSS,
which were no longer needed or were possible to set via HTML width.

Also included are two small fixes:

- Fix one more case of incorrect avatar offset on review timeline
- Vertically center avatars in review sidebar

There is more to be done here, but some of the work depends on Fomantic
`comment` module removal, or in the case of org member lists, a refactor
of the `avatarlink` template to accept a size.

<img width="371" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/9c5902fb-2b89-4a7d-a152-60e74c3b2c56">
<img width="306" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/c8d92e2a-91c9-4f4a-a7de-6ae1a6bc0479">

---------

Co-authored-by: Giteabot <teabot@gitea.io>
2023-05-14 14:15:59 +00:00

92 lines
1.5 KiB
CSS

/* These are the remnants of the fomantic comment module */
/* TODO: remove all of these rules */
.ui.comments {
margin: 1.5em 0;
max-width: 650px;
}
.ui.comments:first-child {
margin-top: 0;
}
.ui.comments:last-child {
margin-bottom: 0;
}
.ui.comments .comment {
position: relative;
background: none;
margin: 0.5em 0 0;
padding: 0.5em 0 0;
border: none;
border-top: none;
line-height: 1.2;
}
.ui.comments .comment:first-child {
margin-top: 0;
padding-top: 0;
}
.ui.comments .comment > .comments {
margin: 0 0 0.5em 0.5em;
padding: 1em 0 1em 1em;
}
.ui.comments .comment > .comments::before {
position: absolute;
top: 0;
left: 0;
}
.ui.comments .comment > .comments .comment {
border: none;
border-top: none;
background: none;
}
.ui.comments .comment .avatar {
float: left;
width: 2.5em;
}
.ui.comments .comment > .content {
display: block;
}
.ui.comments .comment > .avatar ~ .content {
margin-left: 3.5em;
}
.ui.comments .comment .author {
font-size: 1em;
font-weight: 500;
}
.ui.comments .comment a.author {
cursor: pointer;
}
.ui.comments .comment .metadata {
display: inline-block;
margin-left: 0.5em;
font-size: 0.875em;
}
.ui.comments .comment .metadata > * {
display: inline-block;
margin: 0 0.5em 0 0;
}
.ui.comments .comment .metadata > :last-child {
margin-right: 0;
}
.ui.comments .comment .text {
margin: 0.25em 0 0.5em;
font-size: 1em;
word-wrap: break-word;
line-height: 1.3;
}