Header
优质
小牛编辑
125浏览
2023-12-01
描述 (Description)
它定义了从h1到h6的所有HTML标题的样式。 您可以使用标题元素中的标记使文本变小。
例子 (Example)
以下示例演示了在Foundation中使用base typography header -
<!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://cdnjs.cloudflare.com/ajax/libs/foundation/6.0.1/css/foundation.css">
<script src = "https://cdnjs.cloudflare.com/ajax/libs/foundation/6.0.1/js/vendor/jquery.min.js"></script>
<script src = "https://cdnjs.cloudflare.com/ajax/libs/foundation/6.0.1/js/foundation.min.js"></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中,我们使用了元素。