diff --git a/bundlesize.config.json b/bundlesize.config.json index 4e9af3deb..f446865b6 100644 --- a/bundlesize.config.json +++ b/bundlesize.config.json @@ -33,6 +33,6 @@ }, { "resourceModule": "skins.minerva.scripts", - "maxSize": "11.9KB" + "maxSize": "12.0KB" } ] diff --git a/resources/skins.minerva.scripts/downloadPageAction.js b/resources/skins.minerva.scripts/downloadPageAction.js index d324aacee..a416cf4b8 100644 --- a/resources/skins.minerva.scripts/downloadPageAction.js +++ b/resources/skins.minerva.scripts/downloadPageAction.js @@ -45,6 +45,11 @@ var androidVersion = getAndroidVersion( userAgent ), chromeVersion = getChromeVersion( userAgent ); + if ( typeof window.print !== 'function' ) { + // T309591: No window.print support + return false; + } + // Download button is restricted to certain namespaces T181152. // Not shown on missing pages // Defaults to 0, in case cached JS has been served.