scinote-web/app/views/shared/_flash_alerts.html.erb
2018-07-27 15:27:08 +02:00

30 lines
1.2 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<div id="notifications">
<% if flash[:success] %>
<div id="alert-flash" class="alert alert-success alert-dismissable alert-floating">
<div>
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
<span class="fas fa-check-circle"></span>
<span><%= sanitize_input(flash[:success]) %></span>
</div>
</div>
<% end %>
<% if notice %>
<div id="alert-flash" class="alert alert-info alert-dismissable alert-floating">
<div>
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
<span class="fas fa-info-circle"></span>
<span><%= notice %></span>
</div>
</div>
<% end %>
<% if alert and !alert.empty? or flash[:error]%>
<div id="alert-flash" class="alert alert-danger alert-dismissable alert-floating">
<div>
<button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">×</span></button>
<span class="fas fa-exclamation-circle"></span>
<span><%= alert || sanitize_input(flash[:error]) %></span>
</div>
</div>
<% end %>
</div>