Skip to content

A platform for community discussion. Free, open, simple.

UX: Additional protections to prevent tag nesting exploits in posts

Kriscb9524c365e4
diff --git a/app/assets/stylesheets/common/base/topic-post.scss b/app/assets/stylesheets/common/base/topic-post.scss
index 0c300ff8b18..71ff99499d2 100644
--- a/app/assets/stylesheets/common/base/topic-post.scss
+++ b/app/assets/stylesheets/common/base/topic-post.scss
@@ -79,8 +79,13 @@
a { word-wrap: break-word; }
ins { background-color: dark-light-choose($success-low, scale-color($success, $lightness: -60%)); }
del { background-color: dark-light-choose($danger-low, scale-color($danger, $lightness: -60%)); }
+ // Prevents users from breaking posts with tag nesting
big { font-size: 2rem; }
small { font-size: 0.75rem; }
+ small small { font-size: .75em; }
+ big big { font-size: 1em; }
+ sub sub sub {bottom: 0;}
+ sup sup sup {top: 0;}
}
.cooked, .d-editor-preview {