Krinkle has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/342661 )
Change subject: Remove @embed for image not used during page load
......................................................................
Remove @embed for image not used during page load
>>! Performance Inspector
> Source: ext.uls.common
> Used selectors: 0.00% (0 of 10)
> Used embeds: 0.00% (0 of 1)
> ----
> .uls-icon-back {
> background-image: .., url("data:image/svg+xml..
It seems the entire module is unused by default. This icon is
used by ext.uls.inputsettings and ext.uls.displaysettings as part
of a click-triggered dialog, which means it can never appear
on a page directly.
In a case like this, it probably makes sense to remove the entire
module from the load queue and instead have it be lazy-loaded
when the widget is interacted with (an early call to load() to
start the fetch, and later on using() where it is actually needed).
That way, the embed can be kept and the dialog will render in full
at once.
Alternatively, keep the existing preload as part of the page but
without the embedded image. The image will automatically load
from the image url in CSS when the dialog is opened.
Bug: T121730
Change-Id: I36831beeb764e6893c331b20b90102a5ceb0d21a
---
M resources/css/ext.uls.css
1 file changed, 0 insertions(+), 1 deletion(-)
git pull
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/UniversalLanguageSelector
refs/changes/61/342661/1
diff --git a/resources/css/ext.uls.css b/resources/css/ext.uls.css
index 7e3c988..6ef48ff 100644
--- a/resources/css/ext.uls.css
+++ b/resources/css/ext.uls.css
@@ -54,7 +54,6 @@
.uls-icon-back {
background: transparent url( ../images/back-grey-ltr.png ) no-repeat
scroll center center;
background-image: -webkit-linear-gradient( transparent, transparent ),
url( ../images/back-grey-ltr.svg );
- /* @embed */
background-image: linear-gradient( transparent, transparent ), url(
../images/back-grey-ltr.svg );
background-size: 28px;
background-position: center center;
--
To view, visit https://gerrit.wikimedia.org/r/342661
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I36831beeb764e6893c331b20b90102a5ceb0d21a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UniversalLanguageSelector
Gerrit-Branch: master
Gerrit-Owner: Krinkle <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits