- Foundation 通用
- Foundation - 全域性樣式
- Foundation - Sass
- Foundation - JavaScript
- Foundation - JavaScript 實用工具
- Foundation - 媒體查詢
- Foundation - 網格
- Foundation - Flex 網格
- Foundation - 表單
- Foundation - 可見性類
- Foundation - 基礎排版
- Foundation - 排版幫助器
- Foundation - 基本控制元件
- Foundation - 導航
- Foundation - 容器
- Foundation - 媒體
- Foundation - 外掛
- Foundation SASS
- Foundation - Sass 函式
- Foundation - Sass Mixins
- Foundation 庫
- Foundation - Motion UI
- Foundation 實用資源
- Foundation - 快速指南
- Foundation - 實用資源
- Foundation - 討論
Foundation - 基礎排版標題
說明
它定義從 h1 到 h6 的所有 HTML 標題樣式。你可以在標題元素中使用 <small> 標記來使文字變小。
示例
以下示例演示了在 Foundation 中使用基礎排版標題 −
<!doctype html>
<head>
<meta charset = "utf-8" />
<meta http-equiv = "x-ua-compatible" content = "ie = edge" />
<meta name = "viewport" content = "width = device-width, initial-scale = 1.0" />
<title>Base Typography Header</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/foundation-sites@6.5.1/dist/css/foundation.min.css" crossorigin="anonymous">
<!-- Compressed JavaScript -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/foundation/6.0.1/js/vendor/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/foundation-sites@6.5.1/dist/js/foundation.min.js" crossorigin="anonymous"></script>
</head>
<body>
<h2>Base Typography Header Example</h2>
<h1>This is heading one</h1>
<h2>This is heading <small>two</small></h2>
<h3>This is heading three</h3>
<h4>This is heading four</h4>
<h5>This is heading five</h5>
<h6>This is heading six</h6>
</body>
</html>
在標題標記 h2 中,我們使用了 <small> 元素。
輸出
讓我們執行以下步驟來了解上述程式碼如何工作 −
將上述 html 程式碼儲存為header.html 檔案。
在瀏覽器中開啟此 HTML 檔案,會顯示如下輸出。
foundation_base_typography.htm
廣告