中文亚洲精品无码_熟女乱子伦免费_人人超碰人人爱国产_亚洲熟妇女综合网

當(dāng)前位置: 首頁(yè) > news >正文

東莞高端做網(wǎng)站百度權(quán)重查詢

東莞高端做網(wǎng)站,百度權(quán)重查詢,企業(yè)營(yíng)銷(xiāo)方案案例范文,wordpress 生成sitemap1. 輪播 1.1 輪播樣式 在Bootstrap 5中, 創(chuàng)建輪播(Carousel)的相關(guān)類名及其介紹: * 1. carousel: 輪播容器的類名, 用于標(biāo)識(shí)一個(gè)輪播組件. * 2. slide: 切換圖片的過(guò)渡和動(dòng)畫(huà)效果. * 3. carousel-inner: 輪播項(xiàng)容器的類名, 用于包含輪播項(xiàng)(輪播圖底下橢圓點(diǎn), 輪播的過(guò)程可以顯…

2023-10-05_00005

1. 輪播

1.1 輪播樣式

在Bootstrap 5, 創(chuàng)建輪播(Carousel)的相關(guān)類名及其介紹:
* 1. carousel: 輪播容器的類名, 用于標(biāo)識(shí)一個(gè)輪播組件.
* 2. slide: 切換圖片的過(guò)渡和動(dòng)畫(huà)效果.
* 3. carousel-inner: 輪播項(xiàng)容器的類名, 用于包含輪播項(xiàng)(輪播圖底下橢圓點(diǎn), 輪播的過(guò)程可以顯示目前是第幾張圖). 
* 4. carousel-item: 輪播項(xiàng)的類名, 表示一個(gè)輪播項(xiàng).
* 5. carousel-indicators: 指示符容器的類名, 用于包含輪播項(xiàng)的指示符.
* 6. active: 用于標(biāo)識(shí)當(dāng)前激活的輪播項(xiàng)或指示符.
* 7. carousel-control-prev: 左切換按鈕的類名, 用于觸發(fā)向前切換輪播項(xiàng)的事件.
* 8. carousel-control-next: 右切換按鈕的類名, 用于觸發(fā)向后切換輪播項(xiàng)的事件.
* 9. carousel-control-prev-icon: 左切換按鈕圖標(biāo)的類名, 用于顯示向前切換的圖標(biāo).
* 10. carousel-control-next-icon: 右切換按鈕圖標(biāo)的類名, 用于顯示向后切換的圖標(biāo).創(chuàng)建錄播步驟:
* 1. 創(chuàng)建了一個(gè)輪播容器的<div>元素, 其中id屬性設(shè)置為"demo", 類名設(shè)置為"carousel slide", 并且添加了data-bs-ride="carousel"屬性以啟用輪播功能.* 2. 添加了一個(gè)指示符容器的<div>元素, 用于顯示輪播項(xiàng)的指示符.* 3. 在指示符容器中添加了多個(gè)指示符按鈕, 每個(gè)按鈕通過(guò)data-bs-target屬性指定了輪播容器的id,data-bs-slide-to屬性指定了輪播項(xiàng)的索引, 其中第一個(gè)按鈕添加了"active"類名以表示默認(rèn)激活的指示符.* 4. 創(chuàng)建了一個(gè)輪播內(nèi)容容器的<div>元素, 用于包含輪播圖片項(xiàng).* 5. 在輪播內(nèi)容容器中添加了多個(gè)輪播項(xiàng)的<div>元素, 每個(gè)輪播項(xiàng)包含一個(gè)<img>元素, 用于顯示圖片內(nèi)容,第一個(gè)輪播項(xiàng)添加了"active"類名以表示默認(rèn)激活的輪播項(xiàng).* 6. 創(chuàng)建了一個(gè)左切換按鈕和一個(gè)右切換按鈕的<button>元素,通過(guò)添加carousel-control-prev和carousel-control-next類名以表示左右切換按鈕.* 7. 在切換按鈕中添加了<span>元素, 并分別為其添加了carousel-control-prev-icon和carousel-control-next-icon類名,以顯示左右切換的圖標(biāo).
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>輪播</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<!-- 輪播 -->
<div id="demo" class="carousel slide" data-bs-ride="carousel"><!-- 指示符 --><div class="carousel-indicators"><button type="button" data-bs-target="#demo" data-bs-slide-to="0" class="active"></button><button type="button" data-bs-target="#demo" data-bs-slide-to="1"></button><button type="button" data-bs-target="#demo" data-bs-slide-to="2"></button><button type="button" data-bs-target="#demo" data-bs-slide-to="3"></button></div><!-- 輪播圖片 --><div class="carousel-inner"><div class="carousel-item active"><img src="img/1.png" class="d-block" style="width:100%"></div><div class="carousel-item"><img src="img/2.png" class="d-block" style="width:100%"></div><div class="carousel-item"><img src="img/3.png" class="d-block" style="width:100%"></div><div class="carousel-item"><img src="img/4.png" class="d-block" style="width:100%"></div></div><!-- 左右切換按鈕 --><button class="carousel-control-prev" type="button" data-bs-target="#demo" data-bs-slide="prev"><span class="carousel-control-prev-icon"></span></button><button class="carousel-control-next" type="button" data-bs-target="#demo" data-bs-slide="next"><span class="carousel-control-next-icon"></span></button>
</div>
</body>
</html>
在上述代碼中, 指示符(指示器)的每個(gè)按鈕通過(guò)data-bs-slide-to屬性設(shè)置與輪播項(xiàng)的索引對(duì)應(yīng).
具體來(lái)說(shuō), 代碼中的指示符按鈕對(duì)應(yīng)的圖片索引如下:
- 第一個(gè)指示符按鈕: data-bs-slide-to="0", 對(duì)應(yīng)第一個(gè)圖片項(xiàng)(索引為 0).
- 第二個(gè)指示符按鈕: data-bs-slide-to="1", 對(duì)應(yīng)第二個(gè)圖片項(xiàng)(索引為 1).
- 第三個(gè)指示符按鈕: data-bs-slide-to="2", 對(duì)應(yīng)第三個(gè)圖片項(xiàng)(索引為 2).
- 第四個(gè)指示符按鈕: data-bs-slide-to="3", 對(duì)應(yīng)第四個(gè)圖片項(xiàng)(索引為 3).通過(guò)將指示符按鈕的data-bs-slide-to屬性與相應(yīng)的圖片項(xiàng)索引對(duì)應(yīng)起來(lái), 可以在用戶點(diǎn)擊指示符時(shí)切換到對(duì)應(yīng)的圖片項(xiàng).
例如, 當(dāng)用戶點(diǎn)擊第二個(gè)指示符按鈕時(shí), 輪播容器將切換到第二個(gè)圖片項(xiàng)(索引為 1)顯示在輪播框中.請(qǐng)注意, 這里的圖片索引是從0開(kāi)始的, 與JavaScript的數(shù)組索引一致.
所以在指示符按鈕的data-bs-slide-to屬性中, 索引值也是從0開(kāi)始的.

在這里插入圖片描述

1.2 輪播標(biāo)題

在Bootstrap 5, .carousel-caption類用于設(shè)置輪播圖片的描述文本(輪播標(biāo)題).
將輪播圖片的描述文本放在每個(gè)圖片項(xiàng)內(nèi), : <div class="carousel-caption"> 嵌套早 <div class="carousel-item"> 元素內(nèi).
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>輪播標(biāo)題</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<!-- 輪播 -->
<div id="demo" class="carousel slide" data-bs-ride="carousel"><!-- 指示符 --><div class="carousel-indicators"><button type="button" data-bs-target="#demo" data-bs-slide-to="0" class="active"></button><button type="button" data-bs-target="#demo" data-bs-slide-to="1"></button><button type="button" data-bs-target="#demo" data-bs-slide-to="2"></button><button type="button" data-bs-target="#demo" data-bs-slide-to="3"></button></div><!-- 輪播圖片 --><div class="carousel-inner"><div class="carousel-item active"><img src="img/1.png" class="d-block" style="width:100%"><div class="carousel-caption"><h3>第一張圖片描述標(biāo)題</h3><p>第一張圖片描述內(nèi)容顯示在這里!!!</p></div></div><div class="carousel-item"><img src="img/2.png" class="d-block" style="width:100%"><div class="carousel-caption"><h3>第二張圖片描述標(biāo)題</h3><p>第二張圖片描述內(nèi)容顯示在這里!!!</p></div></div><div class="carousel-item"><img src="img/3.png" class="d-block" style="width:100%"><div class="carousel-caption"><h3>第三張圖片描述標(biāo)題</h3><p>第三張圖片描述內(nèi)容顯示在這里!!!</p></div></div><div class="carousel-item"><img src="img/4.png" class="d-block" style="width:100%"><div class="carousel-caption"><h3>第四張圖片描述標(biāo)題</h3><p>第四張圖片描述內(nèi)容顯示在這里!!!</p></div></div></div><!-- 左右切換按鈕 --><button class="carousel-control-prev" type="button" data-bs-target="#demo" data-bs-slide="prev"><span class="carousel-control-prev-icon"></span></button><button class="carousel-control-next" type="button" data-bs-target="#demo" data-bs-slide="next"><span class="carousel-control-next-icon"></span></button>
</div>
</body>
</html>

在這里插入圖片描述

2. 模態(tài)框

模態(tài)框是一種覆蓋在父窗體上的子窗體, 通常用于在不離開(kāi)父窗體的情況下展示額外的內(nèi)容或進(jìn)行互動(dòng).模態(tài)框常用于以下場(chǎng)景:
- 彈出對(duì)話框: 通過(guò)模態(tài)框可以顯示一些提示, 確認(rèn)或警告信息, 用戶需要對(duì)其進(jìn)行操作后才能繼續(xù)操作父窗體.
- 表單輸入: 模態(tài)框可以用于顯示一個(gè)表單, 用戶可以在其中輸入信息, 提交后將數(shù)據(jù)傳回給父窗體進(jìn)行處理.
- 圖片/媒體展示: 模態(tài)框可用于顯示大圖, 視頻, 音頻等媒體內(nèi)容, 以便用戶在不離開(kāi)當(dāng)前頁(yè)面的情況下查看細(xì)節(jié).
- 信息交互: 通過(guò)模態(tài)框, 用戶可以與內(nèi)容進(jìn)行交互, 例如點(diǎn)擊按鈕, 滑塊或其他交互元素.

2.1 模態(tài)框樣式

在Bootstrap 5, 設(shè)置模態(tài)框的相關(guān)類名及其介紹:
* 1. modal: 表示一個(gè)模態(tài)框容器, 通過(guò)添加該類名來(lái)創(chuàng)建模態(tài)框.
* 2. modal-dialog: 表示模態(tài)框的對(duì)話框容器, 用于包裹模態(tài)框的內(nèi)容.
* 3. modal-content: 表示模態(tài)框的內(nèi)容容器, 包含了模態(tài)框的頭部、主體和底部部分.
* 4. modal-header: 表示模態(tài)框的頭部部分, 通常用于顯示標(biāo)題和關(guān)閉按鈕.
* 5. modal-title: 表示模態(tài)框的標(biāo)題, 通常在modal-header中使用.
* 6. modal-body: 表示模態(tài)框的主體部分, 通常用于放置模態(tài)框的主要內(nèi)容.
* 7. modal-footer: 表示模態(tài)框的底部部分, 通常用于放置模態(tài)框的按鈕或其他操作元素.
* 8. btn-close: 用于創(chuàng)建關(guān)閉按鈕的樣式; 這個(gè)類可用于在模態(tài)框的頭部或其他區(qū)域添加一個(gè)標(biāo)準(zhǔn)的關(guān)閉按鈕.用于控制模態(tài)框的行為和交互的常用的屬性介紹:
* 1. data-bs-toggle="modal": 通過(guò)給觸發(fā)元素添加該屬性, 可以在點(diǎn)擊時(shí)打開(kāi)或關(guān)閉模態(tài)框.例如, 可以將其添加到按鈕的data-bs-target屬性中來(lái)觸發(fā)模態(tài)框的顯示.* 2. data-bs-target="#modalId": 通過(guò)設(shè)置觸發(fā)元素的data-bs-target屬性來(lái)指定模態(tài)框的選擇器.可以是模態(tài)框的id屬性或者對(duì)應(yīng)選擇器的類名. 點(diǎn)擊觸發(fā)元素時(shí), 將會(huì)對(duì)目標(biāo)模態(tài)框進(jìn)行開(kāi)啟或關(guān)閉操作.* 3. data-bs-dismiss="modal": 將該屬性添加到按鈕等元素上, 點(diǎn)擊時(shí)將關(guān)閉模態(tài)框. 通常用于關(guān)閉按鈕或取消操作按鈕.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>模態(tài)框</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-3"><button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#myModal">打開(kāi)模態(tài)框</button><!-- 模態(tài)框 --><div class="modal" id="myModal"><div class="modal-dialog"><div class="modal-content"><!-- 模態(tài)框頭部 --><div class="modal-header"><h4 class="modal-title">模態(tài)框標(biāo)題</h4><button type="button" class="btn-close" data-bs-dismiss="modal"></button></div><!-- 模態(tài)框內(nèi)容 --><div class="modal-body">模態(tài)框內(nèi)容..</div><!-- 模態(tài)框底部 --><div class="modal-footer"><button type="button" class="btn btn-danger" data-bs-dismiss="modal">關(guān)閉</button></div></div></div></div>
</div>
</body>
</html>

GIF 2023-10-3 22-53-34

2.2 模態(tài)框動(dòng)畫(huà)效果

在Bootstrap 5, .fade類可以設(shè)置模態(tài)框彈出或關(guān)閉的效果.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>動(dòng)畫(huà)效果</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-3"><button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#myModal">打開(kāi)模態(tài)框</button>
</div><!-- 模態(tài)框 -->
<div class="modal fade" id="myModal"><div class="modal-dialog"><div class="modal-content"><!-- 模態(tài)框頭部 --><div class="modal-header"><h4 class="modal-title">模態(tài)框標(biāo)題</h4><button type="button" class="btn-close" data-bs-dismiss="modal"></button></div><!-- 模態(tài)框內(nèi)容 --><div class="modal-body">模態(tài)框內(nèi)容..</div><!-- 模態(tài)框底部 --><div class="modal-footer"><button type="button" class="btn btn-danger" data-bs-dismiss="modal">關(guān)閉</button></div></div></div>
</div>
</body>
</html>

GIF 2023-10-3 22-54-23

2.3 模態(tài)框尺寸

在Bootstrap 5, 模態(tài)框有多種預(yù)定義的尺寸大小可供選擇: (small), 默認(rèn)(default), (large), 額外大(extra large)...
可以通過(guò)在模態(tài)框的modal-dialog元素上添加相應(yīng)的類名來(lái)設(shè)置模態(tài)框的尺寸.以下是幾種尺寸類名:
* 1. .modal-sm: 用于設(shè)置小尺寸的模態(tài)框.
* 2. .modal-dialog: 默認(rèn), 用于設(shè)置默認(rèn)尺寸的模態(tài)框.
* 3. .modal-lg: 用于設(shè)置大尺寸的模態(tài)框.
* 4. .modal-xl: 用于設(shè)置額外大尺寸的模態(tài)框.
* 5. .modal-fullscreen: 可以讓模態(tài)框全屏幕顯示.
* 6. .modal-fullscreen-*-*: 可以控制在什么尺寸下全屏幕顯示..modal-fullscreen-sm-down:  576px以下尺寸全屏幕顯示..modal-fullscreen-md-down:	 768px以下尺寸全屏幕顯示..modal-fullscreen-lg-down:	 992px以下尺寸全屏幕顯示.	.modal-fullscreen-xl-down:	 1200px以下尺寸全屏幕顯示.	.modal-fullscreen-xxl-down: 1400px 以下尺寸全屏幕顯示.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>模態(tài)框尺寸</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-3"><button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#myModal">打開(kāi)模態(tài)框</button>
</div><!-- 模態(tài)框 -->
<div class="modal fade" id="myModal"><div class="modal-dialog modal-lg"><div class="modal-content"><!-- 模態(tài)框頭部 --><div class="modal-header"><h4 class="modal-title">模態(tài)框標(biāo)題</h4><button type="button" class="btn-close" data-bs-dismiss="modal"></button></div><!-- 模態(tài)框內(nèi)容 --><div class="modal-body">模態(tài)框內(nèi)容..</div><!-- 模態(tài)框底部 --><div class="modal-footer"><button type="button" class="btn btn-danger" data-bs-dismiss="modal">關(guān)閉</button></div></div></div>
</div>
</body>
</html>

image-20231003225516463

2.4 模態(tài)框居中顯示

在Bootstrap 5, .modal-dialog-centered類可以設(shè)置模態(tài)框水平和垂直方向都居中顯示.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>居中顯示</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-3"><button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#myModal">打開(kāi)模態(tài)框</button>
</div><!-- 模態(tài)框 -->
<div class="modal fade" id="myModal"><div class="modal-dialog modal-lg modal-dialog-centered"><div class="modal-content"><!-- 模態(tài)框頭部 --><div class="modal-header"><h4 class="modal-title">模態(tài)框標(biāo)題</h4><button type="button" class="btn-close" data-bs-dismiss="modal"></button></div><!-- 模態(tài)框內(nèi)容 --><div class="modal-body">模態(tài)框內(nèi)容..</div><!-- 模態(tài)框底部 --><div class="modal-footer"><button type="button" class="btn btn-danger" data-bs-dismiss="modal">關(guān)閉</button></div></div></div>
</div>
</body>
</html>

image-20231003225557025

2.5 模態(tài)框滾動(dòng)條

默認(rèn)情況下模態(tài)框如果包含很多內(nèi)容, 頁(yè)面會(huì)自動(dòng)生成一個(gè)滾動(dòng), 模態(tài)框隨著頁(yè)面的滾動(dòng)而滾動(dòng).

image-20231003225632455

在Bootstrap 5, .modal-dialog-scrollable類可以在模態(tài)框里頭設(shè)置一個(gè)滾動(dòng)條. 
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>模態(tài)框滾動(dòng)條</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-3"><button type="button" class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#myModal">打開(kāi)模態(tài)框</button>
</div><!-- 模態(tài)框 -->
<div class="modal" id="myModal"><!-- <div class="modal-dialog"> --><div class="modal-dialog modal-dialog-scrollable"><div class="modal-content"><!-- 模態(tài)框頭部 --><div class="modal-header"><h4 class="modal-title">模態(tài)框標(biāo)題</h4><button type="button" class="btn-close" data-bs-dismiss="modal"></button></div><!-- 模態(tài)框內(nèi)容 --><div class="modal-body">模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/>模態(tài)框內(nèi)容..<br/></div><!-- 模態(tài)框底部 --><div class="modal-footer"><button type="button" class="btn btn-danger" data-bs-dismiss="modal">關(guān)閉</button></div></div></div>
</div>
</body>
</html>

image-20231003225711230

3. 提示框

3.1 提示框樣式

在Bootstrap 5, 可以使用Tooltip組件來(lái)實(shí)現(xiàn)彈窗式提示框.創(chuàng)建提示框步驟:
* 1. 將data-bs-toggle="tooltip"屬性添加到希望觸發(fā)提示框的元素上.
* 2. 使用title屬性指定提示框顯示的內(nèi)容.
* 3. 當(dāng)鼠標(biāo)懸停在按鈕上時(shí), 提示框會(huì)顯示相應(yīng)的內(nèi)容.
// 當(dāng)使用JavaScript初始化提示框時(shí), 可以獲得更多的控制和定制化的能力, 
// 初始化提示框
var tooltipTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'))
var tooltipList = tooltipTriggerList.map(function (tooltipTriggerEl) {return new bootstrap.Tooltip(tooltipTriggerEl)
})
這段代碼的意義是用于初始化提示框(Tooltip)組件, 讓具有data-bs-toggle="tooltip"屬性的元素?fù)碛刑崾究虻墓δ?/span>.
這段代碼的具體作用:
* 1. tooltipTriggerList變量是一個(gè)空數(shù)組, 用于存儲(chǔ)具有data-bs-toggle="tooltip"屬性的元素.
* 2. document.querySelectorAll('[data-bs-toggle="tooltip"]')`選擇器將選取所有帶有data-bs-toggle="tooltip"屬性的元素,并將其構(gòu)成一個(gè)節(jié)點(diǎn)列表.* 3. [].slice.call()將節(jié)點(diǎn)列表轉(zhuǎn)換為真正的數(shù)組, 并將其存儲(chǔ)在tooltipTriggerList變量中.* 4. map()方法遍歷tooltipTriggerList數(shù)組中的每個(gè)元素并執(zhí)行一個(gè)匿名回調(diào)函數(shù), 該回調(diào)函數(shù)接收每個(gè)元素作為參數(shù).* 5. 在匿名回調(diào)函數(shù)中, 通過(guò)new bootstrap.Tooltip(tooltipTriggerEl)創(chuàng)建一個(gè)新的Tooltip 實(shí)例, 并將其返回.bootstrap.Tooltip是Bootstrap框架中負(fù)責(zé)創(chuàng)建和管理提示框的構(gòu)造函數(shù).* 6. tooltipList變量接收map()方法返回的所有Tooltip實(shí)例數(shù)組.通過(guò)執(zhí)行這段代碼, 具有data-bs-toggle="tooltip"`屬性的元素將被初始化為擁有提示框功能的元素.
當(dāng)鼠標(biāo)在這些元素上懸停時(shí), 提示框?qū)@示相應(yīng)的內(nèi)容(一般來(lái)自title屬性或通過(guò)JavaScript動(dòng)態(tài)設(shè)置).
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>提示框</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-5"><button type="button" class="btn btn-primary" data-bs-toggle="tooltip" title="我是提示內(nèi)容!">鼠標(biāo)移動(dòng)到我這</button>
</div><script>// 初始化提示框var tooltipTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'))var tooltipList = tooltipTriggerList.map(function (tooltipTriggerEl) {return new bootstrap.Tooltip(tooltipTriggerEl)})
</script>
</body>
</html>

