Skip to content

Instantly share code, notes, and snippets.

@SuryawanshiPrajakta
Created June 11, 2020 07:18
Show Gist options
  • Save SuryawanshiPrajakta/585e749afb7a4242ad33a49fa1828d38 to your computer and use it in GitHub Desktop.
Save SuryawanshiPrajakta/585e749afb7a4242ad33a49fa1828d38 to your computer and use it in GitHub Desktop.
Change Timeline icon on hover of title
1) Add the below script in active theme's functions.php
function modal_custom_script() {
?>
<script type="text/javascript">
jQuery(function($) {
$('.uael-content').on('mouseover', function(){
$( this ).parents('.uael-day-new').prev('.uael-timeline-marker').addClass('hover');
});
$('.uael-content').on('mouseout', function(){
$( this ).parents('.uael-day-new').prev('.uael-timeline-marker').removeClass('hover');
});
});
</script>
<?php
}
add_action( 'wp_footer', 'modal_custom_script' );
2) Add CSS on the class 'hover'
.uael-timeline-marker.hover i:before{
content: "\f144";
font-size: 18px;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment