Implementing the timeline functionality