Raw Source
TagoDR / Manga OnlineViewer

// ==UserScript==
// @name Manga OnlineViewer
// @author Tago
// @updateURL https://github.com/TagoDR/MangaOnlineViewer/raw/master/Manga_OnlineViewer.meta.js
// @downloadURL https://github.com/TagoDR/MangaOnlineViewer/raw/master/Manga_OnlineViewer.user.js
// @namespace https://github.com/TagoDR
// @description Shows all pages at once in online view for these sites: Batoto, ComiCastle, Dynasty-Scans, EatManga, Easy Going Scans, FoOlSlide, KissManga, MangaDoom, MangaFox, MangaGo, MangaHere, MangaInn, MangaLyght, MangaPark, MangaReader,MangaPanda, MangaStream, MangaTown, NineManga, ReadManga Today, SenManga(Raw), TenManga, TheSpectrum, MangaDeep, Funmanga, UnionMangas, MangaHost, Hoc Vien Truyen Tranh, JaiminisBox, MangaDex, HatigarmScans
// @version 13.44.0
// @license MIT
// @date 2018-05-29
// @grant GM_getValue
// @grant GM_setValue
// @grant GM_listValues
// @grant GM_deleteValue
// @grant GM_xmlhttpRequest
// @connect *
// @require https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/jquery-scrollTo/2.1.2/jquery.scrollTo.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.5/jszip.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/nprogress/0.2.0/nprogress.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/limonte-sweetalert2/6.11.5/sweetalert2.all.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/jscolor/2.0.4/jscolor.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/color-scheme/1.0.0/color-scheme.min.js
// @require https://cdnjs.cloudflare.com/ajax/libs/ramda/0.24.1/ramda.min.js
// @include /https?:\/\/(www.)?bato.to\/chapter.*/
// @include /https?:\/\/(www.)?comicastle.org\/comic\/.+\/[0-9]+.*/
// @include /https?:\/\/(www.)?dynasty-scans.com\/chapters\/.+/
// @include /https?:\/\/(www.)?eatmanga.me\/Manga-Scan\/.+\/.+\//
// @include /https?:\/\/read.egscans.com\/.+/
// @include /^(?!.*jaiminisbox).*\/read\/.+/
// @include /https?:\/\/(www.)?kissmanga.com\/Manga\/.+\/.+?id=[0-9]+/
// @include /https?:\/\/(www.)?mngdoom.com\/.+\/[0-9]+/
// @include /https?:\/\/(www.)?(mangafox.la|fanfox.net)\/manga\/.+\/.+\//
// @include /https?:\/\/(www.)?mangago.me\/read-manga\/.+\/.+/
// @include /https?:\/\/(www.)?mangahere.cc\/manga\/.+\/.+/
// @include /https?:\/\/(www.)?mangainn.net\/.+\/[0-9]+(\/[0-9]*)?/
// @include /https?:\/\/manga.lyght.net\/series\/.+\.html/
// @include /https?:\/\/(www.)?mangapark.me\/manga\/.+\/.+/
// @include /https?:\/\/(www.)?(mangareader|mangapanda)(.net|.com)\/.+\/.+/
// @include /https?:\/\/(www.)?(mangastream|readms)(.net|.com)\/r.*\/.+/
// @include /https?:\/\/(www.)?mangatown.com\/manga\/.+\/.+/
// @include /https?:\/\/(www.)?ninemanga.com\/chapter\/.+\/.+\.html/
// @include /https?:\/\/(www.)?readmng.com\/.+\/[0-9.]+(\/[0-9]*)?/
// @include /https?:\/\/raw.senmanga.com\/.+\/.+\/?/
// @include /https?:\/\/(www.)?tenmanga.com\/chapter\/.+/
// @include /https?:\/\/view.thespectrum.net\/.+/
// @include /https?:\/\/(www.)?(mangadeep).com\/.+\/[0-9]+/
// @include /https?:\/\/(www.)?funmanga.com\/.+\/[0-9]+/
// @include /https?:\/\/(www.)?unionmangas.net\/leitor\/.+\/.+/
// @include /https?:\/\/(www.)?mangahost.net\/manga\/.+\/.+/
// @include /https?:\/\/(www.)?hocvientruyentranh.com\/chapter\/.+\/.+/
// @include /https?:\/\/(www.)?jaiminisbox.com\/reader\/read\/.+/
// @include /https?:\/\/(www.)?mangadex.org\/chapter\/.+(\/.+)?/
// @include /https?:\/\/(www.)?hatigarmscans.net\/manga\/.+\/.+(\/[0-9]*)?/
// @exclude /https?:\/\/(www.)?tsumino.com\/.+/
// @exclude /https?:\/\/(www.)?pururin.us\/.+/
// @exclude /https?:\/\/hentai.cafe\/.+/
// ==/UserScript==

