01bedb54c6
This better handles error messages formatted for console display, by adding a <br> after each line. Hmm, I wonder if it'd be worth pulling in a markdown formatter, and running the messages through it?
25 lines
702 B
Text
25 lines
702 B
Text
<div .alert .fade .in .#{divclass} :block:.alert-block ##{alertid}>
|
|
$if closable
|
|
<a .close onclick="(function( $ ) { $.get('@{CloseAlert aid}') })( jQuery );">×</a>
|
|
$maybe h <- renderAlertHeader alert
|
|
$if block
|
|
<h4 .alert-heading>
|
|
$maybe i <- alertIcon alert
|
|
^{htmlIcon i} #
|
|
#{h}
|
|
$else
|
|
$maybe i <- alertIcon alert
|
|
^{htmlIcon i} #
|
|
<strong>#{h}</strong> #
|
|
$nothing
|
|
$maybe i <- alertIcon alert
|
|
^{htmlIcon i} #
|
|
$if multiline
|
|
$forall l <- messagelines
|
|
#{l}<br>
|
|
$else
|
|
#{message}
|
|
$maybe button <- alertButton alert
|
|
<br>
|
|
<a .btn .btn-primary href="@{ClickAlert aid}">
|
|
#{buttonLabel button}
|