Panel asas


Panel Foundation ialah modul dengan sempadan kelabu dan kandungan yang mengandungi padding. Anda boleh menggunakan kelas .panel untuk mencipta:

Instance

<!DOCTYPE html>
<html>
<head>
  <title>Foundation 实例</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="http://static.php.cn/assets/foundation-5.5.3/foundation.min.css">
  <script src="http://static.php.cn/assets/jquery/2.0.3/jquery.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/foundation.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/vendor/modernizr.js"></script>
</head>
<body>

<div style="padding:20px;">
  <h2>面板</h2>
  <div class="panel">
    <h3>标题</h3>
    <p>文本内容..</p>
  </div>
</div>

</body>
</html>

Run Instance»

Klik "Run Butang Instance" Lihat contoh dalam talian


Warna panel

Gunakan kelas .callout untuk menukar warna panel kepada biru muda:

Instance

<!DOCTYPE html>
<html>
<head>
  <title>Foundation 实例</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="http://static.php.cn/assets/foundation-5.5.3/foundation.min.css">
  <script src="http://static.php.cn/assets/jquery/2.0.3/jquery.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/foundation.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/vendor/modernizr.js"></script>
</head>
<body>

<div style="padding:20px;">
  <h2>面板颜色修改</h2>
  <div class="panel callout">
    <h3>标题</h3>
    <p>文本内容..</p>
  </div>
</div>

</body>
</html>

Run Instance»

Klik butang "Run Instance" untuk melihat contoh dalam talian


Panel Sudut Bulat

Tetapkan panel ke sudut bulat menggunakan kelas .radius:

Instance

<!DOCTYPE html>
<html>
<head>
  <title>Foundation 实例</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="http://static.php.cn/assets/foundation-5.5.3/foundation.min.css">
  <script src="http://static.php.cn/assets/jquery/2.0.3/jquery.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/foundation.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/vendor/modernizr.js"></script>
</head>
<body>

<div style="padding:20px;">
  <h2>圆角面板 Panel</h2>
  <div class="panel radius">
    <h3>标题</h3>
    <p>文本内容..</p>
  </div>
</div>

</body>
</html>

Jalankan instance »

Klik butang "Jalankan contoh" untuk melihat contoh dalam talian


Panel tersuai

Anda boleh menggunakan CSS untuk menyesuaikan panel dalam yang berikut contoh, kami menggunakan panel sebagai kad:

Instance

<!DOCTYPE html>
<html>
<head>
  <title>Foundation 实例</title>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="http://static.php.cn/assets/foundation-5.5.3/foundation.min.css">
  <script src="http://static.php.cn/assets/jquery/2.0.3/jquery.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/foundation.min.js"></script>
  <script src="http://static.php.cn/assets/foundation-5.5.3/js/vendor/modernizr.js"></script>
<style>
  body {
    padding: 20px;
  }
  .panel {
    padding: 0;
    border: none;
    width: 50%;
  }
  div.container {
    text-align: center;
    padding: 15px;
    margin-top: 20px;
  }
  img {
    width: 100%;
  }
  </style>
</head>
<body>

<h2>Customized Panels</h2>
<div class="panel">
  <img src="http://www.php.cn/wp-content/uploads/2015/11/20121204024112919.jpg" alt="Cinque Terre" width="400" height="300"> 
  <div class="container">
    <h4>长城</h4>
    <p>不到长城非好汉!!!</p>
  </div>
</div>

</body>
</html>

Run Instance»

Klik "Run Instance butang " untuk melihat contoh dalam talian