hourOfPeriod property

int hourOfPeriod

Which hour of the current period (e.g., am or pm) this time is.

For 12AM (midnight) and 12PM (noon) this returns 12.

Implementation

int get hourOfPeriod => hour == 0 || hour == 12 ? 12 : hour - periodOffset;