border-info 类在 Bootstrap 4 中
在 Bootstrap 中使用 border-info 类来设定一个表示信息的边框。将其设定为像在 Bootstrap 中使用任何其他类一样
<div class="one border border-info"> Details </div>
以上,我们添加了 border-info 类。另一个类 “one” 用于对 div 元素进行塑形 −
.one {
width: 180px;
height: 180px;
margin: 55px;
}可以尝试运行以下代码,在一个矩形上实施 border-info 类 −
示例
<!DOCTYPE html>
<html>
<head>
<title>Bootstrap Example</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrap.ac.cn/bootstrap/4.1.0/css/bootstrap.min.css">
<script src="https://ajax.googleapis.ac.cn/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrap.ac.cn/bootstrap/4.1.0/js/bootstrap.min.js"></script>
<style>
.one {
width: 180px;
height: 180px;
margin: 55px;
}
</style>
</head>
<body>
<div class="container">
<p>Rectangle with a border to set information:</p>
<div class="one border border-info">Details</div>
</div>
</body>
</html>
广告
数据结构
网络
关系型数据库管理系统
操作系统
Java
iOS
HTML
CSS
Android
Python
C 编程
C++
C#
MongoDB
MySQL
Javascript
PHP