GIF 2023-10-3 22-57-44

3.2 提示框顯示方向

默認(rèn)情況下提示框顯示在元素上方, 上方?jīng)]有足夠的空間顯示會(huì)換到其他方向上顯示.
可以使用data-bs-placement屬性來(lái)設(shè)定提示框顯示的方向, : top, bottom, left, right.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>提示框顯示方向</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-5"><a href="#" data-bs-toggle="tooltip" data-bs-placement="top" title="我是提示內(nèi)容!">鼠標(biāo)移動(dòng)到我這</a><a href="#" data-bs-toggle="tooltip" data-bs-placement="bottom" title="我是提示內(nèi)容!">鼠標(biāo)移動(dòng)到我這</a><a href="#" data-bs-toggle="tooltip" data-bs-placement="left" title="我是提示內(nèi)容!">鼠標(biāo)移動(dòng)到我這</a><a href="#" data-bs-toggle="tooltip" data-bs-placement="right" title="我是提示內(nèi)容!">鼠標(biāo)移動(dòng)到我這</a>
</div><script>var tooltipTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'))var tooltipList = tooltipTriggerList.map(function (tooltipTriggerEl) {return new bootstrap.Tooltip(tooltipTriggerEl)})
</script>
</body>
</html>

GIF 2023-10-3 22-58-33

