$newline never
_{MsgAllocationSemester}
_{unTermKey allocationTerm}
_{MsgAllocationSchool}
#{schoolName} $maybe desc <- allocationDescription
_{MsgAllocationDescription}
#{desc} $maybe desc <- guardOn isAnyLecturer =<< allocationStaffDescription
_{MsgAllocationStaffDescription}
#{desc} $maybe fromT <- allocationStaffRegisterFrom
$maybe _ <- allocationStaffRegisterTo _{MsgAllocationStaffRegister} $nothing _{MsgAllocationStaffRegisterFrom}
^{formatTimeRangeW SelFormatDateTime fromT allocationStaffRegisterTo} $maybe fromT <- allocationRegisterFrom
$maybe _ <- allocationRegisterTo _{MsgAllocationRegister} $nothing _{MsgAllocationRegisterFrom}
^{formatTimeRangeW SelFormatDateTime fromT allocationRegisterTo} $maybe fromT <- allocationStaffAllocationFrom
$maybe _ <- allocationStaffAllocationTo _{MsgAllocationStaffAllocation} $nothing _{MsgAllocationStaffAllocationFrom}
^{formatTimeRangeW SelFormatDateTime fromT allocationStaffAllocationTo} $maybe fromT <- allocationRegisterByStaffFrom
$maybe _ <- allocationRegisterByStaffTo _{MsgAllocationRegisterByStaff} ^{iconTooltip (i18n MsgAllocationRegisterByStaffTip) Nothing True} $nothing _{MsgAllocationRegisterByStaffFrom} ^{iconTooltip (i18n MsgAllocationRegisterByStaffFromTip) Nothing True}
^{formatTimeRangeW SelFormatDateTime fromT allocationRegisterByStaffTo} $if isAdmin
_{MsgAllocationNextSubstitutesDeadline} # ^{iconInvisible}
$maybe deadline <- nextSubstitutesDeadline ^{formatTimeW SelFormatDateTime deadline} $nothing _{MsgAllocationNextSubstitutesDeadlineNever}
_{MsgAllocationFreeCapacity} # ^{iconInvisible}
$maybe freeCap <- freeCapacity #{freeCap} $if freeCap <= 0 \ ^{iconOK} $nothing ∞ $maybe fromT <- allocationRegisterByCourse
_{MsgAllocationRegisterByCourseFrom} ^{iconTooltip (i18n MsgAllocationRegisterByCourseFromTip) Nothing True}
^{formatTimeW SelFormatDateTime fromT} $maybe toT <- allocationOverrideDeregister
_{MsgAllocationOverrideDeregister}

^{formatTimeW SelFormatDateTime toT}

_{MsgAllocationParticipation} $if is _Nothing muid

_{MsgAllocationParticipationLoginFirst} $elseif mayRegister $# existing registrations may also be edited in this case ^{registerForm'} $elseif is _Just registration $# show existing registration even if it cannot be changed now $maybe Entity _ AllocationUser{allocationUserTotalCourses} <- registration

_{MsgAllocationTotalCourses}
#{allocationUserTotalCourses} $else $# Provide helpful information for confused students who cannot register now $maybe daysToOpen <- daysToRegistrationStart

_{MsgAllocationRegisterOpensIn (formatDiffDays daysToOpen)} $nothing

_{MsgAllocationRegisterClosed}

$# This redundant links prevents useless help requests from frantic users ^{allocationInfoModal}

_{MsgAllocationNotificationNewCourse} $if is _Just muid

_{MsgAllocationNotificationNewCourseTip}
_{bool MsgAllocationNotificationNewCourseCurrentlyOff MsgAllocationNotificationNewCourseCurrentlyOn wouldNotifyNewCourse} ^{notificationForm'} $else _{MsgAllocationNotificationLoginFirst} $if not (null courseWidgets)

_{MsgAllocationCourses}

_{MsgAllocationPriorityTip}

_{MsgAllocationPriorityRelative}

_{MsgApplicationEditTip} $if is _Just muid

_{MsgAllocationNumCoursesAvailableApplied numCourses numAppliedCourses}

$forall courseWgt <- courseWidgets ^{courseWgt}