slide-down-alerts-rails (still under development)
Rails notifications Twitter-style
Installation
Add this line to your application's Gemfile:
gem 'slide-down-alerts-rails'
And then execute:
$ bundle
Or install it yourself as:
$ gem install slide-down-alerts-rails
Now import the Javascript by adding this //= require jquery.bar.custom
and this //= require helpers
to the manifest section of your application.js
file.
After that it's time to import the CSS by adding require jbar.colors
and require jbar
to the manifest section of application.css
OR your could use @import "jbar.colors";
and @import "jbar";
if you're dealing with a SASS file :)
Usage
Add this view helper <%= slide_down_alerts %>
to your application layout and you're good to go. Whenever there is something related to notice
, alert
or error
in the flash
scope it will be shown in a nice-looking-down-sliding notification. Check it out!
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request