Skip to content

Instantly share code, notes, and snippets.

@wplit
Created September 4, 2020 04:11
Show Gist options
  • Select an option

  • Save wplit/17eb23563c131ecf3f99114c90cb320d to your computer and use it in GitHub Desktop.

Select an option

Save wplit/17eb23563c131ecf3f99114c90cb320d to your computer and use it in GitHub Desktop.
timeline customisations - amanda
/* Even posts background colour */
.timeline_vertical > .ct-div-block:nth-child(even) {
background: blue;
}
/* Add transforms to fade animations */
.timeline_vertical > .ct-div-block:nth-child(even)[data-aos^=fade][data-aos^=fade] {
transform: translateX(50px);
}
.timeline_vertical > .ct-div-block:nth-child(odd)[data-aos^=fade][data-aos^=fade] {
transform: translateX(-50px);
}
/* Make sure transforms reset when scrolled to */
.timeline_vertical > .ct-div-block[data-aos^=fade][data-aos^=fade].aos-animate {
transform: none;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment