I have blended the rectangle using figma but I am searching for how to do it in css so it can view like below image (the blue one),
How to achive this is css ?
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
body {
width: 100vw;
height: 100vh;
margin: 0%;
padding: 0%;
}
.outer {
width: 100vw;
height: 100vh;
background-color: white;
}
.outer .inner {
/*How to do blend it*/
width: 100vw;
height: 100vh;
background-color: #12B1F2;
}
</style>
<title>Demo</title>
</head>
<body>
<div >
<div >
</div>
</div>
</body>
</html>
CodePudding user response:
You could use a clip-path.
There are two ways to do it:
Create an SVG that has a path of the shape you want and use that as the clip-path: https://codesandbox.io/s/bezier-curve-clip-path-h8x8l?from-embed=&file=/index.html
Generate a polygon yourself with code which approximates the curve you want. Have a look at this question here: Create clip-path wave css edges

