mirror of
https://github.com/twbs/bootstrap.git
synced 2024-12-01 13:24:25 +01:00
Merge branch 'pr/11138'
Conflicts: dist/css/bootstrap.min.css dist/js/bootstrap.min.js docs-assets/js/raw-files.js
This commit is contained in:
commit
a9b86cbfde
@ -121,6 +121,7 @@
|
||||
<li><a href="#list-group-basic">Basic example</a></li>
|
||||
<li><a href="#list-group-badges">Badges</a></li>
|
||||
<li><a href="#list-group-linked">Linked items</a></li>
|
||||
<li><a href="#list-group-contextual-classes">Contextual classes</a></li>
|
||||
<li><a href="#list-group-custom-content">Custom content</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
@ -3354,6 +3354,43 @@ body { padding-bottom: 70px; }
|
||||
<a href="#" class="list-group-item">Porta ac consectetur ac</a>
|
||||
<a href="#" class="list-group-item">Vestibulum at eros</a>
|
||||
</div>
|
||||
{% endhighlight %}
|
||||
|
||||
<h3 id="list-group-contextual-classes">Contextual classes</h3>
|
||||
<p>Use contextual classes to style list items, default or linked. Also includes <code>.active</code> state.</p>
|
||||
<div class="bs-example">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<ul class="list-group">
|
||||
<li class="list-group-item list-group-item-success">Dapibus ac facilisis in</li>
|
||||
<li class="list-group-item list-group-item-warning">Porta ac consectetur ac</li>
|
||||
<li class="list-group-item list-group-item-danger">Vestibulum at eros</li>
|
||||
<li class="list-group-item list-group-item-info">Cras sit amet nibh libero</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<div class="list-group">
|
||||
<a href="#" class="list-group-item list-group-item-success">Dapibus ac facilisis in</a>
|
||||
<a href="#" class="list-group-item list-group-item-warning">Porta ac consectetur ac</a>
|
||||
<a href="#" class="list-group-item list-group-item-danger">Vestibulum at eros</a>
|
||||
<a href="#" class="list-group-item list-group-item-info">Cras sit amet nibh libero</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% highlight html %}
|
||||
<ul class="list-group">
|
||||
<li class="list-group-item list-group-item-success">Dapibus ac facilisis in</li>
|
||||
<li class="list-group-item list-group-item-warning">Porta ac consectetur ac</li>
|
||||
<li class="list-group-item list-group-item-danger">Vestibulum at eros</li>
|
||||
<li class="list-group-item list-group-item-info">Cras sit amet nibh libero</li>
|
||||
</ul>
|
||||
<div class="list-group">
|
||||
<a href="#" class="list-group-item list-group-item-success">Dapibus ac facilisis in</a>
|
||||
<a href="#" class="list-group-item list-group-item-warning">Porta ac consectetur ac</a>
|
||||
<a href="#" class="list-group-item list-group-item-danger">Vestibulum at eros</a>
|
||||
<a href="#" class="list-group-item list-group-item-info">Cras sit amet nibh libero</a>
|
||||
</div>
|
||||
{% endhighlight %}
|
||||
|
||||
<h3 id="list-group-custom-content">Custom content</h3>
|
||||
|
108
dist/css/bootstrap.css
vendored
108
dist/css/bootstrap.css
vendored
@ -5612,6 +5612,114 @@ a.list-group-item.active:focus .list-group-item-text {
|
||||
color: #e1edf7;
|
||||
}
|
||||
|
||||
.list-group-item-success {
|
||||
color: #3c763d;
|
||||
background-color: #dff0d8;
|
||||
}
|
||||
|
||||
a.list-group-item-success {
|
||||
color: #3c763d;
|
||||
}
|
||||
|
||||
a.list-group-item-success .list-group-item-heading {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
a.list-group-item-success:hover,
|
||||
a.list-group-item-success:focus {
|
||||
color: #3c763d;
|
||||
background-color: #d0e9c6;
|
||||
}
|
||||
|
||||
a.list-group-item-success.active,
|
||||
a.list-group-item-success.active:hover,
|
||||
a.list-group-item-success.active:focus {
|
||||
color: #fff;
|
||||
background-color: #3c763d;
|
||||
border-color: #3c763d;
|
||||
}
|
||||
|
||||
.list-group-item-warning {
|
||||
color: #8a6d3b;
|
||||
background-color: #fcf8e3;
|
||||
}
|
||||
|
||||
a.list-group-item-warning {
|
||||
color: #8a6d3b;
|
||||
}
|
||||
|
||||
a.list-group-item-warning .list-group-item-heading {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
a.list-group-item-warning:hover,
|
||||
a.list-group-item-warning:focus {
|
||||
color: #8a6d3b;
|
||||
background-color: #faf2cc;
|
||||
}
|
||||
|
||||
a.list-group-item-warning.active,
|
||||
a.list-group-item-warning.active:hover,
|
||||
a.list-group-item-warning.active:focus {
|
||||
color: #fff;
|
||||
background-color: #8a6d3b;
|
||||
border-color: #8a6d3b;
|
||||
}
|
||||
|
||||
.list-group-item-danger {
|
||||
color: #a94442;
|
||||
background-color: #f2dede;
|
||||
}
|
||||
|
||||
a.list-group-item-danger {
|
||||
color: #a94442;
|
||||
}
|
||||
|
||||
a.list-group-item-danger .list-group-item-heading {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
a.list-group-item-danger:hover,
|
||||
a.list-group-item-danger:focus {
|
||||
color: #a94442;
|
||||
background-color: #ebcccc;
|
||||
}
|
||||
|
||||
a.list-group-item-danger.active,
|
||||
a.list-group-item-danger.active:hover,
|
||||
a.list-group-item-danger.active:focus {
|
||||
color: #fff;
|
||||
background-color: #a94442;
|
||||
border-color: #a94442;
|
||||
}
|
||||
|
||||
.list-group-item-info {
|
||||
color: #31708f;
|
||||
background-color: #d9edf7;
|
||||
}
|
||||
|
||||
a.list-group-item-info {
|
||||
color: #31708f;
|
||||
}
|
||||
|
||||
a.list-group-item-info .list-group-item-heading {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
a.list-group-item-info:hover,
|
||||
a.list-group-item-info:focus {
|
||||
color: #31708f;
|
||||
background-color: #c4e3f3;
|
||||
}
|
||||
|
||||
a.list-group-item-info.active,
|
||||
a.list-group-item-info.active:hover,
|
||||
a.list-group-item-info.active:focus {
|
||||
color: #fff;
|
||||
background-color: #31708f;
|
||||
border-color: #31708f;
|
||||
}
|
||||
|
||||
.list-group-item-heading {
|
||||
margin-top: 0;
|
||||
margin-bottom: 5px;
|
||||
|
2
dist/css/bootstrap.min.css
vendored
2
dist/css/bootstrap.min.css
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -2,17 +2,21 @@
|
||||
// List groups
|
||||
// --------------------------------------------------
|
||||
|
||||
|
||||
// Base class
|
||||
//
|
||||
// Easily usable on <ul>, <ol>, or <div>.
|
||||
|
||||
.list-group {
|
||||
// No need to set list-style: none; since .list-group-item is block level
|
||||
margin-bottom: 20px;
|
||||
padding-left: 0; // reset padding because ul and ol
|
||||
}
|
||||
|
||||
|
||||
// Individual list items
|
||||
// -------------------------
|
||||
//
|
||||
// Use on `li`s or `div`s within the `.list-group` parent.
|
||||
|
||||
.list-group-item {
|
||||
position: relative;
|
||||
@ -41,7 +45,12 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Linked list items
|
||||
//
|
||||
// Use anchor elements instead of `li`s or `div`s to create linked list items.
|
||||
// Includes an extra `.active` modifier class for showing selected items.
|
||||
|
||||
a.list-group-item {
|
||||
color: @list-group-link-color;
|
||||
|
||||
@ -75,8 +84,21 @@ a.list-group-item {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Contextual variants
|
||||
//
|
||||
// Add modifier classes to change text and background color on individual items.
|
||||
// Organizationally, this must come after the `:hover` states.
|
||||
|
||||
.list-group-item-variant(success; @state-success-bg; @state-success-text);
|
||||
.list-group-item-variant(warning; @state-warning-bg; @state-warning-text);
|
||||
.list-group-item-variant(danger; @state-danger-bg; @state-danger-text);
|
||||
.list-group-item-variant(info; @state-info-bg; @state-info-text);
|
||||
|
||||
|
||||
// Custom content options
|
||||
// -------------------------
|
||||
//
|
||||
// Extra classes for creating well-formatted content within `.list-group-item`s.
|
||||
|
||||
.list-group-item-heading {
|
||||
margin-top: 0;
|
||||
|
@ -437,6 +437,33 @@
|
||||
}
|
||||
}
|
||||
|
||||
// List Groups
|
||||
// -------------------------
|
||||
.list-group-item-variant(@state; @background; @color) {
|
||||
.list-group-item-@{state} {
|
||||
color: @color;
|
||||
background-color: @background;
|
||||
}
|
||||
a.list-group-item-@{state} {
|
||||
color: @color;
|
||||
|
||||
.list-group-item-heading { color: inherit; }
|
||||
|
||||
&:hover,
|
||||
&:focus {
|
||||
color: @color;
|
||||
background-color: darken(@background, 5%);
|
||||
}
|
||||
&.active,
|
||||
&.active:hover,
|
||||
&.active:focus {
|
||||
color: #fff;
|
||||
background-color: @color;
|
||||
border-color: @color;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Button variants
|
||||
// -------------------------
|
||||
// Easily pump out default styles, as well as :hover, :focus, :active,
|
||||
|
Loading…
Reference in New Issue
Block a user