Sidetap icon indicating copy to clipboard operation
Sidetap copied to clipboard

When require zepto.js it does run!

Open snamper opened this issue 12 years ago • 2 comments

when i replace the query with zepto ,but it doesn't run。

snamper avatar Feb 17 '13 00:02 snamper

Here's how I got it to work:

in stonehenge.js

change

_results.push(thumbs.push($("<img src='" + img.url_s + "' />").load(function() {

to

_results.push(thumbs.push($("<img src='" + img.url_s + "' />").on("load", function() {

change

$("<img src='" + img.url_z + "' />").load(function() {

to

$("<img src='" + img.url_z + "' />").on("load", function() {

(optional code cleanup) in images.js

  • replace http: with https:
  • remove line 14 (image no longer exists on flickr)

in index.html

change

<script type="text/javascript" src="../../lib/jquery.1.7.2.js"></script>

to

<script type="text/javascript" src="https://github.com/ftlabs/fastclick/raw/master/lib/fastclick.js"></script>
<script type="text/javascript" src="http://zeptojs.com/zepto.js"></script>
<script type="text/javascript" src="https://github.com/madrobby/zepto/blob/master/src/fx_methods.js"></script>

replace the google-analytics code at the bottom of index.html with

    <script type="text/javascript">
        window.addEventListener('load', function() {
            new FastClick(document.body);
        }, false);
    </script>

stela5 avatar Feb 18 '13 23:02 stela5

thank you very much

snamper avatar Feb 20 '13 01:02 snamper