From 10384a8a6fbfe84d19f3f629a09e36ad4643d25b Mon Sep 17 00:00:00 2001 From: Cristian Date: Wed, 7 Oct 2020 10:15:56 -0500 Subject: [PATCH] style: Improve look of tags in admin list --- archivebox/core/admin.py | 4 ++-- archivebox/themes/default/static/admin.css | 8 ++++++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/archivebox/core/admin.py b/archivebox/core/admin.py index 14f24c19..b28d6e52 100644 --- a/archivebox/core/admin.py +++ b/archivebox/core/admin.py @@ -81,9 +81,9 @@ class SnapshotAdmin(admin.ModelAdmin): def title_str(self, obj): canon = obj.as_link().canonical_outputs() tags = ''.join( - format_html(' {} ', tag) + format_html(' {} ', tag.id, tag) for tag in obj.tags.all() - ) if obj.tags.all() else '' + ) return format_html( '' '' diff --git a/archivebox/themes/default/static/admin.css b/archivebox/themes/default/static/admin.css index b2b58d64..932f380b 100644 --- a/archivebox/themes/default/static/admin.css +++ b/archivebox/themes/default/static/admin.css @@ -222,3 +222,11 @@ body.model-snapshot.change-list #content .object-tools { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } } + +.tags > a > .tag { + border: 1px solid; + border-radius: 10px; + background-color: #f3f3f3; + padding: 3px; +} +