4. 彈出框

4.1 彈出框樣式

在Bootstrap 5, 可以使用popover組件來(lái)實(shí)現(xiàn)彈出式的信息框.創(chuàng)建彈出框步驟:
* 1. 將data-bs-toggle="popover"屬性添加到希望觸發(fā)提示框的元素上.
* 2. 使用title屬性指定彈出框的標(biāo)題.
* 3. data-bs-content屬性指定彈出框的文本內(nèi)容.
* 4. 當(dāng)點(diǎn)擊按鈕時(shí), 顯示彈出框的內(nèi)容(標(biāo)題及文本內(nèi)容).
// 彈出框的JavaScript的初始化代碼:
var popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'))
var popoverList = popoverTriggerList.map(function (popoverTriggerEl) {return new bootstrap.Popover(popoverTriggerEl)
})
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>彈出框</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-3"><button type="button" class="btn btn-primary" data-bs-toggle="popover" title="彈出框標(biāo)題"data-bs-content="彈出框內(nèi)容">點(diǎn)擊按鈕</button>
</div><script>var popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'))var popoverList = popoverTriggerList.map(function (popoverTriggerEl) {return new bootstrap.Popover(popoverTriggerEl)})
</script>
</body>
</html>

image-20231003225921824

4.2 彈出框顯示方向

默認(rèn)情況下彈出框顯示在元素右側(cè), 顯示空間不足會(huì)在其他方向上顯示.可以使用data-bs-placement屬性來(lái)設(shè)定彈出框顯示的方向, : top, bottom, left, right.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>彈出框顯示方向</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container" style="margin-top: 100px"><div class="row"><div class="col"><a href="#" title="標(biāo)題" data-bs-toggle="popover" data-bs-placement="top"data-bs-content="我是內(nèi)容部分">點(diǎn)我</a></div><div class="col"><a href="#" title="標(biāo)題" data-bs-toggle="popover" data-bs-placement="bottom" data-bs-content="我是內(nèi)容部分">點(diǎn)我</a></div><div class="col"><a href="#" title="標(biāo)題" data-bs-toggle="popover" data-bs-placement="left"data-bs-content="我是內(nèi)容部分">點(diǎn)我</a></div><div class="col"><a href="#" title="標(biāo)題" data-bs-toggle="popover" data-bs-placement="right" data-bs-content="我是內(nèi)容部分">點(diǎn)我</a></div></div><script>var popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'))var popoverList = popoverTriggerList.map(function (popoverTriggerEl) {return new bootstrap.Popover(popoverTriggerEl)})</script>
</div>
</body>
</html>

image-20231003230004446

4.3 關(guān)閉彈出框

默認(rèn)情況下, 彈出框在再次點(diǎn)擊指定元素后就會(huì)關(guān)閉.
可以使用data-bs-trigger="focus"屬性來(lái)設(shè)置在鼠標(biāo)點(diǎn)擊元素外部區(qū)域來(lái)關(guān)閉彈出框.
可以使用data-bs-trigger="hover"屬性來(lái)在鼠標(biāo)移動(dòng)到元素上顯示彈出框, 移除后關(guān)閉彈出框.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>取消彈出框</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="container mt-5"><div class="row"><div class="col"><a href="#" title="取消彈出框" data-bs-toggle="popover" data-bs-trigger="focus"data-bs-content="點(diǎn)擊文檔的其他地方關(guān)閉我">點(diǎn)我</a></div><div class="col"><a href="#" title="取消彈出框" data-bs-toggle="popover" data-bs-trigger="hover"data-bs-content="點(diǎn)擊文檔的其他地方關(guān)閉我">點(diǎn)我</a></div></div>
</div><script>var popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'))var popoverList = popoverTriggerList.map(function (popoverTriggerEl) {return new bootstrap.Popover(popoverTriggerEl)})
</script>
</body>
</html>

GIF 2023-10-3 23-00-38

5. 滾動(dòng)監(jiān)聽(tīng)

5.1 滾動(dòng)監(jiān)聽(tīng)樣式

