3
Using the pseudo-elements :after
and :before
:
In their need it may be necessary to adapt the code by changing the values of top
, left
and rigth
until you reach the effect you want
div{
width: 0;
height: 0;
top:40px;
left:50px;
position: relative;
border-style: solid;
border-width: 100px 130px 0 130px;
border-color: #000000 transparent transparent transparent;
}
div:before {
content: "";
display: block;
position: relative;;
border-top-left-radius: 100px;
border-top-right-radius: 100px;
width: 200px;
height: 50px;
background-color: white;
right: 220px;
top: -80px;
}
div:after {
content: "";
display: block;
position: relative;
border-top-left-radius: 100px;
border-top-right-radius: 100px;
width: 200px;
height: 50px;
background-color: white;
left: 20px;
top: -130px;
}
button{
width: 400px;
height: 80px;
display: block;
position: absolute;
left: 0px;
background: rgb(0, 0, 0);
border-radius: 70px;
}
<button></button>
<br/>
<div></div>
You can use
:after
and:before
to "create" elements linked to the parent element– MarceloBoni
It’s possible... I just don’t think anyone will be willing to do it for you.
– KaduAmaral
"draws" is different from "draw".. anyway, see this link: http://jsfiddle.net/stackmanoz/VbgKW/
– Daniel Omine
Related: How to make this arrow in CSS
– Jorge B.