fix transcript design screen when having specializations
improve assign classes: when previous period was empty, can use the period before