Load the page logo immediately
authorAlexander Ebert <ebert@woltlab.com>
Mon, 10 May 2021 11:45:52 +0000 (13:45 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 10 May 2021 11:45:52 +0000 (13:45 +0200)
com.woltlab.wcf/templates/pageHeaderLogo.tpl
wcfsetup/install/files/style/layout/pageHeader.scss

index 5a210b5ff016700f784b82e93c38d0b234651971..5b4253509d7643da9e9163fa38819a2f466a1706 100644 (file)
@@ -2,8 +2,11 @@
        {if MODULE_WCF_AD && $__disableAds|empty}{@$__wcf->getAdHandler()->getAds('com.woltlab.wcf.logo')}{/if}
        
        <a href="{if PAGE_LOGO_LINK_TO_APP_DEFAULT}{link application=$__wcf->getActiveApplication()->getAbbreviation()}{/link}{else}{link}{/link}{/if}">
-               <img src="{$__wcf->getStyleHandler()->getStyle()->getPageLogo()}" alt="" class="pageHeaderLogoLarge" style="{if $__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoWidth')}width: {@$__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoWidth')}px;{/if}{if $__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoHeight')}height: {@$__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoHeight')}px{/if}">
-               <img src="{$__wcf->getStyleHandler()->getStyle()->getPageLogoMobile()}" alt="" class="pageHeaderLogoSmall">
+               <img src="{$__wcf->getStyleHandler()->getStyle()->getPageLogo()}" alt="" class="pageHeaderLogoLarge"{*
+                       *}{if $__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoHeight')} height="{@$__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoHeight')}"{/if}{*
+                       *}{if $__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoWidth')} width="{@$__wcf->getStyleHandler()->getStyle()->getVariable('pageLogoWidth')}"{/if}{*
+                       *} loading="eager">
+               <img src="{$__wcf->getStyleHandler()->getStyle()->getPageLogoMobile()}" alt="" class="pageHeaderLogoSmall" loading="eager">
                
                {event name='headerLogo'}
        </a>
index cfaa43c2a88ac05d390fd1fb31e613fb2db4324c..df7e323484ca93318f568c631182420fef8fb4fa 100644 (file)
                flex: 1 1 auto;
 
                .pageHeaderLogoLarge {
+                       height: auto;
                        max-width: 100%;
                }