Fix utf-8 issues in preview