被选择文本圆角样式
https://codepen.io/ines/pen/NXbmRO
<div class="edit">Edit text below</div>
<h1>
<div class="goo" contenteditable="true">This is an example of a simple headline or text with rounded corners using<br>a gooey SVG filter.</div>
</h1>
<!-- Filter: https://css-tricks.com/gooey-effect/ -->
<svg style="visibility: hidden; position: absolute;" width="0" height="0" xmlns="http://www.w3.org/2000/svg" version="1.1">
<defs>
<filter id="goo"><feGaussianBlur in="SourceGraphic" stdDeviation="10" result="blur" />
<feColorMatrix in="blur" mode="matrix" values="1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 19 -9" result="goo" />
<feComposite in="SourceGraphic" in2="goo" operator="atop"/>
</filter>
</defs>
</svg>
:root {
--color-bg: #34304c;
--color-bg2: #534d7a;
--color-highlight: #fff;
--font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}
.goo {
font-size: 3rem;
line-height: 1.35;
display: inline;
box-decoration-break: clone;
background: var(--color-highlight);
padding: 0.5rem 1rem;
filter: url('#goo');
}
.goo:focus {
outline: 0;
}
.edit {
display: inline-block;
padding: 0.5rem 1rem;
background: var(--color-bg2);
text-transform: uppercase;
font-size: 0.7rem;
color: var(--color-highlight);
border-radius: 1em;
}
body {
padding: 7.5vh 100px 0 100px;
font-family: var(--font);
background: var(--color-bg);
}