Skip to content

Commit

Permalink
feat: add support for the opacity filter
Browse files Browse the repository at this point in the history
chore(deps): change the required Hugo version to v0.119.0
  • Loading branch information
razonyang committed Oct 7, 2023
1 parent 0488c7d commit 26371df
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion hugo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[module.hugoVersion]
min = "0.111.3"
min = "0.119.0"

[params.images]
class_name = "img-fluid"
Expand Down
3 changes: 3 additions & 0 deletions layouts/partials/images/image.html
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,9 @@
{{- with $params.Has "invert" }}
{{ $filters = $filters | append images.Invert }}
{{ end }}
{{- with $params.Get "opacity" }}
{{ $filters = $filters | append (images.Opacity .) }}
{{ end }}
{{- with $params.Get "saturation" }}
{{ $filters = $filters | append (images.Saturation .) }}
{{ end }}
Expand Down

0 comments on commit 26371df

Please sign in to comment.