From 6f684e02831f6e63a39fb0751fb390c9df8f7c4c Mon Sep 17 00:00:00 2001 From: Floorb <132411956+Neetpone@users.noreply.github.com> Date: Tue, 16 May 2023 23:40:16 -0400 Subject: [PATCH] fix: syntax highlighting for redtext --- includes/Pastedown.php | 2 +- public/theme/bulma/css/paste.css | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/includes/Pastedown.php b/includes/Pastedown.php index 51766a9..3a8bdc1 100644 --- a/includes/Pastedown.php +++ b/includes/Pastedown.php @@ -6,7 +6,7 @@ use ParsedownExtra; class Pastedown extends ParsedownExtra { public function __construct() { $this->BlockTypes['>'] = ['Greentext']; - $this->BlockTypes['<'] []= ['Redtext']; + array_unshift($this->BlockTypes['<'], 'Redtext'); $this->BlockTypes['@'] = ['Purpletext']; } diff --git a/public/theme/bulma/css/paste.css b/public/theme/bulma/css/paste.css index b9e5c19..6d5029c 100644 --- a/public/theme/bulma/css/paste.css +++ b/public/theme/bulma/css/paste.css @@ -262,16 +262,15 @@ code { white-space: pre-wrap; } -.content .greentext { +.greentext { color: #789922; - content: ">"; } -.content .redtext { +.redtext { color: #d12222; } -.content .purpletext { +.purpletext { color: #9f14ae; }