Form fields resets when phx-keyup event is trigerred

Hello! I am currently making a backoffice section which handles articles from a blog. I want to make the form component(where i add or edit article) with 4 fields title, body, is_posted and post_date. The problem comes here because i want to make a live markdown language parser for the body - when i edit the body i have a live preview on the left. I managed to do it - with phx-keyup action on the body input - but here comes the problem - every time i edit the body the other fields reset to initial state.