You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Rellax is great. Thanks for making it. I've just got a feature request that would reduce the amount of markup I need to write:
As well as setting breakpoint-specific speed values in HTML, could default breakpoint-specific speeds be set in JavaScript?
For example, instead of writing the below for multiple HTML elements that share the same speed value across breakpoints:
<divclass="rellax"
data-rellax-xs-speed="1.25"
data-rellax-mobile-speed="3"
data-rellax-tablet-speed="5"
data-rellax-desktop-speed="10">
Stuff here
</div><!-- Repeat the above for each element that shares the same speed values -->
...could there be defaults set in the accompanying JavaScript like so:
constrellax=newRellax(".rellax",{// This already works to set a default speed value to anything with the class ".relax"speed: 3,// This below doesn't work but would be nice to havexsSpeed: 1.25,mobileSpeed: 3,tabletSpeed: 5,desktopSpeed: 10});
Thanks!
The text was updated successfully, but these errors were encountered:
Hi,
Rellax is great. Thanks for making it. I've just got a feature request that would reduce the amount of markup I need to write:
As well as setting breakpoint-specific speed values in HTML, could default breakpoint-specific speeds be set in JavaScript?
For example, instead of writing the below for multiple HTML elements that share the same
speed
value across breakpoints:...could there be defaults set in the accompanying JavaScript like so:
Thanks!
The text was updated successfully, but these errors were encountered: