Implement better flash behavior

This commit is contained in:
Maximilian Grundke
2017-06-23 12:19:27 +02:00
parent ff9fb8d491
commit e739749828
3 changed files with 28 additions and 15 deletions

View File

@ -1,3 +1,5 @@
#flash.fixed_error_messages.clickthrough data-message-failure=t('shared.message_failure')
#flash.fixed_error_messages data-message-failure=t('shared.message_failure')
- %w[alert danger info notice success warning].each do |severity|
p.alert.flash class="alert-#{{'alert' => 'warning', 'notice' => 'success'}.fetch(severity, severity)}" id="flash-#{severity}" = flash[severity]
div.alert.flash class="alert-#{{'alert' => 'warning', 'notice' => 'success'}.fetch(severity, severity)}" id="flash-#{severity}"
p = flash[severity]
span.fa.fa-times