When you click the link apply any CSS animation during show/hide toggle. The toggle works, but animation is not applied.
$('.working-hours-link').click(function(e) {
$(this).siblings(".hours").toggleClass('hidden shown');
});
.hidden {
background-color: #fff;
color: #000;
-webkit-transition: all 1s;
-moz-transition: all 1s;
-o-transition: all 1s;
transition: all 1s;
display: none;
}
.shown {
background-color: #000;
color: #fff;
-webkit-transition: all 1s;
-moz-transition: all 1s;
-o-transition: all 1s;
transition: all 1s;
display: block;
}
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<a class="working-hours-link" href="#">Show working hours</a>
<br>
<div class="hours hidden">
Sunday: 12:00 pm-6:00 pm
</div>