I have a problem on this page: http://wtgecommerce.powersoftware.in/land.
The youtube video blink like something refresh it.
I opened the developer console and I noticed that this could be caused by Owl Carousel.
You can see here the code before blinking:
and after:
Why this is happening? And how I can fix this?
Thank you very much.
I think this is due to fade-in fade-out animation.
remove transitionStyle: "fade" or comment these line in owl.transitions.css
.owl-fade-out {
z-index: 10;
-webkit-animation: fadeOut .7s both ease;
-moz-animation: fadeOut .7s both ease;
animation: fadeOut .7s both ease;
}
.owl-fade-in {
-webkit-animation: fadeIn .7s both ease;
-moz-animation: fadeIn .7s both ease;
animation: fadeIn .7s both ease;
}
Related
I want my navbar background color to change slowly from transparent to white as I hover it.
I'm using this script to hide the navbar as I scroll down and pop up as I scroll up and it works perfectly. manage to change the color on hover but without transition ...
can someone please help me to add transition?
please see
www.maimoncpa.com
Consider this code, involving nav
nav{
-webkit-transition: background-color 2s ease-out;
-moz-transition: background-color 2s ease-out;
-o-transition: background-color 2s ease-out;
transition: background-color 2s ease-out;
}
nav:hover {
background: white;
}
I'm with angular 1.4, and i hope this one is a common, and solvable problem:
I have an div with background image of a ball, the div has the following extra styling:
-webkit-transition: all 0.5s ease;
-moz-transition: all 0.5s ease;
-o-transition: all 0.5s ease;
transition: all 0.5s ease;
Because the ball moves left and right with a smoothing transition (the one from the style).
When i ng-if this div to false, when it needs to disappear, the div is stuck there for a sec (or half a sec?), is there any way around this behaviour?
It's not a matter of $digest or $apply, and without the transitions it goes away quickly and normaly.
I have a
<a onclick="document.getElementById('massage').style.display = 'block';">Button</a>
And I want to add a fadeIn to the function, but dont know how.
You have two options:
A css3 opacity animation - only suitable for HTML5 enabled browsers i.e. IE9+. Apply this by adding the css class fade to your element.
.fade {
opacity: 1;
transition: opacity .25s ease-in-out;
-moz-transition: opacity .25s ease-in-out;
-webkit-transition: opacity .25s ease-in-out;
}
2.) Use jquerys fadein function. Which supports older browsers.
http://api.jquery.com/fadeIn/
You will need to learn jQuery of course if you don't know it but this is worth doing I think.
Hope that helps
The following code snippet shows how I made popups with CSS and JS. Is there any chance to let it fade when opening/closing it, without changing the way I used to work, I mean just popping up the box by changing its display style?
function lightbox_open(){
window.scrollTo(100,500);
document.getElementById('light').style.display='block';
document.getElementById('fade').style.display='block';
}
function lightbox_close(){
document.getElementById('light').style.display='none';
document.getElementById('fade').style.display='none';
}
You could use either use jQuery to do the fading $().fadeIn() or use CSS3 animations if you want to stick to bare JS. In the latter case, set the opacity to 0 by default and change it to 1 via Javascript. You need to add this to your stylesheet:
selector {
opacity: 0;
-webkit-transition: opacity 1s ease-in-out;
-moz-transition: opacity 1s ease-in-out;
-ms-transition: opacity 1s ease-in-out;
-o-transition: opacity 1s ease-in-out;
transition: opacity 1s ease-in-out;
}
You can use jquery fadein() on open and fadeout() on close, but if you want to do it with pure javascript, i recommend reading this source code. they did it it wonderfully.
You can use jQuery:
.fadeIn()
function lightbox_open(){
window.scrollTo(100,500);
$('#light,#fade').fadeIn();
}
.fadeOut()
function lightbox_close(){
$('#light,#fade').fadeOut();
}
I have a website, and a slideshow of pictures on the main page. Before a photo is removed, I write the next photo behind it and then remove it. I wanted to know how I can add a fading effect before the photo is removed. my website is: guyzyl.org, so you can check out what im talking about. Also I dont know how to use Jquery, so please dont offer that solution. Thanks for any help. Guy Z.
.photo{
-webkit-transition: opacity .5s ease-in-out; /*Webkit*/
-moz-transition: opacity .5s ease-in-out; /*Firefox*/
-o-transition: opacity .5s ease-in-out; /*Opera*/
transition: opacity .5s ease-in-out; /*CSS3 Standard*/
opacity: 1;
}
.photo.fade{
opacity: 0;
}
document.querySelector(".photo").classList.add("fade");
See Demo: http://jsfiddle.net/DerekL/jzLZZ/