SOURCE

console 命令行工具 X clear

                    
>
console
<html>

<head>
	<title>background-clip</title>
</head>
<body>
	<p class="border-box">背景延伸到边框。</p>
	<p class="padding-box">背景延伸到边框的内部边缘。</p>
	<p class="content-box">背景仅延伸到内容盒的边缘。</p>
	<p class="text">背景被裁剪为前景文本。</p>
</body>

</html>
p {
    border: .8em darkviolet;
    border-style:  double;
    margin: 1em 0;
    padding: 1.4em;
    background: linear-gradient(60deg, red, yellow, red, yellow, red);
    font: 900 1.2em sans-serif;
    text-decoration: underline;
}
.border-box {
    background-clip: border-box;
}

.padding-box {
    background-clip: padding-box;
}

.content-box {
    background-clip: content-box;
}

.text {
    background-clip: text;
    -webkit-background-clip: text;
    color: rgba(0, 0, 0, .2);
}