bootstrap-sass 2.3.1.3 → 3.0.0.0

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

Potentially problematic release.


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

Files changed (147) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +15 -0
  3. data/.travis.yml +12 -0
  4. data/CHANGELOG.md +104 -0
  5. data/CONTRIBUTING.md +79 -0
  6. data/Gemfile +3 -0
  7. data/README.md +114 -78
  8. data/Rakefile +48 -0
  9. data/bootstrap-sass.gemspec +28 -0
  10. data/lib/bootstrap-sass/engine.rb +4 -2
  11. data/lib/bootstrap-sass/version.rb +4 -0
  12. data/lib/bootstrap-sass.rb +10 -5
  13. data/tasks/converter.rb +829 -0
  14. data/templates/project/_variables.scss.erb +3 -0
  15. data/templates/project/manifest.rb +10 -13
  16. data/templates/project/styles.scss +1 -6
  17. data/test/compass_test.rb +8 -0
  18. data/test/compilation_test.rb +13 -0
  19. data/test/dummy/README.rdoc +3 -0
  20. data/test/dummy/Rakefile +6 -0
  21. data/test/dummy/app/assets/images/.keep +0 -0
  22. data/test/dummy/app/assets/javascripts/application.js +2 -0
  23. data/test/dummy/app/assets/stylesheets/application.css.sass +1 -0
  24. data/test/dummy/app/controllers/application_controller.rb +5 -0
  25. data/test/dummy/app/controllers/pages_controller.rb +4 -0
  26. data/test/dummy/app/helpers/application_helper.rb +2 -0
  27. data/test/dummy/app/views/layouts/application.html.erb +14 -0
  28. data/test/dummy/app/views/pages/root.html.slim +11 -0
  29. data/test/dummy/bin/bundle +3 -0
  30. data/test/dummy/bin/rails +4 -0
  31. data/test/dummy/bin/rake +4 -0
  32. data/test/dummy/config/application.rb +17 -0
  33. data/test/dummy/config/boot.rb +5 -0
  34. data/test/dummy/config/environment.rb +5 -0
  35. data/test/dummy/config/environments/development.rb +26 -0
  36. data/test/dummy/config/environments/production.rb +76 -0
  37. data/test/dummy/config/environments/test.rb +30 -0
  38. data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
  39. data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
  40. data/test/dummy/config/initializers/inflections.rb +16 -0
  41. data/test/dummy/config/initializers/mime_types.rb +5 -0
  42. data/test/dummy/config/initializers/secret_token.rb +18 -0
  43. data/test/dummy/config/initializers/session_store.rb +3 -0
  44. data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
  45. data/test/dummy/config/locales/en.yml +3 -0
  46. data/test/dummy/config/locales/es.yml +3 -0
  47. data/test/dummy/config/routes.rb +3 -0
  48. data/test/dummy/config.ru +4 -0
  49. data/test/dummy/db/test.sqlite3 +0 -0
  50. data/test/dummy/lib/assets/.keep +0 -0
  51. data/test/dummy/log/.keep +0 -0
  52. data/test/dummy/log/development.log +0 -0
  53. data/test/dummy/public/404.html +58 -0
  54. data/test/dummy/public/422.html +58 -0
  55. data/test/dummy/public/500.html +57 -0
  56. data/test/dummy/public/favicon.ico +0 -0
  57. data/test/gemfiles/sass_3_2.gemfile +5 -0
  58. data/test/gemfiles/sass_head.gemfile +6 -0
  59. data/test/pages_test.rb +14 -0
  60. data/test/support/integration_test.rb +29 -0
  61. data/test/test_helper.rb +32 -0
  62. data/vendor/assets/fonts/bootstrap/glyphicons-halflings-regular.eot +0 -0
  63. data/vendor/assets/fonts/bootstrap/glyphicons-halflings-regular.svg +228 -0
  64. data/vendor/assets/fonts/bootstrap/glyphicons-halflings-regular.ttf +0 -0
  65. data/vendor/assets/fonts/bootstrap/glyphicons-halflings-regular.woff +0 -0
  66. data/vendor/assets/javascripts/bootstrap/affix.js +126 -0
  67. data/vendor/assets/javascripts/bootstrap/alert.js +98 -0
  68. data/vendor/assets/javascripts/bootstrap/button.js +109 -0
  69. data/vendor/assets/javascripts/bootstrap/carousel.js +217 -0
  70. data/vendor/assets/javascripts/bootstrap/collapse.js +179 -0
  71. data/vendor/assets/javascripts/bootstrap/dropdown.js +154 -0
  72. data/vendor/assets/javascripts/bootstrap/modal.js +246 -0
  73. data/vendor/assets/javascripts/bootstrap/popover.js +117 -0
  74. data/vendor/assets/javascripts/bootstrap/scrollspy.js +158 -0
  75. data/vendor/assets/javascripts/bootstrap/tab.js +135 -0
  76. data/vendor/assets/javascripts/bootstrap/tooltip.js +386 -0
  77. data/vendor/assets/javascripts/bootstrap/transition.js +56 -0
  78. data/vendor/assets/javascripts/bootstrap.js +12 -13
  79. data/vendor/assets/stylesheets/bootstrap/_alerts.scss +46 -58
  80. data/vendor/assets/stylesheets/bootstrap/_badges.scss +51 -0
  81. data/vendor/assets/stylesheets/bootstrap/_breadcrumbs.scss +8 -9
  82. data/vendor/assets/stylesheets/bootstrap/_button-groups.scss +173 -154
  83. data/vendor/assets/stylesheets/bootstrap/_buttons.scss +97 -165
  84. data/vendor/assets/stylesheets/bootstrap/_carousel.scss +116 -65
  85. data/vendor/assets/stylesheets/bootstrap/_close.scss +11 -8
  86. data/vendor/assets/stylesheets/bootstrap/_code.scss +16 -21
  87. data/vendor/assets/stylesheets/bootstrap/_component-animations.scss +10 -3
  88. data/vendor/assets/stylesheets/bootstrap/_dropdowns.scss +103 -146
  89. data/vendor/assets/stylesheets/bootstrap/_forms.scss +222 -559
  90. data/vendor/assets/stylesheets/bootstrap/_glyphicons.scss +232 -0
  91. data/vendor/assets/stylesheets/bootstrap/_grid.scss +336 -11
  92. data/vendor/assets/stylesheets/bootstrap/_input-groups.scss +127 -0
  93. data/vendor/assets/stylesheets/bootstrap/_jumbotron.scss +40 -0
  94. data/vendor/assets/stylesheets/bootstrap/_labels.scss +58 -0
  95. data/vendor/assets/stylesheets/bootstrap/_list-group.scss +90 -0
  96. data/vendor/assets/stylesheets/bootstrap/_media.scss +8 -7
  97. data/vendor/assets/stylesheets/bootstrap/_mixins.scss +470 -430
  98. data/vendor/assets/stylesheets/bootstrap/_modals.scss +103 -52
  99. data/vendor/assets/stylesheets/bootstrap/_navbar.scss +511 -383
  100. data/vendor/assets/stylesheets/bootstrap/_navs.scss +169 -349
  101. data/vendor/assets/stylesheets/bootstrap/_normalize.scss +396 -0
  102. data/vendor/assets/stylesheets/bootstrap/_pager.scss +45 -33
  103. data/vendor/assets/stylesheets/bootstrap/_pagination.scss +65 -105
  104. data/vendor/assets/stylesheets/bootstrap/_panels.scss +148 -0
  105. data/vendor/assets/stylesheets/bootstrap/_popovers.scss +51 -51
  106. data/vendor/assets/stylesheets/bootstrap/_print.scss +100 -0
  107. data/vendor/assets/stylesheets/bootstrap/_progress-bars.scss +28 -55
  108. data/vendor/assets/stylesheets/bootstrap/_responsive-utilities.scss +180 -45
  109. data/vendor/assets/stylesheets/bootstrap/_scaffolding.scss +101 -24
  110. data/vendor/assets/stylesheets/bootstrap/_tables.scss +169 -168
  111. data/vendor/assets/stylesheets/bootstrap/_theme.scss +232 -0
  112. data/vendor/assets/stylesheets/bootstrap/_thumbnails.scss +11 -33
  113. data/vendor/assets/stylesheets/bootstrap/_tooltip.scss +45 -20
  114. data/vendor/assets/stylesheets/bootstrap/_type.scss +101 -110
  115. data/vendor/assets/stylesheets/bootstrap/_utilities.scss +19 -22
  116. data/vendor/assets/stylesheets/bootstrap/_variables.scss +498 -179
  117. data/vendor/assets/stylesheets/bootstrap/_wells.scss +7 -7
  118. data/vendor/assets/stylesheets/bootstrap/bootstrap.scss +29 -33
  119. metadata +226 -44
  120. data/templates/project/_variables.scss +0 -301
  121. data/vendor/assets/images/glyphicons-halflings-white.png +0 -0
  122. data/vendor/assets/images/glyphicons-halflings.png +0 -0
  123. data/vendor/assets/javascripts/bootstrap-affix.js +0 -117
  124. data/vendor/assets/javascripts/bootstrap-alert.js +0 -99
  125. data/vendor/assets/javascripts/bootstrap-button.js +0 -105
  126. data/vendor/assets/javascripts/bootstrap-carousel.js +0 -207
  127. data/vendor/assets/javascripts/bootstrap-collapse.js +0 -167
  128. data/vendor/assets/javascripts/bootstrap-dropdown.js +0 -165
  129. data/vendor/assets/javascripts/bootstrap-modal.js +0 -247
  130. data/vendor/assets/javascripts/bootstrap-popover.js +0 -114
  131. data/vendor/assets/javascripts/bootstrap-scrollspy.js +0 -162
  132. data/vendor/assets/javascripts/bootstrap-tab.js +0 -144
  133. data/vendor/assets/javascripts/bootstrap-tooltip.js +0 -361
  134. data/vendor/assets/javascripts/bootstrap-transition.js +0 -60
  135. data/vendor/assets/javascripts/bootstrap-typeahead.js +0 -335
  136. data/vendor/assets/stylesheets/bootstrap/_accordion.scss +0 -34
  137. data/vendor/assets/stylesheets/bootstrap/_hero-unit.scss +0 -25
  138. data/vendor/assets/stylesheets/bootstrap/_labels-badges.scss +0 -83
  139. data/vendor/assets/stylesheets/bootstrap/_layouts.scss +0 -16
  140. data/vendor/assets/stylesheets/bootstrap/_reset.scss +0 -216
  141. data/vendor/assets/stylesheets/bootstrap/_responsive-1200px-min.scss +0 -28
  142. data/vendor/assets/stylesheets/bootstrap/_responsive-767px-max.scss +0 -193
  143. data/vendor/assets/stylesheets/bootstrap/_responsive-768px-979px.scss +0 -19
  144. data/vendor/assets/stylesheets/bootstrap/_responsive-navbar.scss +0 -189
  145. data/vendor/assets/stylesheets/bootstrap/_sprites.scss +0 -197
  146. data/vendor/assets/stylesheets/bootstrap/responsive.scss +0 -48
  147. data/vendor/assets/stylesheets/bootstrap-responsive.scss +0 -1
