You are here

function baguettebox_field_formatter_settings_form in baguetteBox.js 7

Implements hook_field_formatter_settings_form().

File

./baguettebox.module, line 63
Primary hooks for baguettebox module.

Code

function baguettebox_field_formatter_settings_form($field, $instance, $view_mode, $form, &$form_state) {
  $display = $instance['display'][$view_mode];
  $settings = $display['settings'];
  $image_styles = image_style_options(FALSE, PASS_THROUGH);
  $element['initial_image_style'] = array(
    '#title' => t('Initial image style'),
    '#type' => 'select',
    '#default_value' => $settings['initial_image_style'],
    '#empty_option' => t('None (original image)'),
    '#options' => $image_styles,
  );
  $element['baguettebox_image_style'] = array(
    '#title' => t('Baguettebox image_style'),
    '#type' => 'select',
    '#default_value' => $settings['baguettebox_image_style'],
    '#empty_option' => t('None (original image)'),
    '#options' => $image_styles,
  );
  $element['animation'] = array(
    '#title' => t('Animation'),
    '#type' => 'select',
    '#default_value' => $settings['animation'],
    '#options' => array(
      '0' => t('None'),
      'slideIn' => t('SlideIn'),
      'fadeIn' => t('FadeIn'),
    ),
  );
  return $element;
}