parse code and add copy button