renamed timeline to eventTree and factored leaf rendering out to a separate method