]> cat aescling's git repositories - mastodon.git/commitdiff
Add support for <sup> formatting element
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>
Wed, 14 Aug 2019 20:26:30 +0000 (22:26 +0200)
committerThibG <thib@sitedethib.com>
Tue, 20 Aug 2019 19:44:09 +0000 (21:44 +0200)
This is based of 3e095cab83f3e88c5f5f4ca9d7029379ed5b5b56

Related: https://git.pleroma.social/pleroma/pleroma/issues/1191

app/javascript/flavours/glitch/styles/components/status.scss
app/lib/sanitize_config.rb

index d0183c2de6df7ddd96beacafedaa4b6fa9ca54e3..5db93ac3bba8b6c9d347c0b1d9a91a94ca5fc2f3 100644 (file)
       text-align: sub;
     }
 
+    sup {
+      font-size: smaller;
+      vertical-align: supper;
+    }
+
     ul, ol {
       margin-left: 1em;
 
index e6e861eb9cb99117fe0fce38ecd1ea85e8800f87..956c464f768906b97a102de18606988f8263203a 100644 (file)
@@ -39,7 +39,7 @@ class Sanitize
     end
 
     MASTODON_STRICT ||= freeze_config(
-      elements: %w(p br span a abbr del pre blockquote code b strong u sub i em h1 h2 h3 h4 h5 ul ol li),
+      elements: %w(p br span a abbr del pre blockquote code b strong u sub sup i em h1 h2 h3 h4 h5 ul ol li),
 
       attributes: {
         'a'          => %w(href rel class title),