滾動(dòng)監(jiān)聽(tīng)(Scrollspy)插件: 是一種常見(jiàn)的前端插件, 用于在網(wǎng)頁(yè)滾動(dòng)時(shí)自動(dòng)更新導(dǎo)航目標(biāo)的狀態(tài).
它通過(guò)監(jiān)測(cè)滾動(dòng)條的位置來(lái)確定用戶當(dāng)前所在的頁(yè)面位置, 然后將對(duì)應(yīng)的導(dǎo)航目標(biāo)狀態(tài)更新為活動(dòng)狀態(tài).在Bootstarp 5, 創(chuàng)建滾動(dòng)監(jiān)聽(tīng)的相關(guān)屬性和類名及其介紹:
* 1. data-bs-spy="scroll": 在容器元素中使用此屬性, 用于指示該容器使用滾動(dòng)監(jiān)聽(tīng)功能.: <body>元素上使用data-bs-spy="scroll"屬性, 指示該頁(yè)面使用滾動(dòng)監(jiān)聽(tīng)功能.* 2. data-bs-target=".navbar": 指定滾動(dòng)監(jiān)聽(tīng)的目標(biāo)元素. 該屬性的值可以是一個(gè)選擇器, 用于選擇目標(biāo)元素.這里指定為.navbar, 表示導(dǎo)航欄是用于滾動(dòng)監(jiān)聽(tīng)的目標(biāo).* 3. data-bs-offset="50": 定義滾動(dòng)監(jiān)聽(tīng)的偏移量. 該屬性的值可以是一個(gè)數(shù)字, 表示垂直偏移的像素值. 默認(rèn)為10px.這個(gè)設(shè)置為50, 當(dāng)滾動(dòng)到目標(biāo)元素的頂部超過(guò)50像素時(shí), 滾動(dòng)監(jiān)聽(tīng)事件就會(huì)觸發(fā), 導(dǎo)航欄中對(duì)應(yīng)的鏈接將被高亮顯示.* 4. .sticky-top: 通過(guò)將此類應(yīng)用于導(dǎo)航欄元素, 可以使導(dǎo)航欄固定在頂部, 以便在滾動(dòng)時(shí)可見(jiàn).創(chuàng)建滾動(dòng)監(jiān)聽(tīng)的步驟(靈敏度不夠高):
* 1. 首先, <body>標(biāo)簽中添加data-bs-spy="scroll"屬性, 以指示需要使用滾動(dòng)監(jiān)聽(tīng)功能.
* 2. 在導(dǎo)航欄的<nav>元素中, 添加相應(yīng)的類名和樣式, 以確保導(dǎo)航欄固定在頂部.例如: navbar-expand-sm bg-dark navbar-dark fixed-top.* 3. 在導(dǎo)航欄的<ul>元素中, 添加導(dǎo)航鏈接列表. 這些鏈接將用于導(dǎo)航到相應(yīng)的部分.* 4. 對(duì)于每個(gè)部分, 創(chuàng)建一個(gè)<div>元素, 并為每個(gè)部分分配一個(gè)唯一的ID屬性.例如: id="section1", id="section2", id="section3".* 5. 在每個(gè)部分的<div>元素中, 添加你想要展示的內(nèi)容.* 6. 使用<a>元素創(chuàng)建導(dǎo)航鏈接, 將鏈接的href屬性設(shè)置為對(duì)應(yīng)部分的ID, 例如href="#section1".* 7. 最后, <body>標(biāo)簽中添加data-bs-target和data-bs-offset屬性, 將滾動(dòng)監(jiān)聽(tīng)功能與導(dǎo)航欄和偏移量關(guān)聯(lián)起來(lái).
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>滾動(dòng)監(jiān)聽(tīng)</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script>
</head>
<body data-bs-spy="scroll" data-bs-target=".navbar" data-bs-offset="50">
<nav class="navbar navbar-expand-sm bg-dark navbar-dark fixed-top"><div class="container-fluid"><ul class="navbar-nav"><li class="nav-item"><a class="nav-link" href="#section1">部分 1</a></li><li class="nav-item"><a class="nav-link" href="#section2">部分 2</a></li><li class="nav-item"><a class="nav-link" href="#section3">部分 3</a></li></ul></div>
</nav><div id="section1" class="container-fluid bg-success text-white" style="padding:100px 30px;"><h1>部分 1</h1><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p>
</div><div id="section2" class="container-fluid bg-warning" style="padding:100px 20px;"><h1>部分 2</h1><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p>
</div><div id="section3" class="container-fluid bg-secondary text-white" style="padding:100px 20px;"><h1>部分 3</h1><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p>
</div>
</body>
</html>

GIF 2023-10-4 20-45-42

5.2 案例

5.2.1 垂直滾動(dòng)監(jiān)聽(tīng)
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>垂直滾動(dòng)監(jiān)聽(tīng)</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<div class="row"><div class="col-4"><nav id="navbar-example3" class="navbar navbar-light bg-light flex-column sticky-top align-items-stretch p-3"><a class="navbar-brand" href="#">Navbar</a><nav class="nav nav-pills flex-column"><a class="nav-link" href="#item-1">Item 1</a><nav class="nav nav-pills flex-column"><a class="nav-link ms-3 my-1" href="#item-1-1">Item 1-1</a><a class="nav-link ms-3 my-1" href="#item-1-2">Item 1-2</a></nav><a class="nav-link" href="#item-2">Item 2</a><a class="nav-link active" href="#item-3">Item 3</a><nav class="nav nav-pills flex-column"><a class="nav-link ms-3 my-1" href="#item-3-1">Item 3-1</a><a class="nav-link ms-3 my-1 active" href="#item-3-2">Item 3-2</a></nav></nav></nav></div><div class="col-8"><div data-bs-spy="scroll" data-bs-target="#navbar-example3" data-bs-offset="0" class="scrollspy-example-2"tabindex="0"><h4 id="item-1">Item 1</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><hr><h5 id="item-1-1">Item 1-1</h5><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><hr><h5 id="item-1-2">Item 1-2</h5><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><hr><h4 id="item-2">Item 2</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><hr><h4 id="item-3">Item 3</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><hr><h5 id="item-3-1">Item 3-1</h5><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><hr><h5 id="item-3-2">Item 3-2</h5><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p></div></div>
</div>
</body>
</html>

GIF 2023-10-4 21-05-06

5.2.2 列表組形式
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>列表組形式</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script><style>.content_padding {padding: 50px 20px;}</style>
</head>
<body>
<div class="row"><div class="col-4"><div id="list-example" class="list-group sticky-top"><a class="list-group-item list-group-item-action" href="#list-item-1">Item 1</a><a class="list-group-item list-group-item-action" href="#list-item-2">Item 2</a><a class="list-group-item list-group-item-action" href="#list-item-3">Item 3</a><a class="list-group-item list-group-item-action active" href="#list-item-4">Item 4</a></div></div><div class="col-8"><div data-bs-spy="scroll" data-bs-target="#list-example" data-bs-offset="0" class="scrollspy-example"tabindex="0"><div id="list-item-1" class="content_padding"><h4>Item 1</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p></div><hr><div id="list-item-2" class="content_padding"><h4>Item 2</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p></div><hr><div id="list-item-3" class="content_padding"><h4>Item 3</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p></div><hr><div id="list-item-4" class="content_padding"><h4>Item 4</h4><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p><p>嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!嘗試滾動(dòng)此部分并在滾動(dòng)時(shí)查看導(dǎo)航欄!</p></div></div></div>
</div>
</body>
</html>

GIF 2023-10-4 21-15-39

6. 側(cè)邊欄

Bootstrap中的側(cè)邊欄類似于模態(tài)框, 在移動(dòng)端設(shè)備中比較常用.

6.1 側(cè)邊欄組件

 Bootstrap 5, 用于創(chuàng)建側(cè)邊欄的相關(guān)類名及其介紹:
