summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--public/css/markdown.css9
-rw-r--r--public/js/render.js12
2 files changed, 20 insertions, 1 deletions
diff --git a/public/css/markdown.css b/public/css/markdown.css
index 6741729d..36e45781 100644
--- a/public/css/markdown.css
+++ b/public/css/markdown.css
@@ -188,3 +188,12 @@
.markdown-body .alert > ul {
margin-bottom: 0;
}
+
+/* Make details boxes look like on GitHub */
+.markdown-body details summary {
+ cursor: pointer;
+}
+
+.markdown-body summary {
+ display: list-item;
+}
diff --git a/public/js/render.js b/public/js/render.js
index 46489247..860f8272 100644
--- a/public/js/render.js
+++ b/public/js/render.js
@@ -19,8 +19,18 @@ whiteList['style'] = []
whiteList['kbd'] = []
// allow ifram tag with some safe attributes
whiteList['iframe'] = ['allowfullscreen', 'name', 'referrerpolicy', 'sandbox', 'src', 'width', 'height']
-// allow summary tag
+// allow details tag
+whiteList['details'] = []
+// allow summary tag for details
whiteList['summary'] = []
+// allow ruby tag
+whiteList['ruby'] = []
+// allow rt tag for ruby
+whiteList['rt'] = []
+// allow figure tag
+whiteList['figure'] = []
+// allow figcaption tag
+whiteList['figcaption'] = []
var filterXSSOptions = {
allowCommentTag: true,