运行 ❯
获取您
自己的
网站
×
更改方向
保存代码
更改主题,深色/浅色
前往 Spaces
<!DOCTYPE html> <html> <head> <style> h2 { outline-style: solid; outline-color: hsla(89, 43%, 51%, 0.3); } div.a { outline-style: solid; outline-color: hsla(89, 43%, 51%, 0.3); } div.b { border: 1px solid black; outline-style: solid; outline-color: hsla(89, 43%, 51%, 0.3); } </style> </head> <body> <h1>The outline-color Property</h1> <h2>A heading with a colored outline</h2> <div class="a">The outline-color can be specified with a HSLA value.</div> <br> <div class="b">Notice that the outline is outside of any border.</div> <p><strong>Note:</strong> The outline-color property does not work if it is used alone. Use the outline-style property to set the outline first.</p> </body> </html>