diff --git a/config/imgix.php b/config/imgix.php index dd09fcd..7788322 100644 --- a/config/imgix.php +++ b/config/imgix.php @@ -6,4 +6,5 @@ 'use_https' => true, 'include_library_param' => true, 'srcset_resolutions' => [1, 2], + 'default_params' => [], ]; diff --git a/src/ImgixHelper.php b/src/ImgixHelper.php index 58bf3ab..b672c1d 100644 --- a/src/ImgixHelper.php +++ b/src/ImgixHelper.php @@ -22,7 +22,7 @@ public static function processParams(array $params = []) $sorted = [ 'path' => $params['path'] ?: "", 'html' => [], - 'imgix' => [], + 'imgix' => config('imgix.default_params', []), ]; // Split the `focus` parameter into fp-x, fp-y and fp-z for imgix @@ -56,4 +56,4 @@ public static function processParams(array $params = []) return $sorted; } -} \ No newline at end of file +}