- $settings += [
- 'absolute_path' => $absolute_path,
- 'bundle' => $bundle,
- 'content_url' => $absolute_path,
- 'count' => $count,
- 'entity_id' => $entity_id,
- 'entity_type_id' => $entity_type_id,
- 'field_type' => $field_type,
- 'field_name' => $field_name,
- 'internal_path' => $internal_path,
- 'target_type' => $target_type,
- 'cache_metadata' => ['keys' => [$id, $count]],
- ];
+ $settings['breakpoints'] = isset($settings['breakpoints']) && empty($settings['responsive_image_style']) ? $settings['breakpoints'] : [];
+ $settings['bundle'] = $bundle;
+ $settings['cache_metadata'] = ['keys' => [$id, $count]];
+ $settings['content_url'] = $settings['absolute_path'] = $absolute_path;
+ $settings['count'] = $count;
+ $settings['entity_id'] = $entity_id;
+ $settings['entity_type_id'] = $entity_type_id;
+ $settings['field_type'] = $field_type;
+ $settings['field_name'] = $field_name;
+ $settings['id'] = $id;
+ $settings['internal_path'] = $internal_path;
+ $settings['lightbox'] = ($switch && in_array($switch, $this->getLightboxes())) ? $switch : FALSE;
+ $settings['resimage'] = function_exists('responsive_image_get_image_dimensions');
+ $settings['target_type'] = $target_type;