markdown refactor