Skip to content
This repository
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 307 lines (255 sloc) 14.552 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>Zoomooz.js</title>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" type="text/javascript"></script>

<script type="text/javascript" src="jquery.zoomooz.min.js"></script>

<!--<script type="text/javascript" src="src/js/jquery.zoomooz-anim.js"></script>
<script type="text/javascript" src="src/js/jquery.zoomooz-core.js"></script>
<script type="text/javascript" src="src/js/purecssmatrix.js"></script>
<script type="text/javascript" src="src/js/sylvester.src.stripped.js"></script>-->

<link rel="stylesheet" href="website-assets/website.css" type="text/css" media="screen">
<link rel="stylesheet" href="website-assets/prettyPhoto.css" type="text/css" media="screen">
<script type="text/javascript" src="website-assets/lib/jquery.masonry.min.js"></script>
<script type="text/javascript" src="website-assets/lib/jquery.prettyPhoto.js"></script>

<script type="text/javascript">
$(document).ready(function() {
$(".section, .highlight").click(function(evt) {
$(this).zoomTo({targetsize:0.75, duration:600});
evt.stopPropagation();
});
$(window).click(function(evt) {
$("body").zoomTo({targetsize:1.0, duration:600});
evt.stopPropagation();
});
$("body").zoomTo({targetsize:1.0, duration:600});

$(".innerContent").masonry({columnWidth:210,animate:false});

$(document).ready(function(){
var videoLink = $("a[rel^='prettyPhoto']");
videoLink.prettyPhoto();
videoLink.click(function() {
$("body").zoomTo({targetsize:1.0, duration: 0.0});
});
});
});
</script>
</head>
<body>

<div id="title">
<h2 id="topsubtitle">jQuery</h2>
<h1>Zoomooz.js</h1>
<div class="topdescription">
Zoomooz is an easy-to-use jQuery plugin for making any web page element zoom.
</div>

</div>

<div class="innerContent">

<!--************************
** TITLE **
*************************-->

<div class="section" id="video">
            <a href="http://www.youtube.com/watch?v=faSRI1iAang" rel="prettyPhoto">
                <img src="website-assets/images/video.jpg" width="350" height="259" />
            </a>
            <a class="linkText" href="http://www.youtube.com/watch?v=faSRI1iAang" rel="prettyPhoto">
             Zoomooz on iPad video
            </a>
            
            </div>

<div class="section" id="description">
<p>
<a class="downloadlink" href="http://github.com/jaukia/zoomooz/zipball/master">Download Zoomooz.js (zip)</a>
</p>
<div id="version">Version 0.91 (April 5, 2012, simplifying code base and scrolling for non-body zoom roots)</div>
            <p>
            <a class="downloadlink" href="http://github.com/jaukia/zoomooz/" rel="me">Fork me on GitHub!</a>
</p>
        </div>

<div class="section" id="praise">
<h2>Praise</h2>
<p>
"The fantastic Javascript zooming library has been updated to work with Firefox 4."<br />
— @azaaza
</p>

<p>
"Really awesome example of a zoomable interface with JavaScript"<br />
— @tdhooper
</p>

<p>
"Amazing little js library for zooming and rotating that works with JQuery"<br />
— @mike_j_edwards
</p>

<p>
"#prezi like styles for your own website. damn cool and pretty easy"<br />
— @wollepb
</p>

</div>

   
<div class="section" id="inuse">
<h2>Zoomooz in use</h2>

<p>
<a href="http://www.azarask.in/blog/post/how-to-prototype-and-influence-people/">Aza Raskin prototyping with Zoomooz</a>
</p>

<p>
<a href="http://www.freshwidows.com/STAR/Legs.html">A photo gallery using Zoomooz</a>
</p>

<p>
<a href="http://richard.milewski.org/archives/788">A zooming comic experiment</a>
</p>

<p>
<a href="http://richard.milewski.org/archives/804">Simple HTML Slides uses Zoomooz</a>
</p>
</div>


<!--************************
** EXAMPLES **
*************************-->

