Skip to content

Commit

Permalink
修复了$.fn.emulateTransition可能和其他框架造成冲突的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
zhaoda committed Sep 23, 2015
1 parent 6d8bd00 commit febd056
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions dist/spa-apis.js
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@
requestAnimationFrame(function() {
$el.get(0).offsetWidth
properties[transitionName] = '0.4s'
$el.css(properties).emulateTransitionEnd(function() {
$el.css(properties).emulateTransitionEndBySpa(function() {
// 过渡动画结束后移除 transition
properties = {}
properties[transitionName] = ''
Expand All @@ -466,7 +466,7 @@
}

// transitionEnd 回调
$.fn.emulateTransitionEnd = function(callback, duration) {
$.fn.emulateTransitionEndBySpa = function(callback, duration) {
var called = false,
$el = $(this),
endtimer
Expand Down
2 changes: 1 addition & 1 deletion dist/spa-apis.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/spa.js
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@
requestAnimationFrame(function() {
$el.get(0).offsetWidth
properties[transitionName] = '0.4s'
$el.css(properties).emulateTransitionEnd(function() {
$el.css(properties).emulateTransitionEndBySpa(function() {
// 过渡动画结束后移除 transition
properties = {}
properties[transitionName] = ''
Expand All @@ -466,7 +466,7 @@
}

// transitionEnd 回调
$.fn.emulateTransitionEnd = function(callback, duration) {
$.fn.emulateTransitionEndBySpa = function(callback, duration) {
var called = false,
$el = $(this),
endtimer
Expand Down
2 changes: 1 addition & 1 deletion dist/spa.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/spa.js
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@
requestAnimationFrame(function() {
$el.get(0).offsetWidth
properties[transitionName] = '0.4s'
$el.css(properties).emulateTransitionEnd(function() {
$el.css(properties).emulateTransitionEndBySpa(function() {
// 过渡动画结束后移除 transition
properties = {}
properties[transitionName] = ''
Expand All @@ -459,7 +459,7 @@
}

// transitionEnd 回调
$.fn.emulateTransitionEnd = function(callback, duration) {
$.fn.emulateTransitionEndBySpa = function(callback, duration) {
var called = false,
$el = $(this),
endtimer
Expand Down

0 comments on commit febd056

Please sign in to comment.