Skip to content

Commit

Permalink
rake convert[v3.4.0-dev]
Browse files Browse the repository at this point in the history
  • Loading branch information
glebm committed Dec 14, 2018
1 parent 58db771 commit 3db610a
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 15 deletions.
12 changes: 7 additions & 5 deletions assets/javascripts/bootstrap.js
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ if (typeof jQuery === 'undefined') {
}

Collapse.prototype.getParent = function () {
return $(this.options.parent)
return $(document).find(this.options.parent)
.find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]')
.each($.proxy(function (i, element) {
var $element = $(element)
Expand Down Expand Up @@ -1320,7 +1320,7 @@ if (typeof jQuery === 'undefined') {
this.type = type
this.$element = $(element)
this.options = this.getOptions(options)
this.$viewport = this.options.viewport && $($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport))
this.$viewport = this.options.viewport && $(document).find($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport))
this.inState = { click: false, hover: false, focus: false }

if (this.$element[0] instanceof document.constructor && !this.options.selector) {
Expand Down Expand Up @@ -1473,7 +1473,7 @@ if (typeof jQuery === 'undefined') {
.addClass(placement)
.data('bs.' + this.type, this)

this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
this.options.container ? $tip.appendTo($(document).find(this.options.container)) : $tip.insertAfter(this.$element)
this.$element.trigger('inserted.bs.' + this.type)

var pos = this.getPosition()
Expand Down Expand Up @@ -2120,7 +2120,7 @@ if (typeof jQuery === 'undefined') {

if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return

var $target = $(selector)
var $target = $(document).find(selector)

this.activate($this.closest('li'), $ul)
this.activate($target, $target.parent(), function () {
Expand Down Expand Up @@ -2244,7 +2244,9 @@ if (typeof jQuery === 'undefined') {
var Affix = function (element, options) {
this.options = $.extend({}, Affix.DEFAULTS, options)

this.$target = $(this.options.target)
var target = this.options.target === Affix.DEFAULTS.target ? $(this.options.target) : $(document).find(this.options.target)

this.$target = target
.on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this))
.on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this))

Expand Down
2 changes: 1 addition & 1 deletion assets/javascripts/bootstrap.min.js

Large diffs are not rendered by default.

4 changes: 3 additions & 1 deletion assets/javascripts/bootstrap/affix.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@
var Affix = function (element, options) {
this.options = $.extend({}, Affix.DEFAULTS, options)

this.$target = $(this.options.target)
var target = this.options.target === Affix.DEFAULTS.target ? $(this.options.target) : $(document).find(this.options.target)

this.$target = target
.on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this))
.on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this))

Expand Down
2 changes: 1 addition & 1 deletion assets/javascripts/bootstrap/collapse.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@
}

Collapse.prototype.getParent = function () {
return $(this.options.parent)
return $(document).find(this.options.parent)
.find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]')
.each($.proxy(function (i, element) {
var $element = $(element)
Expand Down
2 changes: 1 addition & 1 deletion assets/javascripts/bootstrap/tab.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@

if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return

var $target = $(selector)
var $target = $(document).find(selector)

this.activate($this.closest('li'), $ul)
this.activate($target, $target.parent(), function () {
Expand Down
4 changes: 2 additions & 2 deletions assets/javascripts/bootstrap/tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
this.type = type
this.$element = $(element)
this.options = this.getOptions(options)
this.$viewport = this.options.viewport && $($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport))
this.$viewport = this.options.viewport && $(document).find($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport))
this.inState = { click: false, hover: false, focus: false }

if (this.$element[0] instanceof document.constructor && !this.options.selector) {
Expand Down Expand Up @@ -204,7 +204,7 @@
.addClass(placement)
.data('bs.' + this.type, this)

this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
this.options.container ? $tip.appendTo($(document).find(this.options.container)) : $tip.insertAfter(this.$element)
this.$element.trigger('inserted.bs.' + this.type)

var pos = this.getPosition()
Expand Down
4 changes: 2 additions & 2 deletions assets/stylesheets/bootstrap/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ $link-hover-decoration: underline !default;
//
//## Font, line-height, and color for body text, headings, and more.

$font-family-sans-serif: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !default;
$font-family-sans-serif: "Helvetica Neue", Helvetica, Arial, sans-serif !default;
$font-family-serif: Georgia, "Times New Roman", Times, serif !default;
//** Default monospace fonts for `<code>`, `<kbd>`, and `<pre>`.
$font-family-monospace: "SFMono-Regular", Menlo, Monaco, Consolas, "Courier New", monospace !default;
$font-family-monospace: Menlo, Monaco, Consolas, "Courier New", monospace !default;
$font-family-base: $font-family-sans-serif !default;

$font-size-base: 14px !default;
Expand Down
4 changes: 2 additions & 2 deletions templates/project/_bootstrap-variables.sass
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@
//
//## Font, line-height, and color for body text, headings, and more.
// $font-family-sans-serif: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif
// $font-family-sans-serif: "Helvetica Neue", Helvetica, Arial, sans-serif
// $font-family-serif: Georgia, "Times New Roman", Times, serif
//** Default monospace fonts for `<code>`, `<kbd>`, and `<pre>`.
// $font-family-monospace: "SFMono-Regular", Menlo, Monaco, Consolas, "Courier New", monospace
// $font-family-monospace: Menlo, Monaco, Consolas, "Courier New", monospace
// $font-family-base: $font-family-sans-serif
// $font-size-base: 14px
Expand Down

0 comments on commit 3db610a

Please sign in to comment.