blob: d315a9cca79799e9e3489eb70fd44d89da68b1af [file] [log] [blame]
<!DOCTYPE HTML>
<html>
<head>
<style type="text/css">
body {
margin: 0;
}
div {
box-sizing: border-box;
}
.container {
position: relative;
width: 800px;
height: 100px;
border: 1px solid black;
margin: 10px 0;
padding: 20px;
}
.container div {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
</style>
<script src="resources/border-radius-helpers.js"></script>
<script>
const borderWidth = 20;
const corners = [
'top-left',
'top-right',
'bottom-left',
'bottom-right'
];
const clipPaths = [
'inset(60px 640px 10px 60px)',
'inset(60px 60px 10px 640px)',
'inset(10px 640px 60px 60px)',
'inset(10px 60px 60px 640px)'
];
var colors = [
'green',
'blue'
];
var radii = '100% 100%';
function doSetup()
{
for (var index in corners)
document.body.appendChild(createContainer(corners[index], colors, clipPaths[index], radii));
}
window.addEventListener('load', doSetup, false);
</script>
</head>
<body>
</body>
</html>