Git Product home page Git Product logo

Comments (8)

ahmedrad avatar ahmedrad commented on July 1, 2024

You're right looks like my scroll disable script doesn't support touch devices @generatepress .. I'll update and close the issue once I test it!

Thanks for point it out 👍

from sliiide.

generatepress avatar generatepress commented on July 1, 2024

Awesome, thanks!

from sliiide.

ahmedrad avatar ahmedrad commented on July 1, 2024

Ok It's updated and tested on nexus 5 and iphone 6 .. the scroll flag should be working on mobile now. You can test it out here

I'm gonna close this issue for now but just let me know if you run into any related issues or open a new one if it's unrelated 😄 @generatepress

from sliiide.

generatepress avatar generatepress commented on July 1, 2024

Looks like it's working - thanks! :)

However, my slide out content is longer than the initial viewport on mobile, so I had to add overflow: auto to it.

This update made it so I can't scroll within my slide out content on mobile either - seems to have disabled mobile scrolling altogether instead of just within the body content.

from sliiide.

ahmedrad avatar ahmedrad commented on July 1, 2024

Yeah the listener that prevents scroll is attached to the body so it applies to all elements. Can you send me a fiddle or a live page that you're working with? I have an idea I can try out as a quick fix. the plugin wasn't really designed for large pieces of content that's why I never considered that case but I could potentially have a quick fix for it @generatepress

from sliiide.

generatepress avatar generatepress commented on July 1, 2024

Maybe this will help: http://codepen.io/anon/pen/rOqyNd

Basically it would be great if we were able to scroll inside the slideout element. Some mobile phones don't have a lot of visible room, so scrolling can be necessary to see all links or content.

Thanks! :)

from sliiide.

ahmedrad avatar ahmedrad commented on July 1, 2024

Ok I see, the disable scroll function is pure javascript so it attaches to window. Try dropping my no_scroll functionality and using this instead https://github.com/ultrapasty/jquery-disablescroll

I'll try porting over my code to jQuery that will probably help with but I think it'll take time for me to do it and test it on a bunch of browsers so in the mean time give that plugin above a shot, I think it can solve your problem @generatepress

from sliiide.

generatepress avatar generatepress commented on July 1, 2024

I found the best way to do this is to add a class to the body element when the slider is opened.

Then just add some simple CSS:

.slide-opened {
    overflow: hidden;
}

.slideout-content {
    overflow-y: auto;
}

from sliiide.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.