* 1. .offcanvas: 用于創(chuàng)建一個(gè)offcanvas元素, 定義側(cè)邊欄的樣式. * 2. .offcanvas-start: 用于指定側(cè)邊欄的位置, 即屏幕的起始位置(左側(cè)), 使用其中之一來(lái)定義側(cè)邊欄的對(duì)齊方式.* 3. .offcanvas-header: 用于定義側(cè)邊欄的頭部區(qū)域, 一般用于顯示標(biāo)題, 關(guān)閉按鈕或其他相關(guān)信息.可以將這個(gè)類應(yīng)用于一個(gè)div元素, 使其成為側(cè)邊欄的頭部.* 4. .offcanvas-body: 用于定義側(cè)邊欄的內(nèi)容區(qū)域, 可以用于放置菜單, 表單, 文本或其他與側(cè)邊欄相關(guān)的內(nèi)容.可以將這個(gè)類應(yīng)用于一個(gè)div元素, 使其成為側(cè)邊欄的內(nèi)容區(qū)域.* 5. .offcanvas-title: 用于定義側(cè)邊欄組件的標(biāo)題區(qū)域.
aria-controls屬性: 是一個(gè)用于無(wú)障礙輔助功能的HTML屬性, 用于指定由當(dāng)前元素控制的其他元素的ID.
通過(guò)將aria-controls屬性添加到一個(gè)元素上, 并將其值設(shè)置為另一個(gè)元素的ID, 可以建立起兩個(gè)元素之間的關(guān)聯(lián)關(guān)系.
雖然aria-controls屬性本身不會(huì)觸發(fā)特定的行為, 但它在構(gòu)建無(wú)障礙界面時(shí)起到重要的角色.role屬性: 是一個(gè)HTML屬性, 用于指定元素在頁(yè)面中扮演的角色或功能.
通過(guò)設(shè)置role屬性, 可以告訴瀏覽器和輔助技術(shù)如何處理和解釋元素.tabindex屬性: 用于指定元素是否可通過(guò)鍵盤(pán)進(jìn)行焦點(diǎn)導(dǎo)航.
當(dāng)設(shè)置tabindex="-1"時(shí), 該元素將被排除在鍵盤(pán)焦點(diǎn)順序之外, 即無(wú)法通過(guò)按Tab鍵來(lái)聚焦到該元素.aria-labelledby: 是一個(gè)WAI-ARIA屬性, 用于關(guān)聯(lián)一個(gè)元素與一個(gè)或多個(gè)標(biāo)簽(或其他可識(shí)別的元素), 以提供對(duì)關(guān)聯(lián)元素的描述或上下文.
通常情況下, aria-labelledby屬性用于將一個(gè)標(biāo)簽元素的ID值與一個(gè)目標(biāo)元素的aria-labelledby屬性進(jìn)行關(guān)聯(lián).
使用屏幕閱讀器的用戶將能夠聽(tīng)到這個(gè)標(biāo)簽的描述, 從而更好地理解其用途.data-bs-dismiss="offcanvas"屬性: 添加到關(guān)閉按鈕上, 用于指定點(diǎn)擊按鈕時(shí)關(guān)閉offcanvas組件.
當(dāng)點(diǎn)擊按鈕時(shí), 相關(guān)的offcanvas組件將被隱藏或關(guān)閉. 這是Bootstrap JavaScript組件的一部分, 它會(huì)根據(jù)該屬性來(lái)處理關(guān)閉事件.aria-label="Close"屬性: 定義了關(guān)閉按鈕的輔助性文本.
它提供一個(gè)描述性的標(biāo)簽, 幫助屏幕閱讀器用戶了解按鈕的作用.
在這個(gè)例子中, 'Close'是表示關(guān)閉按鈕的合適描述.
對(duì)于使用a鏈接的情況, 可以在href屬性中指定目標(biāo)元素的選擇器,
并為鏈接添加data-bs-toggle="offcanvas"屬性.對(duì)于使用button元素的情況, 可以使用data-bs-target屬性來(lái)指定目標(biāo)元素的選擇器,
并為按鈕添加data-bs-toggle="offcanvas"屬性.當(dāng)你點(diǎn)擊鏈接或按鈕時(shí), JavaScript會(huì)自動(dòng)為目標(biāo)元素添加.show類, 顯示側(cè)邊欄內(nèi)容.
再次點(diǎn)擊鏈接或按鈕, JavaScript會(huì)將.show類移除, 隱藏側(cè)邊欄內(nèi)容.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>側(cè)邊欄組件</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body><div><a class="btn btn-primary" data-bs-toggle="offcanvas" href="" role="button"aria-controls="offcanvasExample">使用鏈接的 href 屬性</a><!--    data-bs-toggle 指定操作的行為, data-bs-target綁定操作的對(duì)象--><button class="btn btn-primary" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasExample">按鈕中使用 data-bs-target</button>
</div><div class="offcanvas offcanvas-start" tabindex="-1" id="offcanvasExample" aria-labelledby="offcanvasExampleLabel"><div class="offcanvas-header"><h5 class="offcanvas-title" id="offcanvasExampleLabel">側(cè)邊欄</h5><button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close"></button></div><div class="offcanvas-body"><div>一些文本作為占位符。在現(xiàn)實(shí)生活中,您可以擁有您選擇的元素。如文本、圖像、列表等。</div><div class="dropdown mt-3"><button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenuButton"data-bs-toggle="dropdown">下拉按鈕</button><ul class="dropdown-menu" aria-labelledby="dropdownMenuButton"><li><a class="dropdown-item" href="#">選項(xiàng)1</a></li><li><a class="dropdown-item" href="#">選項(xiàng)2</a></li><li><a class="dropdown-item" href="#">選項(xiàng)3</a></li></ul></div></div>
</div></body>
</html>

GIF 2023-10-5 10-01-41

6.2 側(cè)邊欄的方向

可以通過(guò)以下四個(gè)類來(lái)控制側(cè)邊欄的方向:
* 1. .offcanvas-start: 顯示在左側(cè).
* 2. .offcanvas-end:   顯示在右側(cè).
* 3. .offcanvas-top:   顯示在頂部.
* 4. .offcanvas-bottom 顯示在底部.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>顯示方向</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body>
<button class="btn btn-primary" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasTop"aria-controls="offcanvasTop">底部側(cè)邊框
</button><div class="offcanvas offcanvas-bottom" tabindex="-1" id="offcanvasTop" aria-labelledby="offcanvasTopLabel"><div class="offcanvas-header"><h5 id="offcanvasTopLabel">顯示在底部側(cè)邊框</h5><button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close"></button></div><div class="offcanvas-body">...</div>
</div></body>
</html>

GIF 2023-10-5 10-23-21

6.3 背景滾動(dòng)條

data-bs-scroll="true": 用于指定背景是否可以垂直滾動(dòng).
data-bs-scroll屬性設(shè)置為false, 在打開(kāi)Offcanvas側(cè)邊欄時(shí), 背景將被禁止?jié)L動(dòng)(默認(rèn)).
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>背景滾動(dòng)條</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body><div class='sticky-top' style="margin: 5px 500px"><button class="btn btn-primary" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasWithBothOptions1"aria-controls="offcanvasWithBothOptions1">默認(rèn)不允許背景滾動(dòng)</button><button class="btn btn-primary" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasWithBothOptions2"aria-controls="offcanvasWithBothOptions2">允許背景滾動(dòng)</button>
</div><div class="offcanvas offcanvas-start" tabindex="-1" id="offcanvasWithBothOptions1"aria-labelledby="offcanvasWithBothOptionsLabel1"><div class="offcanvas-header"><h5 class="offcanvas-title" id="offcanvasWithBothOptionsLabel1">使用背景畫(huà)布, 背景內(nèi)容可滾動(dòng)</h5><button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close"></button></div><div class="offcanvas-body"><p>滾動(dòng)背景頁(yè)面查看效果</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/></div>
</div>
<div class="offcanvas offcanvas-start" data-bs-scroll="true" tabindex="-1" id="offcanvasWithBothOptions2"aria-labelledby="offcanvasWithBothOptionsLabel2"><div class="offcanvas-header"><h5 class="offcanvas-title" id="offcanvasWithBothOptionsLabel2">使用背景畫(huà)布, 正文內(nèi)容可滾動(dòng)</h5><button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close"></button></div><div class="offcanvas-body"><p>滾動(dòng)頁(yè)面查看效果</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/></div>
</div>
<div class="container mt-3 text-end"><h3>背景滾動(dòng)滾動(dòng)測(cè)試</h3><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/>
</div>
</body>
</html>

GIF 2023-10-5 11-28-31

6.3 背景遮罩設(shè)置

data-bs-backdrop屬性: 用于指定是否啟用背景遮罩, 默認(rèn)是開(kāi)啟的.
當(dāng)設(shè)置data-bs-backdrop="false"屬性時(shí), 打開(kāi)的Offcanvas組件將沒(méi)有背景遮罩.
這意味著用戶可以與背景下的內(nèi)容進(jìn)行交互, 而不是被阻止.
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>背景遮罩</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script></head>
<body><div class='sticky-top' style="margin: 5px 500px"><button class="btn btn-primary" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasWithBothOptions1"aria-controls="offcanvasWithBothOptions1">默認(rèn)開(kāi)啟遮罩</button><button class="btn btn-primary" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasWithBothOptions2"aria-controls="offcanvasWithBothOptions2">關(guān)閉遮罩</button>
</div><div class="offcanvas offcanvas-start" tabindex="-1" id="offcanvasWithBothOptions1"aria-labelledby="offcanvasWithBothOptionsLabel1"><div class="offcanvas-header"><h5 class="offcanvas-title" id="offcanvasWithBothOptionsLabel1">使用背景畫(huà)布, 背景內(nèi)容可滾動(dòng)</h5><button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close"></button></div><div class="offcanvas-body"><p>滾動(dòng)背景頁(yè)面查看效果</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/></div>
</div>
<!--關(guān)閉遮罩并開(kāi)啟背景可滾動(dòng)-->
<div class="offcanvas offcanvas-start" data-bs-backdrop="false" data-bs-scroll="true" tabindex="-1"id="offcanvasWithBothOptions2"aria-labelledby="offcanvasWithBothOptionsLabel2"><div class="offcanvas-header"><h5 class="offcanvas-title" id="offcanvasWithBothOptionsLabel2">使用背景畫(huà)布, 正文內(nèi)容可滾動(dòng)</h5><button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close"></button></div><div class="offcanvas-body"><p>滾動(dòng)頁(yè)面查看效果</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/></div>
</div>
<div class="container mt-3 text-end"><h3>背景滾動(dòng)滾動(dòng)測(cè)試</h3><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><p>背景滾動(dòng)測(cè)試內(nèi)容...</p><br/><br/><br/><br/><br/>
</div>
</body>
</html>

GIF 2023-10-5 11-38-50

6.4 側(cè)邊欄案例

