diff --git a/public/style.css b/public/style.css index 0c432fbb..f4e864ac 100644 --- a/public/style.css +++ b/public/style.css @@ -7472,9 +7472,6 @@ article code { .h1-5 { height: 1.5rem; } -.pre-line { - white-space: pre-line; } - .fira { font-family: "Fira Sans", sans-serif; } @@ -9396,10 +9393,13 @@ span.icon-rss::before { .timeline-item .avatar-icon.big { width: 3.875rem; height: 3.875rem; } } - .timeline-item .timeline-content-box > * { - display: block; - max-width: 100%; - max-height: 80vh; } + .timeline-item .timeline-content-box { + background-color: rgba(0, 0, 0, 0.2); + background-color: var(--timeline-content-background); } + .timeline-item .timeline-content-box > * { + display: block; + max-width: 100%; + max-height: 80vh; } .timeline-modal .container { max-height: 100vh; } diff --git a/public/themes/dark/theme.css b/public/themes/dark/theme.css index c69c5f6d..bcb5d540 100644 --- a/public/themes/dark/theme.css +++ b/public/themes/dark/theme.css @@ -288,6 +288,7 @@ pre, code, .codeblock { --forum-diff-insert-border-color: #30591b; --card-background: #282828; --card-background-hover: #333; + --timeline-content-background: rgba(255, 255, 255, 0.06); --irc-border-color: #333; --irc-tab-current-shadow: 0px 0px 5px #000 inset; --irc-tab-close-button-color: #bbb; diff --git a/public/themes/light/theme.css b/public/themes/light/theme.css index 1e6a2371..5ea692db 100644 --- a/public/themes/light/theme.css +++ b/public/themes/light/theme.css @@ -306,6 +306,7 @@ pre, code, .codeblock { --forum-diff-insert-border-color: #5baa3f; --card-background: #e8e8e8; --card-background-hover: #f0f0f0; + --timeline-content-background: rgba(0, 0, 0, 0.2); --irc-border-color: #ddd; --irc-tab-current-shadow: 0px 0px 5px #bbb inset; --irc-tab-close-button-color: #fff; diff --git a/src/parsing/parsing.go b/src/parsing/parsing.go index 63802938..9a747404 100644 --- a/src/parsing/parsing.go +++ b/src/parsing/parsing.go @@ -4,6 +4,7 @@ import ( "bytes" "github.com/yuin/goldmark/parser" + "github.com/yuin/goldmark/renderer/html" "github.com/yuin/goldmark" highlighting "github.com/yuin/goldmark-highlighting" @@ -42,6 +43,7 @@ var DiscordMarkdown = makeGoldmark( Previews: false, Embeds: false, })...), + goldmark.WithRendererOptions(html.WithHardWraps()), ) func ParseMarkdown(source string, md goldmark.Markdown) string { diff --git a/src/rawdata/scss/_core.scss b/src/rawdata/scss/_core.scss index d486bde4..bb05d4c4 100644 --- a/src/rawdata/scss/_core.scss +++ b/src/rawdata/scss/_core.scss @@ -337,10 +337,6 @@ article code { height: 1.5rem; } -.pre-line { - white-space: pre-line; -} - .fira { font-family: "Fira Sans", sans-serif; } diff --git a/src/rawdata/scss/_timeline.scss b/src/rawdata/scss/_timeline.scss index deb97b4e..b4ea6085 100644 --- a/src/rawdata/scss/_timeline.scss +++ b/src/rawdata/scss/_timeline.scss @@ -18,17 +18,21 @@ } } - .timeline-content-box > * { - display: block; - max-width: 100%; - max-height: 80vh; - } + .timeline-content-box { + @include usevar(background-color, timeline-content-background); - .timeline-content-box.embed { - @extend .aspect-ratio, .aspect-ratio--16x9; - - > iframe { - @extend .aspect-ratio--object; + > * { + display: block; + max-width: 100%; + max-height: 80vh; + } + + &.embed { + @extend .aspect-ratio, .aspect-ratio--16x9; + + > iframe { + @extend .aspect-ratio--object; + } } } } diff --git a/src/rawdata/scss/themes/dark/_variables.scss b/src/rawdata/scss/themes/dark/_variables.scss index f90fac10..48f13e07 100644 --- a/src/rawdata/scss/themes/dark/_variables.scss +++ b/src/rawdata/scss/themes/dark/_variables.scss @@ -99,6 +99,8 @@ $vars: ( card-background: #282828, card-background-hover: #333, + timeline-content-background: rgba(255, 255, 255, 0.06), + irc-border-color: #333, irc-tab-current-shadow: 0px 0px 5px #000 inset, irc-tab-close-button-color: #bbb, diff --git a/src/rawdata/scss/themes/light/_variables.scss b/src/rawdata/scss/themes/light/_variables.scss index 20f21859..0f02537c 100644 --- a/src/rawdata/scss/themes/light/_variables.scss +++ b/src/rawdata/scss/themes/light/_variables.scss @@ -99,6 +99,8 @@ $vars: ( card-background: #e8e8e8, card-background-hover: #f0f0f0, + timeline-content-background: rgba(0, 0, 0, 0.2), + irc-border-color: #ddd, irc-tab-current-shadow: 0px 0px 5px #bbb inset, irc-tab-close-button-color: #fff, diff --git a/src/templates/src/include/showcase_templates.html b/src/templates/src/include/showcase_templates.html index d63affae..beb73827 100644 --- a/src/templates/src/include/showcase_templates.html +++ b/src/templates/src/include/showcase_templates.html @@ -27,7 +27,7 @@ -