fix(Doc): Reset private properties when Doc::affect() is called (refs #4875)