Ace editor edit and preview modes