style-guide 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +11 -0
- data/.gitmodules +3 -0
- data/.pairs +11 -0
- data/.rvmrc +1 -0
- data/Gemfile +5 -0
- data/Gemfile.lock +144 -0
- data/Guardfile +14 -0
- data/LICENSE +7 -0
- data/README.md +7 -0
- data/Rakefile +27 -0
- data/app/assets/images/style_guide/.gitkeep +0 -0
- data/app/assets/images/style_guide/img/bird.png +0 -0
- data/app/assets/images/style_guide/img/bootstrap-mdo-sfmoma-01.jpg +0 -0
- data/app/assets/images/style_guide/img/bootstrap-mdo-sfmoma-02.jpg +0 -0
- data/app/assets/images/style_guide/img/bootstrap-mdo-sfmoma-03.jpg +0 -0
- data/app/assets/images/style_guide/img/browsers.png +0 -0
- data/app/assets/images/style_guide/img/bs-docs-bootstrap-features.png +0 -0
- data/app/assets/images/style_guide/img/bs-docs-masthead-pattern.png +0 -0
- data/app/assets/images/style_guide/img/bs-docs-responsive-illustrations.png +0 -0
- data/app/assets/images/style_guide/img/bs-docs-twitter-github.png +0 -0
- data/app/assets/images/style_guide/img/example-diagram-01.png +0 -0
- data/app/assets/images/style_guide/img/example-diagram-02.png +0 -0
- data/app/assets/images/style_guide/img/example-diagram-03.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/8020select.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/adoptahydrant.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/bartop.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/breakingnews.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/fleetio.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/gathercontent.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/jshint.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/kippt.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/railwayjs.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/soundready.png +0 -0
- data/app/assets/images/style_guide/img/example-sites/totalwireframe.png +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-carousel.png +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-fluid.jpg +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-hero.jpg +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-marketing-narrow.png +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-signin.png +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-starter.jpg +0 -0
- data/app/assets/images/style_guide/img/examples/bootstrap-example-sticky-footer.png +0 -0
- data/app/assets/images/style_guide/img/examples/browser-icon-chrome.png +0 -0
- data/app/assets/images/style_guide/img/examples/browser-icon-firefox.png +0 -0
- data/app/assets/images/style_guide/img/examples/browser-icon-safari.png +0 -0
- data/app/assets/images/style_guide/img/examples/slide-01.jpg +0 -0
- data/app/assets/images/style_guide/img/examples/slide-02.jpg +0 -0
- data/app/assets/images/style_guide/img/examples/slide-03.jpg +0 -0
- data/app/assets/images/style_guide/img/github-16px.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_009_magic.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_042_group.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_079_podium.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_082_roundabout.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_155_show_thumbnails.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_163_iphone.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_214_resize_small.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons/glyphicons_266_book_open.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons-halflings-white.png +0 -0
- data/app/assets/images/style_guide/img/glyphicons-halflings.png +0 -0
- data/app/assets/images/style_guide/img/grid-18px-masked.png +0 -0
- data/app/assets/images/style_guide/img/grid-baseline-20px.png +0 -0
- data/app/assets/images/style_guide/img/icon-css3.png +0 -0
- data/app/assets/images/style_guide/img/icon-github.png +0 -0
- data/app/assets/images/style_guide/img/icon-html5.png +0 -0
- data/app/assets/images/style_guide/img/icon-twitter.png +0 -0
- data/app/assets/images/style_guide/img/less-logo-large.png +0 -0
- data/app/assets/images/style_guide/img/less-small.png +0 -0
- data/app/assets/images/style_guide/img/responsive-illustrations.png +0 -0
- data/app/assets/javascripts/style_guide/application.js +13 -0
- data/app/assets/javascripts/style_guide/docs.js +154 -0
- data/app/assets/javascripts/style_guide/prettify.js +28 -0
- data/app/assets/stylesheets/style_guide/application.css +13 -0
- data/app/assets/stylesheets/style_guide/docs.css +1015 -0
- data/app/assets/stylesheets/style_guide/prettify.css +30 -0
- data/app/controllers/style_guide/application_controller.rb +4 -0
- data/app/controllers/style_guide/style_controller.rb +12 -0
- data/app/helpers/style_guide/application_helper.rb +4 -0
- data/app/views/layouts/style_guide/application.html.erb +44 -0
- data/app/views/style_guide/partials/_buttons.erb +167 -0
- data/app/views/style_guide/partials/_code.erb +31 -0
- data/app/views/style_guide/partials/_forms.erb +714 -0
- data/app/views/style_guide/partials/_images.erb +318 -0
- data/app/views/style_guide/partials/_tables.erb +409 -0
- data/app/views/style_guide/partials/_typography.erb +331 -0
- data/app/views/style_guide/style/index.html.erb +32 -0
- data/config/routes.rb +3 -0
- data/lib/style_guide/engine.rb +12 -0
- data/lib/style_guide/version.rb +3 -0
- data/lib/style_guide.rb +4 -0
- data/script/rails +8 -0
- data/spec/dummy/README.rdoc +261 -0
- data/spec/dummy/Rakefile +7 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_009_magic.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_042_group.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_079_podium.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_082_roundabout.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_155_show_thumbnails.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_163_iphone.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_214_resize_small.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons/glyphicons_266_book_open.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons-halflings-white.png +0 -0
- data/spec/dummy/app/assets/images/img/glyphicons-halflings.png +0 -0
- data/spec/dummy/app/assets/javascripts/application.js +27 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-affix.js +106 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-alert.js +88 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-button.js +94 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-carousel.js +176 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-collapse.js +156 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-dropdown.js +148 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-modal.js +234 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-popover.js +103 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-scrollspy.js +151 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-tab.js +133 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-tooltip.js +276 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-transition.js +60 -0
- data/spec/dummy/app/assets/javascripts/bootstrap-typeahead.js +310 -0
- data/spec/dummy/app/assets/javascripts/jquery.js +2 -0
- data/spec/dummy/app/assets/stylesheets/application.css +15 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/accordion.less +34 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/alerts.less +65 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/bootstrap.less +63 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/breadcrumbs.less +24 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/button-groups.less +242 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/buttons.less +232 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/carousel.less +131 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/close.less +31 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/code.less +58 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/component-animations.less +22 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/dropdowns.less +237 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/forms.less +683 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/grid.less +21 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/hero-unit.less +25 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/labels-badges.less +74 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/layouts.less +16 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/media.less +55 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/mixins.less +687 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/modals.less +94 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/navbar.less +475 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/navs.less +385 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/pager.less +41 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/pagination.less +121 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/popovers.less +117 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/progress-bars.less +122 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/reset.less +138 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/responsive-1200px-min.less +28 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/responsive-767px-max.less +193 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/responsive-768px-979px.less +19 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/responsive-navbar.less +185 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/responsive-utilities.less +43 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/responsive.less +48 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/scaffolding.less +52 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/sprites.less +193 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/tables.less +236 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/thumbnails.less +52 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/tooltip.less +70 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/type.less +227 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/utilities.less +30 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/variables.less +301 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap/wells.less +29 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap-responsive.css +1088 -0
- data/spec/dummy/app/assets/stylesheets/bootstrap.css +5893 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap/_colors.scss +10 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap/ars-maquette-web.css +35 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap/button.less +5 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap/layout.css.scss +11 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap/typography.css.scss +20 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap/variables.css.less +10 -0
- data/spec/dummy/app/assets/stylesheets/pivotal-bootstrap.css.less +3 -0
- data/spec/dummy/app/controllers/application_controller.rb +3 -0
- data/spec/dummy/app/controllers/home_controller.rb +3 -0
- data/spec/dummy/app/helpers/application_helper.rb +2 -0
- data/spec/dummy/app/mailers/.gitkeep +0 -0
- data/spec/dummy/app/models/.gitkeep +0 -0
- data/spec/dummy/app/views/home/index.html.erb +1 -0
- data/spec/dummy/app/views/layouts/application.html.erb +14 -0
- data/spec/dummy/app/views/styles/_info-header.erb +1 -0
- data/spec/dummy/config/application.rb +32 -0
- data/spec/dummy/config/boot.rb +10 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +30 -0
- data/spec/dummy/config/environments/production.rb +67 -0
- data/spec/dummy/config/environments/test.rb +34 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/inflections.rb +15 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/secret_token.rb +7 -0
- data/spec/dummy/config/initializers/session_store.rb +8 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +9 -0
- data/spec/dummy/config/locales/en.yml +5 -0
- data/spec/dummy/config/routes.rb +4 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/lib/assets/.gitkeep +0 -0
- data/spec/dummy/log/.gitkeep +0 -0
- data/spec/dummy/public/404.html +26 -0
- data/spec/dummy/public/422.html +26 -0
- data/spec/dummy/public/500.html +25 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_009_magic.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_042_group.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_079_podium.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_082_roundabout.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_155_show_thumbnails.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_163_iphone.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_214_resize_small.png +0 -0
- data/spec/dummy/public/img/glyphicons/glyphicons_266_book_open.png +0 -0
- data/spec/dummy/public/img/glyphicons-halflings-white.png +0 -0
- data/spec/dummy/public/img/glyphicons-halflings.png +0 -0
- data/spec/dummy/script/rails +6 -0
- data/style-guide.gemspec +26 -0
- metadata +500 -0
@@ -0,0 +1,63 @@
|
|
1
|
+
/*!
|
2
|
+
* Bootstrap v2.2.1
|
3
|
+
*
|
4
|
+
* Copyright 2012 Twitter, Inc
|
5
|
+
* Licensed under the Apache License v2.0
|
6
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
7
|
+
*
|
8
|
+
* Designed and built with all the love in the world @twitter by @mdo and @fat.
|
9
|
+
*/
|
10
|
+
|
11
|
+
// CSS Reset
|
12
|
+
@import "reset.less";
|
13
|
+
|
14
|
+
// Core variables and mixins
|
15
|
+
@import "variables.less"; // Modify this for custom colors, font-sizes, etc
|
16
|
+
@import "mixins.less";
|
17
|
+
|
18
|
+
// Grid system and page structure
|
19
|
+
@import "scaffolding.less";
|
20
|
+
@import "grid.less";
|
21
|
+
@import "layouts.less";
|
22
|
+
|
23
|
+
// Base CSS
|
24
|
+
@import "type.less";
|
25
|
+
@import "code.less";
|
26
|
+
@import "forms.less";
|
27
|
+
@import "tables.less";
|
28
|
+
|
29
|
+
// Components: common
|
30
|
+
@import "sprites.less";
|
31
|
+
@import "dropdowns.less";
|
32
|
+
@import "wells.less";
|
33
|
+
@import "component-animations.less";
|
34
|
+
@import "close.less";
|
35
|
+
|
36
|
+
// Components: Buttons & Alerts
|
37
|
+
@import "buttons.less";
|
38
|
+
@import "button-groups.less";
|
39
|
+
@import "alerts.less"; // Note: alerts share common CSS with buttons and thus have styles in buttons.less
|
40
|
+
|
41
|
+
// Components: Nav
|
42
|
+
@import "navs.less";
|
43
|
+
@import "navbar.less";
|
44
|
+
@import "breadcrumbs.less";
|
45
|
+
@import "pagination.less";
|
46
|
+
@import "pager.less";
|
47
|
+
|
48
|
+
// Components: Popovers
|
49
|
+
@import "modals.less";
|
50
|
+
@import "tooltip.less";
|
51
|
+
@import "popovers.less";
|
52
|
+
|
53
|
+
// Components: Misc
|
54
|
+
@import "thumbnails.less";
|
55
|
+
@import "media.less";
|
56
|
+
@import "labels-badges.less";
|
57
|
+
@import "progress-bars.less";
|
58
|
+
@import "accordion.less";
|
59
|
+
@import "carousel.less";
|
60
|
+
@import "hero-unit.less";
|
61
|
+
|
62
|
+
// Utility classes
|
63
|
+
@import "utilities.less"; // Has to be last to override when necessary
|
@@ -0,0 +1,24 @@
|
|
1
|
+
//
|
2
|
+
// Breadcrumbs
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
.breadcrumb {
|
7
|
+
padding: 8px 15px;
|
8
|
+
margin: 0 0 @baseLineHeight;
|
9
|
+
list-style: none;
|
10
|
+
background-color: #f5f5f5;
|
11
|
+
.border-radius(@baseBorderRadius);
|
12
|
+
li {
|
13
|
+
display: inline-block;
|
14
|
+
.ie7-inline-block();
|
15
|
+
text-shadow: 0 1px 0 @white;
|
16
|
+
}
|
17
|
+
.divider {
|
18
|
+
padding: 0 5px;
|
19
|
+
color: #ccc;
|
20
|
+
}
|
21
|
+
.active {
|
22
|
+
color: @grayLight;
|
23
|
+
}
|
24
|
+
}
|
@@ -0,0 +1,242 @@
|
|
1
|
+
//
|
2
|
+
// Button groups
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Make the div behave like a button
|
7
|
+
.btn-group {
|
8
|
+
position: relative;
|
9
|
+
display: inline-block;
|
10
|
+
.ie7-inline-block();
|
11
|
+
font-size: 0; // remove as part 1 of font-size inline-block hack
|
12
|
+
vertical-align: middle; // match .btn alignment given font-size hack above
|
13
|
+
white-space: nowrap; // prevent buttons from wrapping when in tight spaces (e.g., the table on the tests page)
|
14
|
+
.ie7-restore-left-whitespace();
|
15
|
+
}
|
16
|
+
|
17
|
+
// Space out series of button groups
|
18
|
+
.btn-group + .btn-group {
|
19
|
+
margin-left: 5px;
|
20
|
+
}
|
21
|
+
|
22
|
+
// Optional: Group multiple button groups together for a toolbar
|
23
|
+
.btn-toolbar {
|
24
|
+
font-size: 0; // Hack to remove whitespace that results from using inline-block
|
25
|
+
margin-top: @baseLineHeight / 2;
|
26
|
+
margin-bottom: @baseLineHeight / 2;
|
27
|
+
.btn + .btn,
|
28
|
+
.btn-group + .btn,
|
29
|
+
.btn + .btn-group {
|
30
|
+
margin-left: 5px;
|
31
|
+
}
|
32
|
+
}
|
33
|
+
|
34
|
+
// Float them, remove border radius, then re-add to first and last elements
|
35
|
+
.btn-group > .btn {
|
36
|
+
position: relative;
|
37
|
+
.border-radius(0);
|
38
|
+
}
|
39
|
+
.btn-group > .btn + .btn {
|
40
|
+
margin-left: -1px;
|
41
|
+
}
|
42
|
+
.btn-group > .btn,
|
43
|
+
.btn-group > .dropdown-menu {
|
44
|
+
font-size: @baseFontSize; // redeclare as part 2 of font-size inline-block hack
|
45
|
+
}
|
46
|
+
|
47
|
+
// Reset fonts for other sizes
|
48
|
+
.btn-group > .btn-mini {
|
49
|
+
font-size: 11px;
|
50
|
+
}
|
51
|
+
.btn-group > .btn-small {
|
52
|
+
font-size: 12px;
|
53
|
+
}
|
54
|
+
.btn-group > .btn-large {
|
55
|
+
font-size: 16px;
|
56
|
+
}
|
57
|
+
|
58
|
+
// Set corners individual because sometimes a single button can be in a .btn-group and we need :first-child and :last-child to both match
|
59
|
+
.btn-group > .btn:first-child {
|
60
|
+
margin-left: 0;
|
61
|
+
-webkit-border-top-left-radius: 4px;
|
62
|
+
-moz-border-radius-topleft: 4px;
|
63
|
+
border-top-left-radius: 4px;
|
64
|
+
-webkit-border-bottom-left-radius: 4px;
|
65
|
+
-moz-border-radius-bottomleft: 4px;
|
66
|
+
border-bottom-left-radius: 4px;
|
67
|
+
}
|
68
|
+
// Need .dropdown-toggle since :last-child doesn't apply given a .dropdown-menu immediately after it
|
69
|
+
.btn-group > .btn:last-child,
|
70
|
+
.btn-group > .dropdown-toggle {
|
71
|
+
-webkit-border-top-right-radius: 4px;
|
72
|
+
-moz-border-radius-topright: 4px;
|
73
|
+
border-top-right-radius: 4px;
|
74
|
+
-webkit-border-bottom-right-radius: 4px;
|
75
|
+
-moz-border-radius-bottomright: 4px;
|
76
|
+
border-bottom-right-radius: 4px;
|
77
|
+
}
|
78
|
+
// Reset corners for large buttons
|
79
|
+
.btn-group > .btn.large:first-child {
|
80
|
+
margin-left: 0;
|
81
|
+
-webkit-border-top-left-radius: 6px;
|
82
|
+
-moz-border-radius-topleft: 6px;
|
83
|
+
border-top-left-radius: 6px;
|
84
|
+
-webkit-border-bottom-left-radius: 6px;
|
85
|
+
-moz-border-radius-bottomleft: 6px;
|
86
|
+
border-bottom-left-radius: 6px;
|
87
|
+
}
|
88
|
+
.btn-group > .btn.large:last-child,
|
89
|
+
.btn-group > .large.dropdown-toggle {
|
90
|
+
-webkit-border-top-right-radius: 6px;
|
91
|
+
-moz-border-radius-topright: 6px;
|
92
|
+
border-top-right-radius: 6px;
|
93
|
+
-webkit-border-bottom-right-radius: 6px;
|
94
|
+
-moz-border-radius-bottomright: 6px;
|
95
|
+
border-bottom-right-radius: 6px;
|
96
|
+
}
|
97
|
+
|
98
|
+
// On hover/focus/active, bring the proper btn to front
|
99
|
+
.btn-group > .btn:hover,
|
100
|
+
.btn-group > .btn:focus,
|
101
|
+
.btn-group > .btn:active,
|
102
|
+
.btn-group > .btn.active {
|
103
|
+
z-index: 2;
|
104
|
+
}
|
105
|
+
|
106
|
+
// On active and open, don't show outline
|
107
|
+
.btn-group .dropdown-toggle:active,
|
108
|
+
.btn-group.open .dropdown-toggle {
|
109
|
+
outline: 0;
|
110
|
+
}
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
// Split button dropdowns
|
115
|
+
// ----------------------
|
116
|
+
|
117
|
+
// Give the line between buttons some depth
|
118
|
+
.btn-group > .btn + .dropdown-toggle {
|
119
|
+
padding-left: 8px;
|
120
|
+
padding-right: 8px;
|
121
|
+
.box-shadow(~"inset 1px 0 0 rgba(255,255,255,.125), inset 0 1px 0 rgba(255,255,255,.2), 0 1px 2px rgba(0,0,0,.05)");
|
122
|
+
*padding-top: 5px;
|
123
|
+
*padding-bottom: 5px;
|
124
|
+
}
|
125
|
+
.btn-group > .btn-mini + .dropdown-toggle {
|
126
|
+
padding-left: 5px;
|
127
|
+
padding-right: 5px;
|
128
|
+
*padding-top: 2px;
|
129
|
+
*padding-bottom: 2px;
|
130
|
+
}
|
131
|
+
.btn-group > .btn-small + .dropdown-toggle {
|
132
|
+
*padding-top: 5px;
|
133
|
+
*padding-bottom: 4px;
|
134
|
+
}
|
135
|
+
.btn-group > .btn-large + .dropdown-toggle {
|
136
|
+
padding-left: 12px;
|
137
|
+
padding-right: 12px;
|
138
|
+
*padding-top: 7px;
|
139
|
+
*padding-bottom: 7px;
|
140
|
+
}
|
141
|
+
|
142
|
+
.btn-group.open {
|
143
|
+
|
144
|
+
// The clickable button for toggling the menu
|
145
|
+
// Remove the gradient and set the same inset shadow as the :active state
|
146
|
+
.dropdown-toggle {
|
147
|
+
background-image: none;
|
148
|
+
.box-shadow(~"inset 0 2px 4px rgba(0,0,0,.15), 0 1px 2px rgba(0,0,0,.05)");
|
149
|
+
}
|
150
|
+
|
151
|
+
// Keep the hover's background when dropdown is open
|
152
|
+
.btn.dropdown-toggle {
|
153
|
+
background-color: @btnBackgroundHighlight;
|
154
|
+
}
|
155
|
+
.btn-primary.dropdown-toggle {
|
156
|
+
background-color: @btnPrimaryBackgroundHighlight;
|
157
|
+
}
|
158
|
+
.btn-warning.dropdown-toggle {
|
159
|
+
background-color: @btnWarningBackgroundHighlight;
|
160
|
+
}
|
161
|
+
.btn-danger.dropdown-toggle {
|
162
|
+
background-color: @btnDangerBackgroundHighlight;
|
163
|
+
}
|
164
|
+
.btn-success.dropdown-toggle {
|
165
|
+
background-color: @btnSuccessBackgroundHighlight;
|
166
|
+
}
|
167
|
+
.btn-info.dropdown-toggle {
|
168
|
+
background-color: @btnInfoBackgroundHighlight;
|
169
|
+
}
|
170
|
+
.btn-inverse.dropdown-toggle {
|
171
|
+
background-color: @btnInverseBackgroundHighlight;
|
172
|
+
}
|
173
|
+
}
|
174
|
+
|
175
|
+
|
176
|
+
// Reposition the caret
|
177
|
+
.btn .caret {
|
178
|
+
margin-top: 8px;
|
179
|
+
margin-left: 0;
|
180
|
+
}
|
181
|
+
// Carets in other button sizes
|
182
|
+
.btn-mini .caret,
|
183
|
+
.btn-small .caret,
|
184
|
+
.btn-large .caret {
|
185
|
+
margin-top: 6px;
|
186
|
+
}
|
187
|
+
.btn-large .caret {
|
188
|
+
border-left-width: 5px;
|
189
|
+
border-right-width: 5px;
|
190
|
+
border-top-width: 5px;
|
191
|
+
}
|
192
|
+
// Upside down carets for .dropup
|
193
|
+
.dropup .btn-large .caret {
|
194
|
+
border-bottom-width: 5px;
|
195
|
+
}
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
// Account for other colors
|
200
|
+
.btn-primary,
|
201
|
+
.btn-warning,
|
202
|
+
.btn-danger,
|
203
|
+
.btn-info,
|
204
|
+
.btn-success,
|
205
|
+
.btn-inverse {
|
206
|
+
.caret {
|
207
|
+
border-top-color: @white;
|
208
|
+
border-bottom-color: @white;
|
209
|
+
}
|
210
|
+
}
|
211
|
+
|
212
|
+
|
213
|
+
|
214
|
+
// Vertical button groups
|
215
|
+
// ----------------------
|
216
|
+
|
217
|
+
.btn-group-vertical {
|
218
|
+
display: inline-block; // makes buttons only take up the width they need
|
219
|
+
.ie7-inline-block();
|
220
|
+
}
|
221
|
+
.btn-group-vertical .btn {
|
222
|
+
display: block;
|
223
|
+
float: none;
|
224
|
+
width: 100%;
|
225
|
+
.border-radius(0);
|
226
|
+
}
|
227
|
+
.btn-group-vertical .btn + .btn {
|
228
|
+
margin-left: 0;
|
229
|
+
margin-top: -1px;
|
230
|
+
}
|
231
|
+
.btn-group-vertical .btn:first-child {
|
232
|
+
.border-radius(4px 4px 0 0);
|
233
|
+
}
|
234
|
+
.btn-group-vertical .btn:last-child {
|
235
|
+
.border-radius(0 0 4px 4px);
|
236
|
+
}
|
237
|
+
.btn-group-vertical .btn-large:first-child {
|
238
|
+
.border-radius(6px 6px 0 0);
|
239
|
+
}
|
240
|
+
.btn-group-vertical .btn-large:last-child {
|
241
|
+
.border-radius(0 0 6px 6px);
|
242
|
+
}
|
@@ -0,0 +1,232 @@
|
|
1
|
+
//
|
2
|
+
// Buttons
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Base styles
|
7
|
+
// --------------------------------------------------
|
8
|
+
|
9
|
+
// Core
|
10
|
+
.btn {
|
11
|
+
display: inline-block;
|
12
|
+
.ie7-inline-block();
|
13
|
+
padding: 4px 12px;
|
14
|
+
margin-bottom: 0; // For input.btn
|
15
|
+
font-size: @baseFontSize;
|
16
|
+
line-height: @baseLineHeight;
|
17
|
+
*line-height: @baseLineHeight;
|
18
|
+
text-align: center;
|
19
|
+
vertical-align: middle;
|
20
|
+
cursor: pointer;
|
21
|
+
.buttonBackground(@btnBackground, @btnBackgroundHighlight, @grayDark, 0 1px 1px rgba(255,255,255,.75));
|
22
|
+
border: 1px solid @btnBorder;
|
23
|
+
*border: 0; // Remove the border to prevent IE7's black border on input:focus
|
24
|
+
border-bottom-color: darken(@btnBorder, 10%);
|
25
|
+
.border-radius(@baseBorderRadius);
|
26
|
+
.ie7-restore-left-whitespace(); // Give IE7 some love
|
27
|
+
.box-shadow(~"inset 0 1px 0 rgba(255,255,255,.2), 0 1px 2px rgba(0,0,0,.05)");
|
28
|
+
|
29
|
+
// Hover state
|
30
|
+
&:hover {
|
31
|
+
color: @grayDark;
|
32
|
+
text-decoration: none;
|
33
|
+
background-color: darken(@white, 10%);
|
34
|
+
*background-color: darken(@white, 15%); /* Buttons in IE7 don't get borders, so darken on hover */
|
35
|
+
background-position: 0 -15px;
|
36
|
+
|
37
|
+
// transition is only when going to hover, otherwise the background
|
38
|
+
// behind the gradient (there for IE<=9 fallback) gets mismatched
|
39
|
+
.transition(background-position .1s linear);
|
40
|
+
}
|
41
|
+
|
42
|
+
// Focus state for keyboard and accessibility
|
43
|
+
&:focus {
|
44
|
+
.tab-focus();
|
45
|
+
}
|
46
|
+
|
47
|
+
// Active state
|
48
|
+
&.active,
|
49
|
+
&:active {
|
50
|
+
background-color: darken(@white, 10%);
|
51
|
+
background-color: darken(@white, 15%) e("\9");
|
52
|
+
background-image: none;
|
53
|
+
outline: 0;
|
54
|
+
.box-shadow(~"inset 0 2px 4px rgba(0,0,0,.15), 0 1px 2px rgba(0,0,0,.05)");
|
55
|
+
}
|
56
|
+
|
57
|
+
// Disabled state
|
58
|
+
&.disabled,
|
59
|
+
&[disabled] {
|
60
|
+
cursor: default;
|
61
|
+
background-color: darken(@white, 10%);
|
62
|
+
background-image: none;
|
63
|
+
.opacity(65);
|
64
|
+
.box-shadow(none);
|
65
|
+
}
|
66
|
+
|
67
|
+
}
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
// Button Sizes
|
72
|
+
// --------------------------------------------------
|
73
|
+
|
74
|
+
// Large
|
75
|
+
.btn-large {
|
76
|
+
padding: @paddingLarge;
|
77
|
+
font-size: @fontSizeLarge;
|
78
|
+
.border-radius(@borderRadiusLarge);
|
79
|
+
}
|
80
|
+
.btn-large [class^="icon-"],
|
81
|
+
.btn-large [class*=" icon-"] {
|
82
|
+
margin-top: 2px;
|
83
|
+
}
|
84
|
+
|
85
|
+
// Small
|
86
|
+
.btn-small {
|
87
|
+
padding: @paddingSmall;
|
88
|
+
font-size: @fontSizeSmall;
|
89
|
+
.border-radius(@borderRadiusSmall);
|
90
|
+
}
|
91
|
+
.btn-small [class^="icon-"],
|
92
|
+
.btn-small [class*=" icon-"] {
|
93
|
+
margin-top: 0;
|
94
|
+
}
|
95
|
+
|
96
|
+
// Mini
|
97
|
+
.btn-mini {
|
98
|
+
padding: @paddingMini;
|
99
|
+
font-size: @fontSizeMini;
|
100
|
+
.border-radius(@borderRadiusSmall);
|
101
|
+
}
|
102
|
+
|
103
|
+
|
104
|
+
// Block button
|
105
|
+
// -------------------------
|
106
|
+
|
107
|
+
.btn-block {
|
108
|
+
display: block;
|
109
|
+
width: 100%;
|
110
|
+
padding-left: 0;
|
111
|
+
padding-right: 0;
|
112
|
+
.box-sizing(border-box);
|
113
|
+
}
|
114
|
+
|
115
|
+
// Vertically space out multiple block buttons
|
116
|
+
.btn-block + .btn-block {
|
117
|
+
margin-top: 5px;
|
118
|
+
}
|
119
|
+
|
120
|
+
// Specificity overrides
|
121
|
+
input[type="submit"],
|
122
|
+
input[type="reset"],
|
123
|
+
input[type="button"] {
|
124
|
+
&.btn-block {
|
125
|
+
width: 100%;
|
126
|
+
}
|
127
|
+
}
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
// Alternate buttons
|
132
|
+
// --------------------------------------------------
|
133
|
+
|
134
|
+
// Provide *some* extra contrast for those who can get it
|
135
|
+
.btn-primary.active,
|
136
|
+
.btn-warning.active,
|
137
|
+
.btn-danger.active,
|
138
|
+
.btn-success.active,
|
139
|
+
.btn-info.active,
|
140
|
+
.btn-inverse.active {
|
141
|
+
color: rgba(255,255,255,.75);
|
142
|
+
}
|
143
|
+
|
144
|
+
// Set the backgrounds
|
145
|
+
// -------------------------
|
146
|
+
.btn {
|
147
|
+
// reset here as of 2.0.3 due to Recess property order
|
148
|
+
border-color: #c5c5c5;
|
149
|
+
border-color: rgba(0,0,0,.15) rgba(0,0,0,.15) rgba(0,0,0,.25);
|
150
|
+
}
|
151
|
+
.btn-primary {
|
152
|
+
.buttonBackground(@btnPrimaryBackground, @btnPrimaryBackgroundHighlight);
|
153
|
+
}
|
154
|
+
// Warning appears are orange
|
155
|
+
.btn-warning {
|
156
|
+
.buttonBackground(@btnWarningBackground, @btnWarningBackgroundHighlight);
|
157
|
+
}
|
158
|
+
// Danger and error appear as red
|
159
|
+
.btn-danger {
|
160
|
+
.buttonBackground(@btnDangerBackground, @btnDangerBackgroundHighlight);
|
161
|
+
}
|
162
|
+
// Success appears as green
|
163
|
+
.btn-success {
|
164
|
+
.buttonBackground(@btnSuccessBackground, @btnSuccessBackgroundHighlight);
|
165
|
+
}
|
166
|
+
// Info appears as a neutral blue
|
167
|
+
.btn-info {
|
168
|
+
.buttonBackground(@btnInfoBackground, @btnInfoBackgroundHighlight);
|
169
|
+
}
|
170
|
+
// Inverse appears as dark gray
|
171
|
+
.btn-inverse {
|
172
|
+
.buttonBackground(@btnInverseBackground, @btnInverseBackgroundHighlight);
|
173
|
+
}
|
174
|
+
|
175
|
+
|
176
|
+
// Cross-browser Jank
|
177
|
+
// --------------------------------------------------
|
178
|
+
|
179
|
+
button.btn,
|
180
|
+
input[type="submit"].btn {
|
181
|
+
|
182
|
+
// Firefox 3.6 only I believe
|
183
|
+
&::-moz-focus-inner {
|
184
|
+
padding: 0;
|
185
|
+
border: 0;
|
186
|
+
}
|
187
|
+
|
188
|
+
// IE7 has some default padding on button controls
|
189
|
+
*padding-top: 3px;
|
190
|
+
*padding-bottom: 3px;
|
191
|
+
|
192
|
+
&.btn-large {
|
193
|
+
*padding-top: 7px;
|
194
|
+
*padding-bottom: 7px;
|
195
|
+
}
|
196
|
+
&.btn-small {
|
197
|
+
*padding-top: 3px;
|
198
|
+
*padding-bottom: 3px;
|
199
|
+
}
|
200
|
+
&.btn-mini {
|
201
|
+
*padding-top: 1px;
|
202
|
+
*padding-bottom: 1px;
|
203
|
+
}
|
204
|
+
}
|
205
|
+
|
206
|
+
|
207
|
+
// Link buttons
|
208
|
+
// --------------------------------------------------
|
209
|
+
|
210
|
+
// Make a button look and behave like a link
|
211
|
+
.btn-link,
|
212
|
+
.btn-link:active,
|
213
|
+
.btn-link[disabled] {
|
214
|
+
background-color: transparent;
|
215
|
+
background-image: none;
|
216
|
+
.box-shadow(none);
|
217
|
+
}
|
218
|
+
.btn-link {
|
219
|
+
border-color: transparent;
|
220
|
+
cursor: pointer;
|
221
|
+
color: @linkColor;
|
222
|
+
.border-radius(0);
|
223
|
+
}
|
224
|
+
.btn-link:hover {
|
225
|
+
color: @linkColorHover;
|
226
|
+
text-decoration: underline;
|
227
|
+
background-color: transparent;
|
228
|
+
}
|
229
|
+
.btn-link[disabled]:hover {
|
230
|
+
color: @grayDark;
|
231
|
+
text-decoration: none;
|
232
|
+
}
|