Update preview when user modifies editor contents