Thumbnail api function

tigor.contact's Avatar

tigor.contact

15 Dec, 2012 07:12 PM

Hi Dmitry,
Thank you for your excellent work.

Is there any api public event for thumbnail click - touch - shift?
Thanks

Iho

  1. Support Staff 1 Posted by Dmytro Semenov on 16 Dec, 2012 04:02 PM

    Dmytro Semenov's Avatar

    Hi,

    Unfortunately - no. If you explain me why you need it I might offer the solution.

    Dmitry

  2. 2 Posted by tigor.contact on 16 Dec, 2012 05:07 PM

    tigor.contact's Avatar

    Hi,

    Besides the usual way of Royal Slider usage I'd like to have the following:
    Main Slide (rsOverflow) hidden initially, with just thumbnail row visible. If a visitor uses the thumbnails some way - click or shift thumbs - the event should trigger to show main Slide.
    I used jquery rsTmb click, but still not satisfied with the result I get.

    Thanks
    Iho

  3. Support Staff 3 Posted by Dmytro Semenov on 16 Dec, 2012 10:36 PM

    Dmytro Semenov's Avatar

    Well, you may use unminified version of script and override private methods onDragStart and onDragRelease, they fire both from swiping of main image and of thumbnails and accept two arguments - event and isThumbnail, second one is true only when swiping is over thumbnails.

    http://help.dimsemenov.com/kb/royalslider-javascript-api/extending-...

    Dmitry

  4. 4 Posted by tigor.contact on 16 Dec, 2012 10:47 PM

    tigor.contact's Avatar

    Great, Dmitry, thank you
    Will they fire on thumbnail click as well?

    Iho

  5. Support Staff 5 Posted by Dmytro Semenov on 16 Dec, 2012 11:35 PM

    Dmytro Semenov's Avatar

    onDragStart will will fire on mousedown/touchstart.

    You may also use rsBeforeAnimStart, it'll fire after you select thumbnail and slide is changed. http://dimsemenov.com/plugins/royal-slider/documentation/#api

    Dmitry

  6. 6 Posted by richard on 19 Dec, 2012 03:18 PM

    richard's Avatar

    Would this work on thumbnail click to fade out the thumbnail navigation?

    slider.ev.on('rsBeforeAnimStart', function() {
    $("div.rsNav").fadeOut("slow"); 
    });
    
  7. Support Staff 7 Posted by Dmytro Semenov on 19 Dec, 2012 06:00 PM

    Dmytro Semenov's Avatar

    Your code will fade-out navigation after slide changes.

    Dmitry

  8. 8 Posted by richard on 19 Dec, 2012 08:03 PM

    richard's Avatar

    Thank you

  9. tigor.contact closed this discussion on 20 Jul, 2013 07:51 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac