Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bootstrap
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
bootstrap
Commits
0c2055ef
Commit
0c2055ef
authored
Oct 16, 2013
by
Aaron Borden
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding contextual styles to list-items
parent
3e9e339e
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
73 additions
and
2 deletions
+73
-2
components.html
components.html
+21
-0
dist/css/bootstrap.css
dist/css/bootstrap.css
+30
-0
dist/css/bootstrap.min.css
dist/css/bootstrap.min.css
+1
-1
docs-assets/js/raw-files.js
docs-assets/js/raw-files.js
+1
-1
less/list-group.less
less/list-group.less
+5
-0
less/mixins.less
less/mixins.less
+15
-0
No files found.
components.html
View file @
0c2055ef
...
...
@@ -3325,6 +3325,27 @@ 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 color list items.
</p>
<div
class=
"bs-example"
>
<div
class=
"list-group"
>
<a
href=
"#"
class=
"list-group-item"
>
Cras justo odio
</a>
<a
href=
"#"
class=
"list-group-item success"
>
Dapibus ac facilisis in
</a>
<a
href=
"#"
class=
"list-group-item"
>
Morbi leo risus
</a>
<a
href=
"#"
class=
"list-group-item warning"
>
Porta ac consectetur ac
</a>
<a
href=
"#"
class=
"list-group-item danger"
>
Vestibulum at eros
</a>
</div>
</div>
{% highlight html %}
<div
class=
"list-group"
>
<a
href=
"#"
class=
"list-group-item"
>
Cras justo odio
</a>
<a
href=
"#"
class=
"list-group-item success"
>
Dapibus ac facilisis in
</a>
<a
href=
"#"
class=
"list-group-item"
>
Morbi leo risus
</a>
<a
href=
"#"
class=
"list-group-item warning"
>
Porta ac consectetur ac
</a>
<a
href=
"#"
class=
"list-group-item danger"
>
Vestibulum at eros
</a>
</div>
{% endhighlight %}
<h3
id=
"list-group-custom-content"
>
Custom content
</h3>
...
...
dist/css/bootstrap.css
View file @
0c2055ef
...
...
@@ -5511,6 +5511,36 @@ a.thumbnail.active {
margin-right
:
5px
;
}
.list-group
>
.list-group-item.success
{
background-color
:
#dff0d8
;
border-color
:
#d6e9c6
;
}
.list-group
>
.list-group-item.success
:hover
{
background-color
:
#d0e9c6
;
border-color
:
#c9e2b3
;
}
.list-group
>
.list-group-item.danger
{
background-color
:
#f2dede
;
border-color
:
#ebccd1
;
}
.list-group
>
.list-group-item.danger
:hover
{
background-color
:
#ebcccc
;
border-color
:
#e4b9c0
;
}
.list-group
>
.list-group-item.warning
{
background-color
:
#fcf8e3
;
border-color
:
#faebcc
;
}
.list-group
>
.list-group-item.warning
:hover
{
background-color
:
#faf2cc
;
border-color
:
#f7e1b5
;
}
a
.list-group-item
{
color
:
#555555
;
}
...
...
dist/css/bootstrap.min.css
View file @
0c2055ef
This source diff could not be displayed because it is too large. You can
view the blob
instead.
docs-assets/js/raw-files.js
View file @
0c2055ef
This diff is collapsed.
Click to expand it.
less/list-group.less
View file @
0c2055ef
...
...
@@ -41,6 +41,11 @@
}
}
// Contextual variants
.list-group-item-variant(success; @state-success-bg; @state-success-border);
.list-group-item-variant(danger; @state-danger-bg; @state-danger-border);
.list-group-item-variant(warning; @state-warning-bg; @state-warning-border);
// Linked list items
a.list-group-item {
color: @list-group-link-color;
...
...
less/mixins.less
View file @
0c2055ef
...
...
@@ -448,6 +448,21 @@
}
}
// List Groups
// -------------------------
.list-group-item-variant(@state; @background; @border) {
.list-group > .list-group-item.@{state} {
background-color: @background;
border-color: @border;
}
// Hover states
.list-group > .list-group-item.@{state}:hover {
background-color: darken(@background, 5%);
border-color: darken(@border, 5%);
}
}
// Button variants
// -------------------------
// Easily pump out default styles, as well as :hover, :focus, :active,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment