semanticize nested lists into ol/uls