refactor edit toolbar