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
27ff51da
Commit
27ff51da
authored
Jan 18, 2013
by
Vickash Mahabir
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix that thing with disabled buttons changing color on hover
parent
f068cdeb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
39 deletions
+20
-39
less/buttons.less
less/buttons.less
+20
-39
No files found.
less/buttons.less
View file @
27ff51da
...
...
@@ -109,7 +109,18 @@ input[type="button"] {
}
}
// Mixin for darkening only enabled buttons for link states
.darken-button-states (@background, @border) {
&:not([disabled]):not(.disabled),
fieldset:not([disabled]) & {
&:hover,
&:focus,
&:active {
background-color: darken(@background, 5%);
border-color: darken(@border, 10%);
}
}
}
// Alternate buttons
// --------------------------------------------------
...
...
@@ -117,67 +128,37 @@ input[type="button"] {
.btn {
color: #fff;
background-color: @btn-background;
border-color: @btn-border;
&:hover,
&:focus,
&:active {
background-color: darken(@btn-background, 5%);
border-color: darken(@btn-border, 10%);
}
border-color: @btn-border;
.darken-button-states(@btn-background, @btn-border)
}
.btn-primary {
background-color: @btn-background-primary;
border-color: @btn-border-primary;
&:hover,
&:focus,
&:active {
background-color: darken(@btn-background-primary, 5%);
border-color: darken(@btn-border-primary, 10%);
}
.darken-button-states(@btn-background-primary, @btn-border-primary)
}
// Warning appears a
re
orange
// Warning appears a
s
orange
.btn-warning {
background-color: @btn-background-warning;
border-color: @btn-border-warning;
&:hover,
&:focus,
&:active {
background-color: darken(@btn-background-warning, 5%);
border-color: darken(@btn-border-warning, 10%);
}
.darken-button-states(@btn-background-warning, @btn-border-warning)
}
// Danger and error appear as red
.btn-danger {
background-color: @btn-background-danger;
border-color: @btn-border-danger;
&:hover,
&:focus,
&:active {
background-color: darken(@btn-background-danger, 5%);
border-color: darken(@btn-border-danger, 10%);
}
.darken-button-states(@btn-background-danger, @btn-border-danger)
}
// Success appears as green
.btn-success {
background-color: @btn-background-success;
border-color: @btn-border-success;
&:hover,
&:focus,
&:active {
background-color: darken(@btn-background-success, 5%);
border-color: darken(@btn-border-success, 10%);
}
.darken-button-states(@btn-background-success, @btn-border-success)
}
// Info appears as blue-green
.btn-info {
background-color: @btn-background-info;
border-color: @btn-border-info;
&:hover,
&:focus,
&:active {
background-color: darken(@btn-background-info, 5%);
border-color: darken(@btn-border-info, 10%);
}
.darken-button-states(@btn-background-info, @btn-border-info)
}
...
...
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