@@ -0,0 +1,386 @@
1
+ /* ========================================================================
2
+ * Bootstrap: tooltip.js v3.0.0
3
+ * http://twbs.github.com/bootstrap/javascript.html#tooltip
4
+ * Inspired by the original jQuery.tipsy by Jason Frame
5
+ * ========================================================================
6
+ * Copyright 2012 Twitter, Inc.
7
+ *
8
+ * Licensed under the Apache License, Version 2.0 (the "License");
9
+ * you may not use this file except in compliance with the License.
10
+ * You may obtain a copy of the License at
11
+ *
12
+ * http://www.apache.org/licenses/LICENSE-2.0
13
+ *
14
+ * Unless required by applicable law or agreed to in writing, software
15
+ * distributed under the License is distributed on an "AS IS" BASIS,
16
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
+ * See the License for the specific language governing permissions and
18
+ * limitations under the License.
19
+ * ======================================================================== */
20
+
21
+
22
+ +function ($) { "use strict";
23
+
24
+ // TOOLTIP PUBLIC CLASS DEFINITION
25
+ // ===============================
26
+
27
+ var Tooltip = function (element, options) {
28
+ this.type =
29
+ this.options =
30
+ this.enabled =
31
+ this.timeout =
32
+ this.hoverState =
33
+ this.$element = null
34
+
35
+ this.init('tooltip', element, options)
36
+ }
37
+
38
+ Tooltip.DEFAULTS = {
39
+ animation: true
40
+ , placement: 'top'
41
+ , selector: false
42
+ , template: '<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>'
43
+ , trigger: 'hover focus'
44
+ , title: ''
45
+ , delay: 0
46
+ , html: false
47
+ , container: false
48
+ }
49
+
50
+ Tooltip.prototype.init = function (type, element, options) {
51
+ this.enabled = true
52
+ this.type = type
53
+ this.$element = $(element)
54
+ this.options = this.getOptions(options)
55
+
56
+ var triggers = this.options.trigger.split(' ')
57
+
58
+ for (var i = triggers.length; i--;) {
59
+ var trigger = triggers[i]
60
+
61
+ if (trigger == 'click') {
62
+ this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this))
63
+ } else if (trigger != 'manual') {
64
+ var eventIn = trigger == 'hover' ? 'mouseenter' : 'focus'
65
+ var eventOut = trigger == 'hover' ? 'mouseleave' : 'blur'
66
+
67
+ this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this))
68
+ this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this))
69
+ }
70
+ }
71
+
72
+ this.options.selector ?
73
+ (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) :
74
+ this.fixTitle()
75
+ }
76
+
77
+ Tooltip.prototype.getDefaults = function () {
78
+ return Tooltip.DEFAULTS
79
+ }
80
+
81
+ Tooltip.prototype.getOptions = function (options) {
82
+ options = $.extend({}, this.getDefaults(), this.$element.data(), options)
83
+
84
+ if (options.delay && typeof options.delay == 'number') {
85
+ options.delay = {
86
+ show: options.delay
87
+ , hide: options.delay
88
+ }
89
+ }
90
+
91
+ return options
92
+ }
93
+
94
+ Tooltip.prototype.getDelegateOptions = function () {
95
+ var options = {}
96
+ var defaults = this.getDefaults()
97
+
98
+ this._options && $.each(this._options, function (key, value) {
99
+ if (defaults[key] != value) options[key] = value
100
+ })
101
+
102
+ return options
103
+ }
104
+
105
+ Tooltip.prototype.enter = function (obj) {
106
+ var self = obj instanceof this.constructor ?
107
+ obj : $(obj.currentTarget)[this.type](this.getDelegateOptions()).data('bs.' + this.type)
108
+
109
+ clearTimeout(self.timeout)
110
+
111
+ self.hoverState = 'in'
112
+
113
+ if (!self.options.delay || !self.options.delay.show) return self.show()
114
+
115
+ self.timeout = setTimeout(function () {
116
+ if (self.hoverState == 'in') self.show()
117
+ }, self.options.delay.show)
118
+ }
119
+
120
+ Tooltip.prototype.leave = function (obj) {
121
+ var self = obj instanceof this.constructor ?
122
+ obj : $(obj.currentTarget)[this.type](this.getDelegateOptions()).data('bs.' + this.type)
123
+
124
+ clearTimeout(self.timeout)
125
+
126
+ self.hoverState = 'out'
127
+
128
+ if (!self.options.delay || !self.options.delay.hide) return self.hide()
129
+
130
+ self.timeout = setTimeout(function () {
131
+ if (self.hoverState == 'out') self.hide()
132
+ }, self.options.delay.hide)
133
+ }
134
+
135
+ Tooltip.prototype.show = function () {
136
+ var e = $.Event('show.bs.'+ this.type)
137
+
138
+ if (this.hasContent() && this.enabled) {
139
+ this.$element.trigger(e)
140
+
141
+ if (e.isDefaultPrevented()) return
142
+
143
+ var $tip = this.tip()
144
+
145
+ this.setContent()
146
+
147
+ if (this.options.animation) $tip.addClass('fade')
148
+
149
+ var placement = typeof this.options.placement == 'function' ?
150
+ this.options.placement.call(this, $tip[0], this.$element[0]) :
151
+ this.options.placement
152
+
153
+ var autoToken = /\s?auto?\s?/i
154
+ var autoPlace = autoToken.test(placement)
155
+ if (autoPlace) placement = placement.replace(autoToken, '') || 'top'
156
+
157
+ $tip
158
+ .detach()
159
+ .css({ top: 0, left: 0, display: 'block' })
160
+ .addClass(placement)
161
+
162
+ this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
163
+
164
+ var pos = this.getPosition()
165
+ var actualWidth = $tip[0].offsetWidth
166
+ var actualHeight = $tip[0].offsetHeight
167
+
168
+ if (autoPlace) {
169
+ var $parent = this.$element.parent()
170
+
171
+ var orgPlacement = placement
172
+ var docScroll = document.documentElement.scrollTop || document.body.scrollTop
173
+ var parentWidth = this.options.container == 'body' ? window.innerWidth : $parent.outerWidth()
174
+ var parentHeight = this.options.container == 'body' ? window.innerHeight : $parent.outerHeight()
175
+ var parentLeft = this.options.container == 'body' ? 0 : $parent.offset().left
176
+
177
+ placement = placement == 'bottom' && pos.top + pos.height + actualHeight - docScroll > parentHeight ? 'top' :
178
+ placement == 'top' && pos.top - docScroll - actualHeight < 0 ? 'bottom' :
179
+ placement == 'right' && pos.right + actualWidth > parentWidth ? 'left' :
180
+ placement == 'left' && pos.left - actualWidth < parentLeft ? 'right' :
181
+ placement
182
+
183
+ $tip
184
+ .removeClass(orgPlacement)
185
+ .addClass(placement)
186
+ }
187
+
188
+ var calculatedOffset = this.getCalculatedOffset(placement, pos, actualWidth, actualHeight)
189
+
190
+ this.applyPlacement(calculatedOffset, placement)
191
+ this.$element.trigger('shown.bs.' + this.type)
192
+ }
193
+ }
194
+
195
+ Tooltip.prototype.applyPlacement = function(offset, placement) {
196
+ var replace
197
+ var $tip = this.tip()
198
+ var width = $tip[0].offsetWidth
199
+ var height = $tip[0].offsetHeight
200
+
201
+ // manually read margins because getBoundingClientRect includes difference
202
+ var marginTop = parseInt($tip.css('margin-top'), 10)
203
+ var marginLeft = parseInt($tip.css('margin-left'), 10)
204
+
205
+ // we must check for NaN for ie 8/9
206
+ if (isNaN(marginTop)) marginTop = 0
207
+ if (isNaN(marginLeft)) marginLeft = 0
208
+
209
+ offset.top = offset.top + marginTop
210
+ offset.left = offset.left + marginLeft
211
+
212
+ $tip
213
+ .offset(offset)
214
+ .addClass('in')
215
+
216
+ // check to see if placing tip in new offset caused the tip to resize itself
217
+ var actualWidth = $tip[0].offsetWidth
218
+ var actualHeight = $tip[0].offsetHeight
219
+
220
+ if (placement == 'top' && actualHeight != height) {
221
+ replace = true
222
+ offset.top = offset.top + height - actualHeight
223
+ }
224
+
225
+ if (/bottom|top/.test(placement)) {
226
+ var delta = 0
227
+
228
+ if (offset.left < 0) {
229
+ delta = offset.left * -2
230
+ offset.left = 0
231
+
232
+ $tip.offset(offset)
233
+
234
+ actualWidth = $tip[0].offsetWidth
235
+ actualHeight = $tip[0].offsetHeight
236
+ }
237
+
238
+ this.replaceArrow(delta - width + actualWidth, actualWidth, 'left')
239
+ } else {
240
+ this.replaceArrow(actualHeight - height, actualHeight, 'top')
241
+ }
242
+
243
+ if (replace) $tip.offset(offset)
244
+ }
245
+
246
+ Tooltip.prototype.replaceArrow = function(delta, dimension, position) {
247
+ this.arrow().css(position, delta ? (50 * (1 - delta / dimension) + "%") : '')
248
+ }
249
+
250
+ Tooltip.prototype.setContent = function () {
251
+ var $tip = this.tip()
252
+ var title = this.getTitle()
253
+
254
+ $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title)
255
+ $tip.removeClass('fade in top bottom left right')
256
+ }
257
+
258
+ Tooltip.prototype.hide = function () {
259
+ var that = this
260
+ var $tip = this.tip()
261
+ var e = $.Event('hide.bs.' + this.type)
262
+
263
+ function complete() {
264
+ if (that.hoverState != 'in') $tip.detach()
265
+ }
266
+
267
+ this.$element.trigger(e)
268
+
269
+ if (e.isDefaultPrevented()) return
270
+
271
+ $tip.removeClass('in')
272
+
273
+ $.support.transition && this.$tip.hasClass('fade') ?
274
+ $tip
275
+ .one($.support.transition.end, complete)
276
+ .emulateTransitionEnd(150) :
277
+ complete()
278
+
279
+ this.$element.trigger('hidden.bs.' + this.type)
280
+
281
+ return this
282
+ }
283
+
284
+ Tooltip.prototype.fixTitle = function () {
285
+ var $e = this.$element
286
+ if ($e.attr('title') || typeof($e.attr('data-original-title')) != 'string') {
287
+ $e.attr('data-original-title', $e.attr('title') || '').attr('title', '')
288
+ }
289
+ }
290
+
291
+ Tooltip.prototype.hasContent = function () {
292
+ return this.getTitle()
293
+ }
294
+
295
+ Tooltip.prototype.getPosition = function () {
296
+ var el = this.$element[0]
297
+ return $.extend({}, (typeof el.getBoundingClientRect == 'function') ? el.getBoundingClientRect() : {
298
+ width: el.offsetWidth
299
+ , height: el.offsetHeight
300
+ }, this.$element.offset())
301
+ }
302
+
303
+ Tooltip.prototype.getCalculatedOffset = function (placement, pos, actualWidth, actualHeight) {
304
+ return placement == 'bottom' ? { top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2 } :
305
+ placement == 'top' ? { top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2 } :
306
+ placement == 'left' ? { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth } :
307
+ /* placement == 'right' */ { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width }
308
+ }
309
+
310
+ Tooltip.prototype.getTitle = function () {
311
+ var title
312
+ var $e = this.$element
313
+ var o = this.options
314
+
315
+ title = $e.attr('data-original-title')
316
+ || (typeof o.title == 'function' ? o.title.call($e[0]) : o.title)
317
+
318
+ return title
319
+ }
320
+
321
+ Tooltip.prototype.tip = function () {
322
+ return this.$tip = this.$tip || $(this.options.template)
323
+ }
324
+
325
+ Tooltip.prototype.arrow = function () {
326
+ return this.$arrow = this.$arrow || this.tip().find('.tooltip-arrow')
327
+ }
328
+
329
+ Tooltip.prototype.validate = function () {
330
+ if (!this.$element[0].parentNode) {
331
+ this.hide()
332
+ this.$element = null
333
+ this.options = null
334
+ }
335
+ }
336
+
337
+ Tooltip.prototype.enable = function () {
338
+ this.enabled = true
339
+ }
340
+
341
+ Tooltip.prototype.disable = function () {
342
+ this.enabled = false
343
+ }
344
+
345
+ Tooltip.prototype.toggleEnabled = function () {
346
+ this.enabled = !this.enabled
347
+ }
348
+
349
+ Tooltip.prototype.toggle = function (e) {
350
+ var self = e ? $(e.currentTarget)[this.type](this.getDelegateOptions()).data('bs.' + this.type) : this
351
+ self.tip().hasClass('in') ? self.leave(self) : self.enter(self)
352
+ }
353
+
354
+ Tooltip.prototype.destroy = function () {
355
+ this.hide().$element.off('.' + this.type).removeData('bs.' + this.type)
356
+ }
357
+
358
+
359
+ // TOOLTIP PLUGIN DEFINITION
360
+ // =========================
361
+
362
+ var old = $.fn.tooltip
363
+
364
+ $.fn.tooltip = function (option) {
365
+ return this.each(function () {
366
+ var $this = $(this)
367
+ var data = $this.data('bs.tooltip')
368
+ var options = typeof option == 'object' && option
369
+
370
+ if (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options)))
371
+ if (typeof option == 'string') data[option]()
372
+ })
373
+ }
374
+
375
+ $.fn.tooltip.Constructor = Tooltip
376
+
377
+
378
+ // TOOLTIP NO CONFLICT
379
+ // ===================
380
+
381
+ $.fn.tooltip.noConflict = function () {
382
+ $.fn.tooltip = old
383
+ return this
384
+ }
385
+
386
+ }(window.jQuery);
@@ -0,0 +1,56 @@
1
+ /* ========================================================================
2
+ * Bootstrap: transition.js v3.0.0
3
+ * http://twbs.github.com/bootstrap/javascript.html#transitions
4
+ * ========================================================================
5
+ * Copyright 2013 Twitter, Inc.
6
+ *
7
+ * Licensed under the Apache License, Version 2.0 (the "License");
8
+ * you may not use this file except in compliance with the License.
9
+ * You may obtain a copy of the License at
10
+ *
11
+ * http://www.apache.org/licenses/LICENSE-2.0
12
+ *
13
+ * Unless required by applicable law or agreed to in writing, software
14
+ * distributed under the License is distributed on an "AS IS" BASIS,
15
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ * See the License for the specific language governing permissions and
17
+ * limitations under the License.
18
+ * ======================================================================== */
19
+
20
+
21
+ +function ($) { "use strict";
22
+
23
+ // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
24
+ // ============================================================
25
+
26
+ function transitionEnd() {
27
+ var el = document.createElement('bootstrap')
28
+
29
+ var transEndEventNames = {
30
+ 'WebkitTransition' : 'webkitTransitionEnd'
31
+ , 'MozTransition' : 'transitionend'
32
+ , 'OTransition' : 'oTransitionEnd otransitionend'
33
+ , 'transition' : 'transitionend'
34
+ }
35
+
36
+ for (var name in transEndEventNames) {
37
+ if (el.style[name] !== undefined) {
38
+ return { end: transEndEventNames[name] }
39
+ }
40
+ }
41
+ }
42
+
43
+ // http://blog.alexmaccaw.com/css-transitions
44
+ $.fn.emulateTransitionEnd = function (duration) {
45
+ var called = false, $el = this
46
+ $(this).one($.support.transition.end, function () { called = true })
47
+ var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
48
+ setTimeout(callback, duration)
49
+ return this
50
+ }
51
+
52
+ $(function () {
53
+ $.support.transition = transitionEnd()
54
+ })
55
+
56
+ }(window.jQuery);
@@ -1,13 +1,12 @@
1
- //= require bootstrap-transition
2
- //= require bootstrap-affix
3
- //= require bootstrap-alert
4
- //= require bootstrap-button
5
- //= require bootstrap-carousel
6
- //= require bootstrap-collapse
7
- //= require bootstrap-dropdown
8
- //= require bootstrap-modal
9
- //= require bootstrap-scrollspy
10
- //= require bootstrap-tab
11
- //= require bootstrap-tooltip
12
- //= require bootstrap-popover
13
- //= require bootstrap-typeahead
1
+ //= require bootstrap/affix
2
+ //= require bootstrap/alert
3
+ //= require bootstrap/button
4
+ //= require bootstrap/carousel
5
+ //= require bootstrap/collapse
6
+ //= require bootstrap/dropdown
7
+ //= require bootstrap/tab
8
+ //= require bootstrap/transition
9
+ //= require bootstrap/scrollspy
10
+ //= require bootstrap/modal
11
+ //= require bootstrap/tooltip
12
+ //= require bootstrap/popover
@@ -7,73 +7,61 @@
7
7
  // -------------------------
