对于线性渐变的方向,设置左上到右下,起始颜色为红色,终止颜色为蓝色,正确的格式为?( )
A: linear-gradient(-45deg, red 0%, blue 100%)
B: linear-gradient(45deg, red 0%, blue 100%)
C: linear-gradient(top left, red 0%, blue 100%)
D: linear-gradient(0deg, red 0%, blue 100%)
A: linear-gradient(-45deg, red 0%, blue 100%)
B: linear-gradient(45deg, red 0%, blue 100%)
C: linear-gradient(top left, red 0%, blue 100%)
D: linear-gradient(0deg, red 0%, blue 100%)
举一反三
- 下列哪项是正确的线性渐变的写法?( ) A: background:linear-gradient(red,blue); B: background:linear-gradient(45deg,red,blue); C: background-image:linear-gradient(red,blue); D: background-image:linear-gradient(45deg,red,blue);
- 【单选题】background-image: linear-gradient(to right, red , yellow)与下面()效果一样。 A. background-image: linear-gradient(0deg, red , yellow) B. background-image: linear-gradient(90deg, red , yellow) C. background-image: linear-gradient(180deg, red , yellow) D. background-image: linear-gradient(-90deg, red , yellow)
- 实现一个css3线性渐变效果,渐变的方向是从右上角到左下角,起点颜色是从白色到黑色,以下写法正确的是( )。 A: ackground:linear-gradient(225deg,rgba(0,0,0,1),rgba(255,255,255,1)); B: ackground:linear-gradient(135deg,hsla(120,100%,0%,1),hsla(240,100%,100%,1)); C: ackground:linear-gradient(to top left,white,black); D: ackground: linear-gradient(to bottom left, white, black);
- 对HTML结构<p id=”red”class=”blue”>段落文本</p>,设置CSS样式为p{color:green;},#red{color:red;},.blue{color:blue;},“段落文本”的显示颜色为()。 A: 绿色(green) B: 黑色(black) C: 蓝色(blue) D: 红色(red)
- CSS3提供了背景渐变色的属性,下面表示正确的渐变色写法是?( ) A: background-size:linear-gradient(green,red); B: background-image:linear-gradient(green,red); C: background-color:inherit; D: background-position:linear-gradient(green,red);