FCC---Create a Gradual CSS Linear Gradient
2024-08-31 13:18:45
Applied Visual Design: Create a Gradual CSS Linear Gradient
background: linear-gradient(gradient_direction, color 1, color 2, color 3, ...)
The first argument specifies the direction from which color transition starts - it can be stated as a degree, where 90deg makes a vertical gradient and 45deg is angled like a backslash.
The following arguments specify the order of colors used in the gradient.
Example:
background: linear-gradient(90deg, red, yellow, rgb(204, 204, 255));
练习代码如下:
<style>
div {
border-radius: 20px;
width: %;
height: 400px;
margin: 50px auto;
background: linear-gradient(35deg, #ccffff, #ffcccc);
}
</style>
<div></div>
效果如下:
最新文章
- ASP.NET MVC Filters 4种默认过滤器的使用【附示例】
- Lua查找表元素过程(元表、__index方法是如何工作的)
- Linux 中常见的命令行,持续更新
- 黄聪:wordpress如何开启文章格式post format
- How Does #DeepDream Work?
- 利用if,else判断输入的是不是一个正整数
- Sqlite数据库的加密
- struts----用Action的属性接收参数
- Solr -- Solr Facet 2
- 【Tomcat】Tomcat工作原理及简单模拟实现
- idea integrate project
- kafka单节点的安装,部署,使用
- HashMap遍历的两种方式,推荐使用entrySet()
- 杂谈2.cpp
- Unity 处理预设中的中文
- LeetCode--020--括号匹配(java版)
- 51nod 1295 XOR key (可持久化Trie树)
- Android 开发添加控件事件的三种方式
- golang-开发配置
- ezmorph-1.0.6.jar的作用