JSFiddle - React, Tailwind, and code Playground
by Ayyappan Sakthivadivel
HTML
<div style="width:300px; position:absolute; right:0;">
<div class="arrow_box">
<h1 class="logo">css arrow please!</h1>
</div>
</div>
CSS
.arrow_box {
height: 30px;
width: 80px;
position: relative;
background: #88b7d5;
border: 1px solid #000;
}
.arrow_box:after, .arrow_box:before {
right: 100%;
top: 50%;
border: solid transparent;
content: " ";
height: 0;
width: 0;
position: absolute;
pointer-events: none;
}
.arrow_box:after {
border-color: rgba(136, 183, 213, 0);
border-right-color: #88b7d5;
border-width: 15px;
margin-top: -15px;
}
.arrow_box:before {
border-color: rgba(0, 0, 0, 0);
border-right-color: #000;
border-width: 16px;
margin-top: -16px;
}