Compare commits

..

2 commits

Author SHA1 Message Date
L3D
2dd3a87fae
Merge branch 'ui' of backwesen.de:c3woc/webseite into ui 2021-08-31 22:50:18 +02:00
L3D
8bc901d5b0
Update 2021-08-31 22:50:02 +02:00
4 changed files with 20 additions and 1 deletions

1
.gitignore vendored
View file

@ -21,6 +21,7 @@ tags
.models/ .models/
.flowblocks/ .flowblocks/
temp/ temp/
packages/
# ---> Windows # ---> Windows
# Windows thumbnail cache files # Windows thumbnail cache files

View file

@ -27,3 +27,4 @@ url_prefix = /en/
[packages] [packages]
lektor-scss = 1.4.1 lektor-scss = 1.4.1
lektor-image-resize = 0.2.0

17
configs/image-resize.ini Normal file
View file

@ -0,0 +1,17 @@
[tiny]
max_width = 128
[small]
max_width = 420
use_guetzli = True
[medium]
max_width = 960
use_guetzli = True
[large]
max_width = 1600
use_guetzli = True
[woowee]
max_width = 2160

View file

@ -4,7 +4,7 @@
{%- if this.box_image is defined and this.box_image != '' -%} {%- if this.box_image is defined and this.box_image != '' -%}
{%- set image = record.attachments.images.get(this.box_image) -%} {%- set image = record.attachments.images.get(this.box_image) -%}
{{- '\n ' -}} <img class="content__inner_third_image content__half_box_image" src="{{ image|url }}" {{- '\n ' -}} <img class="content__inner_third_image content__half_box_image" src="{{ image|url }}"
{{- '\n ' -}} width="{{ image.width / 2 }}" {{- '\n ' -}} width="{{ image.width / 2 | int }}"
{%- if this.image_alt is defined and this.image_alt != "" -%} {%- if this.image_alt is defined and this.image_alt != "" -%}
{{- ' ' -}} {{- ' ' -}}
alt="{{ this.image_alt }}" alt="{{ this.image_alt }}"