CSS3圓形進度條效果
分享一段程式碼例項,它利用css3實現了圓形進度條效果。
準確的說應該是環形進度條,程式碼例項如下:
[HTML] 純文字檢視 複製程式碼執行程式碼<!doctype html> <html> <head> <meta charset="utf-8"> <meta name="author" content="http://www.softwhy.com/" /> <title>螞蟻部落</title> <style> * { margin: 0; padding: 0; } .progress-ring { width: 160px; height: 160px; border: 20px solid green; border-radius: 50%; box-sizing: border-box; position: absolute; top: 0; left: 0; } .progress-track { width: 160px; height: 160px; border: 20px solid green; border-radius: 50%; box-sizing: border-box; position: absolute; clip: rect(0px,80px,160px,0px); top: -20px; left: -20px; } .progress-left { position: relative; width: 160px; height: 160px; border: 20px solid goldenrod; border-radius: 50%; box-sizing: border-box; position: absolute; clip: rect(0px,80px,160px,0px); top: -20px; left: -20px; transform: rotate(3.6deg); transition: transform 2s linear; animation: mymove 3s linear forwards; } .progress-right { width: 160px; height: 160px; border: 20px solid goldenrod; border-radius: 50%; box-sizing: border-box; position: absolute; clip: rect(0px,80px,160px,0px); top: -20px; left: -20px; transform: rotate(180deg); opacity: 0; animation: toggle 0s ease 1.5s forwards; } .progress-cover { position: relative; width: 160px; height: 160px; border: 20px solid green; border-radius: 50%; box-sizing: border-box; position: absolute; clip: rect(0px,80px,160px,0px); top: -20px; left: -20px; opacity: 1; animation: toggleq 0s ease 1.5s forwards; } @keyframes mymove { from { transform: rotate(0deg); } to { transform: rotate(360deg); } } @keyframes toggle { 0% { opacity: 0; } 100% { opacity: 1; } } @keyframes toggleq { 0% { opacity: 1; } 100% { opacity: 0; } } </style> </head> <body> <div class="progress-ring"> <div class="progress-track"></div> <div class="progress-left"></div> <div class="progress-right"></div> <div class="progress-cover"></div> <div class="inn"></div> </div> </body> </html>
相關文章
- Flutter 波浪圓形進度條Flutter
- 自定義圓形進度條
- SVG畫圓形進度條SVG
- canvas環形進度條效果Canvas
- [-Flutter 自定義元件-] 圓形進度條Flutter元件
- Android自定義圓形進度條Android
- 使用canvas繪製圓形進度條Canvas
- canvas的簡單圓形進度條Canvas
- CSS3進度條效果程式碼CSSS3
- canvas圓形進度條註釋超全Canvas
- 實現環形進度條效果【一】
- CSS3實現原型進度條效果CSSS3原型
- CSS3 螺紋載入進度條效果CSSS3
- Javascript 及 CSS3 實現進度條效果JavaScriptCSSS3
- Android 自定義圓形旋轉進度條,仿微博頭像載入效果Android
- 可拖拽圓形進度條元件(支援移動端)元件
- Android自定義圓形進度條原始碼解析Android原始碼
- Vue canvas繪製圓形進度條動畫載入VueCanvas動畫
- Android進階 自定義View(三)圓形刻度進度條AndroidView
- CSS3圓形時鐘效果程式碼CSSS3
- css3動態圓形鐘錶效果CSSS3
- jQuery環形旋轉載入進度條效果jQuery
- CSS3帶有節點的進度條效果CSSS3
- Android自定義圓形進度條實現程式碼Android
- svg和css3建立環形漸變進度條SVGCSSS3
- CSS3標懸浮圓形縮放效果CSSS3
- CSS3圓形旋轉變大動畫效果CSSS3動畫
- canvas環形百分比進度條效果Canvas
- js和css3實現的圓形鐘錶效果JSCSSS3
- 3個自定義view佈局:矩形TextView,圓形進度條,圓環viewTextView
- Android自定義View——從零開始實現圓形進度條AndroidView
- Android閃屏頁圓形倒數計時進度條實現Android
- jQuery 進度條效果程式碼jQuery
- CSS快遞進度條效果CSS
- CSS3空心圓效果CSSS3
- Android自定義控制元件系列之圓形進度條的實現Android控制元件
- css3 製作圓環進度條CSSS3
- canvas錐形漸變進度條Canvas