From c55b94202858eac95358358d2add5cd46afa38b4 Mon Sep 17 00:00:00 2001 From: Adam Mathes Date: Sat, 10 Feb 2018 14:03:38 -0800 Subject: add pre,code tags. css tweaks --- models/item/item.go | 2 +- static/style.css | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/models/item/item.go b/models/item/item.go index 91335cf..c5ffff9 100644 --- a/models/item/item.go +++ b/models/item/item.go @@ -70,7 +70,7 @@ func (i *Item) FullSave() { func filterPolicy() *bluemonday.Policy { p := bluemonday.NewPolicy() - p.AllowElements("ul", "ol", "li", "blockquote", "a", "img", "p", "h1", "h2", "h3", "h4", "b", "i", "em", "strong") + p.AllowElements("ul", "ol", "li", "blockquote", "a", "img", "p", "h1", "h2", "h3", "h4", "b", "i", "em", "strong", "pre", "code") p.AllowAttrs("href").OnElements("a") p.AllowAttrs("src", "alt").OnElements("img") return p diff --git a/static/style.css b/static/style.css index 76d1ebd..8c44363 100644 --- a/static/style.css +++ b/static/style.css @@ -199,6 +199,7 @@ button { min-width: 0; width: 100%; max-width: 100%; + overflow: hidden; } -- cgit v1.2.3