Keep metadata through celltype changes

Just 4* a slight modification on notebook/to_{markdown, code, rawcell, heading}