+ 6
Triangles
How do draw a triangle in css?
5 Respostas
+ 14
https://www.w3schools.com/howto/tryit.asp?filename=tryhow_css_shapes_triangle-up
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.triangle-up {
width: 0;
height: 0;
border-left: 25px solid transparent;
border-right: 25px solid transparent;
border-bottom: 50px solid #0f0;
}
</style>
</head>
<body>
<h2>Triangle Up CSS</h2>
<div class="triangle-up"></div>
</body>
</html>
+ 1
.triangle {
width: 200px;
height: 200px;
background-image: linear-gradient(-45deg, red 49.9%, transparent 50%);
}
https://code.sololearn.com/WWNxohxfdr34/?ref=app