about summary refs log tree commit diff
path: root/app/javascript/flavours/glitch/styles/components/media.scss
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2019-04-27 03:24:09 +0200
committerThibaut Girka <thib@sitedethib.com>2019-05-04 18:07:44 +0200
commitccf4f3240ae80f4b1410d816f03d0bef33062a71 (patch)
tree2ea8fd54803f2c002372f927785cf8bb5f5f4d4d /app/javascript/flavours/glitch/styles/components/media.scss
parent1149ddd3da0ca94d5dcdf3b58ca9424a5e34fc25 (diff)
[Glitch] Add blurhash
Port front-end changes from fba96c808d25d2fc35ec63ee6745a1e55a95d707 to glitch-soc

Signed-off-by: Thibaut Girka <thib@sitedethib.com>
Diffstat (limited to 'app/javascript/flavours/glitch/styles/components/media.scss')
-rw-r--r--app/javascript/flavours/glitch/styles/components/media.scss17
1 files changed, 17 insertions, 0 deletions
diff --git a/app/javascript/flavours/glitch/styles/components/media.scss b/app/javascript/flavours/glitch/styles/components/media.scss
index fabef2a56..0393a3886 100644
--- a/app/javascript/flavours/glitch/styles/components/media.scss
+++ b/app/javascript/flavours/glitch/styles/components/media.scss
@@ -117,6 +117,8 @@
   text-decoration: none;
   color: $secondary-text-color;
   line-height: 0;
+  position: relative;
+  z-index: 1;
 
   &,
   img {
@@ -131,6 +133,21 @@
   }
 }
 
+.media-gallery__preview {
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+  position: absolute;
+  top: 0;
+  left: 0;
+  z-index: 0;
+  background: $base-overlay-background;
+
+  &--hidden {
+    display: none;
+  }
+}
+
 .media-gallery__gifv {
   height: 100%;
   overflow: hidden;