Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Breakpoint option for setting when the mobile layout gets triggered #151

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions jquery.joyride-2.1.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
'nubPosition' : 'auto', // override on a per tooltip bases
'scroll' : true, // whether to scroll to tips
'scrollSpeed' : 300, // Page scrolling speed in milliseconds
'breakpoint' : 768, // Sets the point in px at which the tips will switch to a full-width layout
'timer' : 0, // 0 = no timer , all other numbers = timer in milliseconds
'autoStart' : false, // true or false - false tour starts when restart called
'startTimerOnClick' : true, // true or false - true requires clicking the first button start the timer
Expand Down Expand Up @@ -354,10 +355,10 @@
// detect phones with media queries if supported.
is_phone : function () {
if (Modernizr) {
return Modernizr.mq('only screen and (max-width: 767px)');
return Modernizr.mq('only screen and (max-width: ' + settings.breakpoint + 'px)');
}

return (settings.$window.width() < 767) ? true : false;
return (settings.$window.width() < settings.breakpoint) ? true : false;
},

support_localstorage : function () {
Expand Down