about summary refs log tree commit diff
path: root/app
diff options
context:
space:
mode:
authorMaciek Baron <thebezet@gmail.com>2018-07-04 16:35:02 +0100
committerEugen Rochko <eugen@zeonfederated.com>2018-07-04 17:35:02 +0200
commit0bfa0f237495249a322cd3a1100b394211755e8c (patch)
treefbd8c6ca7476415f03ecfb250298875cab3bb5ed /app
parentf3af1a96a8456f6287c827aa96d363c92191024e (diff)
Add white outline to black emojis (fix #5083) (#7936)
Diffstat (limited to 'app')
-rw-r--r--app/javascript/styles/application.scss1
-rw-r--r--app/javascript/styles/mastodon/accessibility.scss14
2 files changed, 15 insertions, 0 deletions
diff --git a/app/javascript/styles/application.scss b/app/javascript/styles/application.scss
index 300040173..f207c02a6 100644
--- a/app/javascript/styles/application.scss
+++ b/app/javascript/styles/application.scss
@@ -22,3 +22,4 @@
 @import 'mastodon/tables';
 @import 'mastodon/admin';
 @import 'mastodon/rtl';
+@import 'mastodon/accessibility';
diff --git a/app/javascript/styles/mastodon/accessibility.scss b/app/javascript/styles/mastodon/accessibility.scss
new file mode 100644
index 000000000..373bcd4ac
--- /dev/null
+++ b/app/javascript/styles/mastodon/accessibility.scss
@@ -0,0 +1,14 @@
+$black-emojis: '8ball' 'ant' 'back' 'black_circle' 'black_large_square' 'black_medium_small_square' 'black_medium_square' 'black_nib' 'black_small_square' 'bomb' 'bust_in_silhouette' 'camera' 'camera_with_flash' 'clubs' 'copyright' 'curly_loop' 'currency_exchange' 'end' 'heavy_check_mark' 'heavy_division_sign' 'heavy_dollar_sign' 'heavy_minus_sign' 'heavy_multiplication_x' 'heavy_plus_sign' 'lower_left_fountain_pen' 'on' 'registered' 'soon' 'spades' 'spider' 'tm' 'top' 'waving_black_flag' 'wavy_dash' 'video_game';
+
+%white-emoji-outline {
+  filter: drop-shadow(1px 1px 0 $white) drop-shadow(-1px 1px 0 $white) drop-shadow(1px -1px 0 $white) drop-shadow(-1px -1px 0 $white);
+  transform: scale(.71);
+}
+
+.emojione {
+  @each $emoji in $black-emojis {
+    &[title=':#{$emoji}:'] {
+      @extend %white-emoji-outline;
+    }
+  }
+}