Skip to content

Commit

Permalink
fix: image style for interactive content
Browse files Browse the repository at this point in the history
Refs: RW-818
  • Loading branch information
orakili committed Oct 25, 2023
1 parent deac7a1 commit 445ed3b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions html/modules/custom/reliefweb_entities/src/Entity/Report.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ public function getAttachments(?array $build = NULL) {
$build['#theme'] = 'reliefweb_file_list__interactive';

$build['#title'] = $this->t('Screenshot(s) of the interactive content as of @date', [
'@date' => DateHelper::format($this->getCreatedTime(), 'custom', 'j m Y'),
'@date' => DateHelper::format($this->getCreatedTime(), 'custom', 'j M Y'),
]);

$url = NULL;
Expand Down Expand Up @@ -164,8 +164,8 @@ public function getAttachments(?array $build = NULL) {
]);
}
if (isset($item['preview'])) {
$item['preview']['#style_name'] = 'large';
$item['preview']['#alt'] = $item['label'];
$item['preview']['#responsive_image_style_id'] = 'large';
$item['preview']['#attributes']['alt'] = $item['label'];
}

// Have the screenshots link to the original content.
Expand Down

0 comments on commit 445ed3b

Please sign in to comment.