twigg-app 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/data/quips.yml +45 -0
- data/lib/twigg-app/app/quips.rb +13 -0
- data/lib/twigg-app/app/routes.rb +43 -0
- data/lib/twigg-app/app/server.rb +146 -0
- data/lib/twigg-app/app/version.rb +5 -0
- data/lib/twigg-app/app.rb +14 -0
- data/lib/twigg-app.rb +5 -0
- data/public/application.js +106 -0
- data/public/favicon.ico +0 -0
- data/public/favicon.png +0 -0
- data/public/vendor/bootstrap/CNAME +1 -0
- data/public/vendor/bootstrap/CONTRIBUTING.md +66 -0
- data/public/vendor/bootstrap/Gruntfile.js +195 -0
- data/public/vendor/bootstrap/LICENSE +176 -0
- data/public/vendor/bootstrap/README.md +139 -0
- data/public/vendor/bootstrap/_config.yml +28 -0
- data/public/vendor/bootstrap/_includes/ads.html +1 -0
- data/public/vendor/bootstrap/_includes/footer.html +33 -0
- data/public/vendor/bootstrap/_includes/header.html +43 -0
- data/public/vendor/bootstrap/_includes/nav-components.html +135 -0
- data/public/vendor/bootstrap/_includes/nav-css.html +77 -0
- data/public/vendor/bootstrap/_includes/nav-customize.html +40 -0
- data/public/vendor/bootstrap/_includes/nav-getting-started.html +28 -0
- data/public/vendor/bootstrap/_includes/nav-javascript.html +88 -0
- data/public/vendor/bootstrap/_includes/nav-main.html +32 -0
- data/public/vendor/bootstrap/_includes/old-bs-docs.html +8 -0
- data/public/vendor/bootstrap/_includes/social-buttons.html +16 -0
- data/public/vendor/bootstrap/_layouts/customize.html +52 -0
- data/public/vendor/bootstrap/_layouts/default.html +72 -0
- data/public/vendor/bootstrap/_layouts/home.html +43 -0
- data/public/vendor/bootstrap/assets/css/docs.css +896 -0
- data/public/vendor/bootstrap/assets/css/pygments-manni.css +66 -0
- data/public/vendor/bootstrap/assets/ico/apple-touch-icon-114-precomposed.png +0 -0
- data/public/vendor/bootstrap/assets/ico/apple-touch-icon-144-precomposed.png +0 -0
- data/public/vendor/bootstrap/assets/ico/apple-touch-icon-57-precomposed.png +0 -0
- data/public/vendor/bootstrap/assets/ico/apple-touch-icon-72-precomposed.png +0 -0
- data/public/vendor/bootstrap/assets/ico/favicon.png +0 -0
- data/public/vendor/bootstrap/assets/js/application.js +82 -0
- data/public/vendor/bootstrap/assets/js/customizer.js +175 -0
- data/public/vendor/bootstrap/assets/js/holder.js +419 -0
- data/public/vendor/bootstrap/assets/js/html5shiv.js +8 -0
- data/public/vendor/bootstrap/assets/js/jquery.bbq.min.js +1287 -0
- data/public/vendor/bootstrap/assets/js/jquery.js +5 -0
- data/public/vendor/bootstrap/assets/js/jszip.js +1425 -0
- data/public/vendor/bootstrap/assets/js/less.js +9 -0
- data/public/vendor/bootstrap/assets/js/respond.min.js +6 -0
- data/public/vendor/bootstrap/assets/js/uglify.js +14 -0
- data/public/vendor/bootstrap/bower.json +11 -0
- data/public/vendor/bootstrap/browserstack.json +37 -0
- data/public/vendor/bootstrap/components.html +2555 -0
- data/public/vendor/bootstrap/composer.json +20 -0
- data/public/vendor/bootstrap/css.html +2276 -0
- data/public/vendor/bootstrap/customize.html +1480 -0
- data/public/vendor/bootstrap/dist/css/bootstrap.css +5579 -0
- data/public/vendor/bootstrap/dist/css/bootstrap.min.css +9 -0
- data/public/vendor/bootstrap/dist/js/bootstrap.js +1993 -0
- data/public/vendor/bootstrap/dist/js/bootstrap.min.js +6 -0
- data/public/vendor/bootstrap/getting-started.html +375 -0
- data/public/vendor/bootstrap/index.html +16 -0
- data/public/vendor/bootstrap/javascript.html +1904 -0
- data/public/vendor/bootstrap/js/affix.js +126 -0
- data/public/vendor/bootstrap/js/alert.js +98 -0
- data/public/vendor/bootstrap/js/button.js +109 -0
- data/public/vendor/bootstrap/js/carousel.js +217 -0
- data/public/vendor/bootstrap/js/collapse.js +179 -0
- data/public/vendor/bootstrap/js/dropdown.js +154 -0
- data/public/vendor/bootstrap/js/modal.js +244 -0
- data/public/vendor/bootstrap/js/popover.js +117 -0
- data/public/vendor/bootstrap/js/scrollspy.js +158 -0
- data/public/vendor/bootstrap/js/tab.js +135 -0
- data/public/vendor/bootstrap/js/tests/index.html +52 -0
- data/public/vendor/bootstrap/js/tests/phantom.js +63 -0
- data/public/vendor/bootstrap/js/tests/server.js +14 -0
- data/public/vendor/bootstrap/js/tests/unit/affix.js +25 -0
- data/public/vendor/bootstrap/js/tests/unit/alert.js +62 -0
- data/public/vendor/bootstrap/js/tests/unit/button.js +116 -0
- data/public/vendor/bootstrap/js/tests/unit/carousel.js +87 -0
- data/public/vendor/bootstrap/js/tests/unit/collapse.js +164 -0
- data/public/vendor/bootstrap/js/tests/unit/dropdown.js +219 -0
- data/public/vendor/bootstrap/js/tests/unit/modal.js +177 -0
- data/public/vendor/bootstrap/js/tests/unit/phantom.js +69 -0
- data/public/vendor/bootstrap/js/tests/unit/popover.js +133 -0
- data/public/vendor/bootstrap/js/tests/unit/scrollspy.js +37 -0
- data/public/vendor/bootstrap/js/tests/unit/tab.js +86 -0
- data/public/vendor/bootstrap/js/tests/unit/tooltip.js +437 -0
- data/public/vendor/bootstrap/js/tests/unit/transition.js +13 -0
- data/public/vendor/bootstrap/js/tests/vendor/jquery.js +5 -0
- data/public/vendor/bootstrap/js/tests/vendor/qunit.css +232 -0
- data/public/vendor/bootstrap/js/tests/vendor/qunit.js +1510 -0
- data/public/vendor/bootstrap/js/tooltip.js +382 -0
- data/public/vendor/bootstrap/js/transition.js +56 -0
- data/public/vendor/bootstrap/less/alerts.less +71 -0
- data/public/vendor/bootstrap/less/badges.less +51 -0
- data/public/vendor/bootstrap/less/bootstrap.less +63 -0
- data/public/vendor/bootstrap/less/breadcrumbs.less +23 -0
- data/public/vendor/bootstrap/less/button-groups.less +244 -0
- data/public/vendor/bootstrap/less/buttons.less +159 -0
- data/public/vendor/bootstrap/less/carousel.less +204 -0
- data/public/vendor/bootstrap/less/close.less +33 -0
- data/public/vendor/bootstrap/less/code.less +56 -0
- data/public/vendor/bootstrap/less/component-animations.less +29 -0
- data/public/vendor/bootstrap/less/dropdowns.less +176 -0
- data/public/vendor/bootstrap/less/forms.less +332 -0
- data/public/vendor/bootstrap/less/grid.less +340 -0
- data/public/vendor/bootstrap/less/input-groups.less +127 -0
- data/public/vendor/bootstrap/less/jumbotron.less +29 -0
- data/public/vendor/bootstrap/less/labels.less +54 -0
- data/public/vendor/bootstrap/less/list-group.less +88 -0
- data/public/vendor/bootstrap/less/media.less +56 -0
- data/public/vendor/bootstrap/less/mixins.less +693 -0
- data/public/vendor/bootstrap/less/modals.less +133 -0
- data/public/vendor/bootstrap/less/navbar.less +559 -0
- data/public/vendor/bootstrap/less/navs.less +228 -0
- data/public/vendor/bootstrap/less/normalize.less +396 -0
- data/public/vendor/bootstrap/less/pager.less +55 -0
- data/public/vendor/bootstrap/less/pagination.less +72 -0
- data/public/vendor/bootstrap/less/panels.less +128 -0
- data/public/vendor/bootstrap/less/popovers.less +133 -0
- data/public/vendor/bootstrap/less/print.less +100 -0
- data/public/vendor/bootstrap/less/progress-bars.less +99 -0
- data/public/vendor/bootstrap/less/responsive-utilities.less +149 -0
- data/public/vendor/bootstrap/less/scaffolding.less +111 -0
- data/public/vendor/bootstrap/less/tables.less +211 -0
- data/public/vendor/bootstrap/less/thumbnails.less +42 -0
- data/public/vendor/bootstrap/less/tooltip.less +95 -0
- data/public/vendor/bootstrap/less/type.less +238 -0
- data/public/vendor/bootstrap/less/utilities.less +42 -0
- data/public/vendor/bootstrap/less/variables.less +607 -0
- data/public/vendor/bootstrap/less/wells.less +29 -0
- data/public/vendor/bootstrap/package.json +33 -0
- data/public/vendor/bootstrap-glyphicons/CHANGELOG.md +3 -0
- data/public/vendor/bootstrap-glyphicons/CNAME +1 -0
- data/public/vendor/bootstrap-glyphicons/CONTRIBUTING.md +54 -0
- data/public/vendor/bootstrap-glyphicons/LICENSE +19 -0
- data/public/vendor/bootstrap-glyphicons/README.md +61 -0
- data/public/vendor/bootstrap-glyphicons/_config.yml +12 -0
- data/public/vendor/bootstrap-glyphicons/composer.json +9 -0
- data/public/vendor/bootstrap-glyphicons/css/bootstrap-glyphicons.css +2 -0
- data/public/vendor/bootstrap-glyphicons/css/bootstrap.css +9 -0
- data/public/vendor/bootstrap-glyphicons/css/docs.css +160 -0
- data/public/vendor/bootstrap-glyphicons/fonts/glyphiconshalflings-regular.eot +0 -0
- data/public/vendor/bootstrap-glyphicons/fonts/glyphiconshalflings-regular.otf +0 -0
- data/public/vendor/bootstrap-glyphicons/fonts/glyphiconshalflings-regular.svg +175 -0
- data/public/vendor/bootstrap-glyphicons/fonts/glyphiconshalflings-regular.ttf +0 -0
- data/public/vendor/bootstrap-glyphicons/fonts/glyphiconshalflings-regular.woff +0 -0
- data/public/vendor/bootstrap-glyphicons/index.html +255 -0
- data/public/vendor/bootstrap-glyphicons/less/bootstrap-glyphicons.less +201 -0
- data/public/vendor/bootstrap-glyphicons/package.json +18 -0
- data/public/vendor/d3/LICENSE +26 -0
- data/public/vendor/d3/README.md +7 -0
- data/public/vendor/d3/bower.json +25 -0
- data/public/vendor/d3/d3.js +8810 -0
- data/public/vendor/d3/d3.min.js +5 -0
- data/public/vendor/jquery/README.md +11 -0
- data/public/vendor/jquery/bower.json +11 -0
- data/public/vendor/jquery/component.json +15 -0
- data/public/vendor/jquery/composer.json +35 -0
- data/public/vendor/jquery/jquery-migrate.js +511 -0
- data/public/vendor/jquery/jquery-migrate.min.js +3 -0
- data/public/vendor/jquery/jquery.js +8829 -0
- data/public/vendor/jquery/jquery.min.js +6 -0
- data/public/vendor/jquery/jquery.min.map +1 -0
- data/public/vendor/jquery/package.json +7 -0
- data/public/vendor/replacejs/CHANGELOG.md +3 -0
- data/public/vendor/replacejs/MIT-LICENSE.txt +20 -0
- data/public/vendor/replacejs/README.md +123 -0
- data/public/vendor/replacejs/bower.json +24 -0
- data/public/vendor/replacejs/primer.js +17 -0
- data/public/vendor/replacejs/primer.min.js +1 -0
- data/public/vendor/replacejs/replace.js +182 -0
- data/public/vendor/stupidtable.js +158 -0
- data/views/dashboard.haml +17 -0
- data/views/layout.haml +60 -0
- metadata +330 -0
@@ -0,0 +1,176 @@
|
|
1
|
+
//
|
2
|
+
// Dropdown menus
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Dropdown arrow/caret
|
7
|
+
.caret {
|
8
|
+
display: inline-block;
|
9
|
+
width: 0;
|
10
|
+
height: 0;
|
11
|
+
margin-left: 2px;
|
12
|
+
vertical-align: middle;
|
13
|
+
border-top: @caret-width-base solid @dropdown-caret-color;
|
14
|
+
border-right: @caret-width-base solid transparent;
|
15
|
+
border-left: @caret-width-base solid transparent;
|
16
|
+
content: "";
|
17
|
+
}
|
18
|
+
|
19
|
+
// The dropdown wrapper (div)
|
20
|
+
.dropdown {
|
21
|
+
position: relative;
|
22
|
+
}
|
23
|
+
|
24
|
+
// Prevent the focus on the dropdown toggle when closing dropdowns
|
25
|
+
.dropdown-toggle:focus {
|
26
|
+
outline: 0;
|
27
|
+
}
|
28
|
+
|
29
|
+
// The dropdown menu (ul)
|
30
|
+
.dropdown-menu {
|
31
|
+
position: absolute;
|
32
|
+
top: 100%;
|
33
|
+
left: 0;
|
34
|
+
z-index: @zindex-dropdown;
|
35
|
+
display: none; // none by default, but block on "open" of the menu
|
36
|
+
float: left;
|
37
|
+
min-width: 160px;
|
38
|
+
padding: 5px 0;
|
39
|
+
margin: 2px 0 0; // override default ul
|
40
|
+
list-style: none;
|
41
|
+
font-size: @font-size-base;
|
42
|
+
background-color: @dropdown-bg;
|
43
|
+
border: 1px solid @dropdown-fallback-border; // IE8 fallback
|
44
|
+
border: 1px solid @dropdown-border;
|
45
|
+
border-radius: @border-radius-base;
|
46
|
+
.box-shadow(0 6px 12px rgba(0,0,0,.175));
|
47
|
+
background-clip: padding-box;
|
48
|
+
|
49
|
+
// Aligns the dropdown menu to right
|
50
|
+
&.pull-right {
|
51
|
+
right: 0;
|
52
|
+
left: auto;
|
53
|
+
}
|
54
|
+
|
55
|
+
// Dividers (basically an hr) within the dropdown
|
56
|
+
.divider {
|
57
|
+
.nav-divider(@dropdown-divider-bg);
|
58
|
+
}
|
59
|
+
|
60
|
+
// Links within the dropdown menu
|
61
|
+
> li > a {
|
62
|
+
display: block;
|
63
|
+
padding: 3px 20px;
|
64
|
+
clear: both;
|
65
|
+
font-weight: normal;
|
66
|
+
line-height: @line-height-base;
|
67
|
+
color: @dropdown-link-color;
|
68
|
+
white-space: nowrap; // prevent links from randomly breaking onto new lines
|
69
|
+
}
|
70
|
+
}
|
71
|
+
|
72
|
+
// Hover/Focus state
|
73
|
+
.dropdown-menu > li > a {
|
74
|
+
&:hover,
|
75
|
+
&:focus {
|
76
|
+
text-decoration: none;
|
77
|
+
color: @dropdown-link-hover-color;
|
78
|
+
#gradient > .vertical(@start-color: @dropdown-link-hover-bg; @end-color: darken(@dropdown-link-hover-bg, 5%));
|
79
|
+
background-color: darken(@dropdown-link-hover-bg, 5%);
|
80
|
+
}
|
81
|
+
}
|
82
|
+
|
83
|
+
// Active state
|
84
|
+
.dropdown-menu > .active > a {
|
85
|
+
&,
|
86
|
+
&:hover,
|
87
|
+
&:focus {
|
88
|
+
color: @dropdown-link-active-color;
|
89
|
+
text-decoration: none;
|
90
|
+
outline: 0;
|
91
|
+
#gradient > .vertical(@start-color: @dropdown-link-active-bg; @end-color: darken(@dropdown-link-active-bg, 5%));
|
92
|
+
background-color: darken(@dropdown-link-active-bg, 5%);
|
93
|
+
}
|
94
|
+
}
|
95
|
+
|
96
|
+
// Disabled state
|
97
|
+
//
|
98
|
+
// Gray out text and ensure the hover/focus state remains gray
|
99
|
+
|
100
|
+
.dropdown-menu > .disabled > a {
|
101
|
+
&,
|
102
|
+
&:hover,
|
103
|
+
&:focus {
|
104
|
+
color: @dropdown-link-disabled-color;
|
105
|
+
}
|
106
|
+
}
|
107
|
+
// Nuke hover/focus effects
|
108
|
+
.dropdown-menu > .disabled > a {
|
109
|
+
&:hover,
|
110
|
+
&:focus {
|
111
|
+
text-decoration: none;
|
112
|
+
background-color: transparent;
|
113
|
+
background-image: none; // Remove CSS gradient
|
114
|
+
.reset-filter();
|
115
|
+
cursor: not-allowed;
|
116
|
+
}
|
117
|
+
}
|
118
|
+
|
119
|
+
// Open state for the dropdown
|
120
|
+
.open {
|
121
|
+
// Show the menu
|
122
|
+
> .dropdown-menu {
|
123
|
+
display: block;
|
124
|
+
}
|
125
|
+
|
126
|
+
// Remove the outline when :focus is triggered
|
127
|
+
> a {
|
128
|
+
outline: 0;
|
129
|
+
}
|
130
|
+
}
|
131
|
+
|
132
|
+
// Dropdown section headers
|
133
|
+
.dropdown-header {
|
134
|
+
display: block;
|
135
|
+
padding: 3px 20px;
|
136
|
+
font-size: @font-size-small;
|
137
|
+
line-height: @line-height-base;
|
138
|
+
color: @dropdown-header-color;
|
139
|
+
}
|
140
|
+
|
141
|
+
// Backdrop to catch body clicks on mobile, etc.
|
142
|
+
.dropdown-backdrop {
|
143
|
+
position: fixed;
|
144
|
+
left: 0;
|
145
|
+
right: 0;
|
146
|
+
bottom: 0;
|
147
|
+
top: 0;
|
148
|
+
z-index: @zindex-dropdown - 10;
|
149
|
+
}
|
150
|
+
|
151
|
+
// Right aligned dropdowns
|
152
|
+
.pull-right > .dropdown-menu {
|
153
|
+
right: 0;
|
154
|
+
left: auto;
|
155
|
+
}
|
156
|
+
|
157
|
+
// Allow for dropdowns to go bottom up (aka, dropup-menu)
|
158
|
+
//
|
159
|
+
// Just add .dropup after the standard .dropdown class and you're set, bro.
|
160
|
+
// TODO: abstract this so that the navbar fixed styles are not placed here?
|
161
|
+
|
162
|
+
.dropup,
|
163
|
+
.navbar-fixed-bottom .dropdown {
|
164
|
+
// Reverse the caret
|
165
|
+
.caret {
|
166
|
+
border-top: 0;
|
167
|
+
border-bottom: 4px solid @dropdown-caret-color;
|
168
|
+
content: "";
|
169
|
+
}
|
170
|
+
// Different positioning for bottom up menu
|
171
|
+
.dropdown-menu {
|
172
|
+
top: auto;
|
173
|
+
bottom: 100%;
|
174
|
+
margin-bottom: 1px;
|
175
|
+
}
|
176
|
+
}
|
@@ -0,0 +1,332 @@
|
|
1
|
+
//
|
2
|
+
// Forms
|
3
|
+
// --------------------------------------------------
|
4
|
+
|
5
|
+
|
6
|
+
// Normalize non-controls
|
7
|
+
//
|
8
|
+
// Restyle and baseline non-control form elements.
|
9
|
+
|
10
|
+
fieldset {
|
11
|
+
padding: 0;
|
12
|
+
margin: 0;
|
13
|
+
border: 0;
|
14
|
+
}
|
15
|
+
|
16
|
+
legend {
|
17
|
+
display: block;
|
18
|
+
width: 100%;
|
19
|
+
padding: 0;
|
20
|
+
margin-bottom: @line-height-computed;
|
21
|
+
font-size: (@font-size-base * 1.5);
|
22
|
+
line-height: inherit;
|
23
|
+
color: @legend-color;
|
24
|
+
border: 0;
|
25
|
+
border-bottom: 1px solid @legend-border-color;
|
26
|
+
}
|
27
|
+
|
28
|
+
label {
|
29
|
+
display: inline-block;
|
30
|
+
margin-bottom: 5px;
|
31
|
+
font-weight: bold;
|
32
|
+
}
|
33
|
+
|
34
|
+
|
35
|
+
// Normalize form controls
|
36
|
+
|
37
|
+
// Override content-box in Normalize (* isn't specific enough)
|
38
|
+
input[type="search"] {
|
39
|
+
.box-sizing(border-box);
|
40
|
+
}
|
41
|
+
|
42
|
+
// Position radios and checkboxes better
|
43
|
+
input[type="radio"],
|
44
|
+
input[type="checkbox"] {
|
45
|
+
margin: 4px 0 0;
|
46
|
+
margin-top: 1px \9; /* IE8-9 */
|
47
|
+
line-height: normal;
|
48
|
+
}
|
49
|
+
|
50
|
+
// Set the height of select and file controls to match text inputs
|
51
|
+
input[type="file"] {
|
52
|
+
display: block;
|
53
|
+
}
|
54
|
+
|
55
|
+
// Make multiple select elements height not fixed
|
56
|
+
select[multiple],
|
57
|
+
select[size] {
|
58
|
+
height: auto;
|
59
|
+
}
|
60
|
+
|
61
|
+
// Fix optgroup Firefox bug per https://github.com/twbs/bootstrap/issues/7611
|
62
|
+
select optgroup {
|
63
|
+
font-size: inherit;
|
64
|
+
font-style: inherit;
|
65
|
+
font-family: inherit;
|
66
|
+
}
|
67
|
+
|
68
|
+
// Focus for select, file, radio, and checkbox
|
69
|
+
input[type="file"]:focus,
|
70
|
+
input[type="radio"]:focus,
|
71
|
+
input[type="checkbox"]:focus {
|
72
|
+
.tab-focus();
|
73
|
+
}
|
74
|
+
|
75
|
+
// Fix for Chrome number input
|
76
|
+
// Setting certain font-sizes causes the `I` bar to appear on hover of the bottom increment button.
|
77
|
+
// See https://github.com/twbs/bootstrap/issues/8350 for more.
|
78
|
+
input[type="number"] {
|
79
|
+
&::-webkit-outer-spin-button,
|
80
|
+
&::-webkit-inner-spin-button {
|
81
|
+
height: auto;
|
82
|
+
}
|
83
|
+
}
|
84
|
+
|
85
|
+
|
86
|
+
// Placeholder
|
87
|
+
//
|
88
|
+
// Placeholder text gets special styles because when browsers invalidate entire
|
89
|
+
// lines if it doesn't understand a selector/
|
90
|
+
.form-control {
|
91
|
+
.placeholder();
|
92
|
+
}
|
93
|
+
|
94
|
+
|
95
|
+
// Common form controls
|
96
|
+
//
|
97
|
+
// Shared size and type resets for form controls. Apply `.form-control` to any
|
98
|
+
// of the following form controls:
|
99
|
+
//
|
100
|
+
// select
|
101
|
+
// textarea
|
102
|
+
// input[type="text"]
|
103
|
+
// input[type="password"]
|
104
|
+
// input[type="datetime"]
|
105
|
+
// input[type="datetime-local"]
|
106
|
+
// input[type="date"]
|
107
|
+
// input[type="month"]
|
108
|
+
// input[type="time"]
|
109
|
+
// input[type="week"]
|
110
|
+
// input[type="number"]
|
111
|
+
// input[type="email"]
|
112
|
+
// input[type="url"]
|
113
|
+
// input[type="search"]
|
114
|
+
// input[type="tel"]
|
115
|
+
// input[type="color"]
|
116
|
+
|
117
|
+
.form-control {
|
118
|
+
display: block;
|
119
|
+
width: 100%;
|
120
|
+
height: @input-height-base; // Make inputs at least the height of their button counterpart (base line-height + padding + border)
|
121
|
+
padding: @padding-base-vertical @padding-base-horizontal;
|
122
|
+
font-size: @font-size-base;
|
123
|
+
line-height: @line-height-base;
|
124
|
+
color: @input-color;
|
125
|
+
vertical-align: middle;
|
126
|
+
background-color: @input-bg;
|
127
|
+
border: 1px solid @input-border;
|
128
|
+
border-radius: @input-border-radius;
|
129
|
+
.box-shadow(inset 0 1px 1px rgba(0,0,0,.075));
|
130
|
+
.transition(~"border-color ease-in-out .15s, box-shadow ease-in-out .15s");
|
131
|
+
|
132
|
+
// Customize the `:focus` state to imitate native WebKit styles.
|
133
|
+
.form-control-focus();
|
134
|
+
|
135
|
+
// Disabled and read-only inputs
|
136
|
+
// Note: HTML5 says that inputs under a fieldset > legend:first-child won't be
|
137
|
+
// disabled if the fieldset is disabled. Due to implementation difficulty,
|
138
|
+
// we don't honor that edge case; we style them as disabled anyway.
|
139
|
+
&[disabled],
|
140
|
+
&[readonly],
|
141
|
+
fieldset[disabled] & {
|
142
|
+
cursor: not-allowed;
|
143
|
+
background-color: @input-bg-disabled;
|
144
|
+
}
|
145
|
+
|
146
|
+
// Reset height for `textarea`s
|
147
|
+
textarea& {
|
148
|
+
height: auto;
|
149
|
+
}
|
150
|
+
}
|
151
|
+
|
152
|
+
|
153
|
+
// Form groups
|
154
|
+
//
|
155
|
+
// Designed to help with the organization and spacing of vertical forms. For
|
156
|
+
// horizontal forms, use the predefined grid classes.
|
157
|
+
|
158
|
+
.form-group {
|
159
|
+
margin-bottom: 15px;
|
160
|
+
}
|
161
|
+
|
162
|
+
|
163
|
+
// Checkboxes and radios
|
164
|
+
//
|
165
|
+
// Indent the labels to position radios/checkboxes as hanging controls.
|
166
|
+
|
167
|
+
.radio,
|
168
|
+
.checkbox {
|
169
|
+
display: block;
|
170
|
+
min-height: @line-height-computed; // clear the floating input if there is no label text
|
171
|
+
margin-top: 10px;
|
172
|
+
margin-bottom: 10px;
|
173
|
+
padding-left: 20px;
|
174
|
+
vertical-align: middle;
|
175
|
+
label {
|
176
|
+
display: inline;
|
177
|
+
margin-bottom: 0;
|
178
|
+
font-weight: normal;
|
179
|
+
cursor: pointer;
|
180
|
+
}
|
181
|
+
}
|
182
|
+
.radio input[type="radio"],
|
183
|
+
.radio-inline input[type="radio"],
|
184
|
+
.checkbox input[type="checkbox"],
|
185
|
+
.checkbox-inline input[type="checkbox"] {
|
186
|
+
float: left;
|
187
|
+
margin-left: -20px;
|
188
|
+
}
|
189
|
+
.radio + .radio,
|
190
|
+
.checkbox + .checkbox {
|
191
|
+
margin-top: -5px; // Move up sibling radios or checkboxes for tighter spacing
|
192
|
+
}
|
193
|
+
|
194
|
+
// Radios and checkboxes on same line
|
195
|
+
.radio-inline,
|
196
|
+
.checkbox-inline {
|
197
|
+
display: inline-block;
|
198
|
+
padding-left: 20px;
|
199
|
+
margin-bottom: 0;
|
200
|
+
vertical-align: middle;
|
201
|
+
font-weight: normal;
|
202
|
+
cursor: pointer;
|
203
|
+
}
|
204
|
+
.radio-inline + .radio-inline,
|
205
|
+
.checkbox-inline + .checkbox-inline {
|
206
|
+
margin-top: 0;
|
207
|
+
margin-left: 10px; // space out consecutive inline controls
|
208
|
+
}
|
209
|
+
|
210
|
+
|
211
|
+
// Form control sizing
|
212
|
+
.input-sm {
|
213
|
+
.input-size(@input-height-small; @padding-small-vertical; @padding-small-horizontal; @font-size-small; @line-height-small; @border-radius-small);
|
214
|
+
}
|
215
|
+
|
216
|
+
.input-lg {
|
217
|
+
.input-size(@input-height-large; @padding-large-vertical; @padding-large-horizontal; @font-size-large; @line-height-large; @border-radius-large);
|
218
|
+
}
|
219
|
+
|
220
|
+
|
221
|
+
// Form control feedback states
|
222
|
+
//
|
223
|
+
// Apply contextual and semantic states to individual form controls.
|
224
|
+
|
225
|
+
// Warning
|
226
|
+
.has-warning {
|
227
|
+
.form-control-validation(@state-warning-text; @state-warning-text; @state-warning-bg);
|
228
|
+
}
|
229
|
+
// Error
|
230
|
+
.has-error {
|
231
|
+
.form-control-validation(@state-danger-text; @state-danger-text; @state-danger-bg);
|
232
|
+
}
|
233
|
+
// Success
|
234
|
+
.has-success {
|
235
|
+
.form-control-validation(@state-success-text; @state-success-text; @state-success-bg);
|
236
|
+
}
|
237
|
+
|
238
|
+
|
239
|
+
// Static form control text
|
240
|
+
//
|
241
|
+
// Apply class to a `p` element to make any string of text align with labels in
|
242
|
+
// a horizontal form layout.
|
243
|
+
|
244
|
+
.form-control-static {
|
245
|
+
margin-bottom: 0; // Remove default margin from `p`
|
246
|
+
padding-top: @padding-base-vertical;
|
247
|
+
}
|
248
|
+
|
249
|
+
|
250
|
+
// Help text
|
251
|
+
//
|
252
|
+
// Apply to any element you wish to create light text for placement immediately
|
253
|
+
// below a form control. Use for general help, formatting, or instructional text.
|
254
|
+
|
255
|
+
.help-block {
|
256
|
+
display: block; // account for any element using help-block
|
257
|
+
margin-top: 5px;
|
258
|
+
margin-bottom: 10px;
|
259
|
+
color: lighten(@text-color, 25%); // lighten the text some for contrast
|
260
|
+
}
|
261
|
+
|
262
|
+
|
263
|
+
|
264
|
+
// Inline forms
|
265
|
+
//
|
266
|
+
// Make forms appear inline(-block) by adding the `.form-inline` class. Inline
|
267
|
+
// forms begin stacked on extra small (mobile) devices and then go inline when
|
268
|
+
// viewports reach <768px.
|
269
|
+
//
|
270
|
+
// Requires wrapping inputs and labels with `.form-group` for proper display of
|
271
|
+
// default HTML form controls and our custom form controls (e.g., input groups).
|
272
|
+
//
|
273
|
+
// Heads up! This is mixin-ed into `.navbar-form` in navbars.less.
|
274
|
+
|
275
|
+
.form-inline {
|
276
|
+
|
277
|
+
// Kick in the inline
|
278
|
+
@media (min-width: @screen-tablet) {
|
279
|
+
// Inline-block all the things for "inline"
|
280
|
+
.form-group {
|
281
|
+
display: inline-block;
|
282
|
+
margin-bottom: 0;
|
283
|
+
vertical-align: middle;
|
284
|
+
}
|
285
|
+
|
286
|
+
// In navbar-form, allow folks to *not* use `.form-group`
|
287
|
+
.form-control {
|
288
|
+
display: inline-block;
|
289
|
+
}
|
290
|
+
|
291
|
+
// Remove default margin on radios/checkboxes that were used for stacking, and
|
292
|
+
// then undo the floating of radios and checkboxes to match (which also avoids
|
293
|
+
// a bug in WebKit: https://github.com/twbs/bootstrap/issues/1969).
|
294
|
+
.radio,
|
295
|
+
.checkbox {
|
296
|
+
display: inline-block;
|
297
|
+
margin-top: 0;
|
298
|
+
margin-bottom: 0;
|
299
|
+
padding-left: 0;
|
300
|
+
}
|
301
|
+
.radio input[type="radio"],
|
302
|
+
.checkbox input[type="checkbox"] {
|
303
|
+
float: none;
|
304
|
+
margin-left: 0;
|
305
|
+
}
|
306
|
+
}
|
307
|
+
}
|
308
|
+
|
309
|
+
|
310
|
+
// Horizontal forms
|
311
|
+
//
|
312
|
+
// Horizontal forms are built on grid classes and allow you to create forms with
|
313
|
+
// labels on the left and inputs on the right.
|
314
|
+
|
315
|
+
.form-horizontal .control-label,
|
316
|
+
.form-horizontal .radio-inline,
|
317
|
+
.form-horizontal .checkbox-inline {
|
318
|
+
padding-top: @padding-base-vertical;
|
319
|
+
}
|
320
|
+
|
321
|
+
.form-horizontal {
|
322
|
+
.form-group {
|
323
|
+
.make-row();
|
324
|
+
}
|
325
|
+
}
|
326
|
+
|
327
|
+
// Only right align form labels here when the columns stop stacking
|
328
|
+
@media (min-width: @screen-tablet) {
|
329
|
+
.form-horizontal .control-label {
|
330
|
+
text-align: right;
|
331
|
+
}
|
332
|
+
}
|