Ticker doesn't loop straight away at end - html

Code is below - I'm trying to get this to loop smoothly from the last headline - currently there is a gap and I can't figure out how to loop the headlines without it :/. The current functionality is good, but the gap at the end of the 4 headlines (NB - eventually there will be many more headlines) is really bugging me. Any help would be awesome
<style>
.box{
width: 80%;
}
* {
box-sizing: border-box;
}
#-webkit-keyframes ticker {
0% {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
100% {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
}
}
#keyframes ticker {
0% {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
100% {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
}
}
.ticker-wrap {
position: relative;
left: 0;
width: 100%;
overflow: hidden;
height: 3rem;
background-color: #000;
box-sizing: content-box;
}
.ticker-wrap .ticker {
display: inline-block;
height: 3rem;
line-height: 3rem;
white-space: nowrap;
padding-right: 10%;
box-sizing: content-box;
-webkit-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: linear;
animation-timing-function: linear;
-webkit-animation-name: ticker;
animation-name: ticker;
-webkit-animation-duration: 25s;
animation-duration: 25s;
}
.ticker-wrap .ticker__item {
display: inline-block;
padding: 0 2rem;
font-size: 2rem;
color: white;
}
</style>
<div class="rt-container">
<div class="col-rt-12">
<div class="Scriptcontent">
<div class="ticker-wrap">
<div class="ticker">
<div class="ticker__item"><h2></h2></div>
<div class="ticker__item"><h2>Massi out in FIA Race Director Shake-up</h2></div>
<div class="ticker__item"></div><div class="ticker__item"><h2>Ferrari Unveil Bold Design For 2022 Car.</h2></div>
<div class="ticker__item"></div><div class="ticker__item"><h2>Sprint Races Cut From 6 to 3 Due to Cost Cap Dispute.</h2></div>
<div class="ticker__item"></div><div class="ticker__item"><h2>Szafnauer named Alpine Team Principal as Rossi confirms new structure.</h2></div>
</div>
</div>
</div>
</div>
</div>

Related

Scrolling text long delay before start after video html and css

I have just finished working on a new website for my festivals business and the scrolling text "ticker tape" is taking an age (Sometimes up to a minute) to load especially on phones. It's just on our camping page though (https://wildfestivals.co.uk/school_holiday_camping.html), all other tickers and videos are working well together. My question is, is it the video that's delaying the start and is there a way I can keep both items on there, but speed the start of the ticker up at all?
I'd hate to lose the function. Does anyone know a way that I can sort this please? As you can see I am a have a go guy, not a pro developer.
#-webkit-keyframes ticker {
0% {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
100% {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
}
}
#keyframes ticker {
0% {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
100% {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
}
}
.ticker2-wrap {
position: static;
left: 0;
width: 100%;
overflow: hidden;
height: 2rem;
background: rgba(0, 0, 0, 0.2);
box-sizing: content-box;
}
.ticker2-wrap .ticker2 {
display: inline-block;
height: 2rem;
line-height: 2rem;
white-space: nowrap;
padding-right: 100%;
box-sizing: content-box;
-webkit-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: linear;
animation-timing-function: linear;
-webkit-animation-name: ticker;
animation-name: ticker;
-webkit-animation-duration: 120s;
animation-duration: 120s;
}
.ticker2-wrap .ticker2__item {
display: inline-block;
padding: 0 0rem;
font-size: 1.2rem;
letter-spacing: 2px;
font-family: 'Orbitron', sans-serif;
font-weight: 400;
color: rgba(0, 0, 0, 0);
text-shadow: none;
}
<div class="ticker2">
<div class="ticker2__item">********<strong>School holidays with a difference Camping is just £6 a night for Adults & £3 for Children</strong>********</div>
<div class="ticker2__item">********<strong>With daytime & evening entertainment included in the price everyone can afford to enjoy a camping holiday with us</strong>********</div>
<div class="ticker2__item">********<strong>Have as much space as you need at no extra cost</strong>********</div>
<div class="ticker2__item">********<strong>Caravans Campervans Motorhomes and tents are all welcome here</strong>********</div>
<div class="ticker2__item">********<strong>Pop up campsites at 7 beautiful locations for up to a week at each one</strong>********</div>
<div class="ticker2__item">********<strong>Full toilet facilities including disabled toilets and elsan points on site</strong>********</div>
<div class="ticker2__item">********<strong>Camping zones to suit all campers you can stay up late or you can enjoy peace and quiet it's your choice</strong>********</div>
<div class="ticker2__item">********<strong>Our camping is now available for everyone, no festival booking required</strong>********</div>
<div class="ticker2__item">********<strong>Camp more for less at WF</strong></div>
</div>
</div>

