[d3] refactor some code + show steps under each other.