diff --git a/assets/sass/_theme/design-system/hero.sass b/assets/sass/_theme/design-system/hero.sass index 1cd7c5d3eaa3bf4b370051c5a0f06692cdf60586..4f1da71cd2c5b8b7ede87617c62c4a5c82cc57d6 100644 --- a/assets/sass/_theme/design-system/hero.sass +++ b/assets/sass/_theme/design-system/hero.sass @@ -40,6 +40,15 @@ margin-bottom: 0 & + .document-content margin-top: $spacing3 + &--with-image + figure + position: relative + > a + position: absolute + top: 0 + left: 0 + height: 100% + width: 100% @include media-breakpoint-down(desktop) .breadcrumb-nav margin-left: half(-$grid-gutter-sm) diff --git a/layouts/partials/header/hero.html b/layouts/partials/header/hero.html index 65f8abf544eb021abe22180c8de0f4bd0a854cb4..4d62d61afe6c90a4bd8e640a6715ab20c6856348 100644 --- a/layouts/partials/header/hero.html +++ b/layouts/partials/header/hero.html @@ -39,6 +39,12 @@ {{- end -}} {{- if .image }} <figure> + {{ partial "commons/image.html" + (dict + "image" .image + "sizes" ( .sizes | default site.Params.image_sizes.design_system.hero ) + "lazy" false + ) }} {{ if not site.Params.image_sizes.design_system.lightbox.disabled }} <a class="glightbox" role="button" @@ -46,14 +52,6 @@ href="{{ partial "GetLightboxUrl" .image }}" title="{{- i18n "commons.lightbox.link.title" -}}" aria-label="{{- i18n "commons.lightbox.link.title" -}}"> - {{ end }} - {{ partial "commons/image.html" - (dict - "image" .image - "sizes" ( .sizes | default site.Params.image_sizes.design_system.hero ) - "lazy" false - ) }} - {{ if not site.Params.image_sizes.design_system.lightbox.disabled }} </a> {{ end }} {{ if partial "GetTextFromHTML" .image.credit }}