[Patchew-devel] [PATCH] www: provide permanent links to every message

Paolo Bonzini posted 1 patch 2 weeks, 4 days ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/patchew-ci tags/patchew/20210603073419.8311-1-pbonzini@redhat.com
static/css/base.css              | 7 +++++++
www/templates/series-detail.html | 4 ++--
2 files changed, 9 insertions(+), 2 deletions(-)

[Patchew-devel] [PATCH] www: provide permanent links to every message

Posted by Paolo Bonzini 2 weeks, 4 days ago
Allow including links to messages in emails.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 static/css/base.css              | 7 +++++++
 www/templates/series-detail.html | 4 ++--
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/static/css/base.css b/static/css/base.css
index fc89898..ff4a9f3 100644
--- a/static/css/base.css
+++ b/static/css/base.css
@@ -155,6 +155,13 @@ h1, h2, h3, .h1, .h2, .h3 {
     margin-left: 40px;
 }
 
+.panel-heading a.permalink {
+    visibility: hidden;
+}
+.panel-heading:hover a.permalink {
+    visibility: visible;
+}
+
 @media (min-width: 1200px) {
   #detail-ops {
     clear: right;
diff --git a/www/templates/series-detail.html b/www/templates/series-detail.html
index e15b44f..b7c599b 100644
--- a/www/templates/series-detail.html
+++ b/www/templates/series-detail.html
@@ -120,10 +120,10 @@ function prompt_and_open(obj, url) {
 <div class="col-lg-10">
     <div id="thread">
     {% for msg in messages %}
-        <div class="panel panel-default message reply-lvl-{{ msg.indent_level }}">
+        <div id="{{ msg.message_id }}" class="panel panel-default message reply-lvl-{{ msg.indent_level }}">
             <div class="panel-heading panel-toggler" onclick="patchew_toggler_onclick(this)">
                     <h3 class="panel-title">
-                        {{ msg.subject }}
+                      {{ msg.subject }} <a class="permalink" href="#{{msg.message_id}}"><span class="fa fa-sm fa-link"></span></a>
                     </h3>
 
                     <div class="message-info">
-- 
2.31.1

_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://listman.redhat.com/mailman/listinfo/patchew-devel

Re: [Patchew-devel] [PATCH] www: provide permanent links to every message

Posted by Philippe Mathieu-Daudé 2 weeks, 3 days ago
On 6/3/21 9:34 AM, Paolo Bonzini wrote:
> Allow including links to messages in emails.
> 
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  static/css/base.css              | 7 +++++++
>  www/templates/series-detail.html | 4 ++--
>  2 files changed, 9 insertions(+), 2 deletions(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>

_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://listman.redhat.com/mailman/listinfo/patchew-devel