1

I got this:

::selection {
    background-color: #80b3ff;
    color: #000000;
}
::-moz-selection {
    background-color: #80b3ff;
    color: #000000;
}
::-o-selection ....

But when I try to define all selectors together it doesn't work.

::selection, ::-moz-selection, ::-o-selection, ::-webkit-selection {
    background-color: #80b3ff;
    color: #000000;
}

What am I doing wrong?

BoltClock
  • 665,005
  • 155
  • 1,345
  • 1,328
Basti
  • 543
  • 1
  • 10
  • 20

1 Answers1

3

This happens because ::selection is a pseudo element. There's a good explanation for this here.

Community
  • 1
  • 1
JSideris
  • 4,823
  • 3
  • 30
  • 49