Merge pull request #171 from dewyatt/twilight-text-selection Fix twilight text selection
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
diff --git a/themes/prism-twilight.css b/themes/prism-twilight.css
index f0ec87d..94ba9e9 100644
--- a/themes/prism-twilight.css
+++ b/themes/prism-twilight.css
@@ -44,6 +44,19 @@ pre[class*="language-"]::selection { /* Firefox */
background:hsl(200, 4%, 16%); /* #282A2B */
}
+/* Text Selection colour */
+pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection,
+code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection {
+ text-shadow: none;
+ background: hsla(0,0%,93%,0.15); /* #EDEDED */
+}
+
+pre[class*="language-"]::selection, pre[class*="language-"] ::selection,
+code[class*="language-"]::selection, code[class*="language-"] ::selection {
+ text-shadow: none;
+ background: hsla(0,0%,93%,0.15); /* #EDEDED */
+}
+
/* Inline code */
:not(pre) > code[class*="language-"] {
border-radius: .3em;
@@ -121,14 +134,6 @@ pre[data-line] {
color: hsl(33, 33%, 52%); /* #AC885B */
}
-/* Text Selection colour */
-::selection {
- background: hsla(0,0%,93%,0.15); /* #EDEDED */
-}
-::-moz-selection {
- background: hsla(0,0%,93%,0.15); /* #EDEDED */
-}
-
/* Make the tokens sit above the line highlight so the colours don't look faded. */
.token {
position:relative;