options-wheelPropagation.html 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta http-equiv="content-type" content="text/html; charset=utf-8">
  5. <title>perfect-scrollbar example</title>
  6. <link href="../dist/css/perfect-scrollbar.css" rel="stylesheet">
  7. <script src="../dist/js/perfect-scrollbar.js"></script>
  8. <style>
  9. .contentHolder { position:relative; margin:0px auto; padding:0px; width: 600px; height: 400px; overflow: auto; }
  10. .contentHolder .content { background-image: url('./azusa.jpg'); width: 1280px; height: 720px; }
  11. .spacer { text-align:center }
  12. </style>
  13. </head>
  14. <body>
  15. <h1 style="text-align:center">Default; wheelPropagation:false</h1>
  16. <div id="Default" class="contentHolder">
  17. <div class="content">
  18. </div>
  19. </div>
  20. <h1 style="text-align:center">wheelPropagation:true</h1>
  21. <div id="WheelPropagation" class="contentHolder">
  22. <div class="content">
  23. </div>
  24. </div>
  25. <div class="spacer">
  26. Note<br>that<br>there<br>is<br>plenty<br>of<br>text<br>after<br>the<br>image<br>to<br>ensure<br>that<br>it<br>is<br>possible<br>to<br>down<br>
  27. after<br>the<br>bottom<br>of<br>the<br>image<br>has<br>been<br>reached<br>to<br>enable<br>the<br>wheel<br>propagation<br>to<br>be<br>tested<br>
  28. </div>
  29. <script>
  30. var $ = document.querySelector.bind(document);
  31. window.onload = function () {
  32. Ps.initialize($('#Default'));
  33. Ps.initialize($('#WheelPropagation'), {wheelPropagation: true});
  34. };
  35. </script>
  36. </body>
  37. </html>