move icon logic into classes and interface