Skip to content
This repository
tree: ee77d69039
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 49 lines (43 sloc) 1.914 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
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="maximum-scale=1,initial-scale=1,user-scalable=0">
  <link rel="stylesheet" href="test.css">
  <title>Zepto fx functional test</title>
  <script src="../src/polyfill.js"></script>
  <script src="../src/zepto.js"></script>
  <script src="../src/event.js"></script>
  <script src="../src/fx.js"></script>
  <script src="../src/fx_methods.js"></script>
  <style>
    #fx_test, #fx_test_2 { text-align: center; background: darkred; color: white; font-size: x-large; }
    #fx_test_2 { background: darkblue; }
  </style>
</head>
<body>
  <h1>Zepto fx functional</h1>

  <div style="width: 280px; height: 180px; background: #ddd; -webkit-user-select: none; margin-bottom: 1em">
    <div id="fx_test" style="height: 100%; line-height: 170px">I ♥ fx</div>
  </div>

  <div style="width: 280px; height: 180px; background: #ddd; -webkit-user-select: none; margin-bottom: 1em">
    <div id="fx_test_2" style="height: 100%; line-height: 170px">I ♥ fx</div>
  </div>

  <button onclick="$('#fx_test').hide('slow')">Hide</button>
  <button onclick="$('#fx_test').show('slow')">Show</button>
  <button onclick="$('#fx_test').show()">Reg. show</button>
  <button onclick="$('#fx_test').toggle('slow')">Toggle</button>
  <button onclick="$('#fx_test, #fx_test_2').toggle('slow')">Both: Toggle ('slow')</button>
  <button onclick="$('#fx_test, #fx_test_2').toggle()">Both: Toggle</button>
  <br>
  <button onclick="$('#fx_test').fadeIn('slow')">Fade in</button>
  <button onclick="$('#fx_test').fadeOut('slow')">Fade out</button>
  <button onclick="$('#fx_test').fadeToggle('slow')">Fade toggle</button>
  <button onclick="$('#fx_test, #fx_test_2').fadeToggle('slow')">Both: Fade toggle</button>

  <div id="browser"> </div>

  <script>
    $('#browser').text(navigator.userAgent)
    $('#fx_test_2').toggle()
  </script>
</body>
</html>
Something went wrong with that request. Please try again.