📜  在背景图像顶部添加背景颜色 - 无论代码示例

📅  最后修改于: 2022-03-11 14:58:38.088000             🧑  作者: Mango

代码示例1
/* Working method */
.tinted-image {
  background: 
    /* top, transparent red, faked with gradient */ 
    linear-gradient(
      rgba(255, 0, 0, 0.45), 
      rgba(255, 0, 0, 0.45)
    ),
    /* bottom, image */
    url(image.jpg);
}Create a snippet