latestPeriod property
Latest period that has a course (accounting for span), or null if empty.
Implementation
Period? get latestPeriod => isEmpty
? null
: Period.values[entries
.map((e) => e.key.period.index + e.value.span - 1)
.reduce(max)];