8
8
 
9
9
  .alert {
10
- padding: 8px 35px 8px 14px;
11
- margin-bottom: $baseLineHeight;
12
- text-shadow: 0 1px 0 rgba(255,255,255,.5);
13
- background-color: $warningBackground;
14
- border: 1px solid $warningBorder;
15
- @include border-radius($baseBorderRadius);
16
- }
17
- .alert,
18
- .alert h4 {
19
- // Specified for the h4 to prevent conflicts of changing $headingsColor
20
- color: $warningText;
21
- }
22
- .alert h4 {
23
- margin: 0;
24
- }
10
+ padding: $alert-padding;
11
+ margin-bottom: $line-height-computed;
12
+ border: 1px solid transparent;
13
+ border-radius: $alert-border-radius;
25
14
 
26
- // Adjust close link position
27
- .alert .close {
28
- position: relative;
29
- top: -2px;
30
- right: -21px;
31
- line-height: $baseLineHeight;
15
+ // Headings for larger alerts
16
+ h4 {
17
+ margin-top: 0;
18
+ // Specified for the h4 to prevent conflicts of changing $headingsColor
19
+ color: inherit;
20
+ }
21
+ // Provide class for links that match alerts
22
+ .alert-link {
23
+ font-weight: $alert-link-font-weight;
24
+ }
25
+
26
+ // Improve alignment and spacing of inner content
27
+ > p,
28
+ > ul {
29
+ margin-bottom: 0;
30
+ }
31
+ > p + p {
32
+ margin-top: 5px;
33
+ }
32
34
  }
