|
|
|
@ -177,6 +177,7 @@
|
|
|
|
|
if (transitionFromObj.transition) { |
|
|
|
|
activeObj = extendWithDom(activeObj, '.content', activeDom.cloneNode(true)); |
|
|
|
|
for (key in bars) { |
|
|
|
|
if (bars.hasOwnProperty(key)) { |
|
|
|
|
barElement = document.querySelector(bars[key]); |
|
|
|
|
if (activeObj[key]) { |
|
|
|
|
swapContent(activeObj[key], barElement); |
|
|
|
@ -185,6 +186,7 @@
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
swapContent( |
|
|
|
|
(activeObj.contents || activeDom).cloneNode(true), |
|
|
|
@ -208,8 +210,10 @@
|
|
|
|
|
options.container = options.container || options.transition ? document.querySelector('.content') : document.body; |
|
|
|
|
|
|
|
|
|
for (key in bars) { |
|
|
|
|
if (bars.hasOwnProperty(key)) { |
|
|
|
|
options[key] = options[key] || document.querySelector(bars[key]); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (xhr && xhr.readyState < 4) { |
|
|
|
|
xhr.onreadystatechange = noop; |
|
|
|
@ -269,6 +273,7 @@
|
|
|
|
|
|
|
|
|
|
if (options.transition) { |
|
|
|
|
for (key in bars) { |
|
|
|
|
if (bars.hasOwnProperty(key)) { |
|
|
|
|
barElement = document.querySelector(bars[key]); |
|
|
|
|
if (data[key]) { |
|
|
|
|
swapContent(data[key], barElement); |
|
|
|
@ -277,6 +282,7 @@
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
swapContent(data.contents, options.container, options.transition, function () { |
|
|
|
|
cacheReplace({ |
|
|
|
@ -408,8 +414,10 @@
|
|
|
|
|
var result = {}; |
|
|
|
|
|
|
|
|
|
for (i in obj) { |
|
|
|
|
if (obj.hasOwnProperty(i)) { |
|
|
|
|
result[i] = obj[i]; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
Object.keys(bars).forEach(function (key) { |
|
|
|
|
var el = dom.querySelector(bars[key]); |
|
|
|
|