css3渐变
css3渐变:由一个颜色到另一个颜色之间的平滑过渡,至少两个颜色
渐变用的属性为: background:; background - image:;
线性渐变: linear - gradient(方位,颜色1起始位,颜色2结束位)
-webkit- linear - gradient()
方位: left right
to left 去左边
to left top去左上角
top bottom
px %
颜色:十六进制
颜色单词
rgb() rgba()
起始位,结束位: px %
重复渐变: repeating-linear-gradient()
径向渐变
径向渐变:由中心向四周的渐变
radial- gradient(方位,形状,大小,颜色1起始位,颜色2结束位)
方位: px %
形状:
circle 正圆
ellipse椭圆
大小:
closest-side:最近边;
farthest-side:最远边:
closest-corner:最近角;
farthest-corner:最远角。
重复径向渐变:
repeating-radial-gradient( )