[ci skip] Use webp instead of jpeg for thumbnails
This commit is contained in:
		
					parent
					
						
							
								540ea51d8e
							
						
					
				
			
			
				commit
				
					
						aa0ecc4104
					
				
			
		
					 2 changed files with 2 additions and 2 deletions
				
			
		|  | @ -1,7 +1,7 @@ | |||
| {{ $image := resources.GetMatch (.Get "src") }} | ||||
| {{ $size := .Get "size" }} | ||||
| {{/* Set the right options for Resize */}} | ||||
| {{ $options := printf "%s %s %s" $size "jpg q90" "Box"}} | ||||
| {{ $options := printf "%s %s %s" $size "webp q90 drawing" "Lanczos"}} | ||||
| {{ $imagethumbnail := $image.Resize $options }} | ||||
| 
 | ||||
| <figure{{ with .Get "class" }} class="{{ . }}"{{ end }}> | ||||
|  |  | |||
|  | @ -1,7 +1,7 @@ | |||
| <div class="gallery flex justify-center"> | ||||
| {{ range $param := .Params }} | ||||
|   {{ $image := resources.GetMatch ($param) }} | ||||
|   {{ $processed := $image.Resize ( printf "x%d %s %s %s" 350 "jpg" "q90" "Box" ) }} | ||||
|   {{ $processed := $image.Resize ( printf "x%d %s %s %s %s" 350 "webp" "q90" "drawing" "Box" ) }} | ||||
|       <a href="{{ $image.RelPermalink }}"> | ||||
|         <img class="thumbnail w6 pa1 mr1" src="{{ $processed.RelPermalink }}" style="width: 95% !important;" /> | ||||
|   </a> | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue