Fix flash of items and make checkbox toggle when all are done
More refactoring