Sha256: 401450815dd34f2f5b9d058e7fa6c1cca6cdfd1e78466c64bb572cefb8c5dcc7
Contents?: true
Size: 1.13 KB
Versions: 36
Compression:
Stored size: 1.13 KB
Contents
<%# Copyright © 2012 The Pennsylvania State University Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. %> <% flash_types_to_classes = { :notice => 'alert-success', :error => 'alert', :alert => 'alert-error' } %> <% [:notice, :error, :alert].each do |type| %> <% if flash[type] %> <div class="alert <%= flash_types_to_classes[type] rescue '' %> ui-corner-all <%= type.to_s %>"> <a class="close" data-dismiss="alert" href="#">×</a> <% if flash[type].respond_to? :join %> <%= flash[type].join("<br/>").html_safe %> <% else %> <%= flash[type].html_safe %> <% end %> </div> <% flash.delete(type) %> <% end %> <% end %>
Version data entries
36 entries across 36 versions & 1 rubygems