******************進(jìn)度條********************************************* *進(jìn)度條作用;提供工作或動作的實(shí)時反饋 * *注意:跨瀏覽器兼容性 *進(jìn)度條使用了CSS3的transition和animation屬性來完成一些效果。這些 *特性在Internet Explorer 9或以下版本中,、Firefox的 *老版本中沒有被支持。Opera 12不支持animation屬性,。 * *定義進(jìn)度條使用的class樣式:progress * *有意義的進(jìn)度條,,換顏色,使用的樣式是:progress-bar-*,, * *的內(nèi)容為success,info,warning,danger. *有條紋的進(jìn)度條,,其樣式是:progress-striped *為滾動條添加運(yùn)動效果:給.progress-striped加上.active使它由右向左運(yùn)動。在 *IE的所有版本不可用,。 * *堆疊效果:講就是多個進(jìn)度條放入同一個.progress中,,讓他們堆疊 * ******************************************************************** 頁面效果: 源碼: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="description" content=""> <meta name="author" content=""> <link rel="shortcut icon" href="../../docs-assets/ico/favicon.png"> <title>Navbar Template for Bootstrap</title> <link rel="stylesheet" href="../../css/bootstrap.min.css" type="text/css"></link> <link rel="stylesheet" href="../../js/bootstrap-theme.min.css" type="text/css"></link><body> <style> body{padding-top:70px;} </style> <div><b>普通進(jìn)度條</b</div> <div class="progress"> <div class="progress-bar" role="progressbar" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100" style="width: 60%;"> <span class="sr-only">60% Complete</span> </div> </div> <br/> <div><b>有意義的進(jìn)度條</b</div> <div class="progress"> <div class="progress-bar progress-bar-danger" role="progressbar" aria-valuenow="40" aria-valuemin="0" aria-valuemax="100" style="width: 40%;"> <span class="sr-only">40% Complete</span> </div> </div> <div class="progress"> <div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="20" aria-valuemin="0" aria-valuemax="100" style="width: 20%;"> <span class="sr-only">20% Complete</span> </div> </div> <div class="progress"> <div class="progress-bar progress-bar-info" role="progressbar" aria-valuenow="50" aria-valuemin="0" aria-valuemax="100" style="width: 50%;"> <span class="sr-only">50% Complete</span> </div> </div> <div class="progress"> <div class="progress-bar progress-bar-warning" role="progressbar" aria-valuenow="80" aria-valuemin="0" aria-valuemax="100" style="width: 80%;"> <span class="sr-only">80% Complete</span> </div> </div> <br/> <div><b>條紋效果</b</div> <div class="progress progress-striped"> <div class="progress-bar progress-bar-danger" role="progressbar" aria-valuenow="40" aria-valuemin="0" aria-valuemax="100" style="width: 40%;"> <span class="sr-only">40% Complete</span> </div> </div> <div class="progress progress-striped"> <div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="20" aria-valuemin="0" aria-valuemax="100" style="width: 20%;"> <span class="sr-only">20% Complete</span> </div> </div> <div class="progress progress-striped"> <div class="progress-bar progress-bar-info" role="progressbar" aria-valuenow="50" aria-valuemin="0" aria-valuemax="100" style="width: 50%;"> <span class="sr-only">50% Complete</span> </div> </div> <div class="progress progress-striped"> <div class="progress-bar progress-bar-warning" role="progressbar" aria-valuenow="80" aria-valuemin="0" aria-valuemax="100" style="width: 80%;"> <span class="sr-only">80% Complete</span> </div> </div> <br/> <div><b>運(yùn)動效果</b</div> <div class="progress progress-striped active"> <div class="progress-bar progress-bar-danger" role="progressbar" aria-valuenow="40" aria-valuemin="0" aria-valuemax="100" style="width: 40%;"> <span class="sr-only">40% Complete</span> </div> </div> <br/> <div><b>堆疊效果</b</div> <div class="progress progress-striped active"> <div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="20" aria-valuemin="0" aria-valuemax="100" style="width: 20%;"> <span class="sr-only">20% Complete</span> </div> <div class="progress-bar progress-bar-info" role="progressbar" aria-valuenow="30" aria-valuemin="0" aria-valuemax="100" style="width: 30%;"> <span class="sr-only">30% Complete</span> </div> <div class="progress-bar progress-bar-warning" role="progressbar" aria-valuenow="10" aria-valuemin="0" aria-valuemax="100" style="width: 10%;"> <span class="sr-only">10% Complete</span> </div> </div> </body> <script type="text/javascript" src="../../js/jquery-2.0.0.min.js"></script> <script type="text/javascript" src="../../js/bootstrap.min.js"></script> </html> |
|
來自: I_T_館 > 《bootstrap》