bootstrap_sass_rails 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (66) hide show
  1. checksums.yaml +15 -0
  2. data/.gitignore +17 -0
  3. data/.rvmrc +1 -0
  4. data/Gemfile +4 -0
  5. data/LICENSE.txt +22 -0
  6. data/README.md +44 -0
  7. data/Rakefile +1 -0
  8. data/app/assets/javascripts/bootstrap.js +12 -0
  9. data/app/assets/javascripts/bootstrap/affix.js +126 -0
  10. data/app/assets/javascripts/bootstrap/alert.js +98 -0
  11. data/app/assets/javascripts/bootstrap/button.js +109 -0
  12. data/app/assets/javascripts/bootstrap/carousel.js +217 -0
  13. data/app/assets/javascripts/bootstrap/collapse.js +179 -0
  14. data/app/assets/javascripts/bootstrap/dropdown.js +154 -0
  15. data/app/assets/javascripts/bootstrap/modal.js +246 -0
  16. data/app/assets/javascripts/bootstrap/popover.js +117 -0
  17. data/app/assets/javascripts/bootstrap/scrollspy.js +158 -0
  18. data/app/assets/javascripts/bootstrap/tab.js +135 -0
  19. data/app/assets/javascripts/bootstrap/tooltip.js +386 -0
  20. data/app/assets/javascripts/bootstrap/transition.js +56 -0
  21. data/app/assets/stylesheets/bootstrap.css.sass +59 -0
  22. data/app/assets/stylesheets/bootstrap/_alerts.css.sass +55 -0
  23. data/app/assets/stylesheets/bootstrap/_badges.css.sass +50 -0
  24. data/app/assets/stylesheets/bootstrap/_breadcrumbs.css.sass +19 -0
  25. data/app/assets/stylesheets/bootstrap/_button-groups.css.sass +210 -0
  26. data/app/assets/stylesheets/bootstrap/_buttons.css.sass +135 -0
  27. data/app/assets/stylesheets/bootstrap/_carousel.css.sass +165 -0
  28. data/app/assets/stylesheets/bootstrap/_close.css.sass +28 -0
  29. data/app/assets/stylesheets/bootstrap/_code.css.sass +49 -0
  30. data/app/assets/stylesheets/bootstrap/_component-animations.css.sass +25 -0
  31. data/app/assets/stylesheets/bootstrap/_dropdowns.css.sass +166 -0
  32. data/app/assets/stylesheets/bootstrap/_forms.css.sass +309 -0
  33. data/app/assets/stylesheets/bootstrap/_glyphicons.css.sass +827 -0
  34. data/app/assets/stylesheets/bootstrap/_grid.css.sass +483 -0
  35. data/app/assets/stylesheets/bootstrap/_input-groups.css.sass +117 -0
  36. data/app/assets/stylesheets/bootstrap/_jumbotron.css.sass +28 -0
  37. data/app/assets/stylesheets/bootstrap/_labels.css.sass +46 -0
  38. data/app/assets/stylesheets/bootstrap/_list-group.css.sass +71 -0
  39. data/app/assets/stylesheets/bootstrap/_media.css.sass +47 -0
  40. data/app/assets/stylesheets/bootstrap/_mixins.css.sass +754 -0
  41. data/app/assets/stylesheets/bootstrap/_modals.css.sass +127 -0
  42. data/app/assets/stylesheets/bootstrap/_navbar.css.sass +457 -0
  43. data/app/assets/stylesheets/bootstrap/_navs.css.sass +171 -0
  44. data/app/assets/stylesheets/bootstrap/_normalize.css.sass +375 -0
  45. data/app/assets/stylesheets/bootstrap/_pager.css.sass +39 -0
  46. data/app/assets/stylesheets/bootstrap/_pagination.css.sass +66 -0
  47. data/app/assets/stylesheets/bootstrap/_panels.css.sass +114 -0
  48. data/app/assets/stylesheets/bootstrap/_popovers.css.sass +124 -0
  49. data/app/assets/stylesheets/bootstrap/_print.css.sass +66 -0
  50. data/app/assets/stylesheets/bootstrap/_progress-bars.css.sass +90 -0
  51. data/app/assets/stylesheets/bootstrap/_responsive-utilities.css.sass +152 -0
  52. data/app/assets/stylesheets/bootstrap/_scaffolding.css.sass +108 -0
  53. data/app/assets/stylesheets/bootstrap/_tables.css.sass +176 -0
  54. data/app/assets/stylesheets/bootstrap/_theme.css.sass +228 -0
  55. data/app/assets/stylesheets/bootstrap/_thumbnails.css.sass +26 -0
  56. data/app/assets/stylesheets/bootstrap/_tooltip.css.sass +91 -0
  57. data/app/assets/stylesheets/bootstrap/_type.css.sass +251 -0
  58. data/app/assets/stylesheets/bootstrap/_utilities.css.sass +36 -0
  59. data/app/assets/stylesheets/bootstrap/_variables.css.sass +614 -0
  60. data/app/assets/stylesheets/bootstrap/_wells.css.sass +25 -0
  61. data/bin/convert-sass.sh +3 -0
  62. data/bootstrap_sass_rails.gemspec +25 -0
  63. data/lib/bootstrap_sass_rails.rb +13 -0
  64. data/lib/bootstrap_sass_rails/engine.rb +4 -0
  65. data/lib/bootstrap_sass_rails/version.rb +3 -0
  66. metadata +152 -0
