Class: UI::Carousel
- Inherits:
-
Phlex::HTML
- Object
- Phlex::HTML
- UI::Carousel
- Defined in:
- app/components/ui/carousel.rb
Instance Method Summary collapse
-
#initialize(classes: nil, orientation: "horizontal", opts: {}, plugins: nil, **attributes) ⇒ Carousel
constructor
A new instance of Carousel.
- #view_template(&block) ⇒ Object
Constructor Details
#initialize(classes: nil, orientation: "horizontal", opts: {}, plugins: nil, **attributes) ⇒ Carousel
Returns a new instance of Carousel.
4 5 6 7 8 9 10 |
# File 'app/components/ui/carousel.rb', line 4 def initialize(classes: nil, orientation: "horizontal", opts: {}, plugins: nil, **attributes) @classes = classes @orientation = orientation @opts = opts @plugins = plugins @attributes = attributes end |
Instance Method Details
#view_template(&block) ⇒ Object
12 13 14 15 16 |
# File 'app/components/ui/carousel.rb', line 12 def view_template(&block) extend UI::CarouselBehavior div(**carousel_html_attributes, &block) end |