scene简单的动画效果
代码语言:html
所属分类:动画
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Scene.js example circle burst css animation</title> <style> html, body { position: relative; height: 100%; margin: 0; padding: 0; } body { background: skyblue; overflow: hidden; } .scene6 { position: relative; width: 100%; height: 100%; overflow: hidden; } .sun { width: 200px; height: 200px; top: 50%; left: 50%; margin-left: -100px; margin-top: -100px; position: absolute; border-radius: 50%; box-sizing: border-box; } #sun { /* background: #FFE26C; */ border-color: #FFE26C; border-style: solid; border-width: 75px; } #sun2 { border: 75px solid #fff; } .sun_afterimage { width: 60px; height: 2px; background: #FFE26C; top: 50%; left: 50%; position: absolute; transform-origin: 0% 1px; transform: translate(120px, 0px); } #moonbackground { background: #96ABC0; top: 50%; left: 50%; width: 1000px; height: 1000px; margin: -500px 0 0 -500px; position: absolute; border-radius: 50%; } #text { top: 50%; left: 50%; width: 100px; height: 100px; font-size: 100px; margin-left: -50px; margin-top: -50px; position: absolute; color: white; text-align: center; line-height: 100px; font-family: sans-serif; } .circles { z-index: 100; } .circle { width: 150px; height: 150px; top: 50%; left: 50%; margin-top: -75px; margin-left: -75px; position: absolute; border-radius: 50%; box-sizing: border-box; border: 75px solid transparent; } .svg_circle { top: 50%; left: 50%; width: 300px; height: 300px; font-size: 100px; margin-left: -150px; margin-top: -150px; position: absolute; } .svg_circle circle { stroke-width: 5; stroke-linejoin: round; stroke-dasharray: 0 1000; stroke-dashoffset: 1; stroke: #ff8c3a; } .svg_circle circle#rotate_circle2 { stroke-width: 2; stroke: #3AA1BF; } .svg_circle circle#rotate_circle3 { stroke-width: 1; stroke: white; } #stick { position: absolute; top: 50%; left: 50%; height: 0; margin-left: -17px; width: 24px; border-bottom: 150px solid #E5EBF7; border-left: 5px solid transparent; border-right: 5px solid transparent; transform-origin: 50% 0%; } #slice_circle { background: #ea6b96; } .circle_square { width: 20px; height: 20px; top: 50%; left: 50%; margin-top: -10px; margin-left: -10px; position: absolute; border-radius: 50%; box-sizing: border-box; background: #FFDDDD; } #bomb { position: absolute; width: 200px; height: 200px; top: 50%; left: 50%; margin-left: -100px; margin-top: -100px; stroke-dasharray: 100 1000; stroke-dashoffset: 0; transform: rotate(20deg); } #bomb .tail { position: absolute; left: 50%; top: -110px; width: 200px; height: 200px; margin-left: -10px; } #bomb .tail path { stroke-width: 3px; fill: none; stroke: #000000; stroke-miterlimit: 10; } #bomb .head { position: absolute; width: 80px; height: 20px; left: 50%; margin-left: -40px; top: -10px; background: #000; } #bomb .body { position: absolute; top: 0; width: 200px; height: 200px; background: #000; border-radius: 50%; } </style> </head> <body translate="no"> <div class="scene1"> <div id="sun" class="sun"></div> <div id="sun2" class="sun"></div> <div class="sun_afterimages"> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> <div class="sun_afterimage"></div> </div> </div> <div class="scene2"> <svg class="svg_circle" version="1.1" id="레이어_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="300px" height="300px" viewBox="0 0 100 100" enable-background="new 0 0 56.69 56.69" xml:space="preserve"> <circle id="rotate_circle1" fill="transparent" stroke="#000000" stroke-miterlimit="10" cx="50" cy="50" r="25" /> <circle id="rotate_circle2" fill="transparent" stroke="#000000" stroke-miterlimit="10" cx="50" cy="50" r="35" /> <circle id="rotate_circle3" fill="transparent" stroke="#000000" stroke-miterlimit="10" cx="50" cy="50" r="45" /> </svg> <div id="stick"></div> </div> <div class="scene3"> <div class="circles" id="circles1"> <div class="circle" style="border-color:#c9af52;"></div> <div class="circle" style="border-color:#183c43;"></div> <div class="circle" style="border-color:#FF0088;"></div> <div class="circle" style="border-color:#7986CB;"></div> <div class="circle" style="border-color:#E2E6E9;"></div> </div> </div> <div class="scene4"> <div id="slice_circle" class="circle"></div> </div> <div class="scene5"> <div id="circle_squares"> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> <div class="circle_square"></div> </div> </div> <div class="scene6"> <div id="bomb"> <svg class="tail" version="1.1" id="레이어_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="63.333px" height="30.667px" viewBox="0 0 63.........完整代码请登录后点击上方下载按钮下载查看
网友评论0