精品久久久久久亚洲精品_成人午夜网站_www日本高清_亚洲精品久久久久午夜福

表格(Tables)

Bootstrap設置表格文件和示例(提供表格在JavaScript插件程序中的用途)

概述

由于<table>橫跨其他第三方套件廣泛的使用,像是calendars和date pickers,因此可選擇使用Bootstrap的表格。在任何<table>加上基本類別 .table,接著使用我們的可選修飾類別或是自定義樣式進行擴展。所有表格樣式在Bootstrap中都不會繼承,意味著嵌套表格的樣式都是獨立于父表格。

使用最基本的表格排版,以下是基本的.table在Bootstrap中的外觀。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table">
<thead>
<tr>
<th scope="col">#</th>
<th scope="col">First</th>
<th scope="col">Last</th>
<th scope="col">Handle</th>
</tr>
</thead>
<tbody>
<tr>
<th scope="row">1</th>
<td>Mark</td>
<td>Otto</td>
<td>@mdo</td>
</tr>
<tr>
<th scope="row">2</th>
<td>Jacob</td>
<td>Thornton</td>
<td>@fat</td>
</tr>
<tr>
<th scope="row">3</th>
<td colspan="2">Larry the Bird</td>
<td>@twitter</td>
</tr>
</tbody>
</table>

變量

使用語意化class給表格列或單元格上色。

Class Heading Heading
Default Cell Cell
Primary Cell Cell
Secondary Cell Cell
Success Cell Cell
Danger Cell Cell
Warning Cell Cell
Info Cell Cell
Light Cell Cell
Dark Cell Cell
<!-- On tables -->
<table class="table-primary">...</table>
<table class="table-secondary">...</table>
<table class="table-success">...</table>
<table class="table-danger">...</table>
<table class="table-warning">...</table>
<table class="table-info">...</table>
<table class="table-light">...</table>
<table class="table-dark">...</table>

<!-- On rows -->
<tr class="table-primary">...</tr>
<tr class="table-secondary">...</tr>
<tr class="table-success">...</tr>
<tr class="table-danger">...</tr>
<tr class="table-warning">...</tr>
<tr class="table-info">...</tr>
<tr class="table-light">...</tr>
<tr class="table-dark">...</tr>

<!-- On cells (`td` or `th`) -->
<tr>
<td class="table-primary">...</td>
<td class="table-secondary">...</td>
<td class="table-success">...</td>
<td class="table-danger">...</td>
<td class="table-warning">...</td>
<td class="table-info">...</td>
<td class="table-light">...</td>
<td class="table-dark">...</td>
</tr>
向輔助技術傳達意義

使用顏色來增加意義只會提供一種視覺指示,而不會傳達給輔助技術(如屏幕閱讀器)的用戶。確保由顏色表示的信息在內容本身(例如可見文本)中是明顯的,或者通過其他方式包含,例如使用.visually hidden類隱藏的其他文本。

強調表格

條紋行

使用.table-striped在<tbody>范圍內任何表格行增加條紋樣式。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-striped">
...
</table>

這些類也可以添加到表變量中:

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-dark table-striped">
...
</table>
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-success table-striped">
...
</table>

可懸停行

Add.table hover可對<tbody>中的表行啟用懸停狀態。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-hover">
...
</table>
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-dark table-hover">
...
</table>

這些可懸停的行還可以與條帶化變量組合使用:

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-striped table-hover">
...
</table>

激活表

通過添加.table-active高亮顯示表行或單元格。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table">
<thead>
...
</thead>
<tbody>
<tr class="table-active">
...
</tr>
<tr>
...
</tr>
<tr>
<th scope="row">3</th>
<td colspan="2" class="table-active">Larry the Bird</td>
<td>@twitter</td>
</tr>
</tbody>
</table>
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-dark">
<thead>
...
</thead>
<tbody>
<tr class="table-active">
...
</tr>
<tr>
...
</tr>
<tr>
<th scope="row">3</th>
<td colspan="2" class="table-active">Larry the Bird</td>
<td>@twitter</td>
</tr>
</tbody>
</table>

變量和表格強調如何運作?