6.4.1 案例1
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>案例1</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script><style>.bi {vertical-align: -.125em;pointer-events: none;fill: currentColor}.dropdown-toggle {outline: 0}.nav-link:hover {background-color: #00fbff;color: black !important;}</style>
</head>
<body>
<svg xmlns="" style="display: none;"><symbol id="bootstrap" viewBox="0 0 118 94"><title>Bootstrap</title><path fill-rule="evenodd" clip-rule="evenodd"d="M24.509 0c-6.733 0-11.715 5.893-11.492 12.284.214 6.14-.064 14.092-2.066 20.577C8.943 39.365 5.547 43.485 0 44.014v5.972c5.547.529 8.943 4.649 10.951 11.153 2.002 6.485 2.28 14.437 2.066 20.577C12.794 88.106 17.776 94 24.51 94H93.5c6.733 0 11.714-5.893 11.491-12.284-.214-6.14.064-14.092 2.066-20.577 2.009-6.504 5.396-10.624 10.943-11.153v-5.972c-5.547-.529-8.934-4.649-10.943-11.153-2.002-6.484-2.28-14.437-2.066-20.577C105.214 5.894 100.233 0 93.5 0H24.508zM80 57.863C80 66.663 73.436 72 62.543 72H44a2 2 0 01-2-2V24a2 2 0 012-2h18.437c9.083 0 15.044 4.92 15.044 12.474 0 5.302-4.01 10.049-9.119 10.88v.277C75.317 46.394 80 51.21 80 57.863zM60.521 28.34H49.948v14.934h8.905c6.884 0 10.68-2.772 10.68-7.727 0-4.643-3.264-7.207-9.012-7.207zM49.948 49.2v16.458H60.91c7.167 0 10.964-2.876 10.964-8.281 0-5.406-3.903-8.178-11.425-8.178H49.948z"></path></symbol><symbol id="home" viewBox="0 0 16 16"><path d="M8.354 1.146a.5.5 0 0 0-.708 0l-6 6A.5.5 0 0 0 1.5 7.5v7a.5.5 0 0 0 .5.5h4.5a.5.5 0 0 0 .5-.5v-4h2v4a.5.5 0 0 0 .5.5H14a.5.5 0 0 0 .5-.5v-7a.5.5 0 0 0-.146-.354L13 5.793V2.5a.5.5 0 0 0-.5-.5h-1a.5.5 0 0 0-.5.5v1.293L8.354 1.146zM2.5 14V7.707l5.5-5.5 5.5 5.5V14H10v-4a.5.5 0 0 0-.5-.5h-3a.5.5 0 0 0-.5.5v4H2.5z"/></symbol><symbol id="speedometer2" viewBox="0 0 16 16"><path d="M8 4a.5.5 0 0 1 .5.5V6a.5.5 0 0 1-1 0V4.5A.5.5 0 0 1 8 4zM3.732 5.732a.5.5 0 0 1 .707 0l.915.914a.5.5 0 1 1-.708.708l-.914-.915a.5.5 0 0 1 0-.707zM2 10a.5.5 0 0 1 .5-.5h1.586a.5.5 0 0 1 0 1H2.5A.5.5 0 0 1 2 10zm9.5 0a.5.5 0 0 1 .5-.5h1.5a.5.5 0 0 1 0 1H12a.5.5 0 0 1-.5-.5zm.754-4.246a.389.389 0 0 0-.527-.02L7.547 9.31a.91.91 0 1 0 1.302 1.258l3.434-4.297a.389.389 0 0 0-.029-.518z"/><path fill-rule="evenodd"d="M0 10a8 8 0 1 1 15.547 2.661c-.442 1.253-1.845 1.602-2.932 1.25C11.309 13.488 9.475 13 8 13c-1.474 0-3.31.488-4.615.911-1.087.352-2.49.003-2.932-1.25A7.988 7.988 0 0 1 0 10zm8-7a7 7 0 0 0-6.603 9.329c.203.575.923.876 1.68.63C4.397 12.533 6.358 12 8 12s3.604.532 4.923.96c.757.245 1.477-.056 1.68-.631A7 7 0 0 0 8 3z"/></symbol><symbol id="table" viewBox="0 0 16 16"><path d="M0 2a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V2zm15 2h-4v3h4V4zm0 4h-4v3h4V8zm0 4h-4v3h3a1 1 0 0 0 1-1v-2zm-5 3v-3H6v3h4zm-5 0v-3H1v2a1 1 0 0 0 1 1h3zm-4-4h4V8H1v3zm0-4h4V4H1v3zm5-3v3h4V4H6zm4 4H6v3h4V8z"/></symbol><symbol id="people-circle" viewBox="0 0 16 16"><path d="M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0z"/><path fill-rule="evenodd"d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8zm8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1z"/></symbol><symbol id="grid" viewBox="0 0 16 16"><path d="M1 2.5A1.5 1.5 0 0 1 2.5 1h3A1.5 1.5 0 0 1 7 2.5v3A1.5 1.5 0 0 1 5.5 7h-3A1.5 1.5 0 0 1 1 5.5v-3zM2.5 2a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3zm6.5.5A1.5 1.5 0 0 1 10.5 1h3A1.5 1.5 0 0 1 15 2.5v3A1.5 1.5 0 0 1 13.5 7h-3A1.5 1.5 0 0 1 9 5.5v-3zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3zM1 10.5A1.5 1.5 0 0 1 2.5 9h3A1.5 1.5 0 0 1 7 10.5v3A1.5 1.5 0 0 1 5.5 15h-3A1.5 1.5 0 0 1 1 13.5v-3zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3zm6.5.5A1.5 1.5 0 0 1 10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-3A1.5 1.5 0 0 1 9 13.5v-3zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3z"/></symbol></svg><div class="d-flex flex-column flex-shrink-0 p-3 text-white bg-dark" style="width: 280px;"><a href="/" class="d-flex align-items-center mb-3 mb-md-0 me-md-auto text-white text-decoration-none"><svg class="bi me-2" width="40" height="32"><use xlink:href="#bootstrap"/></svg><span class="fs-4">側(cè)邊欄</span></a><hr><ul class="nav nav-pills flex-column mb-auto"><li class="nav-item"><a href="#" class="nav-link text-white" aria-current="page"><svg class="bi me-2" width="16" height="16"><use xlink:href="#home"/></svg>主頁(yè)</a></li><li><a href="#" class="nav-link text-white"><svg class="bi me-2" width="16" height="16"><use xlink:href="#speedometer2"/></svg>儀表盤(pán)</a></li><li><a href="#" class="nav-link text-white"><svg class="bi me-2" width="16" height="16"><use xlink:href="#table"/></svg>訂單</a></li><li><a href="#" class="nav-link text-white"><svg class="bi me-2" width="16" height="16"><use xlink:href="#grid"/></svg>產(chǎn)品</a></li><li><a href="#" class="nav-link text-white"><svg class="bi me-2" width="16" height="16"><use xlink:href="#people-circle"/></svg>客戶</a></li></ul><hr><div class="dropdown"><a href="#" class="d-flex align-items-center text-white text-decoration-none dropdown-toggle"id="dropdownUser1" data-bs-toggle="dropdown" aria-expanded="false"><img src="img/5.png" alt="" width="32" height="32" class="rounded-circle me-2"><strong>qz</strong></a><ul class="dropdown-menu dropdown-menu-dark text-small shadow" aria-labelledby="dropdownUser1"><li><a class="dropdown-item" href="#">新項(xiàng)目...</a></li><li><a class="dropdown-item" href="#">設(shè)置</a></li><li><a class="dropdown-item" href="#">個(gè)人信息</a></li><li><hr class="dropdown-divider"></li><li><a class="dropdown-item" href="#">登出</a></li></ul></div>
</div>
</body>
</html>

GIF 2023-10-5 12-16-30

6.4.2 案例2
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>案例2</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script><style>.bi {vertical-align: -.125em;pointer-events: none;fill: currentColor}.dropdown-toggle {outline: 0}.nav-flush .nav-link {border-radius: 0}.btn-toggle-nav a {display: inline-flex;padding: .1875rem .5rem;margin-top: .125rem;margin-left: 1.25rem;text-decoration: none}.btn-toggle-nav a:hover, .btn-toggle-nav a:focus {background-color: #d2f4ea}.nav-link:hover {background-color: #00fbff;color: black !important;}</style>
</head>
<body>
<svg xmlns="" style="display: none;"><symbol id="bootstrap" viewBox="0 0 118 94"><title>Bootstrap</title><path fill-rule="evenodd" clip-rule="evenodd"d="M24.509 0c-6.733 0-11.715 5.893-11.492 12.284.214 6.14-.064 14.092-2.066 20.577C8.943 39.365 5.547 43.485 0 44.014v5.972c5.547.529 8.943 4.649 10.951 11.153 2.002 6.485 2.28 14.437 2.066 20.577C12.794 88.106 17.776 94 24.51 94H93.5c6.733 0 11.714-5.893 11.491-12.284-.214-6.14.064-14.092 2.066-20.577 2.009-6.504 5.396-10.624 10.943-11.153v-5.972c-5.547-.529-8.934-4.649-10.943-11.153-2.002-6.484-2.28-14.437-2.066-20.577C105.214 5.894 100.233 0 93.5 0H24.508zM80 57.863C80 66.663 73.436 72 62.543 72H44a2 2 0 01-2-2V24a2 2 0 012-2h18.437c9.083 0 15.044 4.92 15.044 12.474 0 5.302-4.01 10.049-9.119 10.88v.277C75.317 46.394 80 51.21 80 57.863zM60.521 28.34H49.948v14.934h8.905c6.884 0 10.68-2.772 10.68-7.727 0-4.643-3.264-7.207-9.012-7.207zM49.948 49.2v16.458H60.91c7.167 0 10.964-2.876 10.964-8.281 0-5.406-3.903-8.178-11.425-8.178H49.948z"></path></symbol><symbol id="home" viewBox="0 0 16 16"><path d="M8.354 1.146a.5.5 0 0 0-.708 0l-6 6A.5.5 0 0 0 1.5 7.5v7a.5.5 0 0 0 .5.5h4.5a.5.5 0 0 0 .5-.5v-4h2v4a.5.5 0 0 0 .5.5H14a.5.5 0 0 0 .5-.5v-7a.5.5 0 0 0-.146-.354L13 5.793V2.5a.5.5 0 0 0-.5-.5h-1a.5.5 0 0 0-.5.5v1.293L8.354 1.146zM2.5 14V7.707l5.5-5.5 5.5 5.5V14H10v-4a.5.5 0 0 0-.5-.5h-3a.5.5 0 0 0-.5.5v4H2.5z"/></symbol><symbol id="speedometer2" viewBox="0 0 16 16"><path d="M8 4a.5.5 0 0 1 .5.5V6a.5.5 0 0 1-1 0V4.5A.5.5 0 0 1 8 4zM3.732 5.732a.5.5 0 0 1 .707 0l.915.914a.5.5 0 1 1-.708.708l-.914-.915a.5.5 0 0 1 0-.707zM2 10a.5.5 0 0 1 .5-.5h1.586a.5.5 0 0 1 0 1H2.5A.5.5 0 0 1 2 10zm9.5 0a.5.5 0 0 1 .5-.5h1.5a.5.5 0 0 1 0 1H12a.5.5 0 0 1-.5-.5zm.754-4.246a.389.389 0 0 0-.527-.02L7.547 9.31a.91.91 0 1 0 1.302 1.258l3.434-4.297a.389.389 0 0 0-.029-.518z"/><path fill-rule="evenodd"d="M0 10a8 8 0 1 1 15.547 2.661c-.442 1.253-1.845 1.602-2.932 1.25C11.309 13.488 9.475 13 8 13c-1.474 0-3.31.488-4.615.911-1.087.352-2.49.003-2.932-1.25A7.988 7.988 0 0 1 0 10zm8-7a7 7 0 0 0-6.603 9.329c.203.575.923.876 1.68.63C4.397 12.533 6.358 12 8 12s3.604.532 4.923.96c.757.245 1.477-.056 1.68-.631A7 7 0 0 0 8 3z"/></symbol><symbol id="table" viewBox="0 0 16 16"><path d="M0 2a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V2zm15 2h-4v3h4V4zm0 4h-4v3h4V8zm0 4h-4v3h3a1 1 0 0 0 1-1v-2zm-5 3v-3H6v3h4zm-5 0v-3H1v2a1 1 0 0 0 1 1h3zm-4-4h4V8H1v3zm0-4h4V4H1v3zm5-3v3h4V4H6zm4 4H6v3h4V8z"/></symbol><symbol id="people-circle" viewBox="0 0 16 16"><path d="M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0z"/><path fill-rule="evenodd"d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8zm8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1z"/></symbol><symbol id="grid" viewBox="0 0 16 16"><path d="M1 2.5A1.5 1.5 0 0 1 2.5 1h3A1.5 1.5 0 0 1 7 2.5v3A1.5 1.5 0 0 1 5.5 7h-3A1.5 1.5 0 0 1 1 5.5v-3zM2.5 2a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3zm6.5.5A1.5 1.5 0 0 1 10.5 1h3A1.5 1.5 0 0 1 15 2.5v3A1.5 1.5 0 0 1 13.5 7h-3A1.5 1.5 0 0 1 9 5.5v-3zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3zM1 10.5A1.5 1.5 0 0 1 2.5 9h3A1.5 1.5 0 0 1 7 10.5v3A1.5 1.5 0 0 1 5.5 15h-3A1.5 1.5 0 0 1 1 13.5v-3zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3zm6.5.5A1.5 1.5 0 0 1 10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-3A1.5 1.5 0 0 1 9 13.5v-3zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5h-3z"/></symbol>
</svg><div class="d-flex flex-column flex-shrink-0 bg-light" style="width: 4.5rem;"><a href="/" class="d-block p-3 link-dark text-decoration-none border-bottom" title="Logo" data-bs-toggle="tooltip"data-bs-placement="right"><svg class="bi" width="40" height="32"><use xlink:href="#bootstrap"/></svg><span class="visually-hidden">Logo</span></a><ul class="nav nav-pills nav-flush flex-column mb-auto text-center"><li class="nav-item"><a href="#" class="nav-link py-3 border-bottom" aria-current="page" title="主頁(yè)"data-bs-toggle="tooltip" data-bs-placement="right"><svg class="bi" width="24" height="24" role="img" aria-label="Home"><use xlink:href="#home"/></svg></a></li><li><a href="#" class="nav-link py-3 border-bottom" title="儀表盤(pán)" data-bs-toggle="tooltip"data-bs-placement="right"><svg class="bi" width="24" height="24" role="img" aria-label="Dashboard"><use xlink:href="#speedometer2"/></svg></a></li><li><a href="#" class="nav-link py-3 border-bottom" title="訂單" data-bs-toggle="tooltip"data-bs-placement="right"><svg class="bi" width="24" height="24" role="img" aria-label="Orders"><use xlink:href="#table"/></svg></a></li><li><a href="#" class="nav-link py-3 border-bottom" title="產(chǎn)品" data-bs-toggle="tooltip"data-bs-placement="right"><svg class="bi" width="24" height="24" role="img" aria-label="Products"><use xlink:href="#grid"/></svg></a></li><li><a href="#" class="nav-link py-3 border-bottom" title="客戶" data-bs-toggle="tooltip"data-bs-placement="right"><svg class="bi" width="24" height="24" role="img" aria-label="Customers"><use xlink:href="#people-circle"/></svg></a></li></ul><div class="dropdown border-top"><a href="#"class="d-flex align-items-center justify-content-center p-3 link-dark text-decoration-none dropdown-toggle"id="dropdownUser3" data-bs-toggle="dropdown" aria-expanded="false"><img src="img/5.png" alt="mdo" width="24" height="24" class="rounded-circle"></a><ul class="dropdown-menu text-small shadow" aria-labelledby="dropdownUser3"><li><a class="dropdown-item" href="#">新項(xiàng)目...</a></li><li><a class="dropdown-item" href="#">設(shè)置</a></li><li><a class="dropdown-item" href="#">個(gè)人信息</a></li><li><hr class="dropdown-divider"></li><li><a class="dropdown-item" href="#">登出</a></li></ul></div>
</div>
</body>
</html>

GIF 2023-10-5 12-35-37

6.4.3 案例3
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>案例3</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script><style>.bi {vertical-align: -.125em;pointer-events: none;fill: currentColor}.btn-toggle {display: inline-flex;align-items: center;padding: .25rem .5rem;font-weight: 600;color: rgba(0, 0, 0, .65);background-color: transparent;border: 0}.btn-toggle:hover, .btn-toggle:focus {color: rgba(0, 0, 0, .85);background-color: #d2f4ea}.btn-toggle::before {width: 1.25em;line-height: 0;content: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='rgba%280,0,0,.5%29' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 14l6-6-6-6'/%3e%3c/svg%3e");transition: transform .35s ease;transform-origin: .5em 50%}.btn-toggle[aria-expanded="true"] {color: rgba(0, 0, 0, .85)}.btn-toggle[aria-expanded="true"]::before {transform: rotate(90deg)}.btn-toggle-nav a {display: inline-flex;padding: .1875rem .5rem;margin-top: .125rem;margin-left: 1.25rem;text-decoration: none}.btn-toggle-nav a:hover, .btn-toggle-nav a:focus {background-color: #d2f4ea}.fw-semibold {font-weight: 600}</style>
</head>
<body>
<svg xmlns="" style="display: none;"><symbol id="bootstrap" viewBox="0 0 118 94"><title>Bootstrap</title><path fill-rule="evenodd" clip-rule="evenodd"d="M24.509 0c-6.733 0-11.715 5.893-11.492 12.284.214 6.14-.064 14.092-2.066 20.577C8.943 39.365 5.547 43.485 0 44.014v5.972c5.547.529 8.943 4.649 10.951 11.153 2.002 6.485 2.28 14.437 2.066 20.577C12.794 88.106 17.776 94 24.51 94H93.5c6.733 0 11.714-5.893 11.491-12.284-.214-6.14.064-14.092 2.066-20.577 2.009-6.504 5.396-10.624 10.943-11.153v-5.972c-5.547-.529-8.934-4.649-10.943-11.153-2.002-6.484-2.28-14.437-2.066-20.577C105.214 5.894 100.233 0 93.5 0H24.508zM80 57.863C80 66.663 73.436 72 62.543 72H44a2 2 0 01-2-2V24a2 2 0 012-2h18.437c9.083 0 15.044 4.92 15.044 12.474 0 5.302-4.01 10.049-9.119 10.88v.277C75.317 46.394 80 51.21 80 57.863zM60.521 28.34H49.948v14.934h8.905c6.884 0 10.68-2.772 10.68-7.727 0-4.643-3.264-7.207-9.012-7.207zM49.948 49.2v16.458H60.91c7.167 0 10.964-2.876 10.964-8.281 0-5.406-3.903-8.178-11.425-8.178H49.948z"></path></symbol></svg><div class="flex-shrink-0 p-3 bg-white" style="width: 280px;"><a href="#" class="d-flex align-items-center pb-3 mb-3 link-dark text-decoration-none border-bottom"><svg class="bi me-2" width="30" height="24"><use xlink:href="#bootstrap"/></svg><span class="fs-5 fw-semibold">標(biāo)題</span></a><ul class="list-unstyled ps-0"><li class="mb-1"><!--   aria-expanded 設(shè)置為T(mén)rue展開(kāi) 菜單        --><button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse"data-bs-target="#home-collapse" aria-expanded="true">主頁(yè)</button><!--  show 顯示子選項(xiàng)--><div class="collapse show" id="home-collapse"><ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small"><li><a href="#" class="link-dark rounded">概述</a></li><li><a href="#" class="link-dark rounded">更新</a></li><li><a href="#" class="link-dark rounded">報(bào)告</a></li></ul></div></li><li class="mb-1"><button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse"data-bs-target="#dashboard-collapse" aria-expanded="false">儀表盤(pán)</button><div class="collapse" id="dashboard-collapse"><ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small"><li><a href="#" class="link-dark rounded">概述</a></li><li><a href="#" class="link-dark rounded">周刊</a></li><li><a href="#" class="link-dark rounded">月報(bào)</a></li><li><a href="#" class="link-dark rounded">每報(bào)</a></li></ul></div></li><li class="mb-1"><button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse"data-bs-target="#orders-collapse" aria-expanded="false">訂單</button><div class="collapse" id="orders-collapse"><ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small"><li><a href="#" class="link-dark rounded">新訂單</a></li><li><a href="#" class="link-dark rounded">已處理</a></li><li><a href="#" class="link-dark rounded">已發(fā)貨</a></li><li><a href="#" class="link-dark rounded">已退貨</a></li></ul></div></li><li class="border-top my-3"></li><li class="mb-1"><button class="btn btn-toggle align-items-center rounded collapsed" data-bs-toggle="collapse"data-bs-target="#account-collapse" aria-expanded="false">帳戶</button><div class="collapse" id="account-collapse"><ul class="btn-toggle-nav list-unstyled fw-normal pb-1 small"><li><a href="#" class="link-dark rounded">新建...</a></li><li><a href="#" class="link-dark rounded">個(gè)人資料</a></li><li><a href="#" class="link-dark rounded">設(shè)置</a></li><li><a href="#" class="link-dark rounded">登出</a></li></ul></div></li></ul>
</div>
</body>
</html>

GIF 2023-10-5 13-03-42

6.4.4 案例4
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>案例4</title><link href="bootstrap-5.3.2-dist/css/bootstrap.min.css" rel="stylesheet"><script src="bootstrap-5.3.2-dist/js/bootstrap.bundle.min.js"></script><style>.bi {vertical-align: -.125em;pointer-events: none;fill: currentColor}.btn-toggle-nav a {display: inline-flex;padding: .1875rem .5rem;margin-top: .125rem;margin-left: 1.25rem;text-decoration: none}.scrollarea {overflow-y: auto}.fw-semibold {font-weight: 600}.lh-tight {line-height: 1.25}.list-group-item:hover {background-color: #00fbff;color: black !important;}</style>
</head>
<body>
<svg xmlns="" style="display: none;"><symbol id="bootstrap" viewBox="0 0 118 94"><title>Bootstrap</title><path fill-rule="evenodd" clip-rule="evenodd"d="M24.509 0c-6.733 0-11.715 5.893-11.492 12.284.214 6.14-.064 14.092-2.066 20.577C8.943 39.365 5.547 43.485 0 44.014v5.972c5.547.529 8.943 4.649 10.951 11.153 2.002 6.485 2.28 14.437 2.066 20.577C12.794 88.106 17.776 94 24.51 94H93.5c6.733 0 11.714-5.893 11.491-12.284-.214-6.14.064-14.092 2.066-20.577 2.009-6.504 5.396-10.624 10.943-11.153v-5.972c-5.547-.529-8.934-4.649-10.943-11.153-2.002-6.484-2.28-14.437-2.066-20.577C105.214 5.894 100.233 0 93.5 0H24.508zM80 57.863C80 66.663 73.436 72 62.543 72H44a2 2 0 01-2-2V24a2 2 0 012-2h18.437c9.083 0 15.044 4.92 15.044 12.474 0 5.302-4.01 10.049-9.119 10.88v.277C75.317 46.394 80 51.21 80 57.863zM60.521 28.34H49.948v14.934h8.905c6.884 0 10.68-2.772 10.68-7.727 0-4.643-3.264-7.207-9.012-7.207zM49.948 49.2v16.458H60.91c7.167 0 10.964-2.876 10.964-8.281 0-5.406-3.903-8.178-11.425-8.178H49.948z"></path></symbol>
</svg><div class="d-flex flex-column align-items-stretch flex-shrink-0 bg-white" style="width: 380px;"><a href="/" class="d-flex align-items-center flex-shrink-0 p-3 link-dark text-decoration-none border-bottom"><svg class="bi me-2" width="30" height="24"><use xlink:href="#bootstrap"/></svg><span class="fs-5 fw-semibold">列表組</span></a><div class="list-group list-group-flush border-bottom scrollarea"><a href="#" class="list-group-item list-group-item-action py-3 lh-tight" aria-current="true"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small>星期一</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a><a href="#" class="list-group-item list-group-item-action py-3 lh-tight"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small class="text-muted">星期二</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a><a href="#" class="list-group-item list-group-item-action py-3 lh-tight"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small class="text-muted">星期三</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a><a href="#" class="list-group-item list-group-item-action py-3 lh-tight" aria-current="true"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small class="text-muted">星期四</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a><a href="#" class="list-group-item list-group-item-action py-3 lh-tight"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small class="text-muted">星期五</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a><a href="#" class="list-group-item list-group-item-action py-3 lh-tight"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small class="text-muted">星期六</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a><a href="#" class="list-group-item list-group-item-action py-3 lh-tight" aria-current="true"><div class="d-flex w-100 align-items-center justify-content-between"><strong class="mb-1">表項(xiàng)標(biāo)題</strong><small class="text-muted">星期日</small></div><div class="col-10 mb-1 small">內(nèi)容信息...</div></a></div>
</div>
</body>
</html>

GIF 2023-10-5 13-16-25

http://www.risenshineclean.com/news/44494.html

相關(guān)文章:

  • 怎么做根優(yōu)酷差不多的網(wǎng)站濟(jì)南網(wǎng)絡(luò)推廣
  • 免費(fèi)手機(jī)網(wǎng)站制作鄭州建網(wǎng)站的公司
  • asp 網(wǎng)站源代碼電商平臺(tái)有哪些
  • 個(gè)人網(wǎng)站主頁(yè)模板黃桃圖片友情鏈接
  • 房地產(chǎn)公司 網(wǎng)站建設(shè)數(shù)據(jù)分析師要學(xué)什么
  • 珠海 網(wǎng)站建設(shè)深圳網(wǎng)絡(luò)營(yíng)銷(xiāo)推廣公司
  • 上海自適應(yīng)網(wǎng)站建設(shè)今日武漢最新消息
  • 成都專業(yè)網(wǎng)站建設(shè)優(yōu)化團(tuán)隊(duì)博為峰軟件測(cè)試培訓(xùn)學(xué)費(fèi)
  • 江西省政府辦公廳網(wǎng)站作風(fēng)建設(shè)網(wǎng)絡(luò)營(yíng)銷(xiāo)的方式和手段
  • 做一些網(wǎng)站犯法么個(gè)人網(wǎng)站設(shè)計(jì)作品
  • 建設(shè)工程服務(wù)平臺(tái)揚(yáng)州seo
  • 有沒(méi)有網(wǎng)站是免費(fèi)做店招圖片的5118關(guān)鍵詞工具
  • 溫州本地網(wǎng)站個(gè)人博客網(wǎng)頁(yè)制作
  • 如果只做p2p種子搜索網(wǎng)站今日小說(shuō)搜索風(fēng)云榜
  • 做網(wǎng)站買(mǎi)域名就行了嗎網(wǎng)址之家
  • wordpress安裝路徑和站點(diǎn)地址的設(shè)置廣州seo公司排名
  • 廣告型網(wǎng)站怎么做站長(zhǎng)工具網(wǎng)址查詢
  • 怎么在一起做網(wǎng)站上拿貨開(kāi)網(wǎng)站需要什么流程
  • 八面通網(wǎng)站建設(shè)nba排名最新賽程
  • 做網(wǎng)站的好處seo外鏈增加
  • 深圳做網(wǎng)站那家好正規(guī)網(wǎng)站建設(shè)服務(wù)
  • 協(xié)會(huì)網(wǎng)站制作百度網(wǎng)盤(pán)app官方下載
  • 太原網(wǎng)站推廣服務(wù)seo推廣seo技術(shù)培訓(xùn)
  • wordpress 騰訊云成都外貿(mào)seo
  • 網(wǎng)站建設(shè)公司起名百度廣告聯(lián)盟怎么賺錢(qián)
  • 聊城做網(wǎng)站最好的網(wǎng)絡(luò)公司哪里有永久免費(fèi)建站
  • 網(wǎng)站建設(shè)進(jìn)什么分錄百度賬號(hào)一鍵登錄
  • 政府網(wǎng)站建設(shè)意見(jiàn)權(quán)威發(fā)布
  • 深圳高端網(wǎng)站制作公司線上推廣如何引流
  • 網(wǎng)站制作建設(shè)怎么收費(fèi)百度問(wèn)一問(wèn)付費(fèi)咨詢