<div class="section" style="height:130px;">
<a class="linkblock" href="examples/imagestack/index.html"><img src="website-assets/images/thumbnails/imagestack-clipped.png" width="140" height="105" /></a>
<a class="linkText" href="examples/imagestack/index.html">Flickr image stack</a>
</div>
<div class="section" style="height:130px;">
<a class="linkblock" href="examples/isometric/index.html"><img src="website-assets/images/thumbnails/isometric-clipped.png" width="140" height="105" /></a>
<a class="linkText" href="examples/isometric/index.html">Isometric cube</a>
</div>
<div class="section" style="height:130px;">
<a class="linkblock" href="examples/svgtree/index.html"><img src="website-assets/images/thumbnails/svgtree-clipped.png" width="140" height="105" /></a>
<a class="linkText" href="examples/svgtree/index.html">SVG Tree demo</a>
</div>
<div class="section" style="height:130px;">
<a class="linkblock" href="examples/rootchange/index.html"><img src="website-assets/images/thumbnails/rootchange-clipped.png" width="140" height="105" /></a>
<a class="linkText" href="examples/rootchange/index.html">Zooming container demo</a>
</div>

<!--************************
** ENABLING THE LIBRARY **
*************************-->

<div class="section" id="gettingstarted">
<h2>Enabling the library</h2>

<p>Put the following in the head-section of your page:</p>

<div class="highlight">
<pre><span class="nt">&lt;link</span> <span class="na">rel=</span><span class="s">&quot;stylesheet&quot;</span> <span class="na">href=</span><span class="s">&quot;style/zoomooz.css&quot;</span> <span class="na">type=</span><span class="s">&quot;text/css&quot;</span> <span class="nt">/&gt;</span>
<span class="nt">&lt;script </span><span class="na">type=</span><span class="s">&quot;text/javascript&quot;</span> <span class="na">src=</span><span class="s">&quot;lib/sylvester.js&quot;</span><span class="nt">&gt;&lt;/script&gt;</span>
<span class="nt">&lt;script </span><span class="na">type=</span><span class="s">&quot;text/javascript&quot;</span> <span class="na">src=</span><span class="s">&quot;lib/jquery-1.4.2.js&quot;</span><span class="nt">&gt;&lt;/script&gt;</span>
<span class="nt">&lt;script </span><span class="na">type=</span><span class="s">&quot;text/javascript&quot;</span> <span class="na">src=</span><span class="s">&quot;js/purecssmatrix.js&quot;</span><span class="nt">&gt;&lt;/script&gt;</span>
<span class="nt">&lt;script </span><span class="na">type=</span><span class="s">&quot;text/javascript&quot;</span> <span class="na">src=</span><span class="s">&quot;js/jquery.animtrans.js&quot;</span><span class="nt">&gt;&lt;/script&gt;</span>
<span class="nt">&lt;script </span><span class="na">type=</span><span class="s">&quot;text/javascript&quot;</span> <span class="na">src=</span><span class="s">&quot;js/jquery.zoomooz.js&quot;</span><span class="nt">&gt;&lt;/script&gt;</span>
</pre>
</div>
</div>

<!--************************
** ADDING ZOOM EFFECT **
*************************-->

<div class="section" id="samplecode">
<h2>Adding zoom effect</h2>

<p>This adds a simple zoom on clicking to elements with class "zoomTarget". The zoom can be reset by clicking the body.</p>
<div class="highlight"><pre><span class="nt">&lt;script </span><span class="na">type=</span><span class="s">&quot;text/javascript&quot;</span> <span class="na">language=</span><span class="s">&quot;javascript&quot;</span><span class="nt">&gt;</span>
  <span class="nx">$</span><span class="p">(</span><span class="nb">document</span><span class="p">).</span><span class="nx">ready</span><span class="p">(</span><span class="kd">function</span><span class="p">()</span>
    <span class="nx">$</span><span class="p">(</span><span class="s2">&quot;.zoomTarget&quot;</span><span class="p">).</span><span class="nx">click</span><span class="p">(</span><span class="kd">function</span><span class="p">(</span><span class="nx">evt</span><span class="p">)</span> <span class="p">{</span>
      <span class="nx">$</span><span class="p">(</span><span class="k">this</span><span class="p">).</span><span class="nx">zoomTo</span><span class="p">();</span>
      <span class="nx">evt</span><span class="p">.</span><span class="nx">stopPropagation</span><span class="p">();</span>
    <span class="p">});</span>
    <span class="nx">$</span><span class="p">(</span><span class="s2">&quot;body&quot;</span><span class="p">).</span><span class="nx">click</span><span class="p">(</span><span class="kd">function</span><span class="p">(</span><span class="nx">evt</span><span class="p">)</span> <span class="p">{</span>
      <span class="nx">$</span><span class="p">(</span><span class="k">this</span><span class="p">).</span><span class="nx">zoomTo</span><span class="p">({</span><span class="nx">targetsize</span><span class="o">:</span><span class="mf">1.0</span><span class="p">});</span>
      <span class="nx">evt</span><span class="p">.</span><span class="nx">stopPropagation</span><span class="p">();</span>
    <span class="p">});</span>
  <span class="p">});</span>
