Class: Matestack::Ui::Bootstrap::Components::Popover

Inherits:
BaseVueJsComponent show all
Defined in:
lib/matestack/ui/bootstrap/components/popover.rb

Constant Summary collapse

DATA_ALIAS_ATTRIBUTES =
%i[container delay selector html template fallback_placement]
DATA_ATTRIBUTES =
%i[tag content title variant animation placement tabindex trigger boundary offset popper_config]

Instance Method Summary collapse

Instance Method Details

#response(&block) ⇒ Object

:tag # different element to apply: div, span, links, button, … :content, :title # popover title and content strings :animation # boolean, default true :variant, :text # button styling & text :placement # placement direction as string



48
49
50
51
52
53
54
55
56
57
58
# File 'lib/matestack/ui/bootstrap/components/popover.rb', line 48

def response(&block)
  if context.tag.present?
    public_send(context.tag, popover_attributes) do
      content_partial(&block)
    end
  else
    bs_btn popover_attributes do
      content_partial(&block)
    end
  end
end