twitter-bootstrap-rails 2.1.7 → 2.1.8
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.
- data/README.md +37 -0
- data/lib/twitter/bootstrap/rails/twitter-bootstrap-breadcrumbs.rb +14 -2
- data/lib/twitter/bootstrap/rails/version.rb +1 -1
- data/test/lib/breadcrumbs_test.rb +75 -0
- data/test/test_helper.rb +8 -0
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-affix.js +12 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-alert.js +12 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-button.js +12 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-carousel.js +11 -2
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-collapse.js +15 -4
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-dropdown.js +16 -3
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-modal.js +12 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-popover.js +14 -3
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-scrollspy.js +13 -2
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-tab.js +12 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-tooltip.js +12 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-transition.js +1 -1
- data/vendor/assets/javascripts/twitter/bootstrap/bootstrap-typeahead.js +23 -10
- data/vendor/toolkit/twitter/bootstrap/alerts.less +14 -0
- data/vendor/toolkit/twitter/bootstrap/bootstrap.less +2 -1
- data/vendor/toolkit/twitter/bootstrap/breadcrumbs.less +6 -6
- data/vendor/toolkit/twitter/bootstrap/button-groups.less +27 -42
- data/vendor/toolkit/twitter/bootstrap/buttons.less +5 -7
- data/vendor/toolkit/twitter/bootstrap/carousel.less +15 -15
- data/vendor/toolkit/twitter/bootstrap/code.less +3 -0
- data/vendor/toolkit/twitter/bootstrap/dropdowns.less +5 -9
- data/vendor/toolkit/twitter/bootstrap/forms.less +12 -8
- data/vendor/toolkit/twitter/bootstrap/labels-badges.less +8 -0
- data/vendor/toolkit/twitter/bootstrap/mixins.less +1 -1
- data/vendor/toolkit/twitter/bootstrap/modals.less +4 -3
- data/vendor/toolkit/twitter/bootstrap/navbar.less +21 -6
- data/vendor/toolkit/twitter/bootstrap/navs.less +6 -0
- data/vendor/toolkit/twitter/bootstrap/popovers.less +50 -38
- data/vendor/toolkit/twitter/bootstrap/reset.less +82 -4
- data/vendor/toolkit/twitter/bootstrap/responsive.less +10 -1
- data/vendor/toolkit/twitter/bootstrap/sprites.less +2 -2
- data/vendor/toolkit/twitter/bootstrap/tables.less +35 -34
- data/vendor/toolkit/twitter/bootstrap/type.less +29 -21
- data/vendor/toolkit/twitter/bootstrap/variables.less +2 -2
- metadata +22 -17
data/README.md
CHANGED
@@ -203,6 +203,42 @@ jQuery ->
|
|
203
203
|
### Flash helper
|
204
204
|
Add flash helper <%= bootstrap_flash %> to your layout (built-in with layout generator)
|
205
205
|
|
206
|
+
### Breadcrumbs Helpers
|
207
|
+
```ruby
|
208
|
+
class ApplicationController
|
209
|
+
add_breadcrumb :index, :root_path
|
210
|
+
end
|
211
|
+
```
|
212
|
+
|
213
|
+
```ruby
|
214
|
+
class ExapmlesController < ApplicationController
|
215
|
+
add_breadcrumb :index, :examples_path
|
216
|
+
|
217
|
+
def index
|
218
|
+
end
|
219
|
+
|
220
|
+
def show
|
221
|
+
@example = Example.find params[:id]
|
222
|
+
add_breadcrumb @example.name, example_path(@example)
|
223
|
+
# add_breadcrumb :show, example_path(@example)
|
224
|
+
end
|
225
|
+
end
|
226
|
+
```
|
227
|
+
|
228
|
+
Add I18n translations
|
229
|
+
|
230
|
+
```yml
|
231
|
+
en:
|
232
|
+
breadcrumbs:
|
233
|
+
application:
|
234
|
+
index: "Index"
|
235
|
+
examples:
|
236
|
+
index: "Examples"
|
237
|
+
show: "Example"
|
238
|
+
```
|
239
|
+
|
240
|
+
Add breadcrumbs helper <%= render_breadcrumbs %> to your layout
|
241
|
+
|
206
242
|
## Changelog
|
207
243
|
<ul>
|
208
244
|
<li>Version 0.0.5 deprecated</li>
|
@@ -245,6 +281,7 @@ Add flash helper <%= bootstrap_flash %> to your layout (built-in with layout gen
|
|
245
281
|
<li>Released gem v.2.1.5 (minor fixes, install generator detects javascript template engine, updated to Twitter Bootstrap 2.2.1)</li>
|
246
282
|
<li>Released gem v.2.1.6 (minor fixes)</li>
|
247
283
|
<li>Added static stylesheets support</li>
|
284
|
+
<li>Released gem v.2.1.8 and updated to Twitter Bootstrap 2.2.2</li>
|
248
285
|
</ul>
|
249
286
|
|
250
287
|
|
@@ -6,8 +6,10 @@ module Twitter
|
|
6
6
|
end
|
7
7
|
|
8
8
|
module ClassMethods
|
9
|
-
def add_breadcrumb
|
9
|
+
def add_breadcrumb(name, url, options = {})
|
10
|
+
class_name = self.name
|
10
11
|
before_filter options do |controller|
|
12
|
+
name = controller.send :translate_breadcrumb, name, class_name if name.is_a?(Symbol)
|
11
13
|
controller.send :add_breadcrumb, name, url
|
12
14
|
end
|
13
15
|
end
|
@@ -15,12 +17,22 @@ module Twitter
|
|
15
17
|
|
16
18
|
protected
|
17
19
|
|
18
|
-
def add_breadcrumb
|
20
|
+
def add_breadcrumb(name, url = '', options = {})
|
19
21
|
@breadcrumbs ||= []
|
22
|
+
name = translate_breadcrumb(name, self.class.name) if name.is_a?(Symbol)
|
20
23
|
url = eval(url.to_s) if url =~ /_path|_url|@/
|
21
24
|
@breadcrumbs << {:name => name, :url => url, :options => options}
|
22
25
|
end
|
23
26
|
|
27
|
+
def translate_breadcrumb(name, class_name)
|
28
|
+
scope = [:breadcrumbs]
|
29
|
+
namespace = class_name.underscore.split('/')
|
30
|
+
namespace.last.sub!('_controller', '')
|
31
|
+
scope += namespace
|
32
|
+
|
33
|
+
I18n.t name, scope: scope
|
34
|
+
end
|
35
|
+
|
24
36
|
def render_breadcrumbs(divider = '/')
|
25
37
|
s = render :partial => 'twitter-bootstrap/breadcrumbs', :locals => {:divider => divider}
|
26
38
|
s.first
|
@@ -0,0 +1,75 @@
|
|
1
|
+
require "test_helper"
|
2
|
+
|
3
|
+
module AbstractController
|
4
|
+
module Testing
|
5
|
+
|
6
|
+
class TestHelper
|
7
|
+
BREADCRUMB_NAMES = [:class_level, :class_level_i18n, :instance_level,
|
8
|
+
:instance_level_i18n, :base_level, :base_level_i18n]
|
9
|
+
|
10
|
+
class << self
|
11
|
+
BREADCRUMB_NAMES.each do |name|
|
12
|
+
define_method "#{name}_name" do
|
13
|
+
"test-breadcrumb-#{name}"
|
14
|
+
end
|
15
|
+
|
16
|
+
define_method "#{name}_path" do
|
17
|
+
"/test/breadcrumb/#{name}"
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
class BaseTestController < AbstractController::Base
|
24
|
+
include Twitter::Bootstrap::BreadCrumbs
|
25
|
+
include AbstractController::Callbacks
|
26
|
+
|
27
|
+
add_breadcrumb TestHelper.base_level_name, TestHelper.base_level_path
|
28
|
+
add_breadcrumb :base_level_i18n, TestHelper.base_level_i18n_path
|
29
|
+
|
30
|
+
def breadcrumbs
|
31
|
+
@breadcrumbs
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
class TestController < BaseTestController
|
36
|
+
add_breadcrumb TestHelper.class_level_name, TestHelper.class_level_path
|
37
|
+
add_breadcrumb :class_level_i18n, TestHelper.class_level_i18n_path
|
38
|
+
|
39
|
+
def index
|
40
|
+
add_breadcrumb TestHelper.instance_level_name, TestHelper.instance_level_path
|
41
|
+
add_breadcrumb :instance_level_i18n, TestHelper.instance_level_i18n_path
|
42
|
+
end
|
43
|
+
end
|
44
|
+
|
45
|
+
class BreadcrumbsTest < MiniTest::Unit::TestCase
|
46
|
+
def setup
|
47
|
+
options = { scope: [:breadcrumbs, 'abstract_controller', 'testing', 'test'] }
|
48
|
+
[:class_level_i18n, :instance_level_i18n].each do |name|
|
49
|
+
I18n.expects(:t).with(name, options).returns(TestHelper.send("#{name}_name"))
|
50
|
+
end
|
51
|
+
|
52
|
+
name = :base_level_i18n
|
53
|
+
options = { scope: [:breadcrumbs, 'abstract_controller', 'testing', 'base_test'] }
|
54
|
+
I18n.expects(:t).with(name, options).returns(TestHelper.send("#{name}_name"))
|
55
|
+
|
56
|
+
@controller = TestController.new
|
57
|
+
@controller.process(:index)
|
58
|
+
end
|
59
|
+
|
60
|
+
def test_should_have_breadcrumbs
|
61
|
+
TestHelper::BREADCRUMB_NAMES.each do |name|
|
62
|
+
assert include_breadcrumb?(name), "#{name} breadcrumb not found"
|
63
|
+
end
|
64
|
+
end
|
65
|
+
|
66
|
+
def include_breadcrumb?(name)
|
67
|
+
selected = @controller.breadcrumbs.select { |b|
|
68
|
+
b[:name] == TestHelper.send("#{name}_name") &&
|
69
|
+
b[:url] == TestHelper.send("#{name}_path")
|
70
|
+
}
|
71
|
+
selected.any?
|
72
|
+
end
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
data/test/test_helper.rb
ADDED
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ==========================================================
|
2
|
-
* bootstrap-affix.js v2.2.
|
2
|
+
* bootstrap-affix.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#affix
|
4
4
|
* ==========================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -68,6 +68,8 @@
|
|
68
68
|
/* AFFIX PLUGIN DEFINITION
|
69
69
|
* ======================= */
|
70
70
|
|
71
|
+
var old = $.fn.affix
|
72
|
+
|
71
73
|
$.fn.affix = function (option) {
|
72
74
|
return this.each(function () {
|
73
75
|
var $this = $(this)
|
@@ -85,6 +87,15 @@
|
|
85
87
|
}
|
86
88
|
|
87
89
|
|
90
|
+
/* AFFIX NO CONFLICT
|
91
|
+
* ================= */
|
92
|
+
|
93
|
+
$.fn.affix.noConflict = function () {
|
94
|
+
$.fn.affix = old
|
95
|
+
return this
|
96
|
+
}
|
97
|
+
|
98
|
+
|
88
99
|
/* AFFIX DATA-API
|
89
100
|
* ============== */
|
90
101
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ==========================================================
|
2
|
-
* bootstrap-alert.js v2.2.
|
2
|
+
* bootstrap-alert.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#alerts
|
4
4
|
* ==========================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -68,6 +68,8 @@
|
|
68
68
|
/* ALERT PLUGIN DEFINITION
|
69
69
|
* ======================= */
|
70
70
|
|
71
|
+
var old = $.fn.alert
|
72
|
+
|
71
73
|
$.fn.alert = function (option) {
|
72
74
|
return this.each(function () {
|
73
75
|
var $this = $(this)
|
@@ -80,6 +82,15 @@
|
|
80
82
|
$.fn.alert.Constructor = Alert
|
81
83
|
|
82
84
|
|
85
|
+
/* ALERT NO CONFLICT
|
86
|
+
* ================= */
|
87
|
+
|
88
|
+
$.fn.alert.noConflict = function () {
|
89
|
+
$.fn.alert = old
|
90
|
+
return this
|
91
|
+
}
|
92
|
+
|
93
|
+
|
83
94
|
/* ALERT DATA-API
|
84
95
|
* ============== */
|
85
96
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ============================================================
|
2
|
-
* bootstrap-button.js v2.2.
|
2
|
+
* bootstrap-button.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#buttons
|
4
4
|
* ============================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -64,6 +64,8 @@
|
|
64
64
|
/* BUTTON PLUGIN DEFINITION
|
65
65
|
* ======================== */
|
66
66
|
|
67
|
+
var old = $.fn.button
|
68
|
+
|
67
69
|
$.fn.button = function (option) {
|
68
70
|
return this.each(function () {
|
69
71
|
var $this = $(this)
|
@@ -82,6 +84,15 @@
|
|
82
84
|
$.fn.button.Constructor = Button
|
83
85
|
|
84
86
|
|
87
|
+
/* BUTTON NO CONFLICT
|
88
|
+
* ================== */
|
89
|
+
|
90
|
+
$.fn.button.noConflict = function () {
|
91
|
+
$.fn.button = old
|
92
|
+
return this
|
93
|
+
}
|
94
|
+
|
95
|
+
|
85
96
|
/* BUTTON DATA-API
|
86
97
|
* =============== */
|
87
98
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ==========================================================
|
2
|
-
* bootstrap-carousel.js v2.2.
|
2
|
+
* bootstrap-carousel.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#carousel
|
4
4
|
* ==========================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -29,7 +29,6 @@
|
|
29
29
|
var Carousel = function (element, options) {
|
30
30
|
this.$element = $(element)
|
31
31
|
this.options = options
|
32
|
-
this.options.slide && this.slide(this.options.slide)
|
33
32
|
this.options.pause == 'hover' && this.$element
|
34
33
|
.on('mouseenter', $.proxy(this.pause, this))
|
35
34
|
.on('mouseleave', $.proxy(this.cycle, this))
|
@@ -141,6 +140,8 @@
|
|
141
140
|
/* CAROUSEL PLUGIN DEFINITION
|
142
141
|
* ========================== */
|
143
142
|
|
143
|
+
var old = $.fn.carousel
|
144
|
+
|
144
145
|
$.fn.carousel = function (option) {
|
145
146
|
return this.each(function () {
|
146
147
|
var $this = $(this)
|
@@ -162,6 +163,14 @@
|
|
162
163
|
$.fn.carousel.Constructor = Carousel
|
163
164
|
|
164
165
|
|
166
|
+
/* CAROUSEL NO CONFLICT
|
167
|
+
* ==================== */
|
168
|
+
|
169
|
+
$.fn.carousel.noConflict = function () {
|
170
|
+
$.fn.carousel = old
|
171
|
+
return this
|
172
|
+
}
|
173
|
+
|
165
174
|
/* CAROUSEL DATA-API
|
166
175
|
* ================= */
|
167
176
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* =============================================================
|
2
|
-
* bootstrap-collapse.js v2.2.
|
2
|
+
* bootstrap-collapse.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#collapse
|
4
4
|
* =============================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -120,8 +120,10 @@
|
|
120
120
|
}
|
121
121
|
|
122
122
|
|
123
|
-
/*
|
124
|
-
*
|
123
|
+
/* COLLAPSE PLUGIN DEFINITION
|
124
|
+
* ========================== */
|
125
|
+
|
126
|
+
var old = $.fn.collapse
|
125
127
|
|
126
128
|
$.fn.collapse = function (option) {
|
127
129
|
return this.each(function () {
|
@@ -140,9 +142,18 @@
|
|
140
142
|
$.fn.collapse.Constructor = Collapse
|
141
143
|
|
142
144
|
|
143
|
-
/*
|
145
|
+
/* COLLAPSE NO CONFLICT
|
144
146
|
* ==================== */
|
145
147
|
|
148
|
+
$.fn.collapse.noConflict = function () {
|
149
|
+
$.fn.collapse = old
|
150
|
+
return this
|
151
|
+
}
|
152
|
+
|
153
|
+
|
154
|
+
/* COLLAPSE DATA-API
|
155
|
+
* ================= */
|
156
|
+
|
146
157
|
$(document).on('click.collapse.data-api', '[data-toggle=collapse]', function (e) {
|
147
158
|
var $this = $(this), href
|
148
159
|
, target = $this.attr('data-target')
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ============================================================
|
2
|
-
* bootstrap-dropdown.js v2.2.
|
2
|
+
* bootstrap-dropdown.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#dropdowns
|
4
4
|
* ============================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -53,9 +53,10 @@
|
|
53
53
|
|
54
54
|
if (!isActive) {
|
55
55
|
$parent.toggleClass('open')
|
56
|
-
$this.focus()
|
57
56
|
}
|
58
57
|
|
58
|
+
$this.focus()
|
59
|
+
|
59
60
|
return false
|
60
61
|
}
|
61
62
|
|
@@ -82,7 +83,7 @@
|
|
82
83
|
|
83
84
|
if (!isActive || (isActive && e.keyCode == 27)) return $this.click()
|
84
85
|
|
85
|
-
$items = $('[role=menu] li:not(.divider) a', $parent)
|
86
|
+
$items = $('[role=menu] li:not(.divider):visible a', $parent)
|
86
87
|
|
87
88
|
if (!$items.length) return
|
88
89
|
|
@@ -124,6 +125,8 @@
|
|
124
125
|
/* DROPDOWN PLUGIN DEFINITION
|
125
126
|
* ========================== */
|
126
127
|
|
128
|
+
var old = $.fn.dropdown
|
129
|
+
|
127
130
|
$.fn.dropdown = function (option) {
|
128
131
|
return this.each(function () {
|
129
132
|
var $this = $(this)
|
@@ -136,12 +139,22 @@
|
|
136
139
|
$.fn.dropdown.Constructor = Dropdown
|
137
140
|
|
138
141
|
|
142
|
+
/* DROPDOWN NO CONFLICT
|
143
|
+
* ==================== */
|
144
|
+
|
145
|
+
$.fn.dropdown.noConflict = function () {
|
146
|
+
$.fn.dropdown = old
|
147
|
+
return this
|
148
|
+
}
|
149
|
+
|
150
|
+
|
139
151
|
/* APPLY TO STANDARD DROPDOWN ELEMENTS
|
140
152
|
* =================================== */
|
141
153
|
|
142
154
|
$(document)
|
143
155
|
.on('click.dropdown.data-api touchstart.dropdown.data-api', clearMenus)
|
144
156
|
.on('click.dropdown touchstart.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
|
157
|
+
.on('touchstart.dropdown.data-api', '.dropdown-menu', function (e) { e.stopPropagation() })
|
145
158
|
.on('click.dropdown.data-api touchstart.dropdown.data-api' , toggle, Dropdown.prototype.toggle)
|
146
159
|
.on('keydown.dropdown.data-api touchstart.dropdown.data-api', toggle + ', [role=menu]' , Dropdown.prototype.keydown)
|
147
160
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* =========================================================
|
2
|
-
* bootstrap-modal.js v2.2.
|
2
|
+
* bootstrap-modal.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#modals
|
4
4
|
* =========================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -193,6 +193,8 @@
|
|
193
193
|
/* MODAL PLUGIN DEFINITION
|
194
194
|
* ======================= */
|
195
195
|
|
196
|
+
var old = $.fn.modal
|
197
|
+
|
196
198
|
$.fn.modal = function (option) {
|
197
199
|
return this.each(function () {
|
198
200
|
var $this = $(this)
|
@@ -213,6 +215,15 @@
|
|
213
215
|
$.fn.modal.Constructor = Modal
|
214
216
|
|
215
217
|
|
218
|
+
/* MODAL NO CONFLICT
|
219
|
+
* ================= */
|
220
|
+
|
221
|
+
$.fn.modal.noConflict = function () {
|
222
|
+
$.fn.modal = old
|
223
|
+
return this
|
224
|
+
}
|
225
|
+
|
226
|
+
|
216
227
|
/* MODAL DATA-API
|
217
228
|
* ============== */
|
218
229
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ===========================================================
|
2
|
-
* bootstrap-popover.js v2.2.
|
2
|
+
* bootstrap-popover.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#popovers
|
4
4
|
* ===========================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -44,7 +44,7 @@
|
|
44
44
|
, content = this.getContent()
|
45
45
|
|
46
46
|
$tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title)
|
47
|
-
$tip.find('.popover-content
|
47
|
+
$tip.find('.popover-content')[this.options.html ? 'html' : 'text'](content)
|
48
48
|
|
49
49
|
$tip.removeClass('fade top bottom left right in')
|
50
50
|
}
|
@@ -81,6 +81,8 @@
|
|
81
81
|
/* POPOVER PLUGIN DEFINITION
|
82
82
|
* ======================= */
|
83
83
|
|
84
|
+
var old = $.fn.popover
|
85
|
+
|
84
86
|
$.fn.popover = function (option) {
|
85
87
|
return this.each(function () {
|
86
88
|
var $this = $(this)
|
@@ -97,7 +99,16 @@
|
|
97
99
|
placement: 'right'
|
98
100
|
, trigger: 'click'
|
99
101
|
, content: ''
|
100
|
-
, template: '<div class="popover"><div class="arrow"></div><div class="popover-inner"><h3 class="popover-title"></h3><div class="popover-content"
|
102
|
+
, template: '<div class="popover"><div class="arrow"></div><div class="popover-inner"><h3 class="popover-title"></h3><div class="popover-content"></div></div></div>'
|
101
103
|
})
|
102
104
|
|
105
|
+
|
106
|
+
/* POPOVER NO CONFLICT
|
107
|
+
* =================== */
|
108
|
+
|
109
|
+
$.fn.popover.noConflict = function () {
|
110
|
+
$.fn.popover = old
|
111
|
+
return this
|
112
|
+
}
|
113
|
+
|
103
114
|
}(window.jQuery);
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* =============================================================
|
2
|
-
* bootstrap-scrollspy.js v2.2.
|
2
|
+
* bootstrap-scrollspy.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#scrollspy
|
4
4
|
* =============================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -59,7 +59,7 @@
|
|
59
59
|
, $href = /^#\w/.test(href) && $(href)
|
60
60
|
return ( $href
|
61
61
|
&& $href.length
|
62
|
-
&& [[ $href.position().top, href ]] ) || null
|
62
|
+
&& [[ $href.position().top + self.$scrollElement.scrollTop(), href ]] ) || null
|
63
63
|
})
|
64
64
|
.sort(function (a, b) { return a[0] - b[0] })
|
65
65
|
.each(function () {
|
@@ -121,6 +121,8 @@
|
|
121
121
|
/* SCROLLSPY PLUGIN DEFINITION
|
122
122
|
* =========================== */
|
123
123
|
|
124
|
+
var old = $.fn.scrollspy
|
125
|
+
|
124
126
|
$.fn.scrollspy = function (option) {
|
125
127
|
return this.each(function () {
|
126
128
|
var $this = $(this)
|
@@ -138,6 +140,15 @@
|
|
138
140
|
}
|
139
141
|
|
140
142
|
|
143
|
+
/* SCROLLSPY NO CONFLICT
|
144
|
+
* ===================== */
|
145
|
+
|
146
|
+
$.fn.scrollspy.noConflict = function () {
|
147
|
+
$.fn.scrollspy = old
|
148
|
+
return this
|
149
|
+
}
|
150
|
+
|
151
|
+
|
141
152
|
/* SCROLLSPY DATA-API
|
142
153
|
* ================== */
|
143
154
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ========================================================
|
2
|
-
* bootstrap-tab.js v2.2.
|
2
|
+
* bootstrap-tab.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#tabs
|
4
4
|
* ========================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -110,6 +110,8 @@
|
|
110
110
|
/* TAB PLUGIN DEFINITION
|
111
111
|
* ===================== */
|
112
112
|
|
113
|
+
var old = $.fn.tab
|
114
|
+
|
113
115
|
$.fn.tab = function ( option ) {
|
114
116
|
return this.each(function () {
|
115
117
|
var $this = $(this)
|
@@ -122,6 +124,15 @@
|
|
122
124
|
$.fn.tab.Constructor = Tab
|
123
125
|
|
124
126
|
|
127
|
+
/* TAB NO CONFLICT
|
128
|
+
* =============== */
|
129
|
+
|
130
|
+
$.fn.tab.noConflict = function () {
|
131
|
+
$.fn.tab = old
|
132
|
+
return this
|
133
|
+
}
|
134
|
+
|
135
|
+
|
125
136
|
/* TAB DATA-API
|
126
137
|
* ============ */
|
127
138
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ===========================================================
|
2
|
-
* bootstrap-tooltip.js v2.2.
|
2
|
+
* bootstrap-tooltip.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#tooltips
|
4
4
|
* Inspired by the original jQuery.tipsy by Jason Frame
|
5
5
|
* ===========================================================
|
@@ -250,6 +250,8 @@
|
|
250
250
|
/* TOOLTIP PLUGIN DEFINITION
|
251
251
|
* ========================= */
|
252
252
|
|
253
|
+
var old = $.fn.tooltip
|
254
|
+
|
253
255
|
$.fn.tooltip = function ( option ) {
|
254
256
|
return this.each(function () {
|
255
257
|
var $this = $(this)
|
@@ -273,4 +275,13 @@
|
|
273
275
|
, html: false
|
274
276
|
}
|
275
277
|
|
278
|
+
|
279
|
+
/* TOOLTIP NO CONFLICT
|
280
|
+
* =================== */
|
281
|
+
|
282
|
+
$.fn.tooltip.noConflict = function () {
|
283
|
+
$.fn.tooltip = old
|
284
|
+
return this
|
285
|
+
}
|
286
|
+
|
276
287
|
}(window.jQuery);
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* ===================================================
|
2
|
-
* bootstrap-transition.js v2.2.
|
2
|
+
* bootstrap-transition.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#transitions
|
4
4
|
* ===================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/* =============================================================
|
2
|
-
* bootstrap-typeahead.js v2.2.
|
2
|
+
* bootstrap-typeahead.js v2.2.2
|
3
3
|
* http://twitter.github.com/bootstrap/javascript.html#typeahead
|
4
4
|
* =============================================================
|
5
5
|
* Copyright 2012 Twitter, Inc.
|
@@ -33,8 +33,8 @@
|
|
33
33
|
this.sorter = this.options.sorter || this.sorter
|
34
34
|
this.highlighter = this.options.highlighter || this.highlighter
|
35
35
|
this.updater = this.options.updater || this.updater
|
36
|
-
this.$menu = $(this.options.menu).appendTo('body')
|
37
36
|
this.source = this.options.source
|
37
|
+
this.$menu = $(this.options.menu)
|
38
38
|
this.shown = false
|
39
39
|
this.listen()
|
40
40
|
}
|
@@ -56,16 +56,18 @@
|
|
56
56
|
}
|
57
57
|
|
58
58
|
, show: function () {
|
59
|
-
var pos = $.extend({}, this.$element.
|
59
|
+
var pos = $.extend({}, this.$element.position(), {
|
60
60
|
height: this.$element[0].offsetHeight
|
61
61
|
})
|
62
62
|
|
63
|
-
this.$menu
|
64
|
-
|
65
|
-
|
66
|
-
|
63
|
+
this.$menu
|
64
|
+
.insertAfter(this.$element)
|
65
|
+
.css({
|
66
|
+
top: pos.top + pos.height
|
67
|
+
, left: pos.left
|
68
|
+
})
|
69
|
+
.show()
|
67
70
|
|
68
|
-
this.$menu.show()
|
69
71
|
this.shown = true
|
70
72
|
return this
|
71
73
|
}
|
@@ -217,7 +219,7 @@
|
|
217
219
|
}
|
218
220
|
|
219
221
|
, keydown: function (e) {
|
220
|
-
this.suppressKeyPressRepeat =
|
222
|
+
this.suppressKeyPressRepeat = ~$.inArray(e.keyCode, [40,38,9,13,27])
|
221
223
|
this.move(e)
|
222
224
|
}
|
223
225
|
|
@@ -276,6 +278,8 @@
|
|
276
278
|
/* TYPEAHEAD PLUGIN DEFINITION
|
277
279
|
* =========================== */
|
278
280
|
|
281
|
+
var old = $.fn.typeahead
|
282
|
+
|
279
283
|
$.fn.typeahead = function (option) {
|
280
284
|
return this.each(function () {
|
281
285
|
var $this = $(this)
|
@@ -297,7 +301,16 @@
|
|
297
301
|
$.fn.typeahead.Constructor = Typeahead
|
298
302
|
|
299
303
|
|
300
|
-
/*
|
304
|
+
/* TYPEAHEAD NO CONFLICT
|
305
|
+
* =================== */
|
306
|
+
|
307
|
+
$.fn.typeahead.noConflict = function () {
|
308
|
+
$.fn.typeahead = old
|
309
|
+
return this
|
310
|
+
}
|
311
|
+
|
312
|
+
|
313
|
+
/* TYPEAHEAD DATA-API
|
301
314
|
* ================== */
|
302
315
|
|
303
316
|
$(document).on('focus.typeahead.data-api', '[data-provide="typeahead"]', function (e) {
|