Lazy load footer icons
Bug: T239377 Change-Id: I71270faf939f9187fafecf5b32defb3412c27580
This commit is contained in:
parent
13926c3dd0
commit
e60b08e212
1 changed files with 2 additions and 0 deletions
|
|
@ -986,6 +986,8 @@ abstract class Skin extends ContextSource {
|
|||
$url = $icon["url"] ?? null;
|
||||
unset( $icon["url"] );
|
||||
if ( isset( $icon["src"] ) && $withImage === 'withImage' ) {
|
||||
// Lazy-load footer icons, since they're not part of the printed view.
|
||||
$icon["loading"] = 'lazy';
|
||||
// do this the lazy way, just pass icon data as an attribute array
|
||||
$html = Html::element( 'img', $icon );
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue