jquery.typer.js icon indicating copy to clipboard operation
jquery.typer.js copied to clipboard

Text color is dark in Firefox

Open namzo opened this issue 12 years ago • 4 comments

The color of the background & text are the same in Firefox. I tested on Firefox 18.0 on Mac.

namzo avatar Dec 16 '12 13:12 namzo

Can you post a jsfiddle or other online example showing that behaviour in a repeatable way?

kontur avatar May 13 '13 17:05 kontur

You can see the issue on the typer.js demo page: http://cosmos.layervault.com/typer-js.html

Note this only happens in Firefox -- Chrome, Safari, and IE all work as expected, but in FF, the highlighted string is a solid block of color, instead of reversing the text.

screen shot 2014-03-19 at 1 49 06 pm

  • I am using Firefox 27.0.1 on a mac.

spaceninja avatar Mar 19 '14 20:03 spaceninja

Set textColor to a value instead of leaving at null. This worked for me.

vpugh avatar Apr 03 '14 03:04 vpugh

spanWithColor = function(color, backgroundColor) {
    if (color === 'rgba(0, 0, 0, 0)') {
      color = 'rgb(255, 255, 255)';
    }

    return $('<span></span>')
      //.css('color', color)
      .css('color', 'rgb(255, 255, 255)')
      .css('background-color', 'rgb(255, 190, 76)');
  };

Use this .css('color', 'rgb(255, 255, 255)') instead of .css('color', color)

sasindu555 avatar Oct 01 '15 06:10 sasindu555