33
35
 
36
+ // Dismissable alerts
37
+ //
38
+ // Expand the right padding and account for the close button's positioning.
39
+
40
+ .alert-dismissable {
41
+ padding-right: ($alert-padding + 20);
42
+
43
+ // Adjust close link position
44
+ .close {
45
+ position: relative;
46
+ top: -2px;
47
+ right: -21px;
48
+ color: inherit;
49
+ }
50
+ }
34
51
 
35
52
  // Alternate styles
36
- // -------------------------
53
+ //
54
+ // Generate contextual modifier classes for colorizing the alert.
37
55
 
38
56
  .alert-success {
39
- background-color: $successBackground;
40
- border-color: $successBorder;
41
- color: $successText;
42
- }
43
- .alert-success h4 {
44
- color: $successText;
45
- }
46
- .alert-danger,
47
- .alert-error {
48
- background-color: $errorBackground;
49
- border-color: $errorBorder;
50
- color: $errorText;
51
- }
52
- .alert-danger h4,
53
- .alert-error h4 {
54
- color: $errorText;
57
+ @include alert-variant($alert-success-bg, $alert-success-border, $alert-success-text);
55
58
  }
56
59
  .alert-info {
57
- background-color: $infoBackground;
58
- border-color: $infoBorder;
59
- color: $infoText;
60
- }
61
- .alert-info h4 {
62
- color: $infoText;
63
- }
64
-
65
-
66
- // Block alerts
67
- // -------------------------
68
-
69
- .alert-block {
70
- padding-top: 14px;
71
- padding-bottom: 14px;
60
+ @include alert-variant($alert-info-bg, $alert-info-border, $alert-info-text);
72
61
  }
