CSS Arrows

Glenn Blog 0 Comments

Here are some useful snippets for pure CSS arrows:-

.arrow-up {
	width: 0; 
	height: 0; 
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-bottom: 5px solid black;
}

.arrow-down {
	width: 0; 
	height: 0; 
	border-left: 7px solid transparent;
	border-right: 7px solid transparent;
	border-top: 7px solid #f00;
}

.arrow-right {
	width: 0; 
	height: 0; 
	border-top: 10px solid transparent;
	border-bottom: 10px solid transparent;
	border-left: 10px solid green;
}

.arrow-left {
	width: 0; 
	height: 0; 
	border-top: 10px solid transparent;
	border-bottom: 10px solid transparent; 
	border-right:10px solid blue; 
}

If you are looking to add arrows to a menu item etc then make sure the parent is relative and apply the following CSS format:-

.my-div {
position: relative;
}
.my-div:after {
content: '';
box-shadow: 5px 13px 10px black;
position: absolute;
left: -19px;
top: 12px;
}
About the Author
css arrows CSS Arrows 0da77002febbfe28d15144a57bbcc2c9 s 180 d mm r g

Glenn

A highly experienced WordPress Web Developer, Front-end and Back-end Developer & New Media Specialist with extensive knowledge of a wide spectrum of technologies in the Development and Creative Industries built up over a number of years.