/*\ title: $:/core/modules/macros/story/views/zoomin.js type: application/javascript module-type: storyview A storyview that shows a single tiddler and navigates by zooming into links. To do this, the story wrapper is set to `position:relative` and then each of the story elements to `position:absolute`. This results in all of the tiddlers being stacked on top of one another flush with the top left of the story wrapper. Navigating between tiddlers is accomplished by switching the story nodes between `display:block` and `display:none`, but the implementation is considerably more complex due to the animation. \*/ (function(){ /*jslint node: true, browser: true */ /*global $tw: false, Node: false */ "use strict"; function Zoomin(story) { // Save the story this.story = story; this.storyNode = this.story.child.domNode; // Set the current tiddler this.currentTiddler = this.story.child.children[0]; // Make all the tiddlers position absolute, and hide all but the first one this.storyNode.style.position = "relative"; for(var t=0; t> macro */ function findTitleNode(node) { var r; if(node.macroName && node.macroName === "view" && node.params && node.params.field && node.params.field === "title") { return node; } if(node.children) { for(var t=0; t