Class: Viewport::Component

Inherits:
Lookbook::BaseComponent
  • Object
show all
Defined in:
app/components/lookbook/viewport/component.rb

Instance Method Summary collapse

Constructor Details

#initialize(src:, resize_height: true, resize_width: true, max_height: nil, iframe_id: nil, **html_attrs) ⇒ Component

Returns a new instance of Component.



3
4
5
6
7
8
9
10
# File 'app/components/lookbook/viewport/component.rb', line 3

def initialize(src:, resize_height: true, resize_width: true, max_height: nil, iframe_id: nil, **html_attrs)
  @src = src
  @resize_height = resize_height
  @resize_width = resize_width
  @max_height = max_height
  @iframe_id = iframe_id
  super(**html_attrs)
end