bootstrap-generators 2.2.1 → 2.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.md +1 -1
- data/lib/bootstrap/generators/version.rb +1 -1
- data/vendor/assets/javascripts/bootstrap-affix.js +12 -1
- data/vendor/assets/javascripts/bootstrap-alert.js +12 -1
- data/vendor/assets/javascripts/bootstrap-button.js +12 -1
- data/vendor/assets/javascripts/bootstrap-carousel.js +11 -2
- data/vendor/assets/javascripts/bootstrap-collapse.js +15 -4
- data/vendor/assets/javascripts/bootstrap-dropdown.js +16 -3
- data/vendor/assets/javascripts/bootstrap-modal.js +12 -1
- data/vendor/assets/javascripts/bootstrap-popover.js +14 -3
- data/vendor/assets/javascripts/bootstrap-scrollspy.js +13 -2
- data/vendor/assets/javascripts/bootstrap-tab.js +12 -1
- data/vendor/assets/javascripts/bootstrap-tooltip.js +12 -1
- data/vendor/assets/javascripts/bootstrap-transition.js +1 -1
- data/vendor/assets/javascripts/bootstrap-typeahead.js +23 -10
- data/vendor/assets/stylesheets/bootstrap-responsive.css +37 -3
- data/vendor/assets/stylesheets/bootstrap.css +643 -378
- data/vendor/twitter/bootstrap/less/alerts.less +14 -0
- data/vendor/twitter/bootstrap/less/bootstrap.less +1 -1
- data/vendor/twitter/bootstrap/less/breadcrumbs.less +6 -6
- data/vendor/twitter/bootstrap/less/button-groups.less +27 -42
- data/vendor/twitter/bootstrap/less/buttons.less +5 -7
- data/vendor/twitter/bootstrap/less/carousel.less +15 -15
- data/vendor/twitter/bootstrap/less/code.less +3 -0
- data/vendor/twitter/bootstrap/less/dropdowns.less +5 -9
- data/vendor/twitter/bootstrap/less/forms.less +12 -8
- data/vendor/twitter/bootstrap/less/labels-badges.less +8 -0
- data/vendor/twitter/bootstrap/less/mixins.less +1 -1
- data/vendor/twitter/bootstrap/less/modals.less +4 -3
- data/vendor/twitter/bootstrap/less/navbar.less +21 -6
- data/vendor/twitter/bootstrap/less/navs.less +6 -0
- data/vendor/twitter/bootstrap/less/popovers.less +50 -38
- data/vendor/twitter/bootstrap/less/reset.less +82 -4
- data/vendor/twitter/bootstrap/less/responsive.less +10 -1
- data/vendor/twitter/bootstrap/less/tables.less +35 -34
- data/vendor/twitter/bootstrap/less/type.less +29 -21
- data/vendor/twitter/bootstrap/less/variables.less +4 -4
- data/vendor/twitter/bootstrap/sass/_alerts.scss +14 -0
- data/vendor/twitter/bootstrap/sass/_breadcrumbs.scss +5 -5
- data/vendor/twitter/bootstrap/sass/_button-groups.scss +27 -42
- data/vendor/twitter/bootstrap/sass/_buttons.scss +5 -7
- data/vendor/twitter/bootstrap/sass/_carousel.scss +15 -15
- data/vendor/twitter/bootstrap/sass/_code.scss +3 -0
- data/vendor/twitter/bootstrap/sass/_dropdowns.scss +5 -9
- data/vendor/twitter/bootstrap/sass/_forms.scss +12 -8
- data/vendor/twitter/bootstrap/sass/_labels-badges.scss +25 -15
- data/vendor/twitter/bootstrap/sass/_mixins.scss +3 -3
- data/vendor/twitter/bootstrap/sass/_modals.scss +1 -1
- data/vendor/twitter/bootstrap/sass/_navbar.scss +22 -4
- data/vendor/twitter/bootstrap/sass/_navs.scss +6 -0
- data/vendor/twitter/bootstrap/sass/_popovers.scss +50 -38
- data/vendor/twitter/bootstrap/sass/_reset.scss +82 -4
- data/vendor/twitter/bootstrap/sass/_tables.scss +36 -35
- data/vendor/twitter/bootstrap/sass/_type.scss +29 -21
- data/vendor/twitter/bootstrap/sass/_variables.scss +9 -9
- data/vendor/twitter/bootstrap/sass/bootstrap.scss +1 -1
- data/vendor/twitter/bootstrap/sass/responsive.scss +10 -1
- metadata +10 -12
- data/vendor/assets/stylesheets/bootstrap-responsive.min.css +0 -9
- data/vendor/assets/stylesheets/bootstrap.min.css +0 -9
data/README.md
CHANGED
@@ -28,7 +28,7 @@ Run bundle install:
|
|
28
28
|
|
29
29
|
Get started:
|
30
30
|
|
31
|
-
rails generate bootstrap:install
|
31
|
+
rails generate bootstrap:install -f
|
32
32
|
|
33
33
|
Once you've done that, any time you generate a controller or scaffold, you'll get [Bootstrap](http://twitter.github.com/bootstrap/) templates.
|
34
34
|
|
@@ -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) {
|