Sha256: db796fc98848f0d72c0b3ef022248c7db9c88d11c8ded6f32157b7a7e1fb5291
Contents?: true
Size: 789 Bytes
Versions: 10
Compression:
Stored size: 789 Bytes
Contents
# frozen_string_literal: true module BootstrapLeather # Alerts, i.e. messages at the top of the page, usually from flash # or form errors module AlertsHelper def flash_class(level) case level when :notice then 'info' when :error then 'danger' when :alert then 'warning' end end def alert(css_class, title, message = nil) render( partial: 'bootstrap_leather/alerts/alert', locals: { css_class: css_class, title: title, message: message } ) end def alert_flash_messages(html_options = {}) render( partial: 'bootstrap_leather/alerts/alert_flash_messages', locals: { html_options: html_options } ) end end end
Version data entries
10 entries across 10 versions & 1 rubygems