Background repeat & position to parallax background

edit
John Muccigrosso 2018-02-10 12:32:16 -05:00 committed by GitHub
parent 7991693bde
commit 5d273cfb29
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 0 deletions

View File

@ -173,6 +173,12 @@
// Parallax background size // Parallax background size
parallaxBackgroundSize: '', // CSS syntax, e.g. "3000px 2000px" parallaxBackgroundSize: '', // CSS syntax, e.g. "3000px 2000px"
// Parallax background repeat
parallaxBackgroundRepeat: '', // repeat/repeat-x/repeat-y/no-repeat/initial/inherit
// Parallax background position
parallaxBackgroundPosition: '', // CSS syntax, e.g. "top left"
// Amount of pixels to move the parallax background per slide step // Amount of pixels to move the parallax background per slide step
parallaxBackgroundHorizontal: null, parallaxBackgroundHorizontal: null,
parallaxBackgroundVertical: null, parallaxBackgroundVertical: null,
@ -867,6 +873,8 @@
dom.background.style.backgroundImage = 'url("' + config.parallaxBackgroundImage + '")'; dom.background.style.backgroundImage = 'url("' + config.parallaxBackgroundImage + '")';
dom.background.style.backgroundSize = config.parallaxBackgroundSize; dom.background.style.backgroundSize = config.parallaxBackgroundSize;
dom.background.style.backgroundRepeat = config.parallaxBackgroundRepeat;
dom.background.style.backgroundPosition = config.parallaxBackgroundPosition;
// Make sure the below properties are set on the element - these properties are // Make sure the below properties are set on the element - these properties are
// needed for proper transitions to be set on the element via CSS. To remove // needed for proper transitions to be set on the element via CSS. To remove