對于表格強調(條紋行,可懸停行,以及活動表格),我們使用了一些技巧來使這些效果適用于所有變數:

  • 我們首先使用--bs-table-bg屬性設定單元格的背景。所有變數都加上該自定義屬性使單元格有色彩。如此若將半透明的顏色用作表格背景,我們就??不會遇到麻煩。
  • 然后,我們在單元格上使用background-image: linear-gradient(var(--bs-table-accent-bg),var(--bs-table-accent-bg));增加漸變,在指定的上層使用background-color。由于--bs-table-accent-bg預設是透明的,因此預設就具有不可見的透明線性漸變。
  • 當加上任一.table-striped、.table-hover或是.table-active樣式,--bs-table-accent-bg被設定為半透明背景色。
  • 我們創造了--bs-table-accent-bg變數具有最高對比度的顏色。例如,.table-primary的強調色會更深,而.table-dark強調色較淺。
  • 文字和框線色彩生成方式相同,預設情形下會繼承其顏色。

在幕后看起來像這樣:

@mixin table-variant($state, $background) {
.table-#{$state} {
$color: color-contrast(opaque($body-bg, $background));
$hover-bg: mix($color, $background, percentage($table-hover-bg-factor));
$striped-bg: mix($color, $background, percentage($table-striped-bg-factor));
$active-bg: mix($color, $background, percentage($table-active-bg-factor));

--#{$variable-prefix}table-bg: #{$background};
--#{$variable-prefix}table-striped-bg: #{$striped-bg};
--#{$variable-prefix}table-striped-color: #{color-contrast($striped-bg)};
--#{$variable-prefix}table-active-bg: #{$active-bg};
--#{$variable-prefix}table-active-color: #{color-contrast($active-bg)};
--#{$variable-prefix}table-hover-bg: #{$hover-bg};
--#{$variable-prefix}table-hover-color: #{color-contrast($hover-bg)};

color: $color;
border-color: mix($color, $background, percentage($table-border-factor));
}
}

表格邊框

帶框的表格

.table-bordered 為表格和單元格的所有邊添加邊框。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-bordered">
...
</table>

可以添加邊框顏色實用程序 來更改顏色:

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-bordered border-primary">
...
</table>

無框的表格

使用.table-borderless使表格呈現無外部邊框。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-borderless">
...
</table>
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-dark table-borderless">
...
</table>

小表格

添加.table-sm將所有單元格填充減半,使任何.table更加緊湊。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-sm">
...
</table>
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-dark table-sm">
...
</table>

垂直對齊

<thead> 的表格單元格始終垂直對齊到底部。<tbody>中的表單元格繼承<table>對齊方式,默認情況下將其對齊到頂部。在需要時可以使用垂直對齊類重新對齊。

Heading 1 Heading 2 Heading 3 Heading 4
This cell inherits vertical-align: middle; from the table This cell inherits vertical-align: middle; from the table This cell inherits vertical-align: middle; from the table This here is some placeholder text, intended to take up quite a bit of vertical space, to demonstrate how the vertical alignment works in the preceding cells.
This cell inherits vertical-align: bottom; from the table row This cell inherits vertical-align: bottom; from the table row This cell inherits vertical-align: bottom; from the table row This here is some placeholder text, intended to take up quite a bit of vertical space, to demonstrate how the vertical alignment works in the preceding cells.
This cell inherits vertical-align: middle; from the table This cell inherits vertical-align: middle; from the table This cell is aligned to the top. This here is some placeholder text, intended to take up quite a bit of vertical space, to demonstrate how the vertical alignment works in the preceding cells.
<table class="table table-sm table-dark">
<div class="table-responsive">
<table class="table align-middle">
<thead>
  <tr>
    ...
  </tr>
</thead>
<tbody>
  <tr>
    ...
  </tr>
  <tr class="align-bottom">
    ...
  </tr>
  <tr>
    <td>...</td>
    <td>...</td>
    <td class="align-top">This cell is aligned to the top.</td>
    <td>...</td>
  </tr>
</tbody>
</table>
</div>
</table>

嵌套

嵌套表不會繼承邊框樣式、活動樣式和表變量。

# First Last Handle
1 Mark Otto @mdo
Header Header Header
A First Last
B First Last
C First Last
3 Larry the Bird @twitter
<table class="table table-striped">
<thead>
...
</thead>
<tbody>
...
<tr>
<td colspan="4">
  <table class="table mb-0">
    ...
  </table>
</td>
</tr>
...
</tbody>
</table>

嵌套原理

為了防止任何樣式泄漏到嵌套表中,我們在CSS中使用子組合符(>)選擇器。由于我們需要針對thead、tbody和tfoot中的所有tds和th,沒有它,我們的選擇器看起來會很長。因此,我們使用外觀非常奇怪的.table > :not(caption) > * > * 選擇器來定位.table的所有tds和TH,但沒有任何潛在的嵌套表。

結構

表頭

與表格和深色表格類似,請使用修改器類。.table-light.table-dark 使<thead>顯示為淺灰色或深灰色。

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table">
<thead class="table-light">
...
</thead>
<tbody>
...
</tbody>
</table>
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table">
<thead class="table-dark">
...
</thead>
<tbody>
...
</tbody>
</table>

表尾

# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
Footer Footer Footer Footer
<table class="table">
<thead>
...
</thead>
<tbody>
...
</tbody>
<tfoot>
...
</tfoot>
</table>

表格標題

<caption> 的功能類似于表格的標題。它幫助屏幕閱讀器的用戶找到一個表,了解它的內容,并決定他們是否要閱讀它。

List of users
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table table-sm">
<caption>List of users</caption>
<thead>
...
</thead>
<tbody>
...
</tbody>
</table>

您還可以使用.caption-top<caption>放在表的頂部。

List of users
# First Last Handle
1 Mark Otto @mdo
2 Jacob Thornton @fat
3 Larry the Bird @twitter
<table class="table caption-top">
<caption>List of users</caption>
<thead>
<tr>
<th scope="col">#</th>
<th scope="col">First</th>
<th scope="col">Last</th>
<th scope="col">Handle</th>
</tr>
</thead>
<tbody>
<tr>
<th scope="row">1</th>
<td>Mark</td>
<td>Otto</td>
<td>@mdo</td>
</tr>
<tr>
<th scope="row">2</th>
<td>Jacob</td>
<td>Thornton</td>
<td>@fat</td>
</tr>
<tr>
<th scope="row">3</th>
<td>Larry</td>
<td>the Bird</td>
<td>@twitter</td>
</tr>
</tbody>
</table>

響應式表格

響應式表格呈現水平滾動,可以使用.table-responsive包覆.table讓任何響應式表格跨裝置使用。或者.table中加入.table-responsive{-sm|-md|-lg|-xl|-xxl}創建響應式表格的最大斷點。

垂直剪裁/縮減

響應式表格將超過表格底部或頂部邊緣透過overflow-y: hidden將內容剪裁掉。具體而言,這會裁掉下拉式功能表和其他第三方的插件程序。

始終響應

.table-responsive 可讓表格水平滾動來跨斷點使用。

# Heading Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell Cell
<div class="table-responsive">
<table class="table">
...
</table>
</div>

特定斷點

根據需要的響應式表格設定.table-responsive{-sm|-md|-lg|-xl|-xxl}。從該斷點開始,表格將正常運行并且不會水平滾動。

這些表可能會顯示為斷開,直到它們的響應樣式應用于特定的視窗寬度。

# Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell
# Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell
# Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell
# Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell
# Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell
# Heading Heading Heading Heading Heading Heading Heading Heading
1 Cell Cell Cell Cell Cell Cell Cell Cell
2 Cell Cell Cell Cell Cell Cell Cell Cell
3 Cell Cell Cell Cell Cell Cell Cell Cell
<div class="table-responsive">
<table class="table">
...
</table>
</div>

<div class="table-responsive-sm">
<table class="table">
...
</table>
</div>

<div class="table-responsive-md">
<table class="table">
...
</table>
</div>

<div class="table-responsive-lg">
<table class="table">
...
</table>
</div>

<div class="table-responsive-xl">
<table class="table">
...
</table>
</div>

<div class="table-responsive-xxl">
<table class="table">
...
</table>
</div>

Sass

變量

