基于svg绘制网页底部层叠的波浪滚动和蓝色的渐变背景结合。这是一款非常精致的网页动效背景特效,先来看看效果:
部分核心的代码如下:
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<title>Simple CSS Waves | Mobile & Full width</title>
<link rel="stylesheet" href="css/style.css">
</head>
<body>
<div class="header">
<div class="inner-header flex">
<h1>简单CSS3波形</h1>
</div>
<!--Waves Container-->
<div>
<svg class="waves" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 24 150 28" preserveAspectRatio="none" shape-rendering="auto">
<defs>
<path id="gentle-wave" d="M-160 44c30 0 58-18 88-18s 58 18 88 18 58-18 88-18 58 18 88 18 v44h-352z" />
</defs>
<g class="parallax">