CSS animation isn't working until click on Angular

I was trying to build a auto sliding bar from right to left with an array of data in Angular. Currrently, the animation wasn't working until user click on it. I tried changedetectorref, setTimeout() and trigger click event manually, but nothing work. Please help me on solving this.
The observation is that the data fetched from backend are received and shown (this.offer has its correct value) but the animation is paused. After several seconds, the shown data disappears by itself. When user click the blank sliding bar, the function of clicking on a data triggers and the animation starts. Please let me know if any further information is required.
HTML Part
<div class="ticker-wrap bg-black">
<div class="ticker py-2.5" id="bar-part-1">
<a class="ticker__item" [id]="'talent-' + o.uniqueCode" [href]="'/talent/' + o.uniqueCode" (click)="openTalentDetailDialog(o.uniqueCode)"
*ngFor="let o of offers">
<div class="flex-col content">
<strong>{{o.uniqueCode}}</strong>
</div>
</a>
</div>
<div class="ticker py-2.5" id="bar-part-2">
<a class="ticker__item" [href]="'/talent/' + o.uniqueCode" (click)="openTalentDetailDialog(o.uniqueCode)"
*ngFor="let o of offers">
<div class="flex-col content">
<strong>{{o.uniqueCode}}</strong>
</div>
</a>
</div>
</div>
CSS Part
$duration: 40s;
#-webkit-keyframes ticker {
0% {
-webkit-transform: translate3d(0%, 0, 0);
transform: translate3d(0%, 0, 0);
visibility: visible;
}
100% {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
}
}
#keyframes ticker {
0% {
-webkit-transform: translate3d(0%, 0, 0);
transform: translate3d(0%, 0, 0);
visibility: visible;
}
100% {
-webkit-transform: translate3d(-100%, 0, 0);
transform: translate3d(-100%, 0, 0);
}
}
.ticker-wrap {
// position: fixed;
z-index: 100;
// bottom: 0;
width: 100%;
overflow: hidden;
// height: 4rem;
// padding-left: 100%;
box-sizing: content-box;
white-space: nowrap;
min-height: 64px;
.ticker {
// display: inline-block;
display: inline-flex;
// height: 4rem;
// line-height: 4rem;
// white-space: nowrap;
// padding-right: 100%;
box-sizing: content-box;
-webkit-animation-iteration-count: infinite;
animation-iteration-count: infinite;
-webkit-animation-timing-function: linear;
animation-timing-function: linear;
-webkit-animation-name: ticker;
animation-name: ticker;
-webkit-animation-duration: $duration;
animation-duration: $duration;
&__item {
display: inline-block;
padding: 0 2rem;
// font-size: 2rem;
color: white;
cursor: pointer;
.content {
max-width: 450px;
min-width: 450px;
white-space: pre-wrap;
}
&:hover {
text-decoration: underline;
}
}
}
&:hover {
.ticker {
animation-play-state: paused;
}
}
}
TypeScript part
loadRecentOffers() {
console.log('loadRecentOffer is triggered');
this._businessService.getRecentOffers().subscribe(async o => {
console.log('recent offers: ', o);
await Promise.all(o.map(oo => {
oo.time = moment(new Date(oo.createdAt)).fromNow();
}));
this.offers = o;
// this._matSnackBar.open('offer applied', 'Close');
setTimeout(() => {
this._cdr.markForCheck();
this._cdr.detectChanges();
// this._matSnackBar.open('cdr triggered', 'Close');
}, 100)
})
}

WHY my animated text are not coming on one line