$table-cell-padding-y:        .5rem;
$table-cell-padding-x:        .5rem;
$table-cell-padding-y-sm:     .25rem;
$table-cell-padding-x-sm:     .25rem;

$table-cell-vertical-align:   top;

$table-color:                 $body-color;
$table-bg:                    transparent;

$table-th-font-weight:        null;

$table-striped-color:         $table-color;
$table-striped-bg-factor:     .05;
$table-striped-bg:            rgba($black, $table-striped-bg-factor);

$table-active-color:          $table-color;
$table-active-bg-factor:      .1;
$table-active-bg:             rgba($black, $table-active-bg-factor);

$table-hover-color:           $table-color;
$table-hover-bg-factor:       .075;
$table-hover-bg:              rgba($black, $table-hover-bg-factor);

$table-border-factor:         .1;
$table-border-width:          $border-width;
$table-border-color:          $border-color;

$table-striped-order:         odd;

$table-group-separator-color: currentColor;

$table-caption-color:         $text-muted;

$table-bg-scale:              -80%;

循環

$table-variants: (
"primary":    shift-color($primary, $table-bg-scale),
"secondary":  shift-color($secondary, $table-bg-scale),
"success":    shift-color($success, $table-bg-scale),
"info":       shift-color($info, $table-bg-scale),
"warning":    shift-color($warning, $table-bg-scale),
"danger":     shift-color($danger, $table-bg-scale),
"light":      $light,
"dark":       $dark,
);

自定義

  • 因子變量 ($table-striped-bg-factor, $table-active-bg-factor & $table-hover-bg-factor) 用于確定表變量中的對比度。
  • 除了明表和暗表的變量,主題顏色由$table-bg-level變量變淺。
