0

Fading

Okay, is there any possible way for the code to not fade out like the that after it reaches all three bars I just want it to reset not fade out https://code.sololearn.com/WZ8Tp3x2RvRU/?ref=app

3rd Mar 2022, 2:13 AM
Junior
Junior - avatar
21 Answers
+ 3
Remove the infinite from the animation and use @keyframes once in both this animation and the one you want. This is all you need: .prog1, .prog2, .prog3 { position: relative; height: 90px; background-color: limegreen; border-radius: 0px; opacity: 0; } @keyframes prog { 0% { opacity: 1; } 100% { opacity: 1; } } Edited.☺️
3rd Mar 2022, 3:42 AM
Solo
Solo - avatar
+ 3
Oh, I'm sorry, I forgot to remove "animation". I hope you understand that all other values ​​that are different from each other should remain in each prog1, prog2, prog3 separately.
3rd Mar 2022, 4:19 AM
Solo
Solo - avatar
+ 3
Maybe you can show the code with my corrections? After all, you need to figure out the code, or you want me to do everything for you, and you just copy it like this code
3rd Mar 2022, 4:45 AM
Solo
Solo - avatar
+ 3
Unfortunately we do not understand each other. What does: "... I just want the code to restart" mean?
3rd Mar 2022, 5:29 AM
Solo
Solo - avatar
+ 3
Use steps function rather than linear to get rid of the linear fading effect. https://developer.mozilla.org/en-US/docs/Web/CSS/animation-timing-function You only need one step to make transition change at 50% of a common @keyframes Check out the code i modified. https://code.sololearn.com/WyIg4yXHt4d6/?ref=app
3rd Mar 2022, 12:55 PM
Calviղ
Calviղ - avatar
+ 3
If the fading is undesirable then use Calviղ's revision and apply my suggested tweaks.
3rd Mar 2022, 4:48 PM
Brian
Brian - avatar
+ 3
Brian, what if I want the stripes to be multi-colored? ☺️
4th Mar 2022, 12:35 PM
Solo
Solo - avatar
+ 3
Brian 👍😉
4th Mar 2022, 3:22 PM
Solo
Solo - avatar
+ 2
Your Mom these tweaks might give the appearance you want. Let .prog3 overlay the others. The others will vanish behind the scenes and .prog3 will be the last one to be seen as it fades out. .prog3 { ... left: 7.5px; ... width: 241px; ...
3rd Mar 2022, 4:43 PM
Brian
Brian - avatar
+ 2
Solo though I expect there is a better way, my technique could work with your requirement, too. Simply overlay two more divs with the same timing as the third.
4th Mar 2022, 2:57 PM
Brian
Brian - avatar
+ 1
?? I just tried that and it didnt work well
3rd Mar 2022, 3:56 AM
Junior
Junior - avatar
+ 1
I jusr want to get rid of the fading at the end Solo
3rd Mar 2022, 3:57 AM
Junior
Junior - avatar
+ 1
Im confused what do you mean by remove qnimation? Thats the whole point of the code, if tou can showme what you mean by writing the code that would be a lot better
3rd Mar 2022, 4:21 AM
Junior
Junior - avatar
+ 1
No no, go to my code and you see the animation, at the END OF THE ANIMATION when the bars start to fade away I DONT want those bars to fade away I just want the code to restart
3rd Mar 2022, 4:47 AM
Junior
Junior - avatar
0
I just want the code to loop, basically when all the 3 bars reach 100% or are all there the code loops again and again like my other codes, i want an infinite code without the fading at the end thats my question
3rd Mar 2022, 6:12 AM
Junior
Junior - avatar
0
Okay, this might help to know what i mean, if tou kbow the fa fa battery animation on w3scgools thats how i wanr it to be basically
3rd Mar 2022, 3:12 PM
Junior
Junior - avatar
0
That overlats the whole battery, look on w3schools animation battery and thats how i want it, no fasing when the code finishes it resets
3rd Mar 2022, 4:46 PM
Junior
Junior - avatar
0
Calviղ thanks but i want all the bara to “restart” all at once
3rd Mar 2022, 5:29 PM
Junior
Junior - avatar
0
Welcome
4th Mar 2022, 11:18 AM
DavroN Husanov
- 2
WILCOM TOW DAY
4th Mar 2022, 4:31 PM
كشف الخدع السحرية