73
- .alert-block > p,
74
- .alert-block > ul {
75
- margin-bottom: 0;
62
+ .alert-warning {
63
+ @include alert-variant($alert-warning-bg, $alert-warning-border, $alert-warning-text);
76
64
  }
77
- .alert-block p + p {
78
- margin-top: 5px;
65
+ .alert-danger {
66
+ @include alert-variant($alert-danger-bg, $alert-danger-border, $alert-danger-text);
79
67
  }
@@ -0,0 +1,51 @@
1
+ //
2
+ // Badges
3
+ // --------------------------------------------------
4
+
5
+
6
+ // Base classes
7
+ .badge {
8
+ display: inline-block;
9
+ min-width: 10px;
10
+ padding: 3px 7px;
11
+ font-size: $font-size-small;
12
+ font-weight: $badge-font-weight;
13
+ color: $badge-color;
14
+ line-height: $badge-line-height;
15
+ vertical-align: baseline;
16
+ white-space: nowrap;
17
+ text-align: center;
18
+ background-color: $badge-bg;
19
+ border-radius: $badge-border-radius;
20
+
21
+ // Empty badges collapse automatically (not available in IE8)
22
+ &:empty {
23
+ display: none;
24
+ }
25
+ }
26
+
27
+ // Hover state, but only for links
28
+ a.badge {
29
+ &:hover,
30
+ &:focus {
31
+ color: $badge-link-hover-color;
32
+ text-decoration: none;
33
+ cursor: pointer;
34
+ }
35
+ }
36
+
37
+ // Quick fix for labels/badges in buttons
38
+ .btn .badge {
39
+ position: relative;
40
+ top: -1px;
41
+ }
42
+
43
+ // Account for counters in navs
44
+ a.list-group-item.active > .badge,
45
+ .nav-pills > .active > a > .badge {
46
+ color: $badge-active-color;
47
+ background-color: $badge-active-bg;
48
+ }
49
+ .nav-pills > li > a > .badge {
50
+ margin-left: 3px;
51
+ }
@@ -5,20 +5,19 @@
5
5
 
6
6
  .breadcrumb {
7
7
  padding: 8px 15px;
8
- margin: 0 0 $baseLineHeight;
8
+ margin-bottom: $line-height-computed;
9
9
  list-style: none;
10
- background-color: #f5f5f5;
11
- @include border-radius($baseBorderRadius);
10
+ background-color: $breadcrumb-bg;
11
+ border-radius: $border-radius-base;
12
12
  > li {
13
13
  display: inline-block;
14
- @include ie7-inline-block();
15
- text-shadow: 0 1px 0 $white;
16
- > .divider {
14
+ &+li:before {
15
+ content: "/\00a0"; // Unicode space added since inline-block means non-collapsing white-space
17
16
  padding: 0 5px;
18
- color: #ccc;
17
+ color: $breadcrumb-color;
19
18
  }
20
19
  }
21
- .active {
22
- color: $grayLight;
20
+ > .active {
21
+ color: $breadcrumb-active-color;
23
22
  }
24
23
  }