]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Better responsive design on many comment children
authorChocobozzz <me@florianbigard.com>
Wed, 18 Apr 2018 13:00:42 +0000 (15:00 +0200)
committerChocobozzz <me@florianbigard.com>
Wed, 18 Apr 2018 13:00:42 +0000 (15:00 +0200)
client/src/app/videos/+video-watch/comment/video-comment.component.scss
client/src/app/videos/+video-watch/comment/video-comments.component.scss
client/src/app/videos/+video-watch/video-watch.component.scss

index 3b0b7eafdb776f4f248b9a3c84d67b208add25f8..3a3f32b83b7693da97f1c949d6d0d3153d8efc87 100644 (file)
@@ -14,6 +14,8 @@
 
   .comment {
     flex-grow: 1;
+    // Fix word-wrap with flex
+    min-width: 1px;
 
     .highlighted-comment {
       display: inline-block;
@@ -44,8 +46,8 @@
     }
 
     .comment-html {
-      word-wrap: initial;
       word-break: normal;
+      word-wrap: break-word;
       text-align: justify;
 
       /deep/ a {
     }
   }
 }
+
+// Decrease the space of child comments on small screens
+@media screen and (max-width: 1600px) {
+  .children {
+    margin-left: -20px;
+  }
+}
+
+@media screen and (max-width: 1200px) {
+  .children {
+    margin-left: -30px;
+  }
+}
+
+@media screen and (max-width: 600px) {
+  .children {
+    margin-left: -40px;
+  }
+
+  .root-comment {
+    img { margin-right: 10px; }
+  }
+}
\ No newline at end of file
index 7aadc28662b0b51504c17a9d13d3017f1a899365..0b8aa1854f26fd0e823b6502034b1ac8dd2dc812 100644 (file)
@@ -19,8 +19,8 @@
   font-size: 13px;
 }
 
-.comment-html {
-  word-wrap: normal;
-  word-break: normal;
-  text-align: justify;
-}
+@media screen and (max-width: 600px) {
+  .view-replies {
+    margin-left: 46px;
+  }
+}
\ No newline at end of file
index 8bc9f8d9a816cd3e66927a0d90d4c5a20a966b02..fe3cc4ded433b020a0acd90354bafd9bb0cdf71e 100644 (file)
       font-size: 15px;
 
       .video-info-description-html {
-        word-wrap: break-word;
+        word-break: normal;
+        word-wrap: normal;
         text-align: justify;
       }