Class: PhlexUI::HoverCard
- Inherits:
-
Base
- Object
- Phlex::HTML
- Base
- PhlexUI::HoverCard
show all
- Defined in:
- lib/phlex_ui/hover_card.rb
Defined Under Namespace
Classes: Content, Trigger
Instance Attribute Summary
Attributes inherited from Base
#attrs
Instance Method Summary
collapse
Methods inherited from Base
#before_template
Constructor Details
#initialize(option: {}, **attrs) ⇒ HoverCard
5
6
7
8
9
10
|
# File 'lib/phlex_ui/hover_card.rb', line 5
def initialize(option: {}, **attrs)
@options = option
@options[:delay] ||= [500, 250]
@options[:trigger] ||= "mouseenter focus click"
super(**attrs)
end
|
Instance Method Details
#view_template ⇒ Object
12
13
14
|
# File 'lib/phlex_ui/hover_card.rb', line 12
def view_template(&)
div(**attrs, &)
end
|