使用橙色边框 Bootstrap 4 按钮设置警告操作
使用 btn-outline-warning 类并指示警示操作,为 Bootstrap 4 按钮设置橙色边框。
以下是按钮上的橙色边框 -
<button type="button" class="btn btn-outline-warning"> Rejected </button>
该类与添加到 Bootstrap 中任何元素的任何其他类一样进行添加。 针对 Bootstrap 按钮,我使用了 <button> 元素。
你可以尝试运行以下代码以实现 btn-outline-warning 类 -
示例
<!DOCTYPE html> <html lang="en"> <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.bootstrapcdn.com/bootstrap/4.1.0/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.0/js/bootstrap.min.js"></script> </head> <body> <h3>College Placements</h3> <ul class = "list-group"> <li class = "list-group-item">Selected Students</li> <li class = "list-group-item">Rejected Students</li> <li class = "list-group-item">Result Awaited</li> </ul> <p>List of selected and rejected students:</p> <button type="button" class="btn btn-outline-success">Selected</button> <button type="button" class="btn btn-outline-warning">Rejected</button> </body> </html>
广告