destroy.html 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376
  1. <!doctype html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <title>destroy &middot; Isotope </title>
  6. <!--[if lt IE 9]><script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
  7. <link rel="stylesheet" href="../css/style.css" />
  8. <!-- scripts at bottom of page -->
  9. </head>
  10. <body class="tests ">
  11. <nav id="site-nav">
  12. <h1><a href="../index.html">Isotope</a></h1>
  13. <h2>Docs</h2>
  14. <ul>
  15. <li><a href="../docs/introduction.html">Introduction</a>
  16. <li><a href="../docs/options.html">Options</a>
  17. <li><a href="../docs/methods.html">Methods</a>
  18. <li><a href="../docs/layout-modes.html">Layout modes</a>
  19. <li><a href="../docs/filtering.html">Filtering</a>
  20. <li><a href="../docs/sorting.html">Sorting</a>
  21. <li><a href="../docs/animating.html">Animating</a>
  22. <li><a href="../docs/adding-items.html">Adding items</a>
  23. <li><a href="../docs/extending-isotope.html">Extending Isotope</a>
  24. <li><a href="../docs/hash-history-jquery-bbq.html">Hash history with jQuery BBQ</a>
  25. <li><a href="../docs/help.html">Help</a>
  26. <li><a href="../docs/license.html">License</a>
  27. </ul>
  28. <h2>Demos</h2>
  29. <ul>
  30. <li><a href="../demos/basic.html">Basic</a>
  31. <li><a href="../demos/elements-complete.html">Elements Complete</a>
  32. <li><a href="../demos/elements-partial.html">Elements Partial</a>
  33. <li><a href="../demos/layout-modes.html">Layout modes</a>
  34. <li><a href="../demos/filtering.html">Filtering</a>
  35. <li><a href="../demos/sorting.html">Sorting</a>
  36. <li><a href="../demos/relayout.html">reLayout</a>
  37. <li><a href="../demos/adding-items.html">Adding items</a>
  38. <li><a href="../demos/infinite-scroll.html">Infinite Scroll</a>
  39. <li><a href="../demos/images.html">Images</a>
  40. <li><a href="../demos/combination-filters.html">Combination filters</a>
  41. <li><a href="../demos/hash-history.html">Hash history</a>
  42. <li><a href="../demos/fluid-responsive.html">Fluid / responsive</a>
  43. </ul>
  44. <h2>Custom layout modes</h2>
  45. <ul>
  46. <li><a href="../custom-layout-modes/centered-masonry.html">Centered Masonry</a>
  47. <li><a href="../custom-layout-modes/category-rows.html">Category rows</a>
  48. <li><a href="../custom-layout-modes/masonry-corner-stamp.html">Masonry corner stamp</a>
  49. <li><a href="../custom-layout-modes/masonry-gutters.html">Masonry gutters</a>
  50. <li><a href="../custom-layout-modes/spine-align.html">Spine align</a>
  51. </ul>
  52. <h2><a href="../tests/index.html">Tests</a></h2>
  53. </nav> <!-- #site-nav -->
  54. <section id="content">
  55. <h1>destroy</h1>
  56. <style>
  57. #container {
  58. width: 80%;
  59. height: 80%;
  60. }
  61. </style>
  62. <section id="copy">
  63. <p>Click <em>init</em> button the <em>destroy</em>. Original CSS, pre-init, should be re-applied, all items back to visibility.</p>
  64. </section>
  65. <section id="options">
  66. <button id="init">Init Isotope instance</button>
  67. <button id="destroy">Destroy Isotope instance</button>
  68. </section>
  69. <div id="container" style="height: 600px">
  70. <div class="element other nonmetal " data-symbol="H" data-category="other">
  71. <p class="number">1</p>
  72. <h3 class="symbol">H</h3>
  73. <h2 class="name">Hydrogen</h2>
  74. <p class="weight">1.00794</p>
  75. </div>
  76. <div class="element noble-gas nonmetal " data-symbol="He" data-category="noble-gas">
  77. <p class="number">2</p>
  78. <h3 class="symbol">He</h3>
  79. <h2 class="name">Helium</h2>
  80. <p class="weight">4.002602</p>
  81. </div>
  82. <div class="element alkali metal " data-symbol="Li" data-category="alkali">
  83. <p class="number">3</p>
  84. <h3 class="symbol">Li</h3>
  85. <h2 class="name">Lithium</h2>
  86. <p class="weight">6.941</p>
  87. </div>
  88. <div class="element alkaline-earth metal " data-symbol="Be" data-category="alkaline-earth">
  89. <p class="number">4</p>
  90. <h3 class="symbol">Be</h3>
  91. <h2 class="name">Beryllium</h2>
  92. <p class="weight">9.012182</p>
  93. </div>
  94. <div class="element metalloid " data-symbol="B" data-category="metalloid">
  95. <p class="number">5</p>
  96. <h3 class="symbol">B</h3>
  97. <h2 class="name">Boron</h2>
  98. <p class="weight">10.811</p>
  99. </div>
  100. <div class="element other nonmetal " data-symbol="C" data-category="other">
  101. <p class="number">6</p>
  102. <h3 class="symbol">C</h3>
  103. <h2 class="name">Carbon</h2>
  104. <p class="weight">12.0107</p>
  105. </div>
  106. <div class="element other nonmetal " data-symbol="N" data-category="other">
  107. <p class="number">7</p>
  108. <h3 class="symbol">N</h3>
  109. <h2 class="name">Nitrogen</h2>
  110. <p class="weight">14.0067</p>
  111. </div>
  112. <div class="element other nonmetal " data-symbol="O" data-category="other">
  113. <p class="number">8</p>
  114. <h3 class="symbol">O</h3>
  115. <h2 class="name">Oxygen</h2>
  116. <p class="weight">15.9994</p>
  117. </div>
  118. <div class="element halogen nonmetal " data-symbol="F" data-category="halogen">
  119. <p class="number">9</p>
  120. <h3 class="symbol">F</h3>
  121. <h2 class="name">Fluorine</h2>
  122. <p class="weight">18.9984032</p>
  123. </div>
  124. <div class="element noble-gas nonmetal " data-symbol="Ne" data-category="noble-gas">
  125. <p class="number">10</p>
  126. <h3 class="symbol">Ne</h3>
  127. <h2 class="name">Neon</h2>
  128. <p class="weight">20.1797</p>
  129. </div>
  130. <div class="element alkali metal " data-symbol="Na" data-category="alkali">
  131. <p class="number">11</p>
  132. <h3 class="symbol">Na</h3>
  133. <h2 class="name">Sodium</h2>
  134. <p class="weight">22.98976928</p>
  135. </div>
  136. <div class="element alkaline-earth metal " data-symbol="Mg" data-category="alkaline-earth">
  137. <p class="number">12</p>
  138. <h3 class="symbol">Mg</h3>
  139. <h2 class="name">Magnesium</h2>
  140. <p class="weight">24.305</p>
  141. </div>
  142. <div class="element post-transition metal " data-symbol="Al" data-category="post-transition">
  143. <p class="number">13</p>
  144. <h3 class="symbol">Al</h3>
  145. <h2 class="name">Aluminium</h2>
  146. <p class="weight">26.9815386</p>
  147. </div>
  148. <div class="element metalloid " data-symbol="Si" data-category="metalloid">
  149. <p class="number">14</p>
  150. <h3 class="symbol">Si</h3>
  151. <h2 class="name">Silicon</h2>
  152. <p class="weight">28.0855</p>
  153. </div>
  154. <div class="element other nonmetal " data-symbol="P" data-category="other">
  155. <p class="number">15</p>
  156. <h3 class="symbol">P</h3>
  157. <h2 class="name">Phosphorus</h2>
  158. <p class="weight">30.973762</p>
  159. </div>
  160. <div class="element other nonmetal " data-symbol="S" data-category="other">
  161. <p class="number">16</p>
  162. <h3 class="symbol">S</h3>
  163. <h2 class="name">Sulfur</h2>
  164. <p class="weight">32.065</p>
  165. </div>
  166. <div class="element halogen nonmetal " data-symbol="Cl" data-category="halogen">
  167. <p class="number">17</p>
  168. <h3 class="symbol">Cl</h3>
  169. <h2 class="name">Chlorine</h2>
  170. <p class="weight">35.453</p>
  171. </div>
  172. <div class="element noble-gas nonmetal " data-symbol="Ar" data-category="noble-gas">
  173. <p class="number">18</p>
  174. <h3 class="symbol">Ar</h3>
  175. <h2 class="name">Argon</h2>
  176. <p class="weight">39.948</p>
  177. </div>
  178. <div class="element alkali metal " data-symbol="K" data-category="alkali">
  179. <p class="number">19</p>
  180. <h3 class="symbol">K</h3>
  181. <h2 class="name">Potassium</h2>
  182. <p class="weight">39.0983</p>
  183. </div>
  184. <div class="element alkaline-earth metal " data-symbol="Ca" data-category="alkaline-earth">
  185. <p class="number">20</p>
  186. <h3 class="symbol">Ca</h3>
  187. <h2 class="name">Calcium</h2>
  188. <p class="weight">40.078</p>
  189. </div>
  190. </div> <!-- #container -->
  191. <script src="../js/jquery-1.6.4.min.js"></script>
  192. <script src="../jquery.isotope.min.js"></script>
  193. <script>
  194. $(function(){
  195. var $container = $('#container');
  196. $('#init').click(function(){
  197. $container.isotope({
  198. itemSelector: '.element',
  199. filter: '.metal'
  200. });
  201. });
  202. $('#destroy').click(function(){
  203. $container.isotope('destroy');
  204. });
  205. });
  206. </script>
  207. <footer>
  208. Isotope by <a href="http://desandro.com">David DeSandro</a> / <a href="http://metafizzy.co">Metafizzy</a>
  209. </footer>
  210. </section> <!-- #content -->
  211. </body>
  212. </html>