Module: Spotlight::JcropHelper

Included in:
ApplicationHelper
Defined in:
app/helpers/spotlight/jcrop_helper.rb

Overview

JCrop options helpers

Instance Method Summary collapse

Instance Method Details

#default_masthead_jcrop_optionsObject



5
6
7
8
9
10
11
12
13
14
15
# File 'app/helpers/spotlight/jcrop_helper.rb', line 5

def default_masthead_jcrop_options
  {
    croppable: true,
    selector: 'masthead_image',
    bg_color: 'black',
    bg_opacity: '.4',
    aspect_ratio: 10,
    box_width: '600',
    initial_set_select: '[0, 0, 1800, 180]'
  }
end

#default_thumbnail_jcrop_optionsObject



17
18
19
20
21
22
23
24
25
26
27
# File 'app/helpers/spotlight/jcrop_helper.rb', line 17

def default_thumbnail_jcrop_options
  {
    croppable: true,
    selector: 'featuredimage_image',
    bg_color: 'black',
    bg_opacity: '.4',
    box_width: '600',
    aspect_ratio: 4.0 / 3.0,
    initial_set_select: '[0, 0, 100000, 100000]'
  }
end