From 59a72077280a356d8160a1d3c59f864240704bf1 Mon Sep 17 00:00:00 2001 From: Gabriel Augendre Date: Sun, 27 Dec 2020 15:49:27 +0100 Subject: [PATCH] Update custom css look --- articles/admin.py | 10 ++++++---- articles/static/admin_articles.css | 5 +++-- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/articles/admin.py b/articles/admin.py index 65180f2..1d23ea5 100644 --- a/articles/admin.py +++ b/articles/admin.py @@ -41,11 +41,13 @@ class ArticleAdmin(admin.ModelAdmin): ), ( "Content", + {"fields": ("content",)}, + ), + ( + "Custom CSS", { - "fields": ( - "content", - "custom_css", - ) + "fields": ("custom_css",), + "classes": ("collapse",), }, ), ] diff --git a/articles/static/admin_articles.css b/articles/static/admin_articles.css index 7a76432..2f7862d 100644 --- a/articles/static/admin_articles.css +++ b/articles/static/admin_articles.css @@ -1,13 +1,14 @@ #id_content, #id_custom_css { font-family: "JetBrains Mono", monospace; + min-height: 30em; + resize: vertical; } #id_content { width: calc(100% - 1em); height: 44.5em; - resize: vertical; } -label[for=id_content] { +label[for=id_content], label[for=id_custom_css] { display: none; }