Module: BootstrapPopoverHelper
- Defined in:
- app/helpers/bootstrap_popover_helper.rb
Overview
RAILS BOOTSTRAP ENGINE
Bootstrap Popovers twitter.github.com/bootstrap/javascript.html#popovers
Copyright 2012-2013 Luiz Eduardo de Oliveira Fonseca, Agência Orangeweb
Licensed under The MIT License
Instance Method Summary collapse
-
#popover(title, content, options = {}) ⇒ Object
Generates bootstrap popover markup.
-
#tooltip_link_to(title, link, opts = {}) ⇒ Object
Generates bootstrap popover markup.
Instance Method Details
#popover(title, content, options = {}) ⇒ Object
Generates bootstrap popover markup
<a href=“#” rel=“popover” data-content=“Some Content” data-original-title=“A Title”> Title </a>
44 45 46 47 48 |
# File 'app/helpers/bootstrap_popover_helper.rb', line 44 def popover title, content, ={} [:rel] = :popover [:data] = { :content => content, "original-title" => title } link_to title, "#", end |
#tooltip_link_to(title, link, opts = {}) ⇒ Object
Generates bootstrap popover markup
<a href=“#” rel=“tooltip” title=“Tooltip Text”>Title</a>
28 29 30 31 |
# File 'app/helpers/bootstrap_popover_helper.rb', line 28 def tooltip_link_to title, link, opts={} opts[:rel] = :tooltip link_to title, link, opts end |