<span class="nt">&lt;/script&gt;</span>
</pre></div>
</div>

<!--************************
** BROWSER SUPPORT **
*************************-->

<div class="section">
<h2>Browser support</h2>
<p>All major browser platforms supported now:</p>
<div class="browsers">
<img src="website-assets/images/safari.png" width="32" height="32" alt="Safari">
<img src="website-assets/images/chrome.png" width="32" height="32" alt="Chrome">
<img src="website-assets/images/ff.png" width="32" height="32" alt="Firefox"><br />
<img src="website-assets/images/opera.png" width="32" height="32" alt="Opera">
<img src="website-assets/images/ie.png" width="32" height="32" alt="IE">
</div>
<p>Supported versions</p>
<ul>
<li>Internet Explorer 9</li>
<li>Safari 3 and newer</li>
<li>Firefox 3.6 and newer</li>
<li>Recent versions of Opera and Chrome</li>
</ul>
</ul>
</div>

<!--************************
** DETAILED SETTINGS **
*************************-->

<div class="section" id="detailedsettings">
<h2>Detailed settings</h2>
<div class="highlight"><pre><span class="nx">settings</span> <span class="o">=</span> <span class="p">{</span>
<span class="c1">// zoomed size relative to screen</span>
<span class="c1">// 0.0-1.0</span>
<span class="nx">targetsize</span><span class="o">:</span> <span class="mf">0.9</span><span class="p">,</span>
<span class="c1">// scale content to screen based on their size</span>
<span class="c1">// &quot;width&quot;|&quot;height&quot;|&quot;both&quot;</span>
<span class="nx">scalemode</span><span class="o">:</span> <span class="s2">&quot;both&quot;</span><span class="p">,</span>
<span class="c1">// animation duration</span>
<span class="nx">duration</span><span class="o">:</span> <span class="mi">1000</span><span class="p">,</span>
<span class="c1">// easing of animation, similar to css transition params</span>
<span class="c1">// &quot;linear&quot;|&quot;ease&quot;|&quot;ease-in&quot;|&quot;ease-out&quot;|
// &quot;ease-in-out&quot;|[p1,p2,p3,p4]</span>
<span class="c1">// [p1, p2, p3, p4] refer to cubic-bezier curve params</span>
<span class="nx">easing</span><span class="o">:</span> <span class="s2">&quot;ease&quot;</span><span class="p">,</span>
<span class="c1">// use browser native animation in webkit</span>
<span class="c1">// true|false</span>
<span class="nx">nativeanimation</span><span class="o">:</span> <span class="kc">true</span>
<span class="p">}</span>
<span class="nx">$</span><span class="p">(</span><span class="k">this</span><span class="p">).</span><span class="nx">zoomTo</span><span class="p">(</span><span class="nx">settings</span><span class="p">);</span>
</pre></div>
</div>

<!--************************
** BUGS **
*************************-->

<div class="section">
<h2>Bugs and issues</h2>
<div>
<ul>
<li>Does not work with full-page zooming in Webkit</li>
<li>Requires a separate css file.</li>
<li>Native animation problem in Webkit: animation not working in Webkit with very long pages when zooming with rotation.</li>
<li>Css box-shadows make animations crawl.</li>
<li>Transforming elements with text content in Opera is buggy.</li>
<li>Rotation goes sometimes via the wrong direction.</li>
</ul>
</div>
</div>

<!--************************
** FEATURES **
*************************-->

<div class="section">
<h2>Some feature ideas</h2>
<div>
<ul>
<li>Make it work in older IE versions.</li>
<li>Have zooming out return to the same scroll position</li>
<li>Support for 3d transformations.</li>
<li>Hide elements that are not shown while transforming.</li>
<li>Kinetic scrolling.</li>
</ul>
</div>
</div>
        

        <!--************************
** GOOGLE ANALYTICS **
*************************-->

<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-16288001-1");
pageTracker._trackPageview();
} catch(err) {}</script>

        </div>
 
         <!--************************
** FOOTER **
*************************-->

    <div id="footer">
    Made by Janne Aukia. Uses jQuery Masonry.
    </div>

</body>
</html>
Something went wrong with that request. Please try again.