twitter-bootstrap-rails 2.2.8 → 3.2.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of twitter-bootstrap-rails might be problematic. Click here for more details.

Files changed (181) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +82 -119
  3. data/Rakefile +4 -6
  4. data/app/assets/fonts/fontawesome-webfont.eot +0 -0
  5. data/app/assets/fonts/fontawesome-webfont.svg +471 -366
  6. data/app/assets/fonts/fontawesome-webfont.ttf +0 -0
  7. data/app/assets/fonts/fontawesome-webfont.woff +0 -0
  8. data/app/assets/fonts/glyphicons-halflings-regular.eot +0 -0
  9. data/app/assets/fonts/glyphicons-halflings-regular.svg +229 -0
  10. data/app/assets/fonts/glyphicons-halflings-regular.ttf +0 -0
  11. data/app/assets/fonts/glyphicons-halflings-regular.woff +0 -0
  12. data/app/assets/javascripts/twitter/bootstrap.js +12 -13
  13. data/app/assets/javascripts/twitter/bootstrap/affix.js +137 -0
  14. data/app/assets/javascripts/twitter/bootstrap/alert.js +88 -0
  15. data/app/assets/javascripts/twitter/bootstrap/button.js +107 -0
  16. data/app/assets/javascripts/twitter/bootstrap/carousel.js +205 -0
  17. data/app/assets/javascripts/twitter/bootstrap/collapse.js +170 -0
  18. data/app/assets/javascripts/twitter/bootstrap/dropdown.js +147 -0
  19. data/app/assets/javascripts/twitter/bootstrap/modal.js +243 -0
  20. data/app/assets/javascripts/twitter/bootstrap/popover.js +110 -0
  21. data/app/assets/javascripts/twitter/bootstrap/scrollspy.js +153 -0
  22. data/app/assets/javascripts/twitter/bootstrap/tab.js +125 -0
  23. data/app/assets/javascripts/twitter/bootstrap/tooltip.js +399 -0
  24. data/app/assets/javascripts/twitter/bootstrap/transition.js +48 -0
  25. data/app/assets/stylesheets/twitter-bootstrap-static/bootstrap.css.erb +1 -890
  26. data/app/assets/stylesheets/twitter-bootstrap-static/fontawesome.css.erb +4 -787
  27. data/app/assets/stylesheets/twitter-bootstrap-static/sprites.css.erb +1 -146
  28. data/app/helpers/bootstrap_flash_helper.rb +7 -5
  29. data/app/helpers/form_errors_helper.rb +22 -0
  30. data/app/helpers/glyph_helper.rb +8 -6
  31. data/app/helpers/modal_helper.rb +29 -21
  32. data/app/helpers/navbar_helper.rb +42 -30
  33. data/app/helpers/twitter_breadcrumbs_helper.rb +3 -2
  34. data/app/views/twitter-bootstrap/_breadcrumbs.html.erb +4 -4
  35. data/lib/generators/bootstrap/install/install_generator.rb +3 -2
  36. data/lib/generators/bootstrap/install/templates/bootstrap_and_overrides.less +7 -8
  37. data/lib/generators/bootstrap/install/templates/en.bootstrap.yml +5 -0
  38. data/lib/generators/bootstrap/layout/layout_generator.rb +1 -4
  39. data/lib/generators/bootstrap/layout/templates/layout.html.erb +22 -43
  40. data/lib/generators/bootstrap/layout/templates/layout.html.haml +16 -31
  41. data/lib/generators/bootstrap/layout/templates/layout.html.slim +10 -25
  42. data/lib/generators/bootstrap/partial/templates/_login.html.erb +2 -3
  43. data/lib/generators/bootstrap/themed/templates/_form.html.erb +25 -8
  44. data/lib/generators/bootstrap/themed/templates/_form.html.haml +7 -7
  45. data/lib/generators/bootstrap/themed/templates/_form.html.slim +7 -7
  46. data/lib/generators/bootstrap/themed/templates/index.html.erb +2 -2
  47. data/lib/generators/bootstrap/themed/templates/index.html.haml +2 -2
  48. data/lib/generators/bootstrap/themed/templates/index.html.slim +2 -2
  49. data/lib/generators/bootstrap/themed/templates/show.html.erb +5 -7
  50. data/lib/generators/bootstrap/themed/templates/show.html.haml +4 -4
  51. data/lib/generators/bootstrap/themed/templates/show.html.slim +5 -6
  52. data/lib/generators/bootstrap/themed/templates/simple_form/_form.html.erb +5 -5
  53. data/lib/generators/bootstrap/themed/templates/simple_form/_form.html.haml +3 -3
  54. data/lib/generators/bootstrap/themed/templates/simple_form/_form.html.slim +4 -4
  55. data/lib/generators/bootstrap/themed/themed_generator.rb +2 -2
  56. data/lib/twitter/bootstrap/rails/{twitter-bootstrap-breadcrumbs.rb → breadcrumbs.rb} +24 -8
  57. data/lib/twitter/bootstrap/rails/engine.rb +5 -2
  58. data/lib/twitter/bootstrap/rails/version.rb +2 -2
  59. data/spec/lib/breadcrumbs_spec.rb +74 -0
  60. data/spec/lib/twitter_bootstrap_rails/badge_label_helper_spec.rb +4 -2
  61. data/spec/lib/twitter_bootstrap_rails/modal_helper_spec.rb +15 -15
  62. data/spec/lib/twitter_bootstrap_rails/navbar_helper_spec.rb +157 -173
  63. data/spec/lib/twitter_bootstrap_rails/uri_state_spec.rb +18 -16
  64. data/spec/spec_helper.rb +7 -1
  65. data/vendor/assets/stylesheets/twitter-bootstrap-static/bootstrap.css.erb +5797 -0
  66. data/vendor/static-source/bootstrap.less +0 -1
  67. data/vendor/static-source/fontawesome.less +0 -1
  68. data/vendor/static-source/sprites.less +1 -1
  69. data/vendor/toolkit/fontawesome/bordered-pulled.less +16 -0
  70. data/vendor/toolkit/fontawesome/core.less +9 -126
  71. data/vendor/toolkit/fontawesome/fixed-width.less +6 -0
  72. data/vendor/toolkit/fontawesome/font-awesome.less +9 -25
  73. data/vendor/toolkit/fontawesome/icons.less +503 -378
  74. data/vendor/toolkit/fontawesome/larger.less +13 -0
  75. data/vendor/toolkit/fontawesome/list.less +19 -0
  76. data/vendor/toolkit/fontawesome/mixins.less +14 -42
  77. data/vendor/toolkit/fontawesome/path.less +1 -1
  78. data/vendor/toolkit/fontawesome/rotated-flipped.less +9 -0
  79. data/vendor/toolkit/fontawesome/spinning.less +32 -0
  80. data/vendor/toolkit/fontawesome/stacked.less +20 -0
  81. data/vendor/toolkit/fontawesome/variables.less +511 -731
  82. data/vendor/toolkit/twitter/bootstrap/alerts.less +47 -58
  83. data/vendor/toolkit/twitter/bootstrap/badges.less +55 -0
  84. data/vendor/toolkit/twitter/bootstrap/bootstrap.less +27 -39
  85. data/vendor/toolkit/twitter/bootstrap/breadcrumbs.less +11 -9
  86. data/vendor/toolkit/twitter/bootstrap/button-groups.less +168 -152
  87. data/vendor/toolkit/twitter/bootstrap/buttons.less +101 -170
  88. data/vendor/toolkit/twitter/bootstrap/carousel.less +150 -65
  89. data/vendor/toolkit/twitter/bootstrap/close.less +20 -19
  90. data/vendor/toolkit/twitter/bootstrap/code.less +38 -30
  91. data/vendor/toolkit/twitter/bootstrap/component-animations.less +12 -3
  92. data/vendor/toolkit/twitter/bootstrap/dropdowns.less +115 -148
  93. data/vendor/toolkit/twitter/bootstrap/forms.less +401 -547
  94. data/vendor/toolkit/twitter/bootstrap/glyphicons.less +233 -0
  95. data/vendor/toolkit/twitter/bootstrap/grid.less +74 -11
  96. data/vendor/toolkit/twitter/bootstrap/input-groups.less +166 -0
  97. data/vendor/toolkit/twitter/bootstrap/jumbotron.less +48 -0
  98. data/vendor/toolkit/twitter/bootstrap/labels.less +64 -0
  99. data/vendor/toolkit/twitter/bootstrap/list-group.less +132 -0
  100. data/vendor/toolkit/twitter/bootstrap/media.less +8 -7
  101. data/vendor/toolkit/twitter/bootstrap/mixins.less +36 -699
  102. data/vendor/toolkit/twitter/bootstrap/mixins/alerts.less +14 -0
  103. data/vendor/toolkit/twitter/bootstrap/mixins/background-variant.less +8 -0
  104. data/vendor/toolkit/twitter/bootstrap/mixins/border-radius.less +18 -0
  105. data/vendor/toolkit/twitter/bootstrap/mixins/buttons.less +52 -0
  106. data/vendor/toolkit/twitter/bootstrap/mixins/center-block.less +7 -0
  107. data/vendor/toolkit/twitter/bootstrap/mixins/clearfix.less +22 -0
  108. data/vendor/toolkit/twitter/bootstrap/mixins/forms.less +85 -0
  109. data/vendor/toolkit/twitter/bootstrap/mixins/gradients.less +59 -0
  110. data/vendor/toolkit/twitter/bootstrap/mixins/grid-framework.less +91 -0
  111. data/vendor/toolkit/twitter/bootstrap/mixins/grid.less +122 -0
  112. data/vendor/toolkit/twitter/bootstrap/mixins/hide-text.less +21 -0
  113. data/vendor/toolkit/twitter/bootstrap/mixins/image.less +33 -0
  114. data/vendor/toolkit/twitter/bootstrap/mixins/labels.less +12 -0
  115. data/vendor/toolkit/twitter/bootstrap/mixins/list-group.less +29 -0
  116. data/vendor/toolkit/twitter/bootstrap/mixins/nav-divider.less +10 -0
  117. data/vendor/toolkit/twitter/bootstrap/mixins/nav-vertical-align.less +9 -0
  118. data/vendor/toolkit/twitter/bootstrap/mixins/opacity.less +8 -0
  119. data/vendor/toolkit/twitter/bootstrap/mixins/pagination.less +23 -0
  120. data/vendor/toolkit/twitter/bootstrap/mixins/panels.less +24 -0
  121. data/vendor/toolkit/twitter/bootstrap/mixins/progress-bar.less +10 -0
  122. data/vendor/toolkit/twitter/bootstrap/mixins/reset-filter.less +8 -0
  123. data/vendor/toolkit/twitter/bootstrap/mixins/resize.less +6 -0
  124. data/vendor/toolkit/twitter/bootstrap/mixins/responsive-visibility.less +15 -0
  125. data/vendor/toolkit/twitter/bootstrap/mixins/size.less +10 -0
  126. data/vendor/toolkit/twitter/bootstrap/mixins/tab-focus.less +9 -0
  127. data/vendor/toolkit/twitter/bootstrap/mixins/table-row.less +28 -0
  128. data/vendor/toolkit/twitter/bootstrap/mixins/text-emphasis.less +8 -0
  129. data/vendor/toolkit/twitter/bootstrap/mixins/text-overflow.less +8 -0
  130. data/vendor/toolkit/twitter/bootstrap/mixins/vendor-prefixes.less +224 -0
  131. data/vendor/toolkit/twitter/bootstrap/modals.less +109 -54
  132. data/vendor/toolkit/twitter/bootstrap/navbar.less +542 -384
  133. data/vendor/toolkit/twitter/bootstrap/navs.less +192 -359
  134. data/vendor/toolkit/twitter/bootstrap/normalize.less +425 -0
  135. data/vendor/toolkit/twitter/bootstrap/pager.less +46 -34
  136. data/vendor/toolkit/twitter/bootstrap/pagination.less +70 -105
  137. data/vendor/toolkit/twitter/bootstrap/panels.less +248 -0
  138. data/vendor/toolkit/twitter/bootstrap/popovers.less +61 -61
  139. data/vendor/toolkit/twitter/bootstrap/print.less +101 -0
  140. data/vendor/toolkit/twitter/bootstrap/progress-bars.less +51 -73
  141. data/vendor/toolkit/twitter/bootstrap/responsive-embed.less +34 -0
  142. data/vendor/toolkit/twitter/bootstrap/responsive-utilities.less +177 -42
  143. data/vendor/toolkit/twitter/bootstrap/scaffolding.less +120 -23
  144. data/vendor/toolkit/twitter/bootstrap/tables.less +171 -182
  145. data/vendor/toolkit/twitter/bootstrap/theme.less +260 -0
  146. data/vendor/toolkit/twitter/bootstrap/thumbnails.less +26 -43
  147. data/vendor/toolkit/twitter/bootstrap/tooltip.less +49 -24
  148. data/vendor/toolkit/twitter/bootstrap/type.less +208 -147
  149. data/vendor/toolkit/twitter/bootstrap/utilities.less +33 -7
  150. data/vendor/toolkit/twitter/bootstrap/variables.less +761 -215
  151. data/vendor/toolkit/twitter/bootstrap/wells.less +7 -7
  152. metadata +128 -138
  153. data/app/assets/javascripts/twitter/bootstrap/bootstrap-affix.js +0 -117
  154. data/app/assets/javascripts/twitter/bootstrap/bootstrap-alert.js +0 -99
  155. data/app/assets/javascripts/twitter/bootstrap/bootstrap-button.js +0 -105
  156. data/app/assets/javascripts/twitter/bootstrap/bootstrap-carousel.js +0 -207
  157. data/app/assets/javascripts/twitter/bootstrap/bootstrap-collapse.js +0 -167
  158. data/app/assets/javascripts/twitter/bootstrap/bootstrap-dropdown.js +0 -169
  159. data/app/assets/javascripts/twitter/bootstrap/bootstrap-modal.js +0 -247
  160. data/app/assets/javascripts/twitter/bootstrap/bootstrap-popover.js +0 -114
  161. data/app/assets/javascripts/twitter/bootstrap/bootstrap-scrollspy.js +0 -162
  162. data/app/assets/javascripts/twitter/bootstrap/bootstrap-tab.js +0 -144
  163. data/app/assets/javascripts/twitter/bootstrap/bootstrap-tooltip.js +0 -361
  164. data/app/assets/javascripts/twitter/bootstrap/bootstrap-transition.js +0 -60
  165. data/app/assets/javascripts/twitter/bootstrap/bootstrap-typeahead.js +0 -335
  166. data/test/lib/breadcrumbs_test.rb +0 -75
  167. data/test/test_helper.rb +0 -11
  168. data/vendor/toolkit/fontawesome/bootstrap.less +0 -84
  169. data/vendor/toolkit/fontawesome/extras.less +0 -93
  170. data/vendor/toolkit/fontawesome/font-awesome-ie7.less +0 -1953
  171. data/vendor/toolkit/twitter/bootstrap/accordion.less +0 -34
  172. data/vendor/toolkit/twitter/bootstrap/hero-unit.less +0 -25
  173. data/vendor/toolkit/twitter/bootstrap/labels-badges.less +0 -84
  174. data/vendor/toolkit/twitter/bootstrap/layouts.less +0 -16
  175. data/vendor/toolkit/twitter/bootstrap/reset.less +0 -216
  176. data/vendor/toolkit/twitter/bootstrap/responsive-1200px-min.less +0 -28
  177. data/vendor/toolkit/twitter/bootstrap/responsive-767px-max.less +0 -193
  178. data/vendor/toolkit/twitter/bootstrap/responsive-768px-979px.less +0 -19
  179. data/vendor/toolkit/twitter/bootstrap/responsive-navbar.less +0 -189
  180. data/vendor/toolkit/twitter/bootstrap/responsive.less +0 -48
  181. data/vendor/toolkit/twitter/bootstrap/sprites.less +0 -197
