Class: PhlexUI::Select::Content

Inherits:
Base
  • Object
show all
Defined in:
lib/phlex_ui/select/content.rb

Instance Attribute Summary

Attributes inherited from Base

#attrs

Instance Method Summary collapse

Methods inherited from Base

#before_template

Constructor Details

#initialize(outlet_id:, **attrs) ⇒ Content

Returns a new instance of Content.



5
6
7
8
# File 'lib/phlex_ui/select/content.rb', line 5

def initialize(outlet_id:, **attrs)
  @outlet_id = outlet_id
  super(**attrs)
end

Instance Method Details

#view_template(&block) ⇒ Object



10
11
12
13
14
# File 'lib/phlex_ui/select/content.rb', line 10

def view_template(&block)
  template_tag(data: {popover_target: "content"}) do
    div(**attrs, &block)
  end
end