Better cross browser support for classic closure animation

print-window-tiddler
Jeremy Ruston 2012-06-22 09:26:59 +01:00
rodzic 7dcbefa9bc
commit d9c916715b
3 zmienionych plików z 11 dodań i 3 usunięć

Wyświetl plik

@ -49,7 +49,7 @@ ClassicScroller.prototype.close = function(targetTiddlerNode,sourceEvent) {
wrapperElement.style.height = "0px";
});
// Attach an event handler for th eend of the transition
wrapperElement.addEventListener("webkitTransitionEnd",function(event) {
wrapperElement.addEventListener($tw.browser.transitionEnd,function(event) {
if(wrapperElement.parentNode) {
wrapperElement.parentNode.removeChild(wrapperElement);
}

Wyświetl plik

@ -19,10 +19,18 @@ exports.startup = function() {
$tw.browser.unHyphenateCss = document.body.style["background-color"] === undefined;
$tw.browser.prefix = document.body.style.webkitTransform !== undefined ? "webkit" :
document.body.style.MozTransform !== undefined ? "Moz" :
document.body.style.OTransform !== undefined ? "O" : null;
document.body.style.MSTransform !== undefined ? "MS" :
document.body.style.OTransform !== undefined ? "O" : "";
$tw.browser.transition = $tw.browser.prefix + "Transition";
$tw.browser.transform = $tw.browser.prefix + "Transform";
$tw.browser.transformorigin = $tw.browser.prefix + "TransformOrigin";
$tw.browser.transitionEnd = {
"": "transitionEnd",
"O": "oTransitionEnd",
"MS": "msTransitionEnd",
"Moz": "transitionend",
"webkit": "webkitTransitionEnd"
}[$tw.browser.prefix];
}
// Set up additional global objects
$tw.plugins.applyMethods("global",$tw);

Wyświetl plik

@ -3,7 +3,7 @@ tags: introduction
TiddlyWiki5 gains new capabilities through a [[completely rebuilt architecture|TiddlyWikiArchitecture]] using the latest features of HTML5 and node.js. It runs natively under node.js, and can also use its own components to construct a version of itself that works entirely within the browser, just as TiddlyWiki has always done.
You can modify this wiki, and then download a copy by clicking this button:
If you're running Google Chrome Canary you can modify this wiki, and then download a copy by clicking this button:
<<download filename:"TiddlyWiki.html" label:"Save Changes">>
You can download a static copy of the tiddlers that are currently displayed in this wiki by clicking this button: <<download title:"$:/core/static.template.html" filename:"Story.html" label:"Static Wiki">>