about summary refs log tree commit diff
diff options
context:
space:
mode:
authorThibG <thib@sitedethib.com>2020-04-28 09:44:17 +0200
committerThibaut Girka <thib@sitedethib.com>2020-05-03 21:41:15 +0200
commit502a0365df7b74ba7a430e79cbda8881e87c97d4 (patch)
tree16dcbf4b5aa39f7198ea2fdc51a28c87d0f7913f
parenta22e6a368333f3563f8d8d56d8e98d02088e82dc (diff)
[Glitch] Fix messed up z-index when NoScript blocks media/previews
Port 04eb59986461bc802d4432fe4131e09eadd070c0 to glitch-soc

Signed-off-by: Thibaut Girka <thib@sitedethib.com>
-rw-r--r--app/javascript/flavours/glitch/styles/basics.scss12
1 files changed, 12 insertions, 0 deletions
diff --git a/app/javascript/flavours/glitch/styles/basics.scss b/app/javascript/flavours/glitch/styles/basics.scss
index 77631097a..eb78b189d 100644
--- a/app/javascript/flavours/glitch/styles/basics.scss
+++ b/app/javascript/flavours/glitch/styles/basics.scss
@@ -150,3 +150,15 @@ button {
     height: 100%;
   }
 }
+
+// NoScript adds a __ns__pop2top class to the full ancestry of blocked elements,
+// to set the z-index to a high value, which messes with modals and dropdowns.
+// Blocked elements can in theory only be media and frames/embeds, so they
+// should only appear in statuses, under divs and articles.
+body,
+div,
+article {
+  .__ns__pop2top {
+    z-index: unset !important;
+  }
+}