Skip to content

Commit

Permalink
fix: Update image style sizes as per 2023 recommendations
Browse files Browse the repository at this point in the history
  • Loading branch information
froboy committed Jul 18, 2023
1 parent 91187c2 commit a59e369
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
4 changes: 2 additions & 2 deletions openy_node/config/install/image.style.facebook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ effects:
id: image_scale
weight: 1
data:
width: 600
height: 315
width: 1200
height: 630
upscale: false
5cc7aae0-016e-4841-8ca9-556674060bf3:
uuid: 5cc7aae0-016e-4841-8ca9-556674060bf3
Expand Down
12 changes: 12 additions & 0 deletions openy_node/openy_node.install
Original file line number Diff line number Diff line change
Expand Up @@ -148,3 +148,15 @@ function openy_node_update_8009() {
'image.style.facebook',
]);
}

/**
* Update to 2023 recommended image size.
*/
function openy_node_update_8010() {
$path = \Drupal::service('extension.list.module')->getPath('openy_node') . '/config/install';
$config_importer = \Drupal::service('config_import.importer');
$config_importer->setDirectory($path);
$config_importer->importConfigs([
'image.style.facebook',
]);
}

0 comments on commit a59e369

Please sign in to comment.