@@ -1,146 +1 @@
1
- .clearfix{*zoom:1;}.clearfix:before,.clearfix:after{display:table;content:"";line-height:0;}
2
- .clearfix:after{clear:both;}
3
- .hide-text{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0;}
4
- .input-block-level{display:block;width:100%;min-height:30px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;}
5
- [class^="icon-"],[class*=" icon-"]{display:inline-block;width:14px;height:14px;*margin-right:.3em;line-height:14px;vertical-align:text-top;background-image:url("<%= asset_path 'twitter/bootstrap/glyphicons-halflings.png' %>");background-position:14px 14px;background-repeat:no-repeat;margin-top:1px;}
6
- .icon-white,.nav-pills>.active>a>[class^="icon-"],.nav-pills>.active>a>[class*=" icon-"],.nav-list>.active>a>[class^="icon-"],.nav-list>.active>a>[class*=" icon-"],.navbar-inverse .nav>.active>a>[class^="icon-"],.navbar-inverse .nav>.active>a>[class*=" icon-"],.dropdown-menu>li>a:hover>[class^="icon-"],.dropdown-menu>li>a:focus>[class^="icon-"],.dropdown-menu>li>a:hover>[class*=" icon-"],.dropdown-menu>li>a:focus>[class*=" icon-"],.dropdown-menu>.active>a>[class^="icon-"],.dropdown-menu>.active>a>[class*=" icon-"],.dropdown-submenu:hover>a>[class^="icon-"],.dropdown-submenu:focus>a>[class^="icon-"],.dropdown-submenu:hover>a>[class*=" icon-"],.dropdown-submenu:focus>a>[class*=" icon-"]{background-image:url("<%= asset_path 'twitter/bootstrap/glyphicons-halflings-white.png' %>");}
7
- .icon-glass{background-position:0 0;}
8
- .icon-music{background-position:-24px 0;}
9
- .icon-search{background-position:-48px 0;}
10
- .icon-envelope{background-position:-72px 0;}
11
- .icon-heart{background-position:-96px 0;}
12
- .icon-star{background-position:-120px 0;}
13
- .icon-star-empty{background-position:-144px 0;}
14
- .icon-user{background-position:-168px 0;}
15
- .icon-film{background-position:-192px 0;}
16
- .icon-th-large{background-position:-216px 0;}
17
- .icon-th{background-position:-240px 0;}
18
- .icon-th-list{background-position:-264px 0;}
19
- .icon-ok{background-position:-288px 0;}
20
- .icon-remove{background-position:-312px 0;}
21
- .icon-zoom-in{background-position:-336px 0;}
22
- .icon-zoom-out{background-position:-360px 0;}
23
- .icon-off{background-position:-384px 0;}
24
- .icon-signal{background-position:-408px 0;}
25
- .icon-cog{background-position:-432px 0;}
26
- .icon-trash{background-position:-456px 0;}
27
- .icon-home{background-position:0 -24px;}
28
- .icon-file{background-position:-24px -24px;}
29
- .icon-time{background-position:-48px -24px;}
30
- .icon-road{background-position:-72px -24px;}
31
- .icon-download-alt{background-position:-96px -24px;}
32
- .icon-download{background-position:-120px -24px;}
33
- .icon-upload{background-position:-144px -24px;}
34
- .icon-inbox{background-position:-168px -24px;}
35
- .icon-play-circle{background-position:-192px -24px;}
36
- .icon-repeat{background-position:-216px -24px;}
37
- .icon-refresh{background-position:-240px -24px;}
38
- .icon-list-alt{background-position:-264px -24px;}
39
- .icon-lock{background-position:-287px -24px;}
40
- .icon-flag{background-position:-312px -24px;}
41
- .icon-headphones{background-position:-336px -24px;}
42
- .icon-volume-off{background-position:-360px -24px;}
43
- .icon-volume-down{background-position:-384px -24px;}
44
- .icon-volume-up{background-position:-408px -24px;}
45
- .icon-qrcode{background-position:-432px -24px;}
46
- .icon-barcode{background-position:-456px -24px;}
47
- .icon-tag{background-position:0 -48px;}
48
- .icon-tags{background-position:-25px -48px;}
49
- .icon-book{background-position:-48px -48px;}
50
- .icon-bookmark{background-position:-72px -48px;}
51
- .icon-print{background-position:-96px -48px;}
52
- .icon-camera{background-position:-120px -48px;}
53
- .icon-font{background-position:-144px -48px;}
54
- .icon-bold{background-position:-167px -48px;}
55
- .icon-italic{background-position:-192px -48px;}
56
- .icon-text-height{background-position:-216px -48px;}
57
- .icon-text-width{background-position:-240px -48px;}
58
- .icon-align-left{background-position:-264px -48px;}
59
- .icon-align-center{background-position:-288px -48px;}
60
- .icon-align-right{background-position:-312px -48px;}
61
- .icon-align-justify{background-position:-336px -48px;}
62
- .icon-list{background-position:-360px -48px;}
63
- .icon-indent-left{background-position:-384px -48px;}
64
- .icon-indent-right{background-position:-408px -48px;}
65
- .icon-facetime-video{background-position:-432px -48px;}
66
- .icon-picture{background-position:-456px -48px;}
67
- .icon-pencil{background-position:0 -72px;}
68
- .icon-map-marker{background-position:-24px -72px;}
69
- .icon-adjust{background-position:-48px -72px;}
70
- .icon-tint{background-position:-72px -72px;}
71
- .icon-edit{background-position:-96px -72px;}
72
- .icon-share{background-position:-120px -72px;}
73
- .icon-check{background-position:-144px -72px;}
74
- .icon-move{background-position:-168px -72px;}
75
- .icon-step-backward{background-position:-192px -72px;}
76
- .icon-fast-backward{background-position:-216px -72px;}
77
- .icon-backward{background-position:-240px -72px;}
78
- .icon-play{background-position:-264px -72px;}
79
- .icon-pause{background-position:-288px -72px;}
80
- .icon-stop{background-position:-312px -72px;}
81
- .icon-forward{background-position:-336px -72px;}
82
- .icon-fast-forward{background-position:-360px -72px;}
83
- .icon-step-forward{background-position:-384px -72px;}
84
- .icon-eject{background-position:-408px -72px;}
85
- .icon-chevron-left{background-position:-432px -72px;}
86
- .icon-chevron-right{background-position:-456px -72px;}
87
- .icon-plus-sign{background-position:0 -96px;}
88
- .icon-minus-sign{background-position:-24px -96px;}
89
- .icon-remove-sign{background-position:-48px -96px;}
90
- .icon-ok-sign{background-position:-72px -96px;}
91
- .icon-question-sign{background-position:-96px -96px;}
92
- .icon-info-sign{background-position:-120px -96px;}
93
- .icon-screenshot{background-position:-144px -96px;}
94
- .icon-remove-circle{background-position:-168px -96px;}
95
- .icon-ok-circle{background-position:-192px -96px;}
96
- .icon-ban-circle{background-position:-216px -96px;}
97
- .icon-arrow-left{background-position:-240px -96px;}
98
- .icon-arrow-right{background-position:-264px -96px;}
99
- .icon-arrow-up{background-position:-289px -96px;}
100
- .icon-arrow-down{background-position:-312px -96px;}
101
- .icon-share-alt{background-position:-336px -96px;}
102
- .icon-resize-full{background-position:-360px -96px;}
103
- .icon-resize-small{background-position:-384px -96px;}
104
- .icon-plus{background-position:-408px -96px;}
105
- .icon-minus{background-position:-433px -96px;}
106
- .icon-asterisk{background-position:-456px -96px;}
107
- .icon-exclamation-sign{background-position:0 -120px;}
108
- .icon-gift{background-position:-24px -120px;}
109
- .icon-leaf{background-position:-48px -120px;}
110
- .icon-fire{background-position:-72px -120px;}
111
- .icon-eye-open{background-position:-96px -120px;}
112
- .icon-eye-close{background-position:-120px -120px;}
113
- .icon-warning-sign{background-position:-144px -120px;}
114
- .icon-plane{background-position:-168px -120px;}
115
- .icon-calendar{background-position:-192px -120px;}
116
- .icon-random{background-position:-216px -120px;width:16px;}
117
- .icon-comment{background-position:-240px -120px;}
118
- .icon-magnet{background-position:-264px -120px;}
119
- .icon-chevron-up{background-position:-288px -120px;}
120
- .icon-chevron-down{background-position:-313px -119px;}
121
- .icon-retweet{background-position:-336px -120px;}
122
- .icon-shopping-cart{background-position:-360px -120px;}
123
- .icon-folder-close{background-position:-384px -120px;width:16px;}
124
- .icon-folder-open{background-position:-408px -120px;width:16px;}
125
- .icon-resize-vertical{background-position:-432px -119px;}
126
- .icon-resize-horizontal{background-position:-456px -118px;}
127
- .icon-hdd{background-position:0 -144px;}
128
- .icon-bullhorn{background-position:-24px -144px;}
129
- .icon-bell{background-position:-48px -144px;}
130
- .icon-certificate{background-position:-72px -144px;}
131
- .icon-thumbs-up{background-position:-96px -144px;}
132
- .icon-thumbs-down{background-position:-120px -144px;}
133
- .icon-hand-right{background-position:-144px -144px;}
134
- .icon-hand-left{background-position:-168px -144px;}
135
- .icon-hand-up{background-position:-192px -144px;}
136
- .icon-hand-down{background-position:-216px -144px;}
137
- .icon-circle-arrow-right{background-position:-240px -144px;}
138
- .icon-circle-arrow-left{background-position:-264px -144px;}
139
- .icon-circle-arrow-up{background-position:-288px -144px;}
140
- .icon-circle-arrow-down{background-position:-312px -144px;}
141
- .icon-globe{background-position:-336px -144px;}
142
- .icon-wrench{background-position:-360px -144px;}
143
- .icon-tasks{background-position:-384px -144px;}
144
- .icon-filter{background-position:-408px -144px;}
145
- .icon-briefcase{background-position:-432px -144px;}
146
- .icon-fullscreen{background-position:-456px -144px;}
1
+ @font-face{font-family:'Glyphicons Halflings';src:url('twitter/fonts/glyphicons-halflings-regular.eot');src:url('twitter/fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'),url('twitter/fonts/glyphicons-halflings-regular.woff') format('woff'),url('twitter/fonts/glyphicons-halflings-regular.ttf') format('truetype'),url('twitter/fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyphicons Halflings';font-style:normal;font-weight:normal;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\2a"}.glyphicon-plus:before{content:"\2b"}.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}
@@ -1,20 +1,22 @@
1
1
  module BootstrapFlashHelper
2
- ALERT_TYPES = [:error, :info, :success, :warning]
2
+ ALERT_TYPES = [:success, :info, :warning, :danger] unless const_defined?(:ALERT_TYPES)
3
3
 
4
- def bootstrap_flash
4
+ def bootstrap_flash(options = {})
5
5
  flash_messages = []
6
6
  flash.each do |type, message|
7
7
  # Skip empty messages, e.g. for devise messages set to nothing in a locale file.
8
8
  next if message.blank?
9
-
9
+
10
+ type = type.to_sym
10
11
  type = :success if type == :notice
11
- type = :error if type == :alert
12
+ type = :danger if type == :alert
13
+ type = :danger if type == :error
12
14
  next unless ALERT_TYPES.include?(type)
13
15
 
14
16
  Array(message).each do |msg|
15
17
  text = content_tag(:div,
16
18
  content_tag(:button, raw("&times;"), :class => "close", "data-dismiss" => "alert") +
17
- msg.html_safe, :class => "alert fade in alert-#{type}")
19
+ msg, :class => "alert fade in alert-#{type} #{options[:class]}")
18
20
  flash_messages << text if msg
19
21
  end
20
22
  end
@@ -0,0 +1,22 @@
1
+ module FormErrorsHelper
2
+
3
+ attr_reader :template
4
+ attr_reader :object
5
+
6
+ def error_span(attribute, options = {})
7
+ options[:class] ||= 'help-inline'
8
+
9
+ template.content_tag(
10
+ :span, self.errors_for(attribute),
11
+ :class => options[:class]
12
+ ) if self.errors_on?(attribute)
13
+ end
14
+
15
+ def errors_on?(attribute)
16
+ self.object.errors[attribute].present? if self.object.respond_to?(:errors)
17
+ end
18
+
19
+ def errors_for(attribute)
20
+ self.object.errors[attribute].try(:join, ', ')
21
+ end
22
+ end
@@ -1,17 +1,19 @@
1
1
  module GlyphHelper
2
2
  # ==== Examples
3
3
  # glyph(:share_alt)
4
- # # => <i class="icon-share-alt"></i>
4
+ # # => <span class="icon-share-alt"></span>
5
5
  # glyph(:lock, :white)
6
- # # => <i class="icon-lock icon-white"></i>
6
+ # # => <span class="icon-lock icon-white"></span>
7
7
  # glyph(:thumbs_up, :pull_left)
8
8
  # # => <i class="icon-thumbs-up pull-left"></i>
9
-
10
- def glyph(*names)
9
+ # glyph(:lock, {tag: :span})
10
+ # # => <span class="icon-lock"></span>
11
+ def glyph(*names, options)
11
12
  names.map! { |name| name.to_s.gsub('_','-') }
12
13
  names.map! do |name|
13
- name =~ /pull-(?:left|right)/ ? name : "icon-#{name}"
14
+ name =~ /pull-(?:left|right)/ ? name : "glyphicon glyphicon-#{name}"
14
15
  end
15
- content_tag :i, nil, :class => names
16
+ options[:tag] = options[:tag] ||= :i
17
+ content_tag options[:tag], nil, :class => names
16
18
  end
17
19
  end
@@ -1,55 +1,63 @@
1
1
  module ModalHelper
2
+
3
+ def default_options
4
+ return {:id => 'modal', :size => '', :show_close => true, :dismiss => true}
5
+ end
2
6
 
3
7
  #modals have a header, a body, a footer for options.
4
8
  def modal_dialog(options = {}, &block)
5
- content_tag :div, :id => options[:id], :class => "bootstrap-modal modal hide fade" do
6
- modal_header(options[:header]) +
7
- modal_body(options[:body]) +
8
- modal_footer(options[:footer])
9
+ opts = default_options.merge(options)
10
+ content_tag :div, :id => options[:id], :class => "bootstrap-modal modal fade" do
11
+ content_tag :div, :class => "modal-dialog #{opts['size']}" do
12
+ content_tag :div, :class => "modal-content" do
13
+ modal_header(opts, &block) +
14
+ modal_body(opts, &block) +
15
+ modal_footer(opts, &block)
16
+ end
17
+ end
9
18
  end
10
19
  end
11
20
 
12
- def modal_header(options = {}, &block)
21
+ def modal_header(options, &block)
13
22
  content_tag :div, :class => 'modal-header' do
14
23
  if options[:show_close]
15
24
  close_button(options[:dismiss]) +
16
- content_tag(:h3, options[:title], &block)
25
+ content_tag(:h4, options[:title], :class => 'modal-title', &block)
17
26
  else
18
- content_tag(:h3, options[:title], &block)
19
- end
27
+ content_tag(:h4, options[:title], :class => 'modal-title', &block)
28
+ end
20
29
  end
21
30
  end
22
31
 
23
- def modal_body(options = {}, &block)
24
- content_tag :div, options, :class => 'modal-body', &block
32
+ def modal_body(options, &block)
33
+ content_tag :div, options[:content], :class => 'modal-body', :style => options[:style], &block
25
34
  end
26
35
 
27
- def modal_footer(options = {}, &block)
28
- content_tag :div, options, :class => 'modal-footer', &block
36
+ def modal_footer(options, &block)
37
+ content_tag :div, options[:content], :class => 'modal-footer', &block
29
38
  end
30
39
 
31
40
  def close_button(dismiss)
32
- #It doesn't seem to like content_tag, so we do this instead.
33
- raw("<button class=\"close\" data-dismiss=\"#{dismiss}\">&times;</button>")
41
+ #It doesn't seem to like content_tag, so we do this instead.
42
+ raw("<button class=\"close\" data-dismiss=\"#{dismiss}\" aria-hidden=\"true\">&times;</button>")
34
43
  end
35
44
 
36
- def modal_toggle(content_or_options = nil, options = {}, &block)
45
+ def modal_toggle(content_or_options = nil, options, &block)
37
46
  if block_given?
38
47
  options = content_or_options if content_or_options.is_a?(Hash)
39
- default_options = { :class => 'btn', "data-toggle" => "modal", "href" => options[:dialog] }.merge(options)
48
+ default_options = { :class => 'btn btn-default', "data-toggle" => "modal", "href" => options[:dialog] }.merge(options)
40
49
 
41
50
  content_tag :a, nil, default_options, true, &block
42
51
  else
43
- default_options = { :class => 'btn', "data-toggle" => "modal", "href" => options[:dialog] }.merge(options)
52
+ default_options = { :class => 'btn btn-default', "data-toggle" => "modal", "href" => options[:dialog] }.merge(options)
44
53
  content_tag :a, content_or_options, default_options, true
45
54
  end
46
55
  end
47
56
 
48
- def modal_cancel_button content, options = {}
49
- default_options = { :class => "btn bootstrap-modal-cancel-button" }
57
+ def modal_cancel_button(content, options)
58
+ default_opts = { :class => "btn bootstrap-modal-cancel-button" }
50
59
 
51
- content_tag_string "a", content, default_options.merge(options)
60
+ content_tag_string "a", content, default_opts.merge(options)
52
61
  end
53
62
 
54
63
  end
55
-
@@ -1,18 +1,16 @@
1
1
  #Credit for this goes to https://github.com/julescopeland/Rails-Bootstrap-Navbar
2
2
  module NavbarHelper
3
3
  def nav_bar(options={}, &block)
4
- nav_bar_div(options) do
5
- navbar_inner_div do
6
- container_div(options[:brand], options[:brand_link], options[:responsive], options[:fluid]) do
7
- yield if block_given?
8
- end
4
+ nav_bar_nav(options) do
5
+ container_div(options[:brand], options[:brand_link], options[:responsive], options[:fluid], options[:no_turbolink]) do
6
+ yield if block_given?
9
7
  end
10
8
  end
11
9
  end
12
10
 
13
11
  def menu_group(options={}, &block)
14
- pull_class = "pull-#{options[:pull].to_s}" if options[:pull].present?
15
- content_tag(:ul, :class => "nav #{pull_class}", &block)
12
+ pull_class = "navbar-#{options[:pull].to_s}" if options[:pull].present?
13
+ content_tag(:ul, :class => "nav navbar-nav #{pull_class}", &block)
16
14
  end
17
15
 
18
16
  def menu_item(name=nil, path="#", *args, &block)
@@ -76,6 +74,8 @@ module NavbarHelper
76
74
  # uri_state('/blog/categories/test', {method: delete}) # :inactive
77
75
  # uri_state('/blog/categories/test/3', {}) # :inactive
78
76
  def uri_state(uri, options={})
77
+ return options[:status] if options.key?(:status)
78
+
79
79
  root_url = request.host_with_port + '/'
80
80
  root = uri == '/' || uri == root_url
81
81
 
@@ -87,7 +87,7 @@ module NavbarHelper
87
87
 
88
88
  if !options[:method].nil? || !options["data-method"].nil?
89
89
  :inactive
90
- elsif uri == request_uri
90
+ elsif uri == request_uri || (options[:root] && (request_uri == '/') || (request_uri == root_url))
91
91
  :active
92
92
  else
93
93
  if request_uri.start_with?(uri) and not(root)
@@ -96,73 +96,85 @@ module NavbarHelper
96
96
  :inactive
97
97
  end
98
98
  end
99
- end
99
+ end
100
100
 
101
101
  private
102
102
 
103
- def nav_bar_div(options, &block)
103
+ def nav_bar_nav(options, &block)
104
104
 
105
105
  position = "static-#{options[:static].to_s}" if options[:static]
106
106
  position = "fixed-#{options[:fixed].to_s}" if options[:fixed]
107
107
  inverse = (options[:inverse].present? && options[:inverse] == true) ? true : false
108
108
 
109
- content_tag :div, :class => nav_bar_css_class(position, inverse) do
109
+ content_tag :nav, :class => nav_bar_css_class(position, inverse), :role => "navigation" do
110
110
  yield
111
111
  end
112
112
  end
113
113
 
114
- def navbar_inner_div(&block)
115
- content_tag :div, :class => "navbar-inner" do
116
- yield
117
- end
118
- end
114
+ def container_div(brand, brand_link, responsive, fluid, no_turbolink, &block)
115
+ div_container_class = fluid ? "container-fluid" : "container"
116
+ no_turbolink ||= false
119
117
 
120
- def container_div(brand, brand_link, responsive, fluid, &block)
121
- content_tag :div, :class => "container#{"-fluid" if fluid}" do
122
- container_div_with_block(brand, brand_link, responsive, &block)
118
+ content_tag :div, :class => div_container_class do
119
+ container_div_with_block(brand, brand_link, responsive, no_turbolink, &block)
123
120
  end
124
121
  end
125
122
 
126
- def container_div_with_block(brand, brand_link, responsive, &block)
123
+ def container_div_with_block(brand, brand_link, responsive, no_turbolink, &block)
127
124
  output = []
128
125
  if responsive == true
129
- output << responsive_button
130
- output << brand_link(brand, brand_link)
126
+ output << responsive_nav_header(brand, brand_link, no_turbolink)
131
127
  output << responsive_div { capture(&block) }
132
128
  else
133
- output << brand_link(brand, brand_link)
129
+ output << brand_link(brand, brand_link, no_turbolink)
134
130
  output << capture(&block)
135
131
  end
136
132
  output.join("\n").html_safe
137
133
  end
138
134
 
135
+ def responsive_nav_header(brand, brand_link, no_turbolink)
136
+ content_tag(:div, :class => "navbar-header") do
137
+ output = []
138
+ output << responsive_button
139
+ output << brand_link(brand, brand_link, no_turbolink)
140
+ output.join("\n").html_safe
141
+ end
142
+ end
143
+
139
144
  def nav_bar_css_class(position, inverse = false)
140
- css_class = ["navbar"]
145
+ css_class = ["navbar", "navbar-default"]
141
146
  css_class << "navbar-#{position}" if position.present?
142
147
  css_class << "navbar-inverse" if inverse
143
148
  css_class.join(" ")
144
149
  end
145
150
 
146
- def brand_link(name, url)
151
+ def brand_link(name, url, no_turbolink)
147
152
  return "" if name.blank?
148
153
  url ||= root_url
149
- link_to(name, url, :class => "brand")
154
+
155
+ if no_turbolink
156
+ link_to(name, url, :class => "navbar-brand", :data => { :no_turbolink => true})
157
+ else
158
+ link_to(name, url, :class => "navbar-brand")
159
+ end
150
160
  end
151
161
 
152
162
  def responsive_button
153
- %{<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
163
+ %{<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
164
+ <span class="sr-only">Toggle navigation</span>
154
165
  <span class="icon-bar"></span>
155
166
  <span class="icon-bar"></span>
156
167
  <span class="icon-bar"></span>
157
- </a>}
168
+ </button>}
158
169
  end
159
170
 
160
171
  def responsive_div(&block)
161
- content_tag(:div, :class => "nav-collapse collapse", &block)
172
+ content_tag(:div, :class => "navbar-collapse collapse", &block)
162
173
  end
163
174
 
164
175
  def is_active?(path, options={})
165
- "active" if uri_state(path, options).in?([:active, :chosen])
176
+ state = uri_state(path, options)
177
+ "active" if state.in?([:active, :chosen]) || state === true
166
178
  end
167
179
 
168
180
  def name_and_caret(name)