Enforce unix file ending when saving files

Some style changes and an edit button/link when previewing files.