上面的演示由以下样式实现
div.hslL1 { background:hsl(320, 100%, 50%); height:20px; }div.hslL2 { background:hsl(320, 50%, 50%); height:20px; }div.hslL3 { background:hsl(320, 100%, 75%); height:20px; }div.hslL4 { background:hsl(202, 100%, 50%); height:20px; }div.hslL5 { background:hsl(202, 50%, 50%); height:20px; }div.hslL6 { background:hsl(202, 100%, 75%); height:20px; }
浏览器支持:
Firefox(3.05+) Google Chrome(1.0.154+) Google Chrome(2.0.156+) Internet Explorer(IE7, IE8 RC1 ) Opera(9.6+) Safari(3.2.1+ windows) CSS3 HSLA上面的效果由以下样式实现:
div.hslaL1 { background:hsla(165, 35%, 50%, 0.2); height:20px; }div.hslaL2 { background:hsla(165, 35%, 50%, 0.4); height:20px; }div.hslaL3 { background:hsla(165, 35%, 50%, 0.6); height:20px; }div.hslaL4 { background:hsla(165, 35%, 50%, 0.8); height:20px; }div.hslaL5 { background:hsla(165, 35%, 50%, 1.0); height:20px; }
浏览器支持:
Firefox(3.05+) Google Chrome(1.0.154+) Google Chrome(2.0.156+) Internet Explorer(IE7, IE8 RC1 ) Opera(9.6+) Safari(3.2.1+ windows)