返回頂部
精品久久久久久亚洲精品_成人午夜网站_www日本高清_亚洲精品久久久久午夜福

      9000px;">

          欧美日韩国产精选| 在线免费一区三区| 美女www一区二区| 亚洲国产三级在线| 一区二区在线观看不卡| 日韩美女视频19| 亚洲欧美中日韩| 综合色中文字幕| 欧美国产日本韩| 中文字幕乱码久久午夜不卡| 国产欧美日韩卡一| 国产精品美女久久久久av爽李琼| 久久久久亚洲蜜桃| 中文字幕精品—区二区四季| 国产精品理伦片| 亚洲女同一区二区| 亚洲国产成人高清精品| 美女一区二区在线观看| 国产大片一区二区| 99久久婷婷国产| 欧美午夜片在线看| 日韩视频免费观看高清在线视频| 欧美成人一区二区| 久久久www成人免费无遮挡大片| 欧美国产日本韩| 亚洲欧美另类小说视频| 日本午夜一区二区| 国产精品一级二级三级| 91玉足脚交白嫩脚丫在线播放| 91豆麻精品91久久久久久| 在线不卡一区二区| 中文字幕欧美日韩一区| 依依成人精品视频| 精品综合久久久久久8888| 成人国产免费视频| 欧美日韩国产综合视频在线观看 | 日韩视频一区二区三区在线播放| 精品不卡在线视频| 亚洲免费观看高清完整版在线观看 | av欧美精品.com| 欧美肥妇bbw| 国产精品三级久久久久三级| 一区二区理论电影在线观看| 久久99九九99精品| 欧美综合欧美视频| 亚洲国产精品国自产拍av| 日韩在线观看一区二区| 99在线精品观看| 精品盗摄一区二区三区| 亚洲黄色录像片| 国产老妇另类xxxxx| 欧美日韩在线综合| 欧美国产精品一区| 久久精品99国产精品日本| 色吧成人激情小说| 日本一区二区三区在线不卡| 亚洲小少妇裸体bbw| 99久久精品国产一区二区三区| 日韩欧美你懂的| 亚洲国产成人高清精品| 99re亚洲国产精品| 国产欧美一区二区三区鸳鸯浴 | 国产精品免费视频一区| 久久er99精品| 欧美一区二区女人| 亚洲第一av色| 欧美午夜一区二区三区| 一区二区三区**美女毛片| 99久久国产综合色|国产精品| 久久日一线二线三线suv| 日韩高清电影一区| 欧美一级欧美一级在线播放| 亚洲v中文字幕| 欧美日韩一区视频| 亚洲成av人在线观看| 欧洲生活片亚洲生活在线观看| 中文字幕一区在线| 99久久精品国产精品久久| 国产精品不卡一区二区三区| 不卡av免费在线观看| 国产日产欧美一区| 成人激情电影免费在线观看| 国产精品妹子av| 99精品欧美一区二区蜜桃免费 | 欧美高清精品3d| 免费观看成人av| 精品国产第一区二区三区观看体验| 蜜桃av一区二区三区电影| 欧美一区二区在线看| 激情文学综合丁香| 中文一区二区在线观看| 91日韩一区二区三区| 性欧美疯狂xxxxbbbb| 久久在线免费观看| 成人精品免费网站| 亚洲一区二区三区四区的| 91精品国产色综合久久不卡电影| 精品一区二区三区在线播放| 国产日韩精品一区| 在线视频一区二区三| 日本美女一区二区三区| 欧美韩国日本不卡| 在线免费av一区| 乱一区二区av| 亚洲婷婷综合久久一本伊一区| 欧美日韩一区三区| 粗大黑人巨茎大战欧美成人| 伊人开心综合网| 久久蜜桃一区二区| 一本久久综合亚洲鲁鲁五月天| 日本最新不卡在线| 亚洲天堂免费在线观看视频| 欧美一卡2卡三卡4卡5免费| 国产91精品入口| 三级在线观看一区二区| 国产视频亚洲色图| 在线成人免费观看| 成人av电影免费在线播放| 免费日本视频一区| 亚洲天堂a在线| 久久综合久久综合久久| 欧美调教femdomvk| 成人av电影在线网| 久久成人综合网| 日日摸夜夜添夜夜添国产精品 | 国内精品伊人久久久久av一坑| 亚洲另类在线一区| 久久久久久亚洲综合| 欧美电影影音先锋| 色先锋资源久久综合| 国产精华液一区二区三区| 污片在线观看一区二区| 亚洲天堂精品视频| 国产精品久久毛片a| 久久免费看少妇高潮| 欧美电影在线免费观看| 欧美丝袜丝交足nylons图片| 99re在线精品| 99在线热播精品免费| 成人免费黄色大片| 国产成人在线网站| 国产麻豆精品在线观看| 理论电影国产精品| 肉色丝袜一区二区| 亚洲aⅴ怡春院| 亚洲午夜久久久久中文字幕久| 中文av一区特黄| 国产精品午夜在线| 欧美国产日本视频| 国产日韩欧美麻豆| 国产精品视频看| 国产精品久久久久久久久图文区 | 日韩精品一区国产麻豆| 8x8x8国产精品| 91精品免费在线| 欧美一二三四区在线| 欧美一区二区三区视频在线| 91精品欧美一区二区三区综合在| 欧美一区二区三区免费大片| 欧美一区二区三区免费| 精品国产一区二区三区忘忧草 | 国v精品久久久网| www.亚洲免费av| 91免费观看视频| 欧美日韩一卡二卡三卡| 欧美群妇大交群中文字幕| 日韩欧美在线网站| 欧美大片一区二区三区| 久久先锋影音av| 日韩理论片中文av| 亚洲福利视频三区| 久久精品国产999大香线蕉| 久99久精品视频免费观看| 国产精品888| 在线一区二区三区四区| 欧美放荡的少妇| 国产色一区二区| 一区二区不卡在线播放| 蜜臀av性久久久久蜜臀aⅴ| 国产在线播放一区| 91丨九色丨黑人外教| 欧美老肥妇做.爰bbww视频| 精品国产免费一区二区三区四区 | 91精选在线观看| 中文欧美字幕免费| 亚洲第一综合色| 国产成人综合网| 欧美日韩午夜精品| 欧美韩国日本一区| 日韩成人av影视| 99久久精品国产观看| 欧美一区二区三区免费| 亚洲精品乱码久久久久久日本蜜臀| 日韩成人免费电影| 91麻豆成人久久精品二区三区| 日韩精品专区在线影院重磅| 亚洲欧美国产三级| 国产麻豆一精品一av一免费| 欧美精品久久99久久在免费线| 国产精品剧情在线亚洲|