This tutorial is about how to add this great preloader to your website, with your own graphic and texts.
See it here: (click the little reload icon on the top right)
Features:
- Graphic, texts and colors are customizable
- Option to play only one time per user visit
- Won't play if not in view (ie, if the user opens your site in a new tab in the background)
This tutorial is only recommended for users comfortable with modifying CSS. Due to the nature of the design, and all the different variations that could be made out of it, this particular tutorial comes with limited customization support & help. I will only support in cases where you can't get it working at all. I won't help with modifying the animation.
The colors and font settings should be simple enough to adjust for most users. The animation itself might be challenging.
Thank you for your understanding!
Let's get started!
First, add this code to your project
This is a premium tutorial. Purchase access to unlock the full tutorial.
21 Responses
Hi Maxime!
I used this kind of preloader in one of my projects and it really works great. Thanks for providing this! I just have one question: Is there a way to use it slightly different when navigating through the website? So that it works more like a page transition? The only thing I'd add is like an Entrance Animation as shown on this website for example: https://www.fourmeta.com/
In my case the desired outcome would be that it moves in from the bottom as I change the page and moves out smoothly to the top (as it already does). Right now it just pops up as an entrance. I was checking your code, but couldn't figure it out yet. I hope you get my request.
Thanks in advance,
Lukas
Hey Lukas!
Page preloaders, and page transitions are two different things... You can't just make small adjustments here to be able to turn it into a page transition...
It would require a new tutorial, and I'm hesitant because Elementor already has a page transition solution.
Did you try using Elementor's solution, maybe along with this tutorial, to get what you want?
Hey Maxime!
Thanks for your quick reply as always. I get what you mean, also was thinking about that. Just have heard that it might be not as stable just yet. Also there's already a preloader solution there, that's why I thought your solution might be cleaner and working for both as their options are still very limited.
I implemented Elementor's solution now and it's working just fine. However I'd love for them to integrate an option where I could choose at least an image to go along with it as there is for the preloader. It would be just a nice-to-have for now, but if you have any idea or a quick fix that would be greatly appreciated 🙂
Hey Lukas!
Sorry for getting back to you just now!
I don't have a quick fix unfortunately. I suggest for now you use the Elementor transition feature...
I will add a page transition tutorial to my list of tutorials to create!
Cheers!
Hi,
the preloaded doesn't work wogether with this full screen menu:
https://element.how/elementor-off-canvas-navigation-menu/
when both of them are active the preloader doesnt function when i turn of the menu snippet it works.
https://snipboard.io/jtMf3y.jpg
any idea how to make them work together?
Thanks
Greetings!
Change this line:
if (node.nodeType === 1 && node.tagName.toLowerCase() !== 'script' && node.tagName.toLowerCase() !== 'style') {
To this:
if (node.nodeType === 1 && node.tagName.toLowerCase() !== 'script' && node.tagName.toLowerCase() !== 'style' && !node.classList.contains('sp_preloader')) {
Cheers!
Thanks for the quick response however i still get a blank pink page and it doesnt work see screenshot:
https://snipboard.io/Yltgux.jpg
Making that change should fix it... would you have a URL to share with me? I will have a look.
My apologies it does work now thanks for the great support and work Max 🙂
Hi Max, is it possible to disable scroll while the preloader loads?
Greetings Coco!
I updated the code in the tutorial for this. Please update to the latest version of the code, and it should work fine!
Cheers!
Thank you so much
Hi Maxime, is it possible to reduce the preloader down to just show the logo part in pink, not the titles part in yellow? I'd imagine it's just a case of stripping out the code related to the titles but I don't want to butcher it. ; )
Hey David!
Try this:
Cheers!
Hi Maxime, great thanks for sending that through. I've activated it and it seems to work fine but something odd happens. I've set it to run only on the homepage and only to run once as per the instructions above which all looked to be working just fine. However, when I refresh the homepage I'm not able to scroll and the page seems unresponsive.
It's pretty weird, do you have any idea why this is happening and what could be a good fix?
The url is https://www.nextdayrealestate.eu/
Hey David!
You are right, the logic didn't quite work for playing only one time.
I updated the JavaScript part of my comment, please import it again, it should work fine now.
Cheers!
Many thanks Maxime! It now works perfectly.
Welcome!
Hey Maxime! I've used this feature on several sites now and it works great! However, now I've got a client who would prefer to have a simple fade out animation instead of the slide up. I managed to fade out the logo, but somehow I can't find the part, which controls the animation of the background. Can you help me out here?
Thanks in advance,
Lukas
Hey Lukas!
Change this line:
.titles-background.playanim {
animation: 0.9s forwards slideUp cubic-bezier(.56, .17, .68, 1) 4.4s;
}
to this:
.titles-background.playanim {
animation: 0.9s forwards fadeOut cubic-bezier(.56, .17, .68, 1) 4.4s;
}
and add this:
@keyframes fadeOut {
0% {
opacity: 100%;
}
100% {
opacity: 0%;
}
}
Cheers!
Hey Maxime!
In this case I only use the Logo Background, but I managed to change the corresponding parameters to make it work. Thanks for your help!
Cheers!