html: Show related bugs that were merged.
authorRicardo Wurmus <rekado@elephly.net>
Mon, 4 Feb 2019 00:24:25 +0000 (01:24 +0100)
committerRicardo Wurmus <rekado@elephly.net>
Mon, 4 Feb 2019 00:24:25 +0000 (01:24 +0100)
* mumi/web/view/html.scm (issue-page): Process "mergedwith" field.
* assets/css/screen.css: Add rules for ul.merged.

assets/css/screen.css
mumi/web/view/html.scm

index 012d359011065336b57f43155902134db08fbfaa..45aea2441698f378082af1c5221fda4cf0b5e4cc 100644 (file)
@@ -61,6 +61,13 @@ h2 {
     padding-bottom: 5px;
 }
 
+ul.merged li {
+    display: inline-block;
+}
+ul.merged li + li:before {
+    content: ", ";
+}
+
 p {
     max-width: 70rem;
 }
index 8cb811fdc5e8a704ef8c39b083f65b14f7ab4df9..bff509fb4b316d90514f1e5e4b46c75776733869 100644 (file)
@@ -338,7 +338,15 @@ range.  The supported arguments are the same as for "
                              ;; return value, because it swallows
                              ;; non-ASCII characters.
                              (sender-name (first messages))
-                             ".")))
+                             ".")
+             ,@(if (bug-mergedwith bug)
+                   `((ul (@ (class "merged"))
+                         "Merged with: "
+                         ,(map (lambda (id)
+                                 `(li (a (@ (href ,(string-append "/issue/" id)))
+                                         ,id)))
+                               (string-split (bug-mergedwith bug) #\space))))
+                   '())))
       (div
        (@ (class "row"))
        (div