(function() {
  'use strict';

  var W = (typeof unsafeWindow === undefined) ? window : unsafeWindow;

  function logScript(...text) {
    console.log('MangaOnlineViewer:', ...text);
    return text;
  }
  const logScriptC = R.curry((x, y) => logScript(x, y)[1]);
  const removeValueGM = GM_deleteValue || (name => logScript('Removing: ', name));
  const getInfoGM = GM_info || {
    scriptHandler: 'Console',
    script: {
      name: 'Debug',
      version: 'Testing'
    }
  };
  const getValueGM = GM_getValue || ((name, defaultValue = null) => logScript('Getting: ', name, '=', defaultValue)[3]);
  const setValueGM = GM_setValue || ((name, value) => logScript('Getting: ', name, '=', value));

  function getBrowser() {
    const ua = navigator.userAgent;
    let tem;
    let M = ua.match(/(opera|chrome|safari|firefox|msie|trident(?=\/))\/?\s*(\d+)/i) || [];
    if (/trident/i.test(M[1])) {
      tem = /\brv[ :]+(\d+)/g.exec(ua) || [];
      return 'IE ' + String(tem[1] || '');
    }
    if (M[1] === 'Chrome') {
      tem = ua.match(/\b(OPR|Edge)\/(\d+)/);
      if (tem !== null) {
        return tem.slice(1).join(' ').replace('OPR', 'Opera');
      }
    }
    M = M[2] ? [M[1], M[2]] : [navigator.appName, navigator.appVersion, '-?'];
    tem = ua.match(/version\/(\d+)/i);
    if (tem !== null) {
      M.splice(1, 1, tem[1]);
    }
    return M.join(' ');
  }

  function getEngine() {
    return String(getInfoGM.scriptHandler || 'Greasemonkey') + ' ' + String(getInfoGM.version);
  }

  if (typeof getValueGM('MangaFitWidthIfOversized') === 'string') {
    setValueGM('MangaFitWidthIfOversized', true);
    setValueGM('MangaShowThumbnails', true);
    setValueGM('MangaDownloadZip', false);
    setValueGM('MangaAlwaysLoad', false);
  }
  if (typeof getValueGM('MangaZoom') === 'string') {
    setValueGM('MangaTimer', 1000);
    setValueGM('MangaZoom', 100);
  }
  removeValueGM('MangaAlwaysWebComic');
  removeValueGM('MangaTheme:');
  const settings = {
    Theme: getValueGM('MangaTheme', 'Light'),
    CustomTheme: getValueGM('MangaCustomTheme', '3d0099'),
    FitWidthIfOversized: getValueGM('MangaFitWidthIfOversized', true),
    ShowThumbnails: getValueGM('MangaShowThumbnails', true),
    DownloadZip: getValueGM('MangaDownloadZip', false),
    Timer: getValueGM('MangaTimer', 1000),
    Zoom: getValueGM('MangaZoom', 100),
    alwaysLoad: getValueGM('MangaAlwaysLoad', false),
    viewMode: getValueGM('MangaViewMode', ''),
    bookmarks: JSON.parse(getValueGM('MangaBookmarks', '[]'))
  };
  const bookmarkTimeLimit = 1000 * 60 * 60 * 24 * 30 * 12;
  settings.bookmarks = settings.bookmarks.filter(el => Date.now() - el.date < bookmarkTimeLimit);
  setValueGM('MangaBookmarks', JSON.stringify(settings.bookmarks));
  const icon = {
    enlage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAA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bKh4tBir1ljK3Rj7HYj8Vjmns1n7vnoM19objJo7rMp77RqL/Yqb/YqsHZq8HarMLWsMfbsMnxtMvftdSst83iv9X4zt72059U1+P24er4////byUxZQAAAAp0Uk5TABzi4+bn7O34+bWXSLUAAADvSURBVDjL5dJrVwFBGMBxQrl1UciOQiVyG1JMRrsq2rV2sd//03jGsOdZrZPX9X/7/M7czgQCf6PSvlzg+IfAu19O6TiKgamqqhec3sURMFXOOcEgXdQRgDljrILExe23ng0iwBilCJznP3p6PXwUXwPDMLmYV4ixKaWMOtWX6fhTAsuCHcScWLKUorXK1ebzYCaBbdtcbEBs2bWiPRUEeN2ABdTu99uLbZeKVsArLKHhfD5cumVqcIa36eRLggYkwL3oUXSTFLd4iIQkoBCBKOoM3sF9KD9Ar4pe8EM4ia4X7AondxI79D/89qP+RSuMhGoqoAbgAQAAAABJRU5ErkJggg==',
    picturedown: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ON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Q89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAPNQTFRF////NFCKNFCKNFCKNFCKNFCKNFCKNFCKNFCKNlOIN1OMOFKHOVKHOViGOleFOliEOlqFPFiRPVmSPlqTQFuRQFyUQVuRQlySX4ayYXukYZo6YnylY32nY4q2ZX+pZmZmZ4GrZ5pAaYOtaoOuapC8bJG5bYarbZC3bZRXcatKcpfDcq5Vd6hMeZKzeZ/Lepu+erpPgINWgKDDgpu+hqbKh4tBiaXUir1ljK3Rj8VjkrPWlazCla3Clq7Dl67Dmns1n7vnoM19objJo7rMp77RrMLWsMfbsMnxtMvftdSst83iv9X4zt72059U1+P24er4////p0NnjQAAAAh0Uk5TADPW6err7O3/ygvKAAAA+ElEQVQ4y+XS2VLCMBSA4SqKQcAFXCCIiK0sIhjWGFygZSm1pfT9n4YT2lJSYRhv9b8932SbSNIfqbCrNXC2twGGPzq97IWBoapqAFA9FQKGyhjDARjd3QgA5pTSKg7A+D4uAkoJ8QC6TmdHrcnDyYEPdN1gfF7FOg99fGmvSmfaPvKBacIOfI5NHtLKmbzy3JjJUQ9YlsX4BthahbTMCvS/5UMX2FCz223abt4KbzP52FthAQ3m88HCDb1/ak9whseIf4YXiIMir1JB52clfovo+poEwhDxq13BOySk3YDAS94WRCAKlLtwwkAQsSRxfvEf9v2o/9ASO2Fiip5S95oAAAAASUVORK5CYII='
  };

  const scheme = new ColorScheme().scheme('mono').variation('default');

  function addTheme(theme) {
    return '<style type=\'text/css\' name=\'' + String(theme[0]) + '\'>\n  .' + String(theme[0]) + ' .controlLable, .' + String(theme[0]) + ' .ViewerTitle, .' + String(theme[0]) + ', .PageFunctions a.visible, .' + String(theme[0]) + ' a, .' + String(theme[0]) + ' a:link, .' + String(theme[0]) + ' a:visited, .' + String(theme[0]) + ' a:active, .' + String(theme[0]) + ' a:focus{ text-decoration:none; color: ' + String(theme[2]) + ';}\n  .' + String(theme[0]) + ' {background-repeat: repeat;background-position: 0 0;background-image: none;background-color: ' + String(theme[1]) + ';background-attachment: scroll;}\n  .' + String(theme[0]) + ' #ImageOptions #menu .menuOuterArrow {border-left-width: 10px;border-left-style: solid;border-left-color: ' + String(theme[4]) + ';}\n  .' + String(theme[0]) + ' #ImageOptions #menu .menuInnerArrow {border-left-width: 5px;border-left-style: solid;border-left-color: ' + String(theme[1]) + ';}\n  .' + String(theme[0]) + ' .PageFunctions { border: 1px solid ' + String(theme[3]) + '; border-bottom: medium none; border-left: medium none; border-right: medium none;}\n  /*.' + String(theme[0]) + ' #Chapter { border: 1px solid ' + String(theme[3]) + '; border-top: medium none; border-left: medium none; border-right: medium none;}*/\n  .' + String(theme[0]) + ' .PageFunctions > span, .' + String(theme[0]) + ' .ThumbNail span {background: none repeat scroll 0 0 ' + String(theme[4]) + ';}\n  .' + String(theme[0]) + ' .painel {background: none repeat scroll 0 0 ' + String(theme[4]) + '; border: thin solid ' + String(theme[3]) + ';}\n  .' + String(theme[0]) + ' .PageContent, .' + String(theme[0]) + ' .ThumbNail img { outline: 2px solid ' + String(theme[3]) + '; background: none repeat scroll 0 0 ' + String(theme[4]) + ';}\n  .' + String(theme[0]) + ' .ChapterControl a { border: 1px solid ' + String(theme[3]) + '; background-color: ' + String(theme[5]) + ';\n  </style>';
  }

  function addCustomTheme(color) {
    const bg = scheme.from_hex(color).colors();
    return addTheme(['Custom_Dark', '#000000', '#' + String(bg[2]), '#' + String(bg[3]), '#' + String(bg[0]), '#' + String(bg[1])]) + addTheme(['Custom_Light', '#eeeeec', '#' + String(bg[3]), '#' + String(bg[2]), '#' + String(bg[0]), '#' + String(bg[1])]);
  }

  function loadThemes() {
    const bg = scheme.from_hex(settings.CustomTheme).colors();
    return [
      ['Dark', '#000000', '#ffffff', '#666666', '#333333', '#282828'],
      ['Light', '#eeeeec', '#2e3436', '#888a85', '#babdb6', '#c8cec2'],
      ['Clear', '#ffffff', '#2e3436', '#888a85', '#eeeeec', '#d3d7cf'],
      ['Dark_Blue', '#000000', '#91a0b0', '#586980', '#3e4b5b', '#222c3b'],
      ['Tango_Blue', '#000000', '#82a0bf', '#3d669b', '#304c77', '#102747'],
      ['Lime', '#000000', '#8abd59', '#608d34', '#38531f', '#233413'],
      ['Plum', '#000000', '#ad7fa8', '#75507b', '#49324d', '#311b37'],
      ['Light_Plum', '#eeeeec', '#5c3566', '#9b71a2', '#ad7fa8', '#d2b8ce'],
      ['Earthy', '#000000', '#ffffff', '#693d3d', '#46211a', '#683327'],
      ['Cool_Blues', '#000000', '#c4dfe6', '#66a5ad', '#07575b', '#003b46'],
      ['Custom_Dark', '#000000', '#' + String(bg[2]), '#' + String(bg[3]), '#' + String(bg[0]), '#' + String(bg[1])],
      ['Custom_Light', '#eeeeec', '#' + String(bg[3]), '#' + String(bg[2]), '#' + String(bg[0]), '#' + String(bg[1])]
    ];
  }
  const themes = loadThemes();
  const themesSelector = R.map(theme => '<option value=\'' + String(theme[0]) + '\' ' + (settings.Theme === theme[0] ? 'selected' : '') + '>' + String(theme[0].replace('_', ' ')) + '</option>', themes);
  const themesCSS = R.map(theme => addTheme(theme), themes).join('');

  const painel = '\n<div id=\'ImageOptions\'>\n  <div id=\'menu\'>\n    <span class=\'menuOuterArrow\'><span class=\'menuInnerArrow\'></span></span>\n  </div>\n  <div class=\'painel\'>\n    <img id=\'enlarge\' title=\'Enlarge\' src=\'' + String(icon.enlage) + '\' class=\'controlButton\' />\n    <img id=\'restore\' title=\'Restore\' src=\'' + String(icon.restore) + '\' class=\'controlButton\' />\n    <img id=\'reduce\' title=\'Reduce\' src=\'' + String(icon.reduce) + '\' class=\'controlButton\' />\n    <img id=\'fitwidth\' title=\'Fit Width\' src=\'' + String(icon.fitwidth) + '\' class=\'controlButton\' />\n    <img id=\'webcomic\' title=\'Web Comic Mode\' src=\'' + String(icon.webcomic) + '\' class=\'controlButton\' />\n    <img id=\'ltrmode\' title=\'Left to Right Mode\' src=\'' + String(icon.pictureleft) + '\' class=\'controlButton\'/>\n    <img id=\'verticalmode\' title=\'Vertical Mode\' src=\'' + String(icon.picturedown) + '\' class=\'controlButton\'/>\n    <img id=\'rtlmode\' title=\'Right to Left Mode\' src=\'' + String(icon.pictureright) + '\' class=\'controlButton\'/>\n    <img id=\'settings\' title=\'settings\' src=\'' + String(icon.settings) + '\' class=\'controlButton\' />\n  </div>\n  <div id=\'Zoom\' class=\'controlLable\'>Zoom: <b>' + String(settings.Zoom) + '</b> %</div>\n</div>';
  const shortcuts = '\n<div id=\'ViewerShortcuts\' class=\'painel\' style=\'display: none;\'>\n  <span class=\'key\'>+</span> or <span class=\'key\'>=</span> : Global Zoom in pages (enlarge)<br/>\n  <span class=\'key\'>-</span> : Global Zoom out pages (reduce)<br/>\n  <span class=\'key\'>*</span> or <span class=\'key\'>8</span> : Global Restore pages to original<br/>\n  <span class=\'key\'>5</span> : Global Fit window width<br/>\n  <span class=\'key\'>Arrow Right</span> or <span class=\'key\'>.</span> : Next Chapter<br/>\n  <span class=\'key\'>Arrow Left</span> or <span class=\'key\'>,</span> : Previous Chapter<br/>\n</div>';
  const controls = '\n<div id=\'ViewerControls\' class=\'painel\' style=\'display: none;\'>\n  <span class=\'controlLable\'>Theme:\n    <input id=\'CustomThemeHue\' class=\'jscolor\' value=\'' + String(settings.CustomTheme) + '\' ' + (settings.Theme !== 'Custom_Dark' && settings.Theme !== 'Custom_Light' ? 'style="display: none;"' : '') + '\'>\n    <select id=\'ThemeSelector\'>\n      ' + String(themesSelector) + '\n    </select>\n  </span>\n  <span class=\'controlLable\'>Pages/Second:\n    <select id=\'PagesPerSecond\'>\n      <option value=\'3000\' ' + (settings.Timer === 3000 ? 'selected' : '') + '>0.3(Slow)</option>\n      <option value=\'2000\' ' + (settings.Timer === 2000 ? 'selected' : '') + '>0.5</option>\n      <option value=\'1000\' ' + (settings.Timer === 1000 ? 'selected' : '') + '>01(Normal)</option>\n      <option value=\'500\' ' + (settings.Timer === 500 ? 'selected' : '') + '>02</option>\n      <option value=\'250\' ' + (settings.Timer === 250 ? 'selected' : '') + '>04(Fast)</option>\n      <option value=\'125\' ' + (settings.Timer === 125 ? 'selected' : '') + '>08</option>\n      <option value=\'100\' ' + (settings.Timer === 100 ? 'selected' : '') + '>10(Extreme)</option>\n    </select>\n  </span>\n  <span class=\'controlLable\'>Default Zoom:\n    <select id=\'DefaultZoom\'>\n      <option value=\'50\' ' + (settings.Zoom === 50 ? 'selected' : '') + '>50%</option>\n      <option value=\'75\' ' + (settings.Zoom === 75 ? 'selected' : '') + '>75%</option>\n      <option value=\'100\' ' + (settings.Zoom === 100 ? 'selected' : '') + '>100%</option>\n      <option value=\'125\' ' + (settings.Zoom === 125 ? 'selected' : '') + '>125%</option>\n      <option value=\'150\' ' + (settings.Zoom === 150 ? 'selected' : '') + '>150%</option>\n      <option value=\'175\' ' + (settings.Zoom === 175 ? 'selected' : '') + '>175%</option>\n      <option value=\'200\' ' + (settings.Zoom === 200 ? 'selected' : '') + '>200%</option>\n      <option value=\'1000\' ' + (settings.Zoom === 1000 ? 'selected' : '') + '>Fit Width</option>\n    </select>\n  </span>\n  <span class=\'controlLable\'>Fit Width if Oversized:\n    <input type=\'checkbox\' val=\'true\' name=\'fitIfOversized\' id=\'fitIfOversized\' ' + (settings.FitWidthIfOversized ? 'checked' : '') + '>\n  </span>\n  <span class=\'controlLable\'>Show Thumbnails:\n    <input type=\'checkbox\' val=\'true\' name=\'showThumbnails\' id=\'showThumbnails\' ' + (settings.ShowThumbnails ? 'checked' : '') + '>\n   </span>\n  <span class=\'controlLable\'>Default View Mode:\n    <select id=\'viewMode\'>\n      <option value=\'\' ' + (settings.viewMode === '' ? 'selected' : '') + '>Vertical</option>\n      <option value=\'WebComic\' ' + (settings.viewMode === 'WebComic' ? 'selected' : '') + '>WebComic</option>\n      <option value=\'FluidLTR\' ' + (settings.viewMode === 'FluidLTR' ? 'selected' : '') + '>Left to Right</option>\n      <option value=\'FluidRTL\' ' + (settings.viewMode === 'FluidRTL' ? 'selected' : '') + '>Right to Left</option>\n    </select>\n  </span>\n  <span class=\'controlLable\'>Download Images as Zip Automatically:\n    <input type=\'checkbox\' val=\'false\' name=\'downloadZip\' id=\'downloadZip\' ' + (settings.DownloadZip ? 'checked' : '') + '>\n  </span>\n  <span class=\'controlLable\'>Always Load Script:\n    <input type=\'checkbox\' val=\'true\' name=\'alwaysLoad\' id=\'alwaysLoad\' ' + (settings.alwaysLoad ? 'checked' : '') + '>\n  </span>\n</div>';
  const chapterControl = R.curry((id, target, manga) => '\n<div id=\'' + String(id) + '\' class=\'ChapterControl\'>\n    <a id=\'bottom\' href=\'#' + String(target) + '\' style=\'display: none;\'>Bottom</a>\n    <a href=\'#\' class=\'download\'>Download</a>\n    <a class=\'prev\' id=\'prev\' href=\'' + String(manga.prev || '') + '\' onclick=\'location="' + String(manga.prev || '') + '";location.reload();\'>Previous</a>\n    <a class=\'next\' id=\'next\' href=\'' + String(manga.next || '') + '\' onclick=\'location="' + String(manga.next || '') + '";location.reload();\'>Next</a>\n</div>');
  const chapterControlTop = chapterControl('ChapterControlTop', 'ChapterControlBottom');
  const chapterControlBottom = chapterControl('ChapterControlBottom', 'MangaOnlineViewer');
  const title = manga => '<div class=\'ViewerTitle\'><br/><a id=\'series\' href=\'' + String(manga.series) + '\'>' + String(manga.title) + '<br/>(Return to Chapter List)</a></div>';
  const listPages = R.times(index => '\n<div id=\'Page' + String(index + 1) + '\' class=\'MangaPage\'>\n  <div class=\'PageFunctions\'>\n    <a class=\'Bookmark controlButton\' title=\'Bookmark\'></a>\n    <a class=\'ZoomIn controlButton\' title=\'Zoom In\'></a>\n    <a class=\'ZoomRestore controlButton\' title=\'Zoom Restore\'></a>\n    <a class=\'ZoomOut controlButton\' title=\'Zoom Out\'></a>\n    <a class=\'ZoomWidth controlButton\' title=\'Zoom to Width\'></a>\n    <a class=\'Hide controlButton\' title=\'Hide\'></a>\n    <a class=\'Reload controlButton\' title=\'Reload\'></a>\n    <span>' + String(index + 1) + '</span>\n  </div>\n  <div class=\'PageContent\' style=\'display: none;\'>\n    <img id=\'PageImg' + String(index + 1) + '\' alt=\'PageImg' + String(index + 1) + '\' />\n  </div>\n</div>');
  const listOptions = R.times(index => '<option value=\'' + String(index + 1) + '\'>' + String(index + 1) + '</option>');
  const listThumbnails = R.times(index => '<div id=\'ThumbNail' + String(index + 1) + '\' class=\'ThumbNail\'><img id=\'ThumbNailImg' + String(index + 1) + '\' alt=\'ThumbNailImg' + String(index + 1) + '\' src=\'\'/><span>' + String(index + 1) + '</span></div>');
  const body = (manga, begin = 0) => '\n<div id=\'MangaOnlineViewer\' class=\'' + String(settings.Theme) + '\' style=\'min-height: 1080px;\'>\n  ' + String(title(manga)) + '\n  ' + String(chapterControlTop(manga)) + '\n  <div id=\'Chapter\' align=\'center\' class=\'' + (settings.FitWidthIfOversized === true ? 'fitWidthIfOversized' : '') + ' ' + String(settings.viewMode) + '\'>\n    ' + String(listPages(manga.quant).slice(begin).join('')) + '    \n  </div>\n  ' + String(title(manga)) + '\n  ' + String(chapterControlBottom(manga)) + '\n  ' + painel + '    \n  ' + controls + '\n  ' + shortcuts + '    \n  <div id=\'Counters\' class=\'controlLable\'>\n    <i>0</i> of <b>' + String(manga.quant) + '</b> Pages Loaded \n    <span class=\'controlLable\'>Go to Page:</span>\n    <select id=\'gotoPage\'>\n      <option selected>#</option>\n      ' + String(listOptions(manga.quant).slice(begin).join('')) + '\n    </select>\n  </div>\n  <div id=\'Navigation\' align=\'center\' class=\'painel ' + (settings.ShowThumbnails ? '' : 'disabled') + '\'>\n    <div id=\'NavigationCounters\' class=\'controlLable\'>\n      <img title=\'Thumbnails\' src=\'' + String(icon.menu) + '\' class=\'nav\' /><i>0</i> of <b>' + String(manga.quant) + '</b> Pages Loaded\n    </div>\n    ' + String(listThumbnails(manga.quant).slice(begin).join('')) + '\n  </div>\n  <a href=\'#\' id=\'blob\' style=\'display: none;\'>Download</a>\n</div>';
  const readerCSS = '\n<style type=\'text/css\'>html{font-size:100%}\nbody{margin:0;font-family:\'Helvetica Neue\',Helvetica,Arial,sans-serif;font-size:14px;line-height:20px;color:#333;background-color:#FFF;padding:0}\na{color:#08C;text-decoration:none}\nimg{height:auto;max-width:100%;vertical-align:middle;border:0 none}\n/*button,input,select,textarea{margin:0;font-size:100%;vertical-align:middle}\nbutton,input{line-height:normal}\nlabel,input,button,select,textarea{font-size:14px;font-weight:normal;line-height:20px}\ninput,button,select,textarea{font-family:\'Helvetica Neue\',Helvetica,Arial,sans-serif}\nselect,textarea,input[type=\'text\'],input[type=\'password\'],input[type=\'datetime\'],input[type=\'datetime-local\'],input[type=\'date\'],input[type=\'month\'],input[type=\'time\'],input[type=\'week\'],input[type=\'number\'],input[type=\'email\'],input[type=\'url\'],input[type=\'search\'],input[type=\'tel\'],input[type=\'color\'],.uneditable-input{display:inline-block;height:20px;padding:4px 6px;margin-bottom:10px;font-size:14px;line-height:20px;color:#555;vertical-align:middle;border-radius:4px 4px 4px 4px}\ninput:not([type=\'checkbox\']),textarea,.uneditable-input{width:206px}\ntextarea,input[type=\'text\'],input[type=\'password\'],input[type=\'datetime\'],input[type=\'datetime-local\'],input[type=\'date\'],input[type=\'month\'],input[type=\'time\'],input[type=\'week\'],input[type=\'number\'],input[type=\'email\'],input[type=\'url\'],input[type=\'search\'],input[type=\'tel\'],input[type=\'color\'],.uneditable-input{background-color:#FFF;border:1px solid #CCC;box-shadow:0 1px 1px rgba(0,0,0,0.075) inset;transition:border .2s linear 0,box-shadow .2s linear 0}\ninput,textarea,.uneditable-input{margin-left:0}*/\n#nprogress .bar{background:#29d;position:fixed;z-index:1031;top:0;left:0;width:100%;height:4px;}\n.key{display:inline;display:inline-block;min-width:1em;padding:.2em .3em;font:400 .85em/1 \'Lucida Grande\',Lucida,Arial,sans-serif;text-align:center;text-decoration:none;-moz-border-radius:.3em;-webkit-border-radius:.3em;border-radius:.3em;border:none;cursor:default;-moz-user-select:none;-webkit-user-select:none;user-select:none}\n.key[title]{cursor:help}\n.key, .dark-keys,.dark-keys .key,.key.dark{background:#505050;background:-moz-linear-gradient(top,#3c3c3c,#505050);background:-webkit-gradient(linear,left top,left bottom,from(#3c3c3c),to(#505050));color:#fafafa;text-shadow:-1px -1px 0 #464646;-moz-box-shadow:inset 0 0 1px #969696,inset 0 -.05em .4em #505050,0 .1em 0 #1e1e1e,0 .1em .1em rgba(0,0,0,.3);-webkit-box-shadow:inset 0 0 1px #969696,inset 0 -.05em .4em #505050,0 .1em 0 #1e1e1e,0 .1em .1em rgba(0,0,0,.3);box-shadow:inset 0 0 1px #969696,inset 0 -.05em .4em #505050,0 .1em 0 #1e1e1e,0 .1em .1em rgba(0,0,0,.3)}\n.light-keys,.light-keys .key,.key.light{background:#fafafa;background:-moz-linear-gradient(top,#d2d2d2,#fff);background:-webkit-gradient(linear,left top,left bottom,from(#d2d2d2),to(#fff));color:#323232;text-shadow:0 0 2px #fff;-moz-box-shadow:inset 0 0 1px #fff,inset 0 0 .4em #c8c8c8,0 .1em 0 #828282,0 .11em 0 rgba(0,0,0,.4),0 .1em .11em rgba(0,0,0,.9);-webkit-box-shadow:inset 0 0 1px #fff,inset 0 0 .4em #c8c8c8,0 .1em 0 #828282,0 .11em 0 rgba(0,0,0,.4),0 .1em .11em rgba(0,0,0,.9);box-shadow:inset 0 0 1px #fff,inset 0 0 .4em #c8c8c8,0 .1em 0 #828282,0 .11em 0 rgba(0,0,0,.4),0 .1em .11em rgba(0,0,0,.9)}\n#MangaOnlineViewer{width:100%;height:100%;padding-bottom: 100px;}\n#MangaOnlineViewer #Chapter{text-align:center;margin: 25px auto 0;display:block;}\n#MangaOnlineViewer #Chapter.WebComic .PageFunctions {position: relative;}\n#MangaOnlineViewer #Chapter.WebComic .PageContent {margin-top: -23px; margin-bottom: 0;}\n#MangaOnlineViewer #Chapter.FluidLTR .MangaPage {width: auto;}\n#MangaOnlineViewer #Chapter.FluidRTL .MangaPage {width: auto;}\n#MangaOnlineViewer #Chapter.FluidLTR {direction: ltr;}\n#MangaOnlineViewer #Chapter.FluidRTL {direction: rtl;}\n#MangaOnlineViewer #ViewerControls{padding: 8px;position:fixed;top:0;left:332px;width:auto;}\n#MangaOnlineViewer #ViewerShortcuts{padding: 8px;position:fixed;top:65px;left:0px;}\n#ViewerControls .controlLable {display: list-item; list-style: none;}\n#MangaOnlineViewer select{height:20px;padding:0;margin-bottom:5px}\n#MangaOnlineViewer .controlButton{cursor:pointer;border:0 none;}\n#MangaOnlineViewer #ImageOptions {left: 0px;position: absolute;top: 0px;width: 332px;}\n#MangaOnlineViewer #ImageOptions .painel {padding:4.5px;position: inherit;}\n#MangaOnlineViewer #ImageOptions:hover {position:fixed;}\n#MangaOnlineViewer #ImageOptions.settingsOpen {position:fixed;}\n#MangaOnlineViewer #ImageOptions #menu {position:fixed;top: 45px;height: 64px;width: 200px;top: 0;}\n#MangaOnlineViewer #ImageOptions #Zoom {position:absolute;left: 18px;bottom: -65px;}\n#MangaOnlineViewer .MangaPage{width:100%;display:inline-block;text-align:center;align:center;transform: translate3d(0, 0, 0);backface-visibility: hidden;perspective: 1000;(0, 0, 0);-webkit-backface-visibility: hidden;-webkit-perspective: 1000;-moz-transform: translate3d(0, 0, 0);-moz-backface-visibility: hidden;-moz-perspective: 1000;}\n#MangaOnlineViewer .PageContent{margin:0 0 15px;text-align:center;display:inline-block}\n#MangaOnlineViewer #gotoPage{width:35px;}\n#MangaOnlineViewer #ThemeSelector{width:110px;}\n#MangaOnlineViewer .ChapterControl{-moz-user-select:none;-webkit-user-select: none;margin-right:120px;margin-top: 1px;float: right;}\n#MangaOnlineViewer .ChapterControl a{display:inline-block;width: 80px;height:25px;text-align:center;margin-left: 3px;margin-bottom: -1px;}\n#MangaOnlineViewer .ChapterControl a[href=\'#\'],#MangaOnlineViewer .ChapterControl a[href=\'\']{visibility:hidden}\n#MangaOnlineViewer .ViewerTitle{display: block;text-align: center;height:35px;}\n#MangaOnlineViewer #Counters {position: absolute;right: 10px;top: 10px;}\n#MangaOnlineViewer .PageFunctions{-moz-user-select:none;-webkit-user-select: none;font-family:monospace;font-size:10pt;padding-right:120px;text-align:right}\n#MangaOnlineViewer .PageFunctions>span{min-width:20px;text-align:center;display:inline-block;padding:2px 10px}\n#MangaOnlineViewer .PageFunctions > a {height: 16px;width: 16px; padding: 10px;}\n#MangaOnlineViewer .PageFunctions a{opacity:0.2}\n#MangaOnlineViewer .PageFunctions:hover a{opacity:1}\n#MangaOnlineViewer #NavigationCounters {margin-top: 5px;width: 100%;}\n#MangaOnlineViewer #Navigation {bottom: -170px;height: 180px;overflow: auto;overflow-x: auto;overflow-y: hidden;padding-bottom: 20px;position: fixed;white-space: nowrap;width: 100%;}\n#MangaOnlineViewer #Navigation:hover {bottom: 0;}\n#MangaOnlineViewer #Navigation.disabled {display: none;}\n#MangaOnlineViewer #Navigation.visible {bottom: 0;}\n#MangaOnlineViewer #Navigation .ThumbNail {display: inline-block;height: 150px;margin: 0 5px;position: relative;}\n#MangaOnlineViewer #Navigation .ThumbNail span {display: block;opacity: 0.8;position: relative;top: -30px;width: 100%;}\n#MangaOnlineViewer #Navigation .ThumbNail img {align-content: center;cursor: pointer;display: inline-block;margin-bottom: -10px;margin-top: 10px;max-height: 150px;min-height: 150px;min-width: 100px;}\n#MangaOnlineViewer #Navigation .nav {behavior:url(-ms-transform.htc);-moz-transform:rotate(-90deg);-webkit-transform:rotate(-90deg);-o-transform:rotate(-90deg);}\n#MangaOnlineViewer #ImageOptions .menuOuterArrow  {width: 0;height: 0;border-top: 10px solid transparent;border-bottom: 10px solid transparent;border-left:10px solid blue;display: inline-block;position: absolute;bottom: 0;}\n#MangaOnlineViewer #ImageOptions .menuInnerArrow {width: 0;height: 0;border-top: 5px solid transparent;border-bottom: 5px solid transparent;border-left:5px solid white;left: -10px;position: absolute;top: -5px;display: inline-block;}\n#MangaOnlineViewer .fitWidthIfOversized .PageContent img { max-width: ' + String($(window).width()) + 'px;}\n#MangaOnlineViewer .PageFunctions .Bookmark {background: url(\'' + String(icon.bookmark) + '\') no-repeat scroll center center transparent;}\n#MangaOnlineViewer .PageFunctions .Reload {background: url(\'' + String(icon.reload) + '\') no-repeat scroll center center transparent;}\n#MangaOnlineViewer .PageFunctions .Hide {background: url(\'' + String(icon.hide) + '\') no-repeat scroll center center transparent;}\n#MangaOnlineViewer .PageFunctions .ZoomIn {background: url(\'' + String(icon.zoomin) + '\') no-repeat scroll center center transparent;}\n#MangaOnlineViewer .PageFunctions .ZoomOut {background: url(\'' + String(icon.zoomout) + '\') no-repeat scroll center center transparent;}\n#MangaOnlineViewer .PageFunctions .ZoomRestore {background: url(\'' + String(icon.zoomrestore) + '\') no-repeat scroll center center transparent;}\n#MangaOnlineViewer .PageFunctions .ZoomWidth {background: url(\'' + String(icon.zoomwidth) + '\') no-repeat scroll center center transparent;}\n</style>';
  const externalScripts = ['<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.5/jszip.min.js" integrity="sha256-PZ/OvdXxEW1u3nuTAUCSjd4lyaoJ3UJpv/X11x2Gi5c=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/nprogress/0.2.0/nprogress.min.js" integrity="sha256-XWzSUJ+FIQ38dqC06/48sNRwU1Qh3/afjmJ080SneA8=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/limonte-sweetalert2/7.11.0/sweetalert2.all.min.js" integrity="sha256-BioifFOOOY9mUlPOQj/1+czPAq+O1osC92/I8kSfW6o=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/color-js/1.0.1/color.min.js" integrity="sha256-qAjuzGZ65rH+O8iRUmRdRCgk33HmM0Gbq15CwUsxW3k=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/color-scheme/1.0.1/color-scheme.min.js" integrity="sha256-7IUC8vhyoPLh1tuQJnffPB5VO6HpR4VWK4Y1ciOOoBY=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/ramda/0.24.1/ramda.min.js" integrity="sha256-yF1J6hzNIWN398K1d+n1XXGC3JEchH55G05dxM+rsFk=" crossorigin="anonymous"></script>', '<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-scrollTo/2.1.2/jquery.scrollTo.min.js" integrity="sha256-7QS1cHsH75h3IFgrFKsdhmKHHpWqF82sb/9vNLqcqs0=" crossorigin="anonymous"></script>'];
  const externalCSS = ['<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/7.0.0/normalize.min.css" integrity="sha256-HxaKz5E/eBbvhGMNwhWRPrAR9i/lG1JeT4mD6hCQ7s4=" crossorigin="anonymous" />', '<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/nprogress/0.2.0/nprogress.min.css" integrity="sha256-pMhcV6/TBDtqH9E9PWKgS+P32PVguLG8IipkPyqMtfY=" crossorigin="anonymous" />', '<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/limonte-sweetalert2/6.10.1/sweetalert2.min.css" integrity="sha256-dFCwuhCfoeoBeMuViN7hhbZEZW7takATo0uQ8SzZSI8=" crossorigin="anonymous" />'];

  function reader(manga, begin = 0) {
    return '\n<head>\n  <title>' + String(manga.title) + '</title>\n  <meta charset="UTF-8">\n  ' + String(externalScripts.join('\n')) + '\n  ' + String(externalCSS.join('\n')) + '\n  ' + readerCSS + '\n  ' + String(themesCSS) + '\n</head>\n<body class=\'' + String(settings.Theme) + '\'>\n  ' + String(body(manga, begin > 0 ? begin - 1 : 0)) + '\n</body>';
  }

  const isEmpty = R.either(R.either(R.isNil, R.isEmpty), R.either(x => R.length(x) === 0, x => x === 0));
  const mapIndexed = R.addIndex(R.map);

  function normalizeUrl(url) {
    let uri = url.trim();
    if (uri.startsWith('//')) {
      uri = 'https:' + String(uri);
    }
    return uri;
  }

  function addImg(index, src) {
    const url = normalizeUrl(src);
    logScript('Image:', index, 'Source:', url);
    $('#PageImg' + String(index)).attr('src', url).parent().slideToggle();
    $('#ThumbNailImg' + String(index)).attr('src', url);
    return index;
  }

  function getPage(url, wait = settings.Timer) {
    return new Promise(resolve => {
      setTimeout(() => {
        logScript('Getting page: ' + String(url));
        $.ajax({
          type: 'GET',
          url,
          dataType: 'html',
          async: true,
          success: html => resolve(html),
          retryCount: 0,
          retryLimit: 10,
          retryTimeout: 10000,
          timeout: 1000,
          created: Date.now(),
          error() {
            this.retryCount += 1;
            if (this.retryCount <= this.retryLimit && Date.now() - this.created < this.retryTimeout) {
              logScript('Retrying Getting page: ' + String(url));
              $.ajax(this);
            } else {
              logScript('Failed Getting page: ' + String(url));
            }
          }
        });
      }, wait);
    });
  }
  const loadMangaPages = (begin, manga) => mapIndexed((url, index) => index >= begin ? getPage(url, (manga.timer || settings.Timer) * (index - begin)).then(response => addImg(index + 1, $(response).find(manga.img).attr('src'))) : null, manga.listPages);

  function getImages(src, wait = settings.Timer) {
    return new Promise(resolve => {
      setTimeout(() => {
        resolve(src);
      }, wait);
    });
  }
  const loadMangaImages = (begin, manga) => mapIndexed((src, index) => index >= begin ? getImages(src, (manga.timer || settings.Timer) * (index - begin)).then(response => addImg(index + 1, response)) : null, manga.listImages);

  function loadManga(manga, begin = 1) {
    logScript('Loading Images');
    logScript('Intervals: ' + String(manga.timer || settings.Timer || 'Default(1000)'));
    if (manga.listPages !== undefined) {
      logScript('Method: Pages:', manga.listPages);
      loadMangaPages(begin - 1, manga);
    } else if (manga.listImages !== undefined) {
      logScript('Method: Images:', manga.listImages);
      loadMangaImages(begin - 1, manga);
    } else {
      logScript('Method: Brute Force');
      manga.bruteForce({
        begin,
        addImg,
        loadMangaImages: R.curry(loadMangaImages)(begin - 1),
        loadMangaPages: R.curry(loadMangaPages)(begin - 1),
        getPage,
        getImages
      });
    }
  }

  function reloadImage(img) {
    const src = img.attr('src');
    if (src !== undefined) {
      img.removeAttr('src');
      setTimeout(() => {
        img.attr('src', src);
      }, 500);
    }
  }

  function applyZoom(page, newZoom) {
    const zoom = newZoom || settings.Zoom;
    const pages = page || '.PageContent img';
    $(pages).each((index, value) => $(value).width(zoom === 1000 ? $('html').width() : $(value).prop('naturalWidth') * (zoom / 100)));
  }

  function checkImagesLoaded(manga) {
    const images = $('.PageContent img').get();
    const total = images.length;
    const missing = images.filter(item => $(item).prop('naturalWidth') === 0);
    const loaded = images.filter(item => $(item).prop('naturalWidth') !== 0);
    loaded.filter(item => $(item).attr('width') === undefined).forEach(item => applyZoom($(item)));
    missing.forEach(item => reloadImage($(item)));
    NProgress.configure({
      showSpinner: false
    }).set(loaded.length / total);
    $('#Counters i, #NavigationCounters i').html(loaded.length);
    logScript('Progress: ' + String(Math.floor(loaded.length / total * 100)) + '%');
    $('title').html('(' + String(Math.floor(loaded.length / total * 100)) + '%) ' + String(manga.title));
    if (loaded.length < total) {
      setTimeout(() => checkImagesLoaded(manga), 5000);
    } else {
      logScript('Images Loading Complete');
      settings.bookmarks = settings.bookmarks.filter(el => el.url !== location.href);
      setValueGM('MangaBookmarks', JSON.stringify(settings.bookmarks));
      $('.download').attr('href', '#download');
      logScript('Download Avaliable');
      if (settings.DownloadZip) {
        $('#blob').click();
      }
    }
  }

  const cache = {
    zip: new JSZip(),
    downloadFiles: 0,
    Data: {}
  };

  function generateZip() {
    if (cache.downloadFiles === 0) {
      $('.MangaPage img').get().forEach((value, index) => {
        const img = $(value);
        const src = img.attr('src');
        const ext = src.match(/.jpg|.png/ig) || ['.png'];
        const filename = 'Page ' + String(String('000' + String(index + 1)).slice(-3)) + String(ext[0]);
        if (src.indexOf('base64') > -1) {
          let base64 = src.replace('data:image/png;base64,', '');
          const i = base64.indexOf(',');
          if (i !== -1) {
            base64 = base64.substring(i + 1, base64.length);
          }
          cache.zip.file(filename, base64, {
            base64: true,
            createFolders: true
          });
          logScript(filename + ' Added to Zip from Base64 Image, From: ' + String(src));
          cache.downloadFiles += 1;
        } else {
          try {
            GM_xmlhttpRequest({
              method: 'GET',
              url: src,
              overrideMimeType: 'text/plain; charset=x-user-defined',
              responseType: 'blob',
              onload(request) {
                cache.zip.file(filename, request.response, {
                  base64: true,
                  createFolders: true,
                  compression: 'DEFLATE'
                });
                logScript(filename + ' Added to Zip as Base64 Image, From: ' + String(src) + ', Data:', request.response);
                cache.downloadFiles += 1;
              }
            });
          } catch (e) {
            logScript(e);
          }
        }
      });
    }
    const total = parseInt($('#Counters').find('b').text(), 10);
    if (cache.downloadFiles < total) {
      logScript('Waiting for Files to Download ' + String(cache.downloadFiles) + ' of ' + String(total));
      setTimeout(generateZip, 2000);
    } else {
      const blobLink = document.getElementById('blob');
      try {
        blobLink.download = String($('title').text().trim()) + '.zip';
        cache.zip.generateAsync({
          type: 'blob'
        }).then(content => {
          blobLink.href = W.URL.createObjectURL(content);
          logScript('Download Ready');
          $('#blob')[0].click();
        });
      } catch (e) {
        logScript(e);
        blobLink.innerHTML += ' (not supported on this browser)';
      }
    }
  }

  function setKeyDownEvents() {
    try {
      $(document).unbind('keyup keydown keypress onload');
      $(W).unbind('keyup keydown keypress onload');
      document.onkeydown = null;
      document.onkeypress = null;
      W.onkeydown = null;
      W.onkeypress = null;
      W.onload = null;
      document.body.onload = null;
    } catch (e) {
      logScript('Keybinds error: ' + String(e));
    }

    function processKey(e) {
      const a = e.keyCode || e.which;
      if ($.inArray(a, [39, 46, 190, 37, 44, 188, 43, 107, 61, 45, 109, 42, 106, 56, 104, 53, 101]) !== -1) {
        e.preventDefault();
        e.stopPropagation();
        e.stopImmediatePropagation();
        switch (a) {
          case 39:
          case 46:
          case 190:
            $('.ChapterControl:first .next')[0].click();
            break;
          case 37:
          case 44:
          case 188:
            $('.ChapterControl:first .prev')[0].click();
            break;
          case 43:
          case 107:
          case 61:
            $('#enlarge').click();
            break;
          case 45:
          case 109:
            $('#reduce').click();
            break;
          case 42:
          case 106:
          case 56:
          case 104:
            $('#restore').click();
            break;
          case 53:
          case 101:
            $('#fitwidth').click();
            break;
          default:
            break;
        }
        return false;
      }
      return true;
    }
    if (navigator.userAgent.match(/mozilla/i)) {
      $(document).keypress(processKey);
    } else {
      $(document).keydown(processKey);
    }
  }

  function controls$1() {
    $('#enlarge').click(() => {
      settings.Zoom += 25;
      $('#Zoom b').html(settings.Zoom);
      applyZoom();
    });
    $('#reduce').click(() => {
      settings.Zoom -= 25;
      $('#Zoom b').html(settings.Zoom);
      applyZoom();
    });
    $('#restore').click(() => {
      settings.Zoom = 100;
      $('#Zoom b').html(settings.Zoom);
      $('.PageContent img').removeAttr('width');
      $('.PageContent img').removeAttr('style');
    });
    $('#fitwidth').click(() => {
      settings.Zoom = 1000;
      $('#Zoom b').html(settings.Zoom);
      applyZoom();
    });
    $('#webcomic').click(() => {
      $('#Chapter').addClass('WebComic').removeClass('FluidLTR').removeClass('FluidRTL');
    });
    $('#ltrmode').click(() => {
      $('#Chapter').removeClass('WebComic').addClass('FluidLTR').removeClass('FluidRTL');
    });
    $('#rtlmode').click(() => {
      $('#Chapter').removeClass('WebComic').removeClass('FluidLTR').addClass('FluidRTL');
    });
    $('#verticalmode').click(() => {
      $('#Chapter').removeClass('WebComic').removeClass('FluidLTR').removeClass('FluidRTL');
    });
    $('#fitIfOversized').change(event => {
      $('#Chapter').toggleClass('fitWidthIfOversized');
      if ($(event.target).is(':checked')) {
        setValueGM('MangaFitWidthIfOversized', true);
      } else {
        setValueGM('MangaFitWidthIfOversized', false);
      }
      logScript('fitIfOversized: ' + String(getValueGM('MangaFitWidthIfOversized')));
    });
    $('#viewMode').change(event => {
      const mode = $(event.target).val();
      $('#Chapter').removeClass('WebComic').removeClass('FluidLTR').removeClass('FluidRTL').addClass(mode);
      setValueGM('MangaViewMode', mode);
      logScript('ViewMode: ' + String(getValueGM('MangaViewMode')));
    });
    $('#alwaysLoad').change(event => {
      if ($(event.target).is(':checked')) {
        setValueGM('MangaAlwaysLoad', true);
      } else {
        setValueGM('MangaAlwaysLoad', false);
      }
      logScript('MangaAlwaysLoad: ' + String(getValueGM('MangaAlwaysLoad')));
    });
    $('#showThumbnails').change(event => {
      $('#Navigation').toggleClass('disabled');
      if ($(event.target).is(':checked')) {
        setValueGM('MangaShowThumbnails', true);
      } else {
        setValueGM('MangaShowThumbnails', false);
      }
      logScript('MangaShowThumbnails: ' + String(getValueGM('MangaShowThumbnails')));
    });
    $('#downloadZip').change(event => {
      if ($(event.target).is(':checked')) {
        setValueGM('MangaDownloadZip', true);
        swal({
          title: 'Attention',
          text: 'Next time a chapter finish loading you will be promted to save automatically',
          timer: 10000,
          type: 'info',
          confirmButtonText: 'OK'
        });
      } else {
        setValueGM('MangaDownloadZip', false);
      }
      logScript('MangaDownloadZip: ' + String(getValueGM('MangaDownloadZip')));
    });
    $('#blob').one('click', generateZip);
    $('.download').click(() => {
      logScript('Downloading Chapter');
      $('#blob')[0].click();
    });
    $('#PagesPerSecond').change(event => {
      setValueGM('MangaTimer', parseInt($(event.target).val(), 10));
      logScript('MangaTimer: ' + String(getValueGM('MangaTimer')));
    });
    $('#DefaultZoom').change(event => {
      settings.Zoom = parseInt($(event.target).val(), 10);
      $('#Zoom b').html(settings.Zoom);
      setValueGM('MangaZoom', settings.Zoom);
      logScript('MangaZoom: ' + String(getValueGM('MangaZoom')));
      applyZoom();
    });
    $('#ThemeSelector').change(event => {
      const target = $(event.target);
      $('#MangaOnlineViewer , body').removeClass().addClass(target.val());
      logScript('MangaTheme', target.val());
      setValueGM('MangaTheme', target.val());
      logScript('MangaTheme: ' + String(getValueGM('MangaTheme')));
      if (target.val() === 'Custom_Dark' || target.val() === 'Custom_Light') {
        $('#CustomThemeHue').show();
      } else {
        $('#CustomThemeHue').hide();
      }
    });
    jscolor(document.getElementById('CustomThemeHue'));
    $('#CustomThemeHue').change(event => {
      const target = $(event.target).val();
      logScript('CustomTheme: #' + String(target));
      $('style[title="Custom_Light"], style[title="Custom_Dark"]').remove();
      $('head').append(addCustomTheme(target));
      setValueGM('MangaCustomTheme', target);
      logScript('MangaCustomTheme: ' + String(getValueGM('MangaCustomTheme')));
    });

    function scrollToElement(ele) {
      $(W).scrollTop(ele.offset().top).scrollLeft(ele.offset().left);
    }
    $('#gotoPage').bind('change', event => {
      scrollToElement($('#Page' + String($(event.target).val())));
    });
    $('.ThumbNail').bind('click', event => {
      scrollToElement($('#Page' + String($(event.target).find('span').html())));
    });
    $('#settings').click(() => {
      $('#ViewerControls').slideToggle();
      $('#ViewerShortcuts').slideToggle();
      $('#ImageOptions').toggleClass('settingsOpen');
      $('#Navigation').toggleClass('visible');
    });
    $('.Bookmark').click(event => {
      const num = parseInt($(event.target).parents('.MangaPage').find('.PageFunctions span').text(), 10);
      const mark = {
        url: location.href,
        page: num,
        date: Date.now()
      };
      const found = settings.bookmarks.filter(el => el.url === mark.url).length > 0;
      settings.bookmarks = settings.bookmarks.filter(el => el.url !== mark.url);
      if (found) {
        swal({
          title: 'Bookmark Removed',
          timer: 10000,
          type: 'error',
          confirmButtonText: 'OK'
        });
      } else {
        settings.bookmarks.push(mark);
        swal({
          title: 'Saved Bookmark',
          html: 'Next time you open this chapter it will resume from:<h4>Page ' + String(num) + '</h4>(Only <i>ONCE</i> per Bookmark, will be removed after a year unused)',
          type: 'success',
          confirmButtonText: 'OK'
        });
      }
      setValueGM('MangaBookmarks', JSON.stringify(settings.bookmarks));
      logScript('MangaBookmarks: ' + String(getValueGM('MangaBookmarks')));
    });
    $('.Reload').click(event => {
      reloadImage($(event.target).parents('.MangaPage').find('.PageContent img'));
    });
    $('.ZoomIn').click(event => {
      const img = $(event.target).parents('.MangaPage').find('.PageContent img');
      const ratio = img.width() / img.prop('naturalWidth') * 1.25 * 100;
      applyZoom(img, ratio);
    });
    $('.ZoomOut').click(event => {
      const img = $(event.target).parents('.MangaPage').find('.PageContent img');
      const ratio = img.width() / img.prop('naturalWidth') * 0.75 * 100;
      applyZoom(img, ratio);
    });
    $('.ZoomRestore').click(() => {
      $('.PageContent img').removeAttr('width');
    });
    $('.ZoomWidth').click(event => {
      const img = $(event.target).parents('.MangaPage').find('.PageContent img');
      applyZoom(img, 1000);
    });
    $('.Hide').click(event => {
      const img = $(event.target).parents('.MangaPage').find('.PageContent');
      img.slideToggle('slow');
    });
  }

  function formatPage(manga, begin = 0) {
    logScript('Found ' + String(manga.quant) + ' pages');
    if (manga.quant > 0) {
      settings.starting = begin || settings.bookmarks
        .filter(x => x.url === location.href).map(x => x.page)[0] || 0;
      let cancel = false;
      if (!settings.alwaysLoad) {
        $('head').append('<style type="text/css">.sweet-alert,.sweet-overlay{position:fixed;display:none}body.stop-scrolling{height:100%;overflow:hidden}.sweet-overlay{background-color:#000;-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=40)";background-color:rgba(0,0,0,.4);left:0;right:0;top:0;bottom:0;z-index:10000}.sweet-alert{background-color:#fff;font-family:"Open Sans","Helvetica Neue",Helvetica,Arial,sans-serif;width:478px;padding:17px;border-radius:5px;text-align:center;left:50%;top:50%;margin-left:-256px;margin-top:-200px;overflow:hidden;z-index:99999}@media all and (max-width:540px){.sweet-alert{width:auto;margin-left:0;margin-right:0;left:15px;right:15px}}.sweet-alert h2{color:#575757;font-size:30px;text-align:center;font-weight:600;text-transform:none;position:relative;margin:25px 0;padding:0;line-height:40px;display:block}.sweet-alert p{color:#797979;font-size:16px;font-weight:300;position:relative;text-align:inherit;float:none;margin:0;padding:0;line-height:normal}.sweet-alert fieldset{border:none;position:relative}.sweet-alert .sa-error-container{background-color:#f1f1f1;margin-left:-17px;margin-right:-17px;overflow:hidden;padding:0 10px;max-height:0;webkit-transition:padding .15s,max-height .15s;transition:padding .15s,max-height .15s}.sweet-alert .sa-error-container.show{padding:10px 0;max-height:100px;webkit-transition:padding .2s,max-height .2s;transition:padding .25s,max-height .25s}.sweet-alert .sa-error-container .icon{display:inline-block;width:24px;height:24px;border-radius:50%;background-color:#ea7d7d;color:#fff;line-height:24px;text-align:center;margin-right:3px}.sweet-alert .sa-error-container p{display:inline-block}.sweet-alert .sa-input-error{position:absolute;top:29px;right:26px;width:20px;height:20px;opacity:0;-webkit-transform:scale(.5);transform:scale(.5);-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transition:all .1s;transition:all .1s}.sweet-alert .sa-input-error::after,.sweet-alert .sa-input-error::before{content:"";width:20px;height:6px;background-color:#f06e57;border-radius:3px;position:absolute;top:50%;margin-top:-4px;left:50%;margin-left:-9px}.sweet-alert .sa-input-error::before{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}.sweet-alert .sa-input-error::after{-webkit-transform:rotate(45deg);transform:rotate(45deg)}.sweet-alert .sa-input-error.show{opacity:1;-webkit-transform:scale(1);transform:scale(1)}.sweet-alert input{width:100%;box-sizing:border-box;border-radius:3px;border:1px solid #d7d7d7;height:43px;margin-top:10px;margin-bottom:17px;font-size:18px;box-shadow:inset 0 1px 1px rgba(0,0,0,.06);padding:0 12px;display:none;-webkit-transition:all .3s;transition:all .3s}.sweet-alert input:focus{outline:0;box-shadow:0 0 3px #c4e6f5;border:1px solid #b4dbed}.sweet-alert input:focus::-moz-placeholder{transition:opacity .3s 30ms ease;opacity:.5}.sweet-alert input:focus:-ms-input-placeholder{transition:opacity .3s 30ms ease;opacity:.5}.sweet-alert input:focus::-webkit-input-placeholder{transition:opacity .3s 30ms ease;opacity:.5}.sweet-alert input::-moz-placeholder{color:#bdbdbd}.sweet-alert input::-ms-clear{display:none}.sweet-alert input:-ms-input-placeholder{color:#bdbdbd}.sweet-alert input::-webkit-input-placeholder{color:#bdbdbd}.sweet-alert.show-input input{display:block}.sweet-alert .sa-confirm-button-container{display:inline-block;position:relative}.sweet-alert .la-ball-fall{position:absolute;left:50%;top:50%;margin-left:-27px;margin-top:4px;opacity:0;visibility:hidden}.sweet-alert button{background-color:#8CD4F5;color:#fff;border:none;box-shadow:none;font-size:17px;font-weight:500;-webkit-border-radius:4px;border-radius:5px;padding:10px 32px;margin:26px 5px 0;cursor:pointer}.sweet-alert button:focus{outline:0;box-shadow:0 0 2px rgba(128,179,235,.5),inset 0 0 0 1px rgba(0,0,0,.05)}.sweet-alert button:hover{background-color:#7ecff4}.sweet-alert button:active{background-color:#5dc2f1}.sweet-alert button.cancel{background-color:#C1C1C1}.sweet-alert button.cancel:hover{background-color:#b9b9b9}.sweet-alert button.cancel:active{background-color:#a8a8a8}.sweet-alert button.cancel:focus{box-shadow:rgba(197,205,211,.8) 0 0 2px,rgba(0,0,0,.0470588) 0 0 0 1px inset!important}.sweet-alert button[disabled]{opacity:.6;cursor:default}.sweet-alert button.confirm[disabled]{color:transparent}.sweet-alert button.confirm[disabled]~.la-ball-fall{opacity:1;visibility:visible;transition-delay:0s}.sweet-alert button::-moz-focus-inner{border:0}.sweet-alert[data-has-cancel-button=false] button{box-shadow:none!important}.sweet-alert[data-has-confirm-button=false][data-has-cancel-button=false]{padding-bottom:40px}.sweet-alert .sa-icon{width:80px;height:80px;border:4px solid gray;-webkit-border-radius:40px;border-radius:50%;margin:20px auto;padding:0;position:relative;box-sizing:content-box}.sweet-alert .sa-icon.sa-error{border-color:#F27474}.sweet-alert .sa-icon.sa-error .sa-x-mark{position:relative;display:block}.sweet-alert .sa-icon.sa-error .sa-line{position:absolute;height:5px;width:47px;background-color:#F27474;display:block;top:37px;border-radius:2px}.sweet-alert .sa-icon.sa-error .sa-line.sa-left{-webkit-transform:rotate(45deg);transform:rotate(45deg);left:17px}.sweet-alert .sa-icon.sa-error .sa-line.sa-right{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);right:16px}.sweet-alert .sa-icon.sa-warning{border-color:#F8BB86}.sweet-alert .sa-icon.sa-warning .sa-body{position:absolute;width:5px;height:47px;left:50%;top:10px;-webkit-border-radius:2px;border-radius:2px;margin-left:-2px;background-color:#F8BB86}.sweet-alert .sa-icon.sa-warning .sa-dot{position:absolute;width:7px;height:7px;-webkit-border-radius:50%;border-radius:50%;margin-left:-3px;left:50%;bottom:10px;background-color:#F8BB86}.sweet-alert .sa-icon.sa-info::after,.sweet-alert .sa-icon.sa-info::before{content:"";background-color:#C9DAE1;left:50%;position:absolute}.sweet-alert .sa-icon.sa-info{border-color:#C9DAE1}.sweet-alert .sa-icon.sa-info::before{width:5px;height:29px;bottom:17px;border-radius:2px;margin-left:-2px}.sweet-alert .sa-icon.sa-info::after{width:7px;height:7px;border-radius:50%;margin-left:-3px;top:19px}.sweet-alert .sa-icon.sa-success{border-color:#A5DC86}.sweet-alert .sa-icon.sa-success::after,.sweet-alert .sa-icon.sa-success::before{content:"";position:absolute;width:60px;height:120px;background:#fff}.sweet-alert .sa-icon.sa-success::before{-webkit-border-radius:120px 0 0 120px;border-radius:120px 0 0 120px;top:-7px;left:-33px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-transform-origin:60px 60px;transform-origin:60px 60px}.sweet-alert .sa-icon.sa-success::after{-webkit-border-radius:0 120px 120px 0;border-radius:0 120px 120px 0;top:-11px;left:30px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-transform-origin:0 60px;transform-origin:0 60px}.sweet-alert .sa-icon.sa-success .sa-placeholder{width:80px;height:80px;border:4px solid rgba(165,220,134,.2);-webkit-border-radius:40px;border-radius:50%;box-sizing:content-box;position:absolute;left:-4px;top:-4px;z-index:2}.sweet-alert .sa-icon.sa-success .sa-fix{width:5px;height:90px;background-color:#fff;position:absolute;left:28px;top:8px;z-index:1;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}.sweet-alert .sa-icon.sa-success .sa-line{height:5px;background-color:#A5DC86;display:block;border-radius:2px;position:absolute;z-index:2}.sweet-alert .sa-icon.sa-success .sa-line.sa-tip{width:25px;left:14px;top:46px;-webkit-transform:rotate(45deg);transform:rotate(45deg)}.sweet-alert .sa-icon.sa-success .sa-line.sa-long{width:47px;right:8px;top:38px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}.sweet-alert .sa-icon.sa-custom{background-size:contain;border-radius:0;border:none;background-position:center center;background-repeat:no-repeat}@-webkit-keyframes showSweetAlert{0%{transform:scale(.7);-webkit-transform:scale(.7)}45%{transform:scale(1.05);-webkit-transform:scale(1.05)}80%{transform:scale(.95);-webkit-transform:scale(.95)}100%{transform:scale(1);-webkit-transform:scale(1)}}@keyframes showSweetAlert{0%{transform:scale(.7);-webkit-transform:scale(.7)}45%{transform:scale(1.05);-webkit-transform:scale(1.05)}80%{transform:scale(.95);-webkit-transform:scale(.95)}100%{transform:scale(1);-webkit-transform:scale(1)}}@-webkit-keyframes hideSweetAlert{0%{transform:scale(1);-webkit-transform:scale(1)}100%{transform:scale(.5);-webkit-transform:scale(.5)}}@keyframes hideSweetAlert{0%{transform:scale(1);-webkit-transform:scale(1)}100%{transform:scale(.5);-webkit-transform:scale(.5)}}@-webkit-keyframes slideFromTop{0%{top:0}100%{top:50%}}@keyframes slideFromTop{0%{top:0}100%{top:50%}}@-webkit-keyframes slideToTop{0%{top:50%}100%{top:0}}@keyframes slideToTop{0%{top:50%}100%{top:0}}@-webkit-keyframes slideFromBottom{0%{top:70%}100%{top:50%}}@keyframes slideFromBottom{0%{top:70%}100%{top:50%}}@-webkit-keyframes slideToBottom{0%{top:50%}100%{top:70%}}@keyframes slideToBottom{0%{top:50%}100%{top:70%}}.showSweetAlert[data-animation=pop]{-webkit-animation:showSweetAlert .3s;animation:showSweetAlert .3s}.showSweetAlert[data-animation=none]{-webkit-animation:none;animation:none}.showSweetAlert[data-animation=slide-from-top]{-webkit-animation:slideFromTop .3s;animation:slideFromTop .3s}.showSweetAlert[data-animation=slide-from-bottom]{-webkit-animation:slideFromBottom .3s;animation:slideFromBottom .3s}.hideSweetAlert[data-animation=pop]{-webkit-animation:hideSweetAlert .2s;animation:hideSweetAlert .2s}.hideSweetAlert[data-animation=none]{-webkit-animation:none;animation:none}.hideSweetAlert[data-animation=slide-from-top]{-webkit-animation:slideToTop .4s;animation:slideToTop .4s}.hideSweetAlert[data-animation=slide-from-bottom]{-webkit-animation:slideToBottom .3s;animation:slideToBottom .3s}@-webkit-keyframes animateSuccessTip{0%,54%{width:0;left:1px;top:19px}70%{width:50px;left:-8px;top:37px}84%{width:17px;left:21px;top:48px}100%{width:25px;left:14px;top:45px}}@keyframes animateSuccessTip{0%,54%{width:0;left:1px;top:19px}70%{width:50px;left:-8px;top:37px}84%{width:17px;left:21px;top:48px}100%{width:25px;left:14px;top:45px}}@-webkit-keyframes animateSuccessLong{0%,65%{width:0;right:46px;top:54px}84%{width:55px;right:0;top:35px}100%{width:47px;right:8px;top:38px}}@keyframes animateSuccessLong{0%,65%{width:0;right:46px;top:54px}84%{width:55px;right:0;top:35px}100%{width:47px;right:8px;top:38px}}@-webkit-keyframes rotatePlaceholder{0%,5%{transform:rotate(-45deg);-webkit-transform:rotate(-45deg)}100%,12%{transform:rotate(-405deg);-webkit-transform:rotate(-405deg)}}@keyframes rotatePlaceholder{0%,5%{transform:rotate(-45deg);-webkit-transform:rotate(-45deg)}100%,12%{transform:rotate(-405deg);-webkit-transform:rotate(-405deg)}}.animateSuccessTip{-webkit-animation:animateSuccessTip .75s;animation:animateSuccessTip .75s}.animateSuccessLong{-webkit-animation:animateSuccessLong .75s;animation:animateSuccessLong .75s}.sa-icon.sa-success.animate::after{-webkit-animation:rotatePlaceholder 4.25s ease-in;animation:rotatePlaceholder 4.25s ease-in}@-webkit-keyframes animateErrorIcon{0%{transform:rotateX(100deg);-webkit-transform:rotateX(100deg);opacity:0}100%{transform:rotateX(0);-webkit-transform:rotateX(0);opacity:1}}@keyframes animateErrorIcon{0%{transform:rotateX(100deg);-webkit-transform:rotateX(100deg);opacity:0}100%{transform:rotateX(0);-webkit-transform:rotateX(0);opacity:1}}.animateErrorIcon{-webkit-animation:animateErrorIcon .5s;animation:animateErrorIcon .5s}@-webkit-keyframes animateXMark{0%,50%{transform:scale(.4);-webkit-transform:scale(.4);margin-top:26px;opacity:0}80%{transform:scale(1.15);-webkit-transform:scale(1.15);margin-top:-6px}100%{transform:scale(1);-webkit-transform:scale(1);margin-top:0;opacity:1}}@keyframes animateXMark{0%,50%{transform:scale(.4);-webkit-transform:scale(.4);margin-top:26px;opacity:0}80%{transform:scale(1.15);-webkit-transform:scale(1.15);margin-top:-6px}100%{transform:scale(1);-webkit-transform:scale(1);margin-top:0;opacity:1}}.animateXMark{-webkit-animation:animateXMark .5s;animation:animateXMark .5s}@-webkit-keyframes pulseWarning{0%{border-color:#F8D486}100%{border-color:#F8BB86}}@keyframes pulseWarning{0%{border-color:#F8D486}100%{border-color:#F8BB86}}.pulseWarning{-webkit-animation:pulseWarning .75s infinite alternate;animation:pulseWarning .75s infinite alternate}@-webkit-keyframes pulseWarningIns{0%{background-color:#F8D486}100%{background-color:#F8BB86}}@keyframes pulseWarningIns{0%{background-color:#F8D486}100%{background-color:#F8BB86}}.pulseWarningIns{-webkit-animation:pulseWarningIns .75s infinite alternate;animation:pulseWarningIns .75s infinite alternate}@-webkit-keyframes rotate-loading{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}@keyframes rotate-loading{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}.sweet-alert .sa-icon.sa-error .sa-line.sa-left{-ms-transform:rotate(45deg)\9}.sweet-alert .sa-icon.sa-error .sa-line.sa-right{-ms-transform:rotate(-45deg)\9}.sweet-alert .sa-icon.sa-success{border-color:transparent\9}.sweet-alert .sa-icon.sa-success .sa-line.sa-tip{-ms-transform:rotate(45deg)\9}.sweet-alert .sa-icon.sa-success .sa-line.sa-long{-ms-transform:rotate(-45deg)\9}.la-ball-fall,.la-ball-fall>div{position:relative;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.la-ball-fall{display:block;font-size:0;color:#fff;width:54px;height:18px}.la-ball-fall.la-dark{color:#333}.la-ball-fall>div{display:inline-block;float:none;background-color:currentColor;border:0 solid currentColor;width:10px;height:10px;margin:4px;border-radius:100%;opacity:0;-webkit-animation:ball-fall 1s ease-in-out infinite;-moz-animation:ball-fall 1s ease-in-out infinite;-o-animation:ball-fall 1s ease-in-out infinite;animation:ball-fall 1s ease-in-out infinite}.la-ball-fall>div:nth-child(1){-webkit-animation-delay:-.2s;-moz-animation-delay:-.2s;-o-animation-delay:-.2s;animation-delay:-.2s}.la-ball-fall>div:nth-child(2){-webkit-animation-delay:-.1s;-moz-animation-delay:-.1s;-o-animation-delay:-.1s;animation-delay:-.1s}.la-ball-fall>div:nth-child(3){-webkit-animation-delay:0s;-moz-animation-delay:0s;-o-animation-delay:0s;animation-delay:0s}.la-ball-fall.la-sm{width:26px;height:8px}.la-ball-fall.la-sm>div{width:4px;height:4px;margin:2px}.la-ball-fall.la-2x{width:108px;height:36px}.la-ball-fall.la-2x>div{width:20px;height:20px;margin:8px}.la-ball-fall.la-3x{width:162px;height:54px}.la-ball-fall.la-3x>div{width:30px;height:30px;margin:12px}@-webkit-keyframes ball-fall{0%{opacity:0;-webkit-transform:translateY(-145%);transform:translateY(-145%)}10%,90%{opacity:.5}20%,80%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}100%{opacity:0;-webkit-transform:translateY(145%);transform:translateY(145%)}}@-moz-keyframes ball-fall{0%{opacity:0;-moz-transform:translateY(-145%);transform:translateY(-145%)}10%,90%{opacity:.5}20%,80%{opacity:1;-moz-transform:translateY(0);transform:translateY(0)}100%{opacity:0;-moz-transform:translateY(145%);transform:translateY(145%)}}@-o-keyframes ball-fall{0%{opacity:0;-o-transform:translateY(-145%);transform:translateY(-145%)}10%,90%{opacity:.5}20%,80%{opacity:1;-o-transform:translateY(0);transform:translateY(0)}100%{opacity:0;-o-transform:translateY(145%);transform:translateY(145%)}}@keyframes ball-fall{0%{opacity:0;-webkit-transform:translateY(-145%);-moz-transform:translateY(-145%);-o-transform:translateY(-145%);transform:translateY(-145%)}10%,90%{opacity:.5}20%,80%{opacity:1;-webkit-transform:translateY(0);-moz-transform:translateY(0);-o-transform:translateY(0);transform:translateY(0)}100%{opacity:0;-webkit-transform:translateY(145%);-moz-transform:translateY(145%);-o-transform:translateY(145%);transform:translateY(145%)}}</style>');
        swal({
          title: 'Starting MangaOnlineViewer',
          text: (settings.starting > 1 ? 'Resuming reading from Page ' + String(settings.starting) + '.\n' : '') + 'Please wait, 3 seconds...',
          showCancelButton: false,
          confirmButtonText: 'No, cancel!',
          confirmButtonColor: '#DD6B55',
          closeOnConfirm: true
        }).then(isConfirm => {
          cancel = isConfirm;
          W.mov = starting => formatPage(manga, starting);
        });
      }
      setTimeout(() => {
        W.stop();
        if (cancel) {
          logScript('Aborted');
          return;
        }
        if (manga.before !== undefined) {
          manga.before();
        }
        document.documentElement.innerHTML = reader(manga, settings.starting);
        setTimeout(() => {
          try {
            controls$1(manga);
            setKeyDownEvents(manga);
            checkImagesLoaded(manga);
            logScript('Site rebuild done');
            setTimeout(() => {
              $('body').scrollTo(0);
              loadManga(manga, settings.starting);
            }, 50);
          } catch (e) {
            logScript(e);
          }
        }, 50);
      }, settings.alwaysLoad ? 50 : 3000);
    }
  }

  function start(sites) {
    logScript('Starting ' + String(getInfoGM.script.name) + ' ' + String(getInfoGM.script.version) + ' on ' + String(getBrowser()) + ' with ' + String(getEngine()));
    W.InfoGM = getInfoGM;
    logScript(String(sites.length) + ' Known Manga Sites');
    let waitElapsed = 0;

    function waitExec(site) {
      let wait = '';
      if (site.waitMax !== undefined) {
        if (waitElapsed >= site.waitMax) {
          formatPage(site.run());
          return;
        }
      }
      if (site.waitEle !== undefined) {
        if (site.waitAttr !== undefined) {
          wait = $(site.waitEle).attr(site.waitAttr);
        } else {
          wait = $(site.waitEle).get();
        }
        logScript('Wating for ' + String(site.waitEle) + ' = ' + String(wait));
        if (isEmpty(wait)) {
          setTimeout(() => {
            waitExec(site);
          }, site.waitStep || 1000);
          waitElapsed += site.waitStep || 1000;
          return;
        }
      }
      if (site.waitVar !== undefined) {
        wait = W[site.waitVar];
        logScript('Wating for ' + String(site.waitVar) + ' = ' + String(wait));
        if (isEmpty(wait)) {
          setTimeout(() => {
            waitExec(site);
          }, site.waitStep || 1000);
          waitElapsed += site.waitStep || 1000;
          return;
        }
      }
      formatPage(site.run());
    }
    logScript('Looking for a match...');
    const test = R.compose(R.map(waitExec), R.map(logScriptC('Site Found:')), R.filter(x => R.test(x.url, location.href)));
    test(sites);
  }

  var batoto = {
    name: 'Batoto',
    url: /https?:\/\/(www.)?bato.to\/chapter.*/,
    homepage: 'http://bato.to/',
    language: ['English'],
    category: 'manga',
    run() {
      const num = $('#viewer .item').length;
      return {
        title: $('.nav-title a').text(),
        series: $('.nav-title a').attr('href'),
        quant: num,
        prev: $('.nav-prev a').attr('href'),
        next: $('.nav-next a').attr('href'),
        listImages: $('.page-img').get().map(i => $(i).attr('src'))
      };
    }
  };

  var comicastle = {
    name: 'ComiCastle',
    url: /https?:\/\/(www.)?comicastle.org\/comic\/.+\/[0-9]+.*/,
    homepage: 'http://www.comicastle.org/',
    language: ['English'],
    category: 'comic',
    run() {
      const url = $('.form-control:last option').get();
      const chapter = $('.form-control:first option');
      return {
        title: chapter.find(':selected').text(),
        series: $('.navbar-header a').attr('href'),
        quant: url.length,
        prev: chapter.find(':selected').prev().val(),
        next: chapter.find(':selected').next().val(),
        listPages: url.map(item => $(item).val()),
        img: '.chapter-img'
      };
    }
  };

  var dysnatyscans = {
    name: 'Dynasty-Scans',
    url: /https?:\/\/(www.)?dynasty-scans.com\/chapters\/.+/,
    homepage: 'https://dynasty-scans.com/',
    language: ['English'],
    category: 'manga',
    run() {
      return {
        title: $('#chapter-title').text(),
        series: '#',
        quant: W.pages.length,
        prev: $('#prev_link').attr('href'),
        next: $('#next_link').attr('href'),
        listImages: W.pages.map(x => x.image)
      };
    }
  };

  var eatmanga = {
    name: 'EatManga',
    url: /https?:\/\/(www.)?eatmanga.me\/Manga-Scan\/.+\/.+\//,
    homepage: 'http://eatmanga.me/',
    language: ['English'],
    category: 'manga',
    run() {
      const chapter = $('#top_chapter_list option:selected');
      return {
        title: $('#main_content h1').text().split(',')[0].trim(),
        series: $('ul#crumbs li a:eq(2)').attr('href'),
        quant: $('select#pages option:last').html(),
        prev: chapter.next().val(),
        next: chapter.prev().val(),
        listPages: $('select#pages option').get().map(item => $(item).val()),
        img: '#eatmanga_image , #eatmanga_image_big'
      };
    }
  };

  var egscans = {
    name: 'Easy Going Scans',
    url: /https?:\/\/read.egscans.com\/.+/,
    homepage: 'http://read.egscans.com/',
    language: ['English'],
    category: 'manga',
    waitVar: 'img_url',
    run() {
      const src = W.img_url.slice(1);
      return {
        title: $('select[name="manga"] option:selected').text().trim(),
        series: '#',
        quant: src.length,
        prev: '../' + String(W.prev_chap),
        next: '../' + String(W.next_chap),
        listImages: src.map(encodeURI).map(x => '../' + String(x))
      };
    }
  };

  var foolslide = {
    name: 'FoOlSlide',
    url: /^(?!.*jaiminisbox).*\/read\/.+/,
    homepage: '',
    language: ['English'],
    obs: 'Any Scanlator site that uses FoOLSlide',
    category: 'manga',
    run() {
      const temp = String(location.href.substr(0, location.href.lastIndexOf('/'))) + '/';
      const url = temp.match(/page\/$/) ? temp : temp + 'page/';
      const num = $('.topbar_right .dropdown li').length;
      const chapter = $('.topbar_left .dropdown_parent:last ul li a');
      return {
        title: $('title').text().trim(),
        series: $('div.tbtitle div.text a:first').attr('href'),
        quant: num,
        prev: chapter.eq(chapter.index(chapter.filter('[href*=\'' + String(location.pathname.replace(/page.+/, '')) + '\']')) + 1).attr('href'),
        next: chapter.eq(chapter.index(chapter.filter('[href*=\'' + String(location.pathname.replace(/page.+/, '')) + '\']')) - 1).attr('href'),
        listPages: [...Array(num).keys()].map(i => url + (i + 1)),
        img: 'img.open'
      };
    }
  };

  var kissmanga = {
    name: 'KissManga',
    url: /https?:\/\/(www.)?kissmanga.com\/Manga\/.+\/.+?id=[0-9]+/,
    homepage: 'http://kissmanga.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const chapter = $('#selectChapter option');
      const origin = $('#navsubbar a');
      return {
        title: origin.text(),
        series: origin.attr('href'),
        quant: $('#selectPage option:last').last().html(),
        prev: chapter.filter(':selected').prev().val(),
        next: chapter.filter(':selected').next().val(),
        listImages: W.lstImages
      };
    }
  };

  var mangadoom = {
    name: 'MangaDoom',
    url: /https?:\/\/(www.)?mngdoom.com\/.+\/[0-9]+/,
    homepage: 'https://mngdoom.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const url = $('.selectPage:first option').get();
      const chapter = $('.chapterSelect:first option:selected');
      return {
        title: $('.widget-heading > div > div:first').text().trim(),
        series: $('.widget-heading a').attr('href'),
        quant: url.length,
        prev: chapter.next().val(),
        next: chapter.prev().val(),
        listPages: url.map(item => $(item).val()),
        img: 'img.img-responsive'
      };
    }
  };

  var mangafox = {
    name: 'MangaFox',
    url: /https?:\/\/(www.)?(mangafox.la|fanfox.net)\/manga\/.+\/.+\//,
    homepage: 'http://mangafox.la/',
    language: ['English'],
    category: 'manga',
    run() {
      const num = parseInt($('select.m:first option:last').prev().val(), 10);
      return {
        title: $('#series .no').text().trim(),
        series: $('#series a:last').attr('href'),
        quant: num,
        prev: $('#chnav p:first a').attr('href'),
        next: $('#chnav p:last a').attr('href'),
        listPages: [...Array(num).keys()].map(i => String(i + 1) + '.html'),
        img: 'img#image'
      };
    }
  };

  var mangago = {
    name: 'MangaGo',
    url: /https?:\/\/(www.)?mangago.me\/read-manga\/.+\/.+/,
    homepage: 'http://www.mangago.me/',
    language: ['English'],
    category: 'manga',
    run() {
      const origin = $('#series');
      return {
        title: origin.text(),
        series: origin.attr('href'),
        quant: $('.page a:first').text().replace(/page 1 of /, ''),
        prev: $('.readtips p:eq(4) a:first').attr('href'),
        next: $('.readtips p:eq(3) a:first').attr('href'),
        listPages: $('.page a').get().map(item => $(item).attr('href')),
        img: '#page1'
      };
    }
  };

  var mangahere = {
    name: 'MangaHere',
    url: /https?:\/\/(www.)?mangahere.cc\/manga\/.+\/.+/,
    homepage: 'http://www.mangahere.cc/',
    language: ['English'],
    category: 'manga',
    run() {
      const num = $('.right select:first option').length - 1;
      const chapter = $('.reader_tip a');
      return {
        title: $('.title h1').text(),
        series: $('div.title h2 a').attr('href'),
        quant: num,
        prev: chapter.eq(-1).attr('href'),
        next: chapter.eq(-2).attr('href'),
        listPages: [''].concat([...Array(num - 1).keys()].map(i => String(i + 2) + '.html')),
        img: 'img#image'
      };
    }
  };

  var mangainn = {
    name: 'MangaInn',
    url: /https?:\/\/(www.)?mangainn.net\/.+\/[0-9]+(\/[0-9]*)?/,
    homepage: 'http://www.mangainn.net/',
    language: ['English'],
    category: 'manga',
    run() {
      return {
        title: W.chapter_page_title.trim(),
        series: W.manga_url,
        quant: W.images.length,
        prev: W.prev_chapter_url,
        next: W.next_chapter_url,
        listImages: W.images.map(i => i.url)
      };
    }
  };

  var mangalyght = {
    name: 'MangaLyght',
    url: /https?:\/\/manga.lyght.net\/series\/.+\.html/,
    homepage: 'http://manga.lyght.net/',
    language: ['English'],
    category: 'manga',
    run() {
      const chapter = $('.selectchapter option:selected');
      const url = String($('form[name=\'pageSelector1\']').attr('action')) + '?ch=' + String(chapter.val().replace(' ', '+')) + '&page=';
      const num = $('.selectpage option').length;
      const origin = $('div.entry h1 a');
      return {
        title: origin.text().trim(),
        series: origin.attr('href'),
        quant: num,
        prev: (String(location.pathname) + '?ch=' + String(chapter.prev().val())).replace(' ', '+'),
        next: (String(location.pathname) + '?ch=' + String(chapter.next().val())).replace(' ', '+'),
        listPages: [...Array(num).keys()].map(i => url + (i + 1)),
        img: '#mainimage'
      };
    }
  };

  var mangapark = {
    name: 'MangaPark',
    url: /https?:\/\/(www.)?mangapark.me\/manga\/.+\/.+/,
    homepage: 'http://mangapark.me/',
    language: ['English'],
    category: 'manga',
    run() {
      const url = location.href + (location.href.lastIndexOf('/') !== location.href.length - 1 ? '/' : '');
      const num = $('.info div:eq(1) a').length;
      return {
        title: $('.loc a:first').text().trim(),
        series: '/manga/' + String(location.pathname.split('/')[2]),
        quant: num,
        prev: $('.info a:eq(0)').attr('href'),
        next: $('.info a:eq(1)').attr('href'),
        listPages: [...Array(num).keys()].map(i => url + (i + 1)),
        img: '.img'
      };
    }
  };

  var mangareader = {
    name: ['MangaReader', 'MangaPanda'],
    url: /https?:\/\/(www.)?(mangareader|mangapanda)(.net|.com)\/.+\/.+/,
    homepage: ['http://www.mangareader.net/', 'http://www.mangapanda.com/'],
    language: ['English'],
    category: 'manga',
    run() {
      const url = location.href + (location.href.lastIndexOf('/') !== location.href.length - 1 ? '/' : '');
      const num = parseInt($('select#pageMenu option:last').html(), 10);
      const chapter = $('#mangainfo_bas a');
      return {
        title: $('#mangainfo h1').text(),
        series: $('#mangainfo a').attr('href'),
        quant: num,
        prev: chapter.last().attr('href'),
        next: chapter.first().attr('href'),
        listPages: [...Array(num).keys()].map(i => url + (i + 1), num),
        img: 'img#img',
        before() {
          if (location.pathname.match(/\/.+\/.+\/chapter-[0-9]+.*/)) {
            const path = location.pathname.split('/');
            location.pathname = '/' + String(path[2]) + '/' + String(path[3].match(/[0-9]+/));
          } else if (location.search) {
            location.href = location.pathname;
          }
        }
      };
    }
  };

  var mangastream = {
    name: 'MangaStream',
    url: /https?:\/\/(www.)?(mangastream|readms)(.net|.com)\/r.*\/.+/,
    homepage: 'http://mangastream.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const url = location.href.substring(0, location.href.lastIndexOf('/') + 1);
      const num = parseInt($('div.controls div.btn-group ul.dropdown-menu li:last').text().match(/[0-9]+/), 10);
      const chapter = $('.controls .dropdown-menu:first a');
      return {
        title: $('.btn:eq(0)').text().trim(),
        series: $('div.controls div.btn-group ul.dropdown-menu:first li a:last').attr('href'),
        quant: num,
        prev: chapter.eq(chapter.index(chapter.filter('[href*=\'' + String(location.pathname) + '\']')) + 1).attr('href'),
        next: chapter.eq(chapter.index(chapter.filter('[href*=\'' + String(location.pathname) + '\']')) - 1).attr('href'),
        listPages: [...Array(num).keys()].map(i => url + (i + 1)),
        img: 'img#manga-page'
      };
    }
  };

  var mangatown = {
    name: 'MangaTown',
    url: /https?:\/\/(www.)?mangatown.com\/manga\/.+\/.+/,
    homepage: 'http://www.mangatown.com/',
    language: ['English'],
    category: 'manga',
    waitEle: '#top_chapter_list option',
    waitMax: 5000,
    run() {
      const num = $('.page_select select:first option').get().slice(0, -1);
      const chapter = $('#top_chapter_list option').eq(W.current_chapter_index);
      return {
        title: $('.title h1').text(),
        series: $('.title h2 a').attr('href'),
        quant: num.length,
        prev: chapter.prev().val(),
        next: chapter.next().val(),
        listPages: num.map(item => $(item).val()),
        img: '#image'
      };
    }
  };

  var ninemanga = {
    name: 'NineManga',
    url: /https?:\/\/(www.)?ninemanga.com\/chapter\/.+\/.+\.html/,
    homepage: 'http://ninemanga.com/',
    language: ['English'],
    category: 'manga',
    run() {
      return {
        title: $('.tip a:first').text(),
        series: $('.subgiude a:eq(1)').attr('href'),
        quant: $('#page:first option').length,
        prev: $('.chnav a:first').attr('href'),
        next: $('.chnav a:eq(1)').attr('href'),
        listPages: $('#page:first option').get().map(item => $(item).val()),
        img: '.manga_pic'
      };
    }
  };

  var readmangatoday = {
    name: 'ReadManga Today',
    url: /https?:\/\/(www.)?readmng.com\/.+\/[0-9.]+(\/[0-9]*)?/,
    homepage: 'http://www.readmng.com/',
    language: ['English'],
    category: 'manga',
    run() {
      return {
        title: W.chapter_page_title.trim(),
        series: W.manga_url,
        quant: W.images.length,
        prev: W.prev_chapter_url,
        next: W.next_chapter_url,
        listImages: W.images.map(i => i.url)
      };
    }
  };

  var senmanga = {
    name: 'SenManga(Raw)',
    url: /https?:\/\/raw.senmanga.com\/.+\/.+\/?/,
    homepage: 'http://raw.senmanga.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const url = '/' + String(location.pathname.split('/')[1]) + '/' + String(location.pathname.split('/')[2]);
      const num = parseInt($('select[name=\'page\'] option:last').val(), 10);
      const chapter = $('select[name="chapter"] option:selected');
      const origin = $('.title a');
      return {
        title: $('.title').text().trim(),
        series: origin.attr('href'),
        quant: num,
        prev: origin.attr('href') + chapter.next().val(),
        next: origin.attr('href') + chapter.prev().val(),
        listPages: [...Array(num).keys()].map(i => url + '/' + String(i + 1) + '/'),
        img: '#picture',
        before() {
          $('body').contents().filter(() => this.nodeType === 3).remove();
        }
      };
    }
  };

  var tenmanga = {
    name: 'TenManga',
    url: /https?:\/\/(www.)?tenmanga.com\/chapter\/.+/,
    homepage: 'http://www.tenmanga.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const url = $('.sl-page:first option').get();
      const chapter = $('.sl-chap:first option:selected');
      return {
        title: $('.read-page  a:eq(2)').text().replace('»', '').trim(),
        series: $('.read-page a:eq(1)').attr('href'),
        quant: url.length,
        prev: chapter.next().val(),
        next: chapter.prev().val(),
        listPages: url.map(item => $(item).val()),
        img: '.manga_pic'
      };
    }
  };

  var thespectrum = {
    name: 'TheSpectrum',
    url: /https?:\/\/view.thespectrum.net\/.+/,
    homepage: 'http://www.thespectrum.net/',
    language: ['English'],
    category: 'manga',
    run() {
      const url = String(location.pathname) + '?' + String($('form').serialize().substring(0, $('form').serialize().lastIndexOf('=')));
      const num = $('.selectpage option').length;
      const chapter = $('.selectchapter option:selected');
      return {
        title: $('.viewerLabel:eq(1)').text(),
        series: '#',
        quant: num,
        prev: String(location.pathname) + '?ch=' + String(chapter.prev().val()),
        next: String(location.pathname) + '?ch=' + String(chapter.next().val()),
        listPages: [...Array(num).keys()].map(i => url + '=' + String(i + 1)),
        img: '#imgContainer img'
      };
    }
  };

  var wpmanga = {
    name: ['MangaDeep'],
    url: /https?:\/\/(www.)?(mangadeep).com\/.+\/[0-9]+/,
    homepage: ['http://mangadeep.com/'],
    language: ['English'],
    category: 'manga',
    run() {
      const url = '/' + String(location.pathname.split('/')[1]) + '/' + String(location.pathname.split('/')[2]);
      const num = parseInt($('select.cbo_wpm_pag:first option:last').html(), 10);
      const chapter = $('.cbo_wpm_chp option:selected');
      const key = $('.cbo_wpm_chp').attr('onchange').replace(/location.href='/, '');
      return {
        title: $('.wpm_pag h1').text().trim(),
        series: $('h1.ttl a').attr('href'),
        quant: num,
        prev: key.replace(/'.+/, chapter.next().val()),
        next: key.replace(/'.+/, chapter.prev().val()),
        listPages: [...Array(num).keys()].map(i => url + '/' + String(i + 1) + '/'),
        img: 'img.manga-page , .prw > a img, .prw a img'
      };
    }
  };

  var funmanga = {
    name: 'Funmanga',
    url: /https?:\/\/(www.)?funmanga.com\/.+\/[0-9]+/,
    homepage: 'http://funmanga.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const chapter = $('.extra-buttons select:first option:selected');
      const url = $('.widget-heading select option').get().slice(1);
      return {
        title: $('title').text().trim(),
        series: $('h5.widget-heading a:first').attr('href'),
        quant: url.length,
        prev: chapter.next('option').val(),
        next: chapter.prev('option').val(),
        listPages: url.map(item => $(item).val()),
        img: '.img-responsive'
      };
    }
  };

  var unionmangas = {
    name: 'UnionMangas',
    url: /https?:\/\/(www.)?unionmangas.net\/leitor\/.+\/.+/,
    homepage: 'http://unionmangas.net/',
    language: ['Portuguese'],
    category: 'manga',
    run() {
      const origin = $('#topo h1 a');
      const chapter = $('#cap_manga1 option:selected');
      const src = $('.item img.real').get();
      return {
        title: origin.text(),
        series: origin.attr('href'),
        quant: $('.selectPage:first option').length,
        prev: chapter.prev().val(),
        next: chapter.next().val(),
        listImages: [$(src[0]).attr('src')].concat(src.splice(1).map(item => $(item).attr('data-lazy')))
      };
    }
  };

  var mangahost = {
    name: 'MangaHost',
    url: /https?:\/\/(www.)?mangahost.net\/manga\/.+\/.+/,
    homepage: 'https://mangahost.net/',
    language: ['Portuguese'],
    category: 'manga',
    run() {
      const url = location.href + (location.href.lastIndexOf('/') !== location.href.length - 1 ? '/' : '');
      const chapter = $('.viewerChapter:first option:selected');
      const num = parseInt($('.viewerPage:first option:last').html(), 10);
      const manga = {
        title: $('.breadcrumb li:eq(3)').text().trim(),
        series: $('.breadcrumb li:eq(2) a').attr('href'),
        quant: num,
        prev: chapter.next().val(),
        next: chapter.prev().val(),
        img: '.image-content img'
      };
      if ($('.read-slideshow img').get().length === 0) {
        manga.listPages = [...Array(num).keys()].map(i => url + (i + 1));
      } else {
        manga.listImages = $('.read-slideshow img').get().map(item => $(item).attr('src'));
      }
      return manga;
    }
  };

  var hocvien = {
    name: 'Hoc Vien Truyen Tranh',
    url: /https?:\/\/(www.)?hocvientruyentranh.com\/chapter\/.+\/.+/,
    homepage: 'http://hocvientruyentranh.com/',
    language: ['Vietnamese'],
    category: 'manga',
    run() {
      const src = $('.manga-container img').get();
      return {
        title: $('.chapters-dropdown option:selected').text().trim(),
        series: $('.theNavi a').attr('href'),
        quant: src.length,
        prev: $('.top-nav a:first').attr('href'),
        next: $('.top-nav a:last').attr('href'),
        listImages: src.map(item => $(item).attr('src'))
      };
    }
  };

  var jaiminisbox = {
    name: 'JaiminisBox',
    url: /https?:\/\/(www.)?jaiminisbox.com\/reader\/read\/.+/,
    homepage: 'https://jaiminisbox.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const chapter = $('.topbar_left .dropdown_parent:last ul li a');
      return {
        title: $('title').text().trim(),
        series: $('div.tbtitle div.text a:first').attr('href'),
        quant: W.pages.length,
        prev: chapter.eq(chapter.index(chapter.filter('[href*=\'' + String(location.pathname.replace(/page.+/, '')) + '\']')) + 1).attr('href'),
        next: chapter.eq(chapter.index(chapter.filter('[href*=\'' + String(location.pathname.replace(/page.+/, '')) + '\']')) - 1).attr('href'),
        listImages: W.pages.map(i => i.url)
      };
    }
  };

  var mangadex = {
    name: 'MangaDex',
    url: /https?:\/\/(www.)?mangadex.org\/chapter\/.+(\/.+)?/,
    homepage: 'https://mangadex.com/',
    language: ['English'],
    category: 'manga',
    run() {
      const text = $('script:last').text();
      const server = text.match(/var server = '(.+)';/)[1];
      const dataUrl = text.match(/var dataurl = '(.+)';/)[1];
      const start = text.indexOf('var page_array = ') + 18;
      const cut = text.substring(start);
      const end = cut.indexOf(';') - 2;
      const pageArray = cut.substring(0, end).trim().replace(/'/g, '"');
      const pages = JSON.parse('[' + String(pageArray) + ']');
      const chapter = $('#jump_chapter option:selected');
      return {
        title: $('title').text().replace(' - MangaDex', ''),
        series: $('span[title] + a').attr('href'),
        quant: pages.length,
        prev: '/chapter/' + String(chapter.next().val()),
        next: '/chapter/' + String(chapter.prev().val()),
        listImages: pages.map(i => String(server + dataUrl) + '/' + String(i))
      };
    }
  };

  var hatigarmscans = {
    name: 'HatigarmScans',
    url: /https?:\/\/(www.)?hatigarmscans.net\/manga\/.+\/.+(\/[0-9]*)?/,
    homepage: 'https://www.hatigarmscans.net//',
    language: ['English'],
    category: 'manga',
    run() {
      const src = $('.scan-page').attr('src');
      const url = src.substring(0, src.lastIndexOf('/') + 1);
      return {
        title: W.title.replace(/ - Page .+/, '').trim(),
        series: W.base_url.substring(0, W.base_url.lastIndexOf('/') + 1),
        quant: W.pages.length,
        prev: W.next_chapter,
        next: W.prev_chapter,
        listImages: W.pages.map(i => url + i.page_image)
      };
    }
  };

  var sites = [batoto, comicastle, dysnatyscans, eatmanga, egscans, foolslide, kissmanga, mangadoom, mangafox, mangago, mangahere, mangainn, mangalyght, mangapark, mangareader, mangastream, mangatown, ninemanga, readmangatoday, senmanga, tenmanga, thespectrum, wpmanga, funmanga, unionmangas, mangahost, hocvien, jaiminisbox, mangadex, hatigarmscans];

  start(sites);

}());