The output above the button which is text inclosed in brackets the problem is its a moving word but it's not getting placed in proper position insted it's going up and down.
I have used animated button which works fine bu the text in the brackets is scrolling as per the
need. Though i've tried a lot but not geting the desired answer
.background {
background-color: darkorange;
width: 100%;
height: 100%;
position: absolute;
}
.first{
color: orange;
text-align: center;
position: fixed;
left: 0%;
right: 0%;
z-index: 9999;
margin-left: 40px;
margin-right: 20px;
margin-top: 250px;
}
<!-- for button patrs css code -->
.button {
border-radius: 4px;
background-color: #f4511e;
border: none;
color: #FFFFFF;
text-align: center;
font-size: 28px;
padding: 10px;
width: 200px;
transition: all 0.5s;
cursor: pointer;
margin: 10px;
}
.button span {
cursor: pointer;
display: inline-block;
position: relative;
transition: 0.5s;
}
.button span:after {
content: '\00bb';
position: absolute;
opacity: 0;
top: 0;
right: -20px;
transition: 0.5s;
}
.button:hover span {
padding-right: 25px;
}
.button:hover span:after {
opacity: 1;
right: 0;
}
<!-- For body parts css codes -->
.content {
position: absolute;
top: 50%;
left: 50%;
-webkit-transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
height: 160px;
overflow: hidden;
font-family: 'Lato', sans-serif;
font-size: 35px;
line-height: 40px;
color: #ecf0f1;
}
.content__container {
font-weight: 600;
overflow: hidden;
height: 40px;
padding: 0 40px;
}
.content__container:before {
content: '[';
left: 0;
}
.content__container:after {
content: ']';
position: absolute;
right: 0;
}
.content__container:after, .content__container:before {
position: absolute;
top: 0;
color: #16a085;
font-size: 42px;
line-height: 40px;
-webkit-animation-name: opacity;
-webkit-animation-duration: 2s;
-webkit-animation-iteration-count: infinite;
animation-name: opacity;
animation-duration: 2s;
animation-iteration-count: infinite;
}
.content__container__text {
display: inline;
float: left;
margin: 0;
}
.content__container__list {
margin-top: 0;
padding-left: 110px;
text-align: left;
list-style: none;
-webkit-animation-name: change;
-webkit-animation-duration: 10s;
-webkit-animation-iteration-count: infinite;
animation-name: change;
animation-duration: 10s;
animation-iteration-count: infinite;
}
.content__container__list__item {
line-height: 40px;
margin: 0;
}
#-webkit-keyframes opacity {
0%, 100% {
opacity: 0;
}
50% {
opacity: 1;
}
}
#-webkit-keyframes change {
0%, 12.66%, 100% {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
16.66%, 29.32% {
-webkit-transform: translate3d(0, -25%, 0);
transform: translate3d(0, -25%, 0);
}
33.32%,45.98% {
-webkit-transform: translate3d(0, -50%, 0);
transform: translate3d(0, -50%, 0);
}
49.98%,62.64% {
-webkit-transform: translate3d(0, -75%, 0);
transform: translate3d(0, -75%, 0);
}
66.64%,79.3% {
-webkit-transform: translate3d(0, -50%, 0);
transform: translate3d(0, -50%, 0);
}
83.3%,95.96% {
-webkit-transform: translate3d(0, -20%, 0);
transform: translate3d(0, -20%, 0);
}
}
#keyframes opacity {
0%, 100% {
opacity: 0;
}
50% {
opacity: 1;
}
}
#keyframes change {
0%, 12.66%, 100% {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
16.66%, 29.32% {
-webkit-transform: translate3d(0, -25%, 0);
transform: translate3d(0, -25%, 0);
}
33.32%,45.98% {
-webkit-transform: translate3d(0, -50%, 0);
transform: translate3d(0, -50%, 0);
}
49.98%,62.64% {
-webkit-transform: translate3d(0, -60%, 0);
transform: translate3d(0, -60%, 0);
}
66.64%,79.3% {
-webkit-transform: translate3d(0, -50%, 0);
transform: translate3d(0, -40%, 0);
}
83.3%,95.96% {
-webkit-transform: translate3d(0, -25%, 0);
transform: translate3d(0, -20%, 0);
}
}
<html>
<link rel="stylesheet" href="stylesheet.css">
<div class="background"></div>
<body>
<div class="content">
<div class="content__container">
<div class="content__container">
<p class="content__container__text">
Hello
</p>
<ul class="content__container__list">
<li class="content__container__list__item">world !</li>
<li class="content__container__list__item">users !</li>
<li class="content__container__list__item">everybody !</li>
</ul>
</div>
</div>
<button class="button"><span>Login</span></button>
<button class="button"><span>Register</span></button>
</div>
</body>
</html>
<!-- end snippet -->
I think you want something like this :
.background {
background-color: darkorange;
width: 100%;
height: 100%;
position: absolute;
}
.first{
color: orange;
text-align: center;
position: fixed;
left: 0%;
right: 0%;
z-index: 9999;
margin-left: 40px;
margin-right: 20px;
margin-top: 250px;
}
<!-- for button patrs css code -->
.button {
border-radius: 4px;
background-color: #f4511e;
border: none;
color: #FFFFFF;
text-align: center;
font-size: 28px;
padding: 10px;
width: 200px;
transition: all 0.5s;
cursor: pointer;
margin: 10px;
}
.button span {
cursor: pointer;
display: inline-block;
position: relative;
transition: 0.5s;
}
.button span:after {
content: '\00bb';
position: absolute;
opacity: 0;
top: 0;
right: -20px;
transition: 0.5s;
}
.button:hover span {
padding-right: 25px;
}
.button:hover span:after {
opacity: 1;
right: 0;
}
<!-- For body parts css codes -->
.content {
position: absolute;
top: 50%;
left: 50%;
-webkit-transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
height: 160px;
overflow: hidden;
font-family: 'Lato', sans-serif;
font-size: 35px;
line-height: 40px;
color: #ecf0f1;
}
.content__container {
font-weight: 600;
overflow: hidden;
height: 40px;
padding: 0 40px;
}
.content__container:before {
content: '[';
left: 0;
}
.content__container:after {
content: ']';
position: absolute;
right: 0;
}
.content__container:after, .content__container:before {
position: absolute;
top: 0;
color: #16a085;
font-size: 42px;
line-height: 40px;
-webkit-animation-name: opacity;
-webkit-animation-duration: 2s;
-webkit-animation-iteration-count: infinite;
animation-name: opacity;
animation-duration: 2s;
animation-iteration-count: infinite;
}
.content__container__text {
display: inline;
float: left;
margin: 0;
}
.content__container__list {
margin-top: 0;
padding-left: 110px;
text-align: left;
list-style: none;
-webkit-animation-name: change;
-webkit-animation-duration: 10s;
-webkit-animation-iteration-count: infinite;
animation-name: change;
animation-duration: 10s;
animation-iteration-count: infinite;
}
.content__container__list__item {
line-height: 40px;
margin: 0;
}
#-webkit-keyframes opacity {
0%, 100% {
opacity: 0;
}
50% {
opacity: 1;
}
}
#-webkit-keyframes change {
0%,15%{
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
25%, 40% {
-webkit-transform: translate3d(0, -30%, 0);
transform: translate3d(0, -30%, 0);
}
50%,65% {
-webkit-transform: translate3d(0, -63%, 0);
transform: translate3d(0, -63%, 0);
}
75%,90% {
-webkit-transform: translate3d(0, -30%, 0);
transform: translate3d(0, -30%, 0);
}
100%{
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
}
#keyframes opacity {
0%, 100% {
opacity: 0;
}
50% {
opacity: 1;
}
}
#keyframes change {
0%,15%{
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
25%, 40% {
-webkit-transform: translate3d(0, -30%, 0);
transform: translate3d(0, -30%, 0);
}
50%,65% {
-webkit-transform: translate3d(0, -63%, 0);
transform: translate3d(0, -63%, 0);
}
75%,90% {
-webkit-transform: translate3d(0, -30%, 0);
transform: translate3d(0, -30%, 0);
}
100%{
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
}
<div class="background"></div>
<body>
<div class="content">
<div class="content__container">
<div class="content__container">
<p class="content__container__text">
Hello
</p>
<ul class="content__container__list">
<li class="content__container__list__item">world !</li>
<li class="content__container__list__item">users !</li>
<li class="content__container__list__item">everybody !</li>
</ul>
</div>
</div>
<button class="button"><span>Login</span></button>
<button class="button"><span>Register</span></button>
</div>

CSS transform with parent transform does not work on iOS Safari

I created a mockup of the situation because I wasn't able to create a testable version so easily. But to get the gist:
#keyframes mainFadeIn {
0% {
opacity: 0;
transform: translateY(-3rem);
}
100% {
opacity: 1;
transform: translateY(0);
}
}
// If I use this, without the transform, then everything works.
//
// #keyframes mainFadeIn {
// 0% {
// opacity: 0;
// }
//
// 100% {
// opacity: 1;
// }
// }
.main {
animation-name: mainFadeIn;
animation-duration: 1s;
animation-fill-mode: both;
animation-timing-function: linear;
background-color: gray;
width: 100%;
height: 16rem;
padding: 3rem;
}
.card {
transition: transform 500ms;
transform-style: preserve-3d;
-webkit-transform-origin: 50% 50%;
perspective: 200px; // Ignore
margin: auto;
width: 30rem;
height: 10rem;
background-color: lightblue;
&.flipped {
transform: rotateY(-180deg);
}
}
.front,
.back {
backface-visibility: hidden;
}
.back {
transform: rotateY(-180deg);
}
<div class="main">
<div class="card">
<div class="front"></div>
<div class="back"></div>
</div>
</div>
Hopefully this is enough to know where the issue is.
CodePen:
https://codepen.io/anon/pen/owvqQP/
EDIT
Well. It's probably this thing: css z-index lost after webkit transform translate3d
But I still can't get it to work. The only solution would be to use position: relative; and top: 0; and top: -3rem; for the animations..
Looks like you forgot -webkit- prefix. Also recommend using translate3d for hardware acceleration. Try this way:
#-webkit-keyframes mainFadeIn {
0% {
opacity: 0;
-webkit-transform: translate3d(0, -3rem, 0);
transform: translate3d(0, -3rem, 0);
}
100% {
opacity: 1;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
}
#keyframes mainFadeIn {
0% {
opacity: 0;
-webkit-transform: translate3d(0, -3rem, 0);
transform: translate3d(0, -3rem, 0);
}
100% {
opacity: 1;
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
}
}
.main {
-webkit-animation-name: mainFadeIn;
-webkit-animation-duration: 1s;
-webkit-animation-fill-mode: both;
-webkit-animation-timing-function: linear;
animation-name: mainFadeIn;
animation-duration: 1s;
animation-fill-mode: both;
animation-timing-function: linear;
background-color: gray;
width: 100%;
height: 16rem;
padding: 3rem;
}
.card {
transition: -webkit-transform 500ms;
-webkit-transform-style: preserve-3d;
transition: transform 500ms;
transform-style: preserve-3d;
-webkit-transform-origin: 50% 50%;
-webkit-perspective: 200px; // Ignore
perspective: 200px; // Ignore
margin: auto;
width: 30rem;
height: 10rem;
background-color: lightblue;
&.flipped {
-webkit-transform: rotateY(-180deg);
transform: rotateY(-180deg);
}
}
.front,
.back {
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
}
.back {
-webkit-transform: rotateY(-180deg);
transform: rotateY(-180deg);
}

