Git Product home page Git Product logo

Comments (8)

ahmedrad avatar ahmedrad commented on July 19, 2024

Hi @lauralisa,

The plugin is not built with a swipe functionality but you do have access to the activate() and deactivate() functions that is in the returned object after activating sliiide. If you want it to work with a swipe event just make an event listener that calls the activate() function.

the code would look something like this

<button id="nav-open">open menu</button>
<div id="my-menu"><a>link1</a><a>linke2</a><a class="close-link">Close</a></div>
<script>
var menu = $('#my-menu').sliiide({place: 'left', exit_selector: '.close-link', toggle: '#nav-open', no_scroll: true});

$(window).on('swiperight', function() {menu.activate();});
$(window).on('swipeleft', function(){menu.deactivate();});
</script>

Hope this helps! :)

from sliiide.

lauralisa avatar lauralisa commented on July 19, 2024

Thank you!! I hope you can answer just one more question..
I can't get the panel to fix (to scroll separatly from the main container). Any tips?
Regards, Laura

from sliiide.

ahmedrad avatar ahmedrad commented on July 19, 2024

hi @lauralisa it's difficult for me to understand without seeing the code, is there a website or a fiddle or a codepen snippet I can check this issue in?

from sliiide.

lauralisa avatar lauralisa commented on July 19, 2024

Hi Ahmed,

The url is www.lauralisa.nl/ralf http://www.lauralisa.nl/ralf , user = rm, pass = 643

The problem is that on mobile devices the whole page scrolls. The panel needs to be fixed. There is a submenu when you click on projects (than the panel needs to scroll).

I really appreciate your mail, thank you.

Van: Ahmed Radwan [mailto:[email protected]]
Verzonden: Monday, November 9, 2015 9:16 PM
Aan: ahmedrad/sliiide [email protected]
CC: lauralisa [email protected]
Onderwerp: Re: [sliiide] Toggle image by click or swipe (#5)

hi @lauralisa https://github.com/lauralisa it's difficult for me to understand without seeing the code, is there a website or a fiddle or a codepen snippet I can check this issue in?


Reply to this email directly or view it on GitHub #5 (comment) . https://github.com/notifications/beacon/AO8oIWJYPFC4iZnMu7slXyq4QSdqPF8Eks5pEPaTgaJpZM4Gcryj.gif

from sliiide.

ahmedrad avatar ahmedrad commented on July 19, 2024

Hey @lauralisa,

It seems like there's a problem with fixed position elements and CSS transform. I don't think I'll be able to resolve it soon so I'll re-open this issue. You could just disable scroll all together on the page when the menu is open which would avoid the problem. Hope this helps!

Cheers,

from sliiide.

lauralisa avatar lauralisa commented on July 19, 2024

Hi Ahmed,

Ok thank you. I cannot disable scroll because the submenu is too long. But i’ll find another way.

Regards,

Laura

Van: Ahmed Radwan [mailto:[email protected]]
Verzonden: Friday, November 13, 2015 11:16 AM
Aan: ahmedrad/sliiide [email protected]
CC: lauralisa [email protected]
Onderwerp: Re: [sliiide] Toggle image by click or swipe (#5)

Hey @lauralisa https://github.com/lauralisa ,

It seems like there's a problem with fixed position elements and CSS transform. I don't think I'll be able to resolve it soon so I'll re-open this issue. You could just disable scroll all together on the page when the menu is open which would avoid the problem. Hope this helps!

Cheers,


Reply to this email directly or view it on GitHub #5 (comment) . https://github.com/notifications/beacon/AO8oIS1NLp16zxbPqwxzBqU2g64dtaLIks5pFa_kgaJpZM4Gcryj.gif

from sliiide.

ahmedrad avatar ahmedrad commented on July 19, 2024

Hi @lauralisa

I added a fix for the issue that you originally mentioned. Now the menu should be fixed as you scroll on a mobile page when you're not using the no_scroll option. Please update the js file and let me know how it went. I'm gonna go ahead and close this issue but will re-open it if you run into any related problems.

from sliiide.

lauralisa avatar lauralisa commented on July 19, 2024

Hi Ahmed,

Great! I¹m sorry I cannot test it anymore, I¹ve solved it another way
around.
If I will use it again I will let you know.

Have a nice day,
Laura

Van: Ahmed Radwan [email protected]
Beantwoorden - Aan: ahmedrad/sliiide
<reply+00ef28211adc5c13629db52771bfd204487a518b6c4174b092cf00000001127d0ecf9
[email protected]>
Datum: maandag 7 december 2015 10:09
Aan: ahmedrad/sliiide [email protected]
CC: Laura Nieuwenhuis [email protected]
Onderwerp: Re: [sliiide] Toggle image by click or swipe (#5)

Hi @lauralisa https://github.com/lauralisa

I added a fix for the issue that you originally mentioned. Now the menu
should be fixed as you scroll on a mobile page when you're not using the
no_scroll option. Please update the js file and let me know how it went. I'm
gonna go ahead and close this issue but will re-open it if you run into any
related problems.


Reply to this email directly or view it on GitHub
#5 (comment) .

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.