TD {width:30px; height:30px; display:table-cell; border:1px solid black;} var color = rgb(102,74,157); .original {background-color:color} .opposite {background-color:blueshift(color,0.5)} .oppositesat {background-color:saturation(blueshift(color,0.5),1)} .shift120 {background-color:blueshift(color,1/3)} .shift120sat {background-color:saturation(blueshift(color,1/3),1)} .shift240 {background-color:blueshift(color,2/3)} .shift240sat {background-color:saturation(blueshift(color,2/3),1)} .desaturatedlight {background-color:lighten(desaturate(color,0.5),0.5)} for (var row=1;row<=10;row++) { var col1 = blueshift(color,row*0.1); jxss('TR.row'+row+' TD.col1', {'background-color':col1}); var col2 = redshift(color,row*0.1); jxss('TR.row'+row+' TD.col2', {'background-color':col2}); var col3 = saturate(color,row*0.1); jxss('TR.row'+row+' TD.col3', {'background-color':col3}); var col4 = desaturate(color,row*0.1); jxss('TR.row'+row+' TD.col4', {'background-color':col4}); var col5 = lighten(color,row*0.1); jxss('TR.row'+row+' TD.col5', {'background-color':col5}); var col6 = darken(color,row*0.1); jxss('TR.row'+row+' TD.col6', {'background-color':col6}); }