Top Left Rounded Corner in CSS

Developer
Size
2,615 Kb
Views
44,528

How do I make an top left rounded corner in css?

What is a top left rounded corner in css? How do you make a top left rounded corner in css? This script and codes were developed by James Barnett on 11 August 2022, Thursday.

Top Left Rounded Corner in CSS Previews

Top Left Rounded Corner in CSS - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Top Left Rounded Corner in CSS</title> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <style> /* NOTE: The styles were added inline because Prefixfree needs access to your styles and they must be inlined if they are on local disk! */ /**** draw the triangle ****/
.box { overflow: hidden; } /* needed to round trinagle corner */
/* draw top-left css triangle */
.triangle { position: absolute; width: 0;	height: 0;	border-top: 55px solid #ea6c6c;	border-right: 55px solid transparent;
}
/* position 'new' label */
.triangle > span { position: absolute; top: -45px; left: 4px; transform: rotate(-45deg);
}
/***** basic styling for the box *****/
.box { position: relative; width: 315px; height: 160px; margin: 20px; background: #f0f7fa; border-radius: 10px; font-size: 18px; font-family: 'Arial'; }
.box-contents { width: 150px; margin: 12px auto; text-align: center; }
.course { color: #9cc7dd; text-transform: uppercase;
}
.badge { color: #337394; font-weight: bold; margin-top: 3px;
}
.box-contents > img { width: 100px; transform: scale(1.1); margin-top: 20px;
}
.triangle > span { font-size: 16px; color: white;
}
/* move badge up on hover */
.box-contents > img:hover { margin-top: 10px; } </style> <script src="https://cdnjs.cloudflare.com/ajax/libs/prefixfree/1.0.7/prefixfree.min.js"></script>
</head>
<body> <div class="box"> <div class="triangle"> <span>New</span> </div> <div class = "box-contents"> <div class = "course">Illustrator Foundations</div> <div class = "badge">Applying Effects</div> <img src="http://d3gswd4a9vhkat.cloudfront.net/badges_DD_ILF_Stage5.png"alt="Applying Effects Badge"> </div> </div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script>
</body>
</html>

Top Left Rounded Corner in CSS - Script Codes CSS Codes

/**** draw the triangle ****/
.box { overflow: hidden; } /* needed to round trinagle corner */
/* draw top-left css triangle */
.triangle { position: absolute; width: 0;	height: 0;	border-top: 55px solid #ea6c6c;	border-right: 55px solid transparent;
}
/* position 'new' label */
.triangle > span { position: absolute; top: -45px; left: 4px; transform: rotate(-45deg);
}
/***** basic styling for the box *****/
.box { position: relative; width: 315px; height: 160px; margin: 20px; background: #f0f7fa; border-radius: 10px; font-size: 18px; font-family: 'Arial'; }
.box-contents { width: 150px; margin: 12px auto; text-align: center; }
.course { color: #9cc7dd; text-transform: uppercase;
}
.badge { color: #337394; font-weight: bold; margin-top: 3px;
}
.box-contents > img { width: 100px; transform: scale(1.1); margin-top: 20px;
}
.triangle > span { font-size: 16px; color: white;
}
/* move badge up on hover */
.box-contents > img:hover { margin-top: 10px; }
Top Left Rounded Corner in CSS - Script Codes
Top Left Rounded Corner in CSS - Script Codes
Home Page Home
Developer James Barnett
Username jamesbarnett
Uploaded August 11, 2022
Rating 3
Size 2,615 Kb
Views 44,528
Do you need developer help for Top Left Rounded Corner in CSS?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

James Barnett (jamesbarnett) Script Codes
Create amazing SEO content with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!