svg comet refactoring