Class: Spotlight::SelectImageComponent

Inherits:
ViewComponent::Base
  • Object
show all
Defined in:
app/components/spotlight/select_image_component.rb

Overview

Component to select section of image

Instance Method Summary collapse

Constructor Details

#initialize(index_id, block_item_id) ⇒ SelectImageComponent

Returns a new instance of SelectImageComponent.



6
7
8
9
10
# File 'app/components/spotlight/select_image_component.rb', line 6

def initialize(index_id, block_item_id)
  super
  @index_id = index_id
  @block_item_id = block_item_id
end

Instance Method Details

#help_textObject



20
21
22
# File 'app/components/spotlight/select_image_component.rb', line 20

def help_text
  t(:'spotlight.pages.form.instructions_html')
end

#initial_crop_selectionObject



16
17
18
# File 'app/components/spotlight/select_image_component.rb', line 16

def initial_crop_selection
  Spotlight::Engine.config.thumbnail_initial_crop_selection
end

#render?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'app/components/spotlight/select_image_component.rb', line 12

def render?
  true
end