CSS3 transform not displaying well in Microsoft Edge (and IE)

Fairly new web developer here. So I have a CSS3 transition on my wordpress site which works fine in every browser but IE and Edge. Not sure exactly what to do about it also since I am not easily able to test it on my mac.
Here are the snippets that may be effecting things. The first is starting them off the page.
.jumbotron #name {
margin-left:-200em;
}
.jumbotron #line {
margin-left:-80em;
}
.jumbotron #occupation1, .jumbotron #occupation2 {
margin-left:-190em;
}
#-webkit-keyframes slideInLeft {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(42%, 0, 0);
transform: translate3d(42%, 0, 0);
}
}
#keyframes slideInLeft {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(42%, 0, 0);
transform: translate3d(42%, 0, 0);
}
}
#-webkit-keyframes slideInLeftLine {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(315%, 0, 0);
transform: translate3d(315%, 0, 0);
}
}
#keyframes slideInLeftLine {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(315%, 0, 0);
transform: translate3d(315%, 0, 0);
}
}
#-webkit-keyframes slideInLeft2 {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(43%, 0, 0);
transform: translate3d(43%, 0, 0);
}
}
#keyframes slideInLeft2 {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(43%, 0, 0);
transform: translate3d(43%, 0, 0);
}
}
#-webkit-keyframes slideInLeft3 {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(45%, 0, 0);
transform: translate3d(45%, 0, 0);
}
}
#keyframes slideInLeft3 {
from {
-webkit-transform: translate3d(0, 0, 0);
transform: translate3d(0, 0, 0);
visibility: visible;
}
to {
-webkit-transform: translate3d(45%, 0, 0);
transform: translate3d(45%, 0, 0);
}
}
.slideInLeft3 {
-webkit-animation-name: slideInLeft3;
animation-name: slideInLeft3;
}
.slideInLeft {
-webkit-animation-name: slideInLeft;
animation-name: slideInLeft;
}
.slideInLeft2 {
-webkit-animation-name: slideInLeft2;
animation-name: slideInLeft2;
}
.slideInLeftLine {
-webkit-animation-name: slideInLeftLine;
animation-name: slideInLeftLine;
}
#name {
opacity:1;
animation: slideInLeft 2s 1;
-webkit-animation: slideInLeft 2s 1;
-moz-animation: slideInLeft 2s 1;
-webkit-animation-fill-mode: forwards; /* Chrome, Safari, Opera */
animation-fill-mode: forwards;
}
#line {
opacity:1;
animation: slideInLeftLine 2s 1;
-webkit-animation: slideInLeftLine 2s 1;
-moz-animation: slideInLeftLine 2s 1;
-webkit-animation-delay: 2s; /* Chrome, Safari, Opera */
animation-delay: 2s;
-webkit-animation-fill-mode: forwards; /* Chrome, Safari, Opera */
animation-fill-mode: forwards;
}
#occupation2 {
animation: slideInLeft3 2s 1;
-webkit-animation: slideInLeft3 2s 1;
-moz-animation: slideInLeft3 2s 1;
-webkit-animation-delay: 5s; /* Chrome, Safari, Opera */
animation-delay: 5s;
-webkit-animation-fill-mode: forwards; /* Chrome, Safari, Opera */
animation-fill-mode: forwards;
}
#occupation1 {
animation: slideInLeft2 2s 1;
-webkit-animation: slideInLeft2 2s 1;
-moz-animation: slideInLeft2 2s 1;
-webkit-animation-delay: 3s; /* Chrome, Safari, Opera */
animation-delay: 3s;
-webkit-animation-fill-mode: forwards; /* Chrome, Safari, Opera */
animation-fill-mode: forwards;
}
Really just the #line is the one that I am having trouble with. It could possibly be because the margins function differently with edge and ie? I know that the resume's on the site are not displaying center in the page either. I put the site up on a sub directory incase you want to see it.
For starters one major issue is your html. You have extra anonymous closing tags i.e. extra closing div in jumbotron and a random closing p tag in col-md-4 col-md-offset-7. I just removed the col-md-4 divs altogether
I also don't know why you are using margin-left. I personally would scrap using margin left and use absolute positioning on the items inside #jumbotron and make sure #jumbotron is relatively positioned. You will have to mess with the positions to get what you want, but this works in IE.
Html:
<div class="jumbotron">
<div id="name">
<h2>Joseph Scalzo</h2>
</div>
<div id="line"></div>
<h3 id="occupation1">Performer.</h3>
<h3 id="occupation2">Sommelier.</h3>
</div>
<main role="main">
<!-- section -->
<section>
<!-- article formerly with class bigboy -->
<article id="post-2" class="post-2 page type-page status-publish hentry">
<div class="container" id="hide" style="height:0; width:0;">
<figure>
<img src="http://joebiz.net/blog/wp-content/uploads/2015/09/jumbotron.jpg" alt="headshot1"/><br />
</figure>
<div class="col-md-4 col-md-offset-7">
<h2>Joseph Scalzo</h2>
<hr id="fixedLine">
<h3>Performer. Sommelier.</h3>
</div>
</div>
<br class="clear">
</article>
<!-- /article -->
</section>
<!-- /section -->
</main>
Css:
.jumbotron {
position: relative;
}
.jumbotron h2 {
font-size:4em;
font-family: 'Raleway', Tahoma, sans-serif;
color:#f3e877;
}
.jumbotron h3 {
font-family: 'Raleway', Tahoma, sans-serif;
color:black;
}
.jumbotron #name {
position: absolute;
top: 100px;
width: 375px;
}
.jumbotron #line {
border-bottom: 1px solid #fff;
height: 1px;
position: absolute;
top: 172px;
left: -100%;
width: 375px;
}
.jumbotron #occupation1 {
position: absolute;
top: 180px;
left: -100%;
width: 375px;
}
.jumbotron #occupation2 {
position: absolute;
top: 220px;
left: -100%;
width: 375px;
}
#-webkit-keyframes slideInLeft {
from {
left: -100%;
}
to {
left: 60%;
}
}
#keyframes slideInLeft {
from {
left: -100%;
}
to {
left: 60%;
}
}
#-webkit-keyframes slideInLeftLine {
from {
left: -100%;
}
to {
left: 60%;
}
}
#keyframes slideInLeftLine {
from {
left: -100%;
}
to {
left: 60%;
}
}
#-webkit-keyframes slideInLeft2 {
from {
left: -100%;
}
to {
left: 68%;
}
}
#keyframes slideInLeft2 {
from {
left: -100%;
}
to {
left: 68%;
}
}
#-webkit-keyframes slideInLeft3 {
from {
left: -100%;
}
to {
left: 72%;
}
}
#keyframes slideInLeft3 {
from {
left: -100%;
}
to {
left: 72%;
}
}