当前位置:网站首页>学习探索-给字体设置前景色
学习探索-给字体设置前景色
2022-08-04 16:58:00 【miao_zz】
效果示例图

代码
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>给字体设置前景色</title>
<style type="text/css">
* {
padding: 0px;
margin: 0px;
box-sizing: border-box;
}
html,
body {
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
}
.clip {
display: inline-block;
font-size: 36px;
background: linear-gradient(to right, #bc2c24, #7533ca);
/*
* text:背景被裁剪成文字的前景色
*/
background-clip: text;
-moz-background-clip: text;
-webkit-background-clip: text;
color: transparent;
}
</style>
</head>
<body>
<div class="clip">HELLO WRODL!</div>
</body>
</html>
边栏推荐
猜你喜欢
随机推荐
HCIP笔记(6)
taro 滚动组件ScrollView
湖北移动中兴B860AV2.1_S905L_线刷固件包
Mobile zte ZXV10 B860AV2. 1 - A_S905L2_MT7668_ wire brush the firmware package
ctfshow 萌新web1-21
CSDN21天学习挑战赛——程序流程控制(02)
Analysis of the gourd baby
小程序+自定义插件的混合模式
R语言使用cov函数计算矩阵或者dataframe数据变量之间的协方差、cor函数计算相关性、cor函数通过method参数指定相关性、相关性计算方法Pearson,Spearman, Kendall
xgboost模块param中的一些错误
机器学习(十六):主成成分分析(PCA)
拼多多详情API接口深度解读
Hubei Mobile HG680-LV_S905L3B_wire brush firmware package
水能自发变成“消毒水”,83岁斯坦福教授:揭示冬天容易得流感的部分原因...
通关剑指 Offer——剑指 Offer II 010. 和为 k 的子数组
小满nestjs(第一章 介绍nestjs)
"Distributed cloud best practices" BBS, on August 11, shenzhen
生产环境重大bug,update加上索引字段会走索引进行更新?还是走全表扫描
WPF 光标初始化的时候 temp 文件夹满了无法创建
Hubei Telecom Tianyi TY1608_S905L3B_MT7668_ card brush firmware package









