Added editing mode (not quite functional yet)