| 1 | <!doctype html> |
| 2 | <html lang="en"> |
| 3 | <head> |
| 4 | <meta charset="utf-8"> |
| 5 | <title>addClass Visual Test : Queue</title> |
| 6 | <link rel="stylesheet" href="../../../themes/base/all.css"> |
| 7 | <style> |
| 8 | .box { |
| 9 | width: 100px; |
| 10 | height: 100px; |
| 11 | background-color: #000; |
| 12 | } |
| 13 | .red { |
| 14 | background-color: #f00; |
| 15 | } |
| 16 | .green { |
| 17 | background-color: #0f0; |
| 18 | } |
| 19 | .blue { |
| 20 | background-color: #00f; |
| 21 | } |
| 22 | </style> |
| 23 | <script src="../../../external/requirejs/require.js"></script> |
| 24 | <script src="../../../demos/bootstrap.js" data-modules="effect" data-composite="true"> |
| 25 | $( "#box1" ) |
| 26 | .delay( 500 ) |
| 27 | .addClass( "red", 2000 ) |
| 28 | .delay( 500 ) |
| 29 | .addClass( "green", 2000 ) |
| 30 | .delay( 500 ) |
| 31 | .addClass( "blue", 2000 ); |
| 32 | $( "#box2" ) |
| 33 | .addClass( "red", 2000 ) |
| 34 | .delay( 500 ) |
| 35 | .addClass( "green", 2000 ) |
| 36 | .delay( 500 ) |
| 37 | .addClass( "blue", 2000 ); |
| 38 | </script> |
| 39 | </head> |
| 40 | <body> |
| 41 | |
| 42 | <p>WHAT: The two boxes animate from black to red to green to blue.</p> |
| 43 | <p>EXPECTED: The first box should start with a delay, the second box should start immediately.</p> |
| 44 | |
| 45 | <div id="box1" class="box"></div> |
| 46 | <div id="box2" class="box"></div> |
| 47 | |
| 48 | </body> |
| 49 | </html> |