Fix mobilenav and modal
[plack-app-gruntmaster.git] / js / 10-modal.js
index 62cbb271c56b32f0f779d0ca4529814aeadeb9b8..3a8a214a6c1716bda539d27ed58ff7b2313bd0e2 100644 (file)
@@ -21,8 +21,10 @@ $(function() {
        });
        $('.backdrop,.modal').each(el => document.body.appendChild(el) );
        $('#solution').on('click', e => {
-               show_modal();
-               e.preventDefault();
+               if(window.matchMedia("(min-width: 768px)").matches){
+                       show_modal();
+                       e.preventDefault();
+               }
        });
        $('.backdrop').on('click', hide_modal);
        window.onkeyup = event => {
This page took 0.009473 seconds and 4 git commands to generate.