From f9973cef3d979b2a47f0a7bbb6fb8b2b5ce5c836 Mon Sep 17 00:00:00 2001 From: Jaifroid Date: Fri, 11 Aug 2017 07:13:44 +0100 Subject: [PATCH] Added missing CSS from new ZIM type to cache Former-commit-id: 98e128ba1ab4cfadf6f00b8dcf87985b243212d1 [formerly 198de12324e711972da980e7dcfeb1eb932f9d0e] Former-commit-id: 1a82cf60d6b95d853412224e71fcab6e5eade40b --- www/-/s/css_modules/ext.math.scripts.css | 6 ++++++ www/-/s/css_modules/ext.math.styles.css | 1 + www/js/lib/transformStyles.js | 2 ++ 3 files changed, 9 insertions(+) create mode 100644 www/-/s/css_modules/ext.math.scripts.css create mode 100644 www/-/s/css_modules/ext.math.styles.css diff --git a/www/-/s/css_modules/ext.math.scripts.css b/www/-/s/css_modules/ext.math.scripts.css new file mode 100644 index 00000000..a40ce3be --- /dev/null +++ b/www/-/s/css_modules/ext.math.scripts.css @@ -0,0 +1,6 @@ +/** + * Dummy stylesheet + * + * This sheet returns an empty css from the ZIM, so it is included here + * to prevent useless retrieval of empty data. + */ \ No newline at end of file diff --git a/www/-/s/css_modules/ext.math.styles.css b/www/-/s/css_modules/ext.math.styles.css new file mode 100644 index 00000000..62f17e2d --- /dev/null +++ b/www/-/s/css_modules/ext.math.styles.css @@ -0,0 +1 @@ +@namespace m url(http:/www.w3.org/1998/Math/MathML);.mwe-math-mathml-inline{display:inline !important}.mwe-math-mathml-display{display:block !important;margin-left:auto;margin-right:auto}.mwe-math-mathml-a11y{clip:rect( 1px,1px,1px,1px );overflow:hidden;position:absolute;width:1px;height:1px;opacity:0}.mwe-math-fallback-image-inline{display:inline-block;vertical-align:middle}.mwe-math-fallback-image-display{display:block;margin-left:auto !important;margin-right:auto !important}.mwe-math-fallback-source-inline{display:inline;vertical-align:middle}.mwe-math-fallback-source-display{display:block;margin-left:auto;margin-right:auto}img.tex{vertical-align:middle}div.mwe-math-element{overflow-x:auto;max-width:100%} \ No newline at end of file diff --git a/www/js/lib/transformStyles.js b/www/js/lib/transformStyles.js index a3f18801..188acfd1 100644 --- a/www/js/lib/transformStyles.js +++ b/www/js/lib/transformStyles.js @@ -60,6 +60,8 @@ define(['uiUtil'], function (uiUtil) { zl.match(/-\/s\/css_modules\/mw.PopUpMediaTransform.css/i) || zl.match(/-\/s\/css_modules\/mw.MediaWikiPlayer.loader.css/i) || zl.match(/-\/s\/css_modules\/ext.tmh.thumbnail.styles.css/i) || + zl.match(/-\/s\/css_modules\/ext.math.styles.css/i) || + zl.match(/-\/s\/css_modules\/ext.math.scripts.css/i) || zl.match(/-\/s\/css_modules\/content.parsoid.css/i) || zl.match(/-\/s\/css_modules\/inserted_style_mobile.css/i) || zl.match(/-\/s\/css_modules\/mobile.css/i) ||