broken implementation of preview