aboutsummaryrefslogtreecommitdiffstats
path: root/web_src
diff options
context:
space:
mode:
authorkolaente <k@knt.li>2021-10-16 04:22:24 +0200
committerGitHub <noreply@github.com>2021-10-16 10:22:24 +0800
commit6dd015a53e94852d2d5bea5fc0412fd3c979d680 (patch)
treeb9de8c21f6facee25374a236b21d45b9318edd21 /web_src
parent74b6805225b57ab765277107cac7c7159873626e (diff)
downloadgitea-6dd015a53e94852d2d5bea5fc0412fd3c979d680.tar.gz
gitea-6dd015a53e94852d2d5bea5fc0412fd3c979d680.zip
fix: code review comments on mobile (#17321)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'web_src')
-rw-r--r--web_src/less/_repository.less4
-rw-r--r--web_src/less/_review.less54
2 files changed, 56 insertions, 2 deletions
diff --git a/web_src/less/_repository.less b/web_src/less/_repository.less
index 3d7d40ffa3..9f32f427f3 100644
--- a/web_src/less/_repository.less
+++ b/web_src/less/_repository.less
@@ -955,6 +955,10 @@
.ui.comments {
max-width: 100%;
+
+ .avatar {
+ margin-right: .5rem;
+ }
}
.comment {
diff --git a/web_src/less/_review.less b/web_src/less/_review.less
index 2b15eec82d..12bd6a608a 100644
--- a/web_src/less/_review.less
+++ b/web_src/less/_review.less
@@ -48,13 +48,51 @@
}
.comment-code-cloud {
- padding: .5rem;
- padding-left: 0;
+ padding: .5rem !important;
position: relative;
margin: 0 auto;
+ @media @mediaSm {
+ padding: .75rem !important;
+
+ .code-comment-buttons {
+ margin: .5rem 0 .25rem !important;
+
+ .code-comment-buttons-buttons {
+ width: 100%;
+ }
+ }
+ }
+
.comments .comment {
margin: 0;
+
+ @media @mediaSm {
+ padding: 0;
+
+ .comment-header-right.actions .ui.basic.label {
+ display: none;
+ }
+
+ .avatar {
+ width: auto;
+ float: none;
+ margin: 0 .5rem 0 0;
+ flex-shrink: 0;
+
+ &.image {
+ margin: 0 !important;
+ }
+ }
+
+ .comment-content {
+ margin-left: 0 !important;
+ }
+
+ &.code-comment {
+ padding: 0 0 .5rem !important;
+ }
+ }
}
.attached {
@@ -112,6 +150,17 @@
display: block;
}
}
+
+ @media @mediaSm {
+ .button {
+ width: 100%;
+ margin: 0 !important;
+
+ &:not(:last-child) {
+ margin-bottom: .75rem !important;
+ }
+ }
+ }
}
.diff-file-body .comment-form {
@@ -142,6 +191,7 @@ a.blob-excerpt:hover {
> .ui.segment {
width: 94vw;
}
+
.editor-toolbar {
overflow-x: auto;
}