mirror of
https://github.com/kiwix/kiwix-js-pwa.git
synced 2025-08-03 19:38:36 -04:00
parent
17038f96bf
commit
acdaa5ffd7
@ -108,7 +108,7 @@ params['linkToWikimediaImageFile'] = getSetting('linkToWikimediaImageFile') == t
|
||||
params['hideToolbars'] = getSetting('hideToolbars') != null ? getSetting('hideToolbars') : true; // Set default to true (hides both), 'top' (hides top only), or false (no hiding)
|
||||
params['rememberLastPage'] = getSetting('rememberLastPage') != null ? getSetting('rememberLastPage') : true; // Set default option to remember the last visited page between sessions
|
||||
params['showPopoverPreviews'] = getSetting('showPopoverPreviews') !== false; // Allows popover previews of articles for Wikimedia ZIMs (defaults to true)
|
||||
params['assetsCache'] = getSetting('appCache') !== false; // Whether to use cache by default or not
|
||||
params['assetsCache'] = getSetting('appCache') !== false; // Whether to use cache by default or not (as the setting is temporary, we set it according to the appCache to avoid issues for developers)
|
||||
params['appCache'] = getSetting('appCache') !== false; // Will be true by default unless explicitly set to false
|
||||
params['useMathJax'] = getSetting('useMathJax') != null ? getSetting('useMathJax') : true; // Set default to true to display math formulae with MathJax, false to use fallback SVG images only
|
||||
// params['showFileSelectors'] = getCookie('showFileSelectors') != null ? getCookie('showFileSelectors') : false; //Set to true to display hidden file selectors in packaged apps
|
||||
|
@ -703,12 +703,12 @@ function requestXhttpData (URL, lang, subj, kiwixDate) {
|
||||
// Remove unused README file
|
||||
doc = doc.replace(/^<a\s+href\b[^<]+README.+$[\r\n]*/m, '');
|
||||
}
|
||||
// Add in some directories from hidden
|
||||
// Add in some directories for developers (other than custom_apps)
|
||||
if (/wikipedia\//.test(doc)) {
|
||||
doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>\s\s)([^<]+)/m, '<a href="#">archive/</a> $3$1$2$3');
|
||||
if (!params.appCache) doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>\s\s)([^<]+)/m, '<a href="#">archive/</a> $3$1$2$3');
|
||||
doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>\s\s)([^<]+)/m, '<a href="#">custom_apps/</a>$3$1$2$3');
|
||||
doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>\s\s)([^<]+)/m, '<a href="#">dev/</a> $3$1$2$3');
|
||||
doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>)([^<]+)/m, '<a href="#">endless/$2 $3$1$2$3');
|
||||
if (!params.appCache) doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>\s\s)([^<]+)/m, '<a href="#">dev/</a> $3$1$2$3');
|
||||
if (!params.appCache) doc = doc.replace(/^(<a\b.+gutenberg\/)(<\/a>)([^<]+)/m, '<a href="#">endless/$2 $3$1$2$3');
|
||||
}
|
||||
var stDoc; // Placeholder for standardized doc to be used to get arrays
|
||||
if (/^[^_\n\r]+_([^_\n\r]+)_.+\.zi[mp].+$/m.test(doc)) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user