finished (very) rough frontend