@@ -0,0 +1,135 @@
1
+ //
2
+ // Buttons
3
+ // --------------------------------------------------
4
+
5
+ // Base styles
6
+ // --------------------------------------------------
7
+
8
+ // Core styles
9
+ .btn
10
+ display: inline-block
11
+ padding: $padding-base-vertical $padding-base-horizontal
12
+ margin-bottom: 0
13
+ // For input.btn
14
+ font-size: $font-size-base
15
+ font-weight: $btn-font-weight
16
+ line-height: $line-height-base
17
+ text-align: center
18
+ vertical-align: middle
19
+ cursor: pointer
20
+ border: 1px solid transparent
21
+ border-radius: $border-radius-base
22
+ white-space: nowrap
23
+ +user-select(none)
24
+ &:focus
25
+ +tab-focus
26
+ &:hover,
27
+ &:focus
28
+ color: $btn-default-color
29
+ text-decoration: none
30
+ &:active,
31
+ &.active
32
+ outline: 0
33
+ background-image: none
34
+ +box-shadow(inset 0 3px 5px rgba(0, 0, 0, 0.125))
35
+ &.disabled,
36
+ &[disabled],
37
+ fieldset[disabled] &
38
+ cursor: not-allowed
39
+ pointer-events: none
40
+ // Future-proof disabling of clicks
41
+ +opacity(0.65)
42
+ +box-shadow(none)
43
+
44
+ // Alternate buttons
45
+ // --------------------------------------------------
46
+
47
+ .btn-default
48
+ +button-variant($btn-default-color, $btn-default-bg, $btn-default-border)
49
+
50
+ .btn-primary
51
+ +button-variant($btn-primary-color, $btn-primary-bg, $btn-primary-border)
52
+
53
+ // Warning appears as orange
54
+ .btn-warning
55
+ +button-variant($btn-warning-color, $btn-warning-bg, $btn-warning-border)
56
+
57
+ // Danger and error appear as red
58
+ .btn-danger
59
+ +button-variant($btn-danger-color, $btn-danger-bg, $btn-danger-border)
60
+
61
+ // Success appears as green
62
+ .btn-success
63
+ +button-variant($btn-success-color, $btn-success-bg, $btn-success-border)
64
+
65
+ // Info appears as blue-green
66
+ .btn-info
67
+ +button-variant($btn-info-color, $btn-info-bg, $btn-info-border)
68
+
69
+ // Link buttons
70
+ // -------------------------
71
+
72
+ // Make a button look and behave like a link
73
+ .btn-link
74
+ color: $link-color
75
+ font-weight: normal
76
+ cursor: pointer
77
+ border-radius: 0
78
+ &,
79
+ &:active,
80
+ &[disabled],
81
+ fieldset[disabled] &
82
+ background-color: transparent
83
+ +box-shadow(none)
84
+ &,
85
+ &:hover,
86
+ &:focus,
87
+ &:active
88
+ border-color: transparent
89
+ &:hover,
90
+ &:focus
91
+ color: $link-hover-color
92
+ text-decoration: underline
93
+ background-color: transparent
94
+ &[disabled],
95
+ fieldset[disabled] &
96
+ &:hover,
97
+ &:focus
98
+ color: $btn-link-disabled-color
99
+ text-decoration: none
100
+
101
+ // Button Sizes
102
+ // --------------------------------------------------
103
+
104
+ .btn-lg
105
+ // line-height: ensure even-numbered height of button next to large input
106
+ +button-size($padding-large-vertical, $padding-large-horizontal, $font-size-large, $line-height-large, $border-radius-large)
107
+
108
+ .btn-sm,
109
+ .btn-xs
110
+ // line-height: ensure proper height of button next to small input
111
+ +button-size($padding-small-vertical, $padding-small-horizontal, $font-size-small, $line-height-small, $border-radius-small)
112
+
113
+ .btn-xs
114
+ padding: 1px 5px
115
+
116
+ // Block button
117
+ // --------------------------------------------------
118
+
119
+ .btn-block
120
+ display: block
121
+ width: 100%
122
+ padding-left: 0
123
+ padding-right: 0
124
+
125
+ // Vertically space out multiple block buttons
126
+ .btn-block + .btn-block
127
+ margin-top: 5px
128
+
129
+ // Specificity overrides
130
+
131
+ input[type="submit"],
132
+ input[type="reset"],
133
+ input[type="button"]
134
+ &.btn-block
135
+ width: 100%
@@ -0,0 +1,165 @@
1
+ //
2
+ // Carousel
3
+ // --------------------------------------------------
4
+
5
+ // Wrapper for the slide container and indicators
6
+ .carousel
7
+ position: relative
8
+
9
+ .carousel-inner
10
+ position: relative
11
+ overflow: hidden
12
+ width: 100%
13
+ > .item
14
+ display: none
15
+ position: relative
16
+ +transition(0.6s ease-in-out left)
17
+ // Account for jankitude on images
18
+ > img,
19
+ > a > img
20
+ +img-responsive
21
+ line-height: 1
22
+ > .active,
23
+ > .next,
24
+ > .prev
25
+ display: block
26
+ > .active
27
+ left: 0
28
+ > .next,
29
+ > .prev
30
+ position: absolute
31
+ top: 0
32
+ width: 100%
33
+ > .next
34
+ left: 100%
35
+ > .prev
36
+ left: -100%
37
+ > .next.left,
38
+ > .prev.right
39
+ left: 0
40
+ > .active.left
41
+ left: -100%
42
+ > .active.right
43
+ left: 100%
44
+
45
+ // Left/right controls for nav
46
+ // ---------------------------
47
+
48
+ .carousel-control
49
+ position: absolute
50
+ top: 0
51
+ left: 0
52
+ bottom: 0
53
+ width: $carousel-control-width
54
+ +opacity($carousel-control-opacity)
55
+ font-size: $carousel-control-font-size
56
+ color: $carousel-control-color
57
+ text-align: center
58
+ text-shadow: $carousel-text-shadow
59
+ // We can't have this transition here because webkit cancels the carousel
60
+ // animation if you trip this while in the middle of another animation.
61
+ // Set gradients for backgrounds
62
+ &.left
63
+ +gradient-horizontal($start_color: rgba(0, 0, 0, 0.5), $end_color: rgba(0, 0, 0, 0.0001))
64
+ &.right
65
+ left: auto
66
+ right: 0
67
+ +gradient-horizontal($start_color: rgba(0, 0, 0, 0.0001), $end_color: rgba(0, 0, 0, 0.5))
68
+ // Hover/focus state
69
+ &:hover,
70
+ &:focus
71
+ color: $carousel-control-color
72
+ text-decoration: none
73
+ +opacity(0.9)
74
+ // Toggles
75
+ .icon-prev,
76
+ .icon-next,
77
+ .glyphicon-chevron-left,
78
+ .glyphicon-chevron-right
79
+ position: absolute
80
+ top: 50%
81
+ left: 50%
82
+ z-index: 5
83
+ display: inline-block
84
+ .icon-prev,
85
+ .icon-next
86
+ width: 20px
87
+ height: 20px
88
+ margin-top: -10px
89
+ margin-left: -10px
90
+ font-family: serif
91
+ .icon-prev
92
+ &:before
93
+ content: '\2039'
94
+ // SINGLE LEFT-POINTING ANGLE QUOTATION MARK (U+2039)
95
+ .icon-next
96
+ &:before
97
+ content: '\203a'
98
+ // SINGLE RIGHT-POINTING ANGLE QUOTATION MARK (U+203A)
99
+
100
+ // Optional indicator pips
101
+ //
102
+ // Add an unordered list with the following class and add a list item for each
103
+ // slide your carousel holds.
104
+
105
+ .carousel-indicators
106
+ position: absolute
107
+ bottom: 10px
108
+ left: 50%
109
+ z-index: 15
110
+ width: 60%
111
+ margin-left: -30%
112
+ padding-left: 0
113
+ list-style: none
114
+ text-align: center
115
+ li
116
+ display: inline-block
117
+ width: 10px
118
+ height: 10px
119
+ margin: 1px
120
+ text-indent: -999px
121
+ border: 1px solid $carousel-indicator-border-color
122
+ border-radius: 10px
123
+ cursor: pointer
124
+ .active
125
+ margin: 0
126
+ width: 12px
127
+ height: 12px
128
+ background-color: $carousel-indicator-active-bg
129
+
130
+ // Optional captions
131
+ // -----------------------------
132
+ // Hidden by default for smaller viewports
133
+ .carousel-caption
134
+ position: absolute
135
+ left: 15%
136
+ right: 15%
137
+ bottom: 20px
138
+ z-index: 10
139
+ padding-top: 20px
140
+ padding-bottom: 20px
141
+ color: $carousel-caption-color
142
+ text-align: center
143
+ text-shadow: $carousel-text-shadow
144
+ & .btn
145
+ text-shadow: none
146
+ // No shadow for button elements in carousel-caption
147
+
148
+ // Scale up controls for tablets and up
149
+ @media screen and (min-width: $screen-tablet)
150
+ // Scale up the controls a smidge
151
+ .carousel-control .icon-prev,
152
+ .carousel-control .icon-next
153
+ width: 30px
154
+ height: 30px
155
+ margin-top: -15px
156
+ margin-left: -15px
157
+ font-size: 30px
158
+ // Show and left align the captions
159
+ .carousel-caption
160
+ left: 20%
161
+ right: 20%
162
+ padding-bottom: 30px
163
+ // Move up the indicators
164
+ .carousel-indicators
165
+ bottom: 20px
@@ -0,0 +1,28 @@
1
+ //
2
+ // Close icons
3
+ // --------------------------------------------------
4
+
5
+ .close
6
+ float: right
7
+ font-size: $font-size-base * 1.5
8
+ font-weight: $close-font-weight
9
+ line-height: 1
10
+ color: $close-color
11
+ text-shadow: $close-text-shadow
12
+ +opacity(0.2)
13
+ &:hover,
14
+ &:focus
15
+ color: $close-color
16
+ text-decoration: none
17
+ cursor: pointer
18
+ +opacity(0.5)
19
+
20
+ // Additional properties for button version
21
+ // iOS requires the button element instead of an anchor tag.
22
+ // If you want the anchor version, it requires `href="#"`.
23
+ button.close
24
+ padding: 0
25
+ cursor: pointer
26
+ background: transparent
27
+ border: 0
28
+ -webkit-appearance: none
@@ -0,0 +1,49 @@
1
+ //
2
+ // Code (inline and blocK)
3
+ // --------------------------------------------------
4
+
5
+ // Inline and block code styles
6
+
7
+ code,
8
+ pre
9
+ font-family: $font-family-monospace
10
+
11
+ // Inline code
12
+ code
13
+ padding: 2px 4px
14
+ font-size: 90%
15
+ color: $code-color
16
+ background-color: $code-bg
17
+ white-space: nowrap
18
+ border-radius: $border-radius-base
19
+
20
+ // Blocks of code
21
+ pre
22
+ display: block
23
+ padding: ($line-height-computed - 1) / 2
24
+ margin: 0 0 $line-height-computed / 2
25
+ font-size: $font-size-base - 1
26
+ // 14px to 13px
27
+ line-height: $line-height-base
28
+ word-break: break-all
29
+ word-wrap: break-word
30
+ color: $pre-color
31
+ background-color: $pre-bg
32
+ border: 1px solid $pre-border-color
33
+ border-radius: $border-radius-base
34
+ // Make prettyprint styles more spaced out for readability
35
+ &.prettyprint
36
+ margin-bottom: $line-height-computed
37
+ // Account for some code outputs that place code tags in pre tags
38
+ code
39
+ padding: 0
40
+ font-size: inherit
41
+ color: inherit
42
+ white-space: pre-wrap
43
+ background-color: transparent
44
+ border: 0
45
+
46
+ // Enable scrollable blocks of code
47
+ .pre-scrollable
48
+ max-height: $pre-scrollable-max-height
49
+ overflow-y: scroll
@@ -0,0 +1,25 @@
1
+ //
2
+ // Component animations
3
+ // --------------------------------------------------
4
+
5
+ // Heads up!
6
+ //
7
+ // We don't use the `.opacity()` mixin here since it causes a bug with text
8
+ // fields in IE7-8. Source: https://github.com/twitter/bootstrap/pull/3552.
9
+
10
+ .fade
11
+ opacity: 0
12
+ +transition(opacity 0.15s linear)
13
+ &.in
14
+ opacity: 1
15
+
16
+ .collapse
17
+ display: none
18
+ &.in
19
+ display: block
20
+
21
+ .collapsing
22
+ position: relative
23
+ height: 0
24
+ overflow: hidden
25
+ +transition(height 0.35s ease)
@@ -0,0 +1,166 @@
1
+ //
2
+ // Dropdown menus
3
+ // --------------------------------------------------
4
+
5
+ // Dropdown arrow/caret
6
+ .caret
7
+ display: inline-block
8
+ width: 0
9
+ height: 0
10
+ margin-left: 2px
11
+ vertical-align: middle
12
+ border-top: $caret-width-base solid $dropdown-caret-color
13
+ border-right: $caret-width-base solid transparent
14
+ border-left: $caret-width-base solid transparent
15
+ // Firefox fix for https://github.com/twbs/bootstrap/issues/9538. Once fixed,
16
+ // we can just straight up remove this.
17
+ border-bottom: 0 dotted
18
+ content: ""
19
+
20
+ // The dropdown wrapper (div)
21
+ .dropdown
22
+ position: relative
23
+
24
+ // Prevent the focus on the dropdown toggle when closing dropdowns
25
+ .dropdown-toggle:focus
26
+ outline: 0
27
+
28
+ // The dropdown menu (ul)
29
+ .dropdown-menu
30
+ position: absolute
31
+ top: 100%
32
+ left: 0
33
+ z-index: $zindex-dropdown
34
+ display: none
35
+ // 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
40
+ // override default ul
41
+ list-style: none
42
+ font-size: $font-size-base
43
+ background-color: $dropdown-bg
44
+ border: 1px solid $dropdown-fallback-border
45
+ // IE8 fallback
46
+ border: 1px solid $dropdown-border
47
+ border-radius: $border-radius-base
48
+ +box-shadow(0 6px 12px rgba(0, 0, 0, 0.175))
49
+ background-clip: padding-box
50
+ // Aligns the dropdown menu to right
51
+ &.pull-right
52
+ right: 0
53
+ left: auto
54
+ // Dividers (basically an hr) within the dropdown
55
+ .divider
56
+ +nav-divider($dropdown-divider-bg)
57
+ // Links within the dropdown menu
58
+ > li > a
59
+ display: block
60
+ padding: 3px 20px
61
+ clear: both
62
+ font-weight: normal
63
+ line-height: $line-height-base
64
+ color: $dropdown-link-color
65
+ white-space: nowrap
66
+ // prevent links from randomly breaking onto new lines
67
+
68
+ // Hover/Focus state
69
+ .dropdown-menu > li > a
70
+ &:hover,
71
+ &:focus
72
+ text-decoration: none
73
+ color: $dropdown-link-hover-color
74
+ background-color: $dropdown-link-hover-bg
75
+
76
+ // Active state
77
+ .dropdown-menu > .active > a
78
+ &,
79
+ &:hover,
80
+ &:focus
81
+ color: $dropdown-link-active-color
82
+ text-decoration: none
83
+ outline: 0
84
+ background-color: $dropdown-link-active-bg
85
+
86
+ // Disabled state
87
+ //
88
+ // Gray out text and ensure the hover/focus state remains gray
89
+
90
+ .dropdown-menu > .disabled > a
91
+ &,
92
+ &:hover,
93
+ &:focus
94
+ color: $dropdown-link-disabled-color
95
+
96
+ // Nuke hover/focus effects
97
+ .dropdown-menu > .disabled > a
98
+ &:hover,
99
+ &:focus
100
+ text-decoration: none
101
+ background-color: transparent
102
+ background-image: none
103
+ // Remove CSS gradient
104
+ +reset-filter
105
+ cursor: not-allowed
106
+
107
+ // Open state for the dropdown
108
+ .open
109
+ // Show the menu
110
+ > .dropdown-menu
111
+ display: block
112
+ // Remove the outline when :focus is triggered
113
+ > a
114
+ outline: 0
115
+
116
+ // Dropdown section headers
117
+ .dropdown-header
118
+ display: block
119
+ padding: 3px 20px
120
+ font-size: $font-size-small
121
+ line-height: $line-height-base
122
+ color: $dropdown-header-color
123
+
124
+ // Backdrop to catch body clicks on mobile, etc.
125
+ .dropdown-backdrop
126
+ position: fixed
127
+ left: 0
128
+ right: 0
129
+ bottom: 0
130
+ top: 0
131
+ z-index: $zindex-dropdown - 10
132
+
133
+ // Right aligned dropdowns
134
+ .pull-right > .dropdown-menu
135
+ right: 0
136
+ left: auto
137
+
138
+ // Allow for dropdowns to go bottom up (aka, dropup-menu)
139
+ //
140
+ // Just add .dropup after the standard .dropdown class and you're set, bro.
141
+ // TODO: abstract this so that the navbar fixed styles are not placed here?
142
+
143
+ .dropup,
144
+ .navbar-fixed-bottom .dropdown
145
+ // Reverse the caret
146
+ .caret
147
+ // Firefox fix for https://github.com/twbs/bootstrap/issues/9538. Once this
148
+ // gets fixed, restore `border-top: 0;`.
149
+ border-top: 0 dotted
150
+ border-bottom: 4px solid $dropdown-caret-color
151
+ content: ""
152
+ // Different positioning for bottom up menu
153
+ .dropdown-menu
154
+ top: auto
155
+ bottom: 100%
156
+ margin-bottom: 1px
157
+
158
+ // Component alignment
159
+ //
160
+ // Reiterate per navbar.less and the modified component alignment there.
161
+
162
+ @media (min-width: $grid-float-breakpoint)
163
+ .navbar-right
164
+ .dropdown-menu
165
+ right: 0
166
+ left: auto