background-image:-webkit-gradient(linear,?0?0,?0?100%,?from(rgba(255,255,255,0.35)),
color-stop(0.3,?rgba(255,255,255,0.35)),?color-stop(0.3,?transparent),
color-stop(0.7,?transparent),?color-stop(0.7,?rgba(255,255,255,0.35)),
to(rgba(255,255,255,0.35)));
background-image:-webkit-linear-gradient(rgba(255,255,255,0.35)?0%,
rgba(255,255,255,0.35)?30%,?transparent?30%,?transparent?70%,
rgba(255,255,255,0.35)?70%,?rgba(255,255,255,0.35)?100%);
1 回答

Aadeutopia
TA貢獻2條經(jīng)驗 獲得超1個贊
線性漸變,background: linear-gradient(direction, color-stop1, color-stop2, ...);
direction:默認為to bottom,即從上向下的漸變;
stop:顏色的分布位置,默認均勻分布,例如有3個顏色,各個顏色的stop均為33.33%。
添加回答
舉報
0/150
提交
取消