5 * Contains image_widget_crop_example.install.
9 * Implements hook_install().
11 function image_widget_crop_examples_install() {
12 // Set the front page.
13 \Drupal::configFactory()
14 ->getEditable('system.site')
15 ->set('page.front', '/image_widget_crop_examples')
18 // Set the IWC general settings.
19 \Drupal::configFactory()
20 ->getEditable('image_widget_crop.settings')
21 ->set('settings.crop_preview_image_style', 'crop_thumbnail')
22 ->set('settings.show_default_crop', TRUE)
23 ->set('settings.warn_multiple_usages', FALSE)
24 ->set('settings.crop_list', [
25 'crop_16_9' => 'crop_16_9',
26 'crop_4_3' => 'crop_4_3',
27 'crop_free_ratio' => 'crop_free_ratio',