\
- (1) Higher compression level can get smaller file without lossing any data, but may takes more time. If you have a decent CPU you can set it higher, and if you\'re using macOS set it to at least 1.\
+ (1) 更高的压缩级别可以在不损失数据的情况下生成更小的文件,但可能需要更多时间。如果 CPU 性能不错,可以设置得更高;如果你使用 macOS,请至少设置为 1。\
\
\
- (2) This may reduce memory usage but some decompress softwares may not support the Zip file. See JSZip Docs for more info.\
+ (2) 这可能减少内存占用,但某些解压软件可能不支持此 Zip 文件。更多信息请参阅 JSZip 文档。\
\
\
- (3) Enable these option will never let you to load from regular image server (or say force loaded from H@H). This may save your image viewing limits (See wiki), but may also cause some download problems, especially if your network cannot connect to specific H@H node.\
+ (3) 启用这些选项后,将无法从普通图片服务器加载图片(即强制从 H@H 加载)。这可能节省图片查看额度 (查看 Wiki),但也可能导致下载问题,尤其是网络无法连接到指定 H@H 节点时。\
\
\
- (4) If enabled you can save larger Zip files (probably ~1GB).\
+ (4) 启用后可以保存更大的 Zip 文件(可能约 1GB)。\
\
\
- (5) If enabled the script will play slient music to avoid downloading freeze when page is in background (See issue). Only needed if you have the problem, because the audio-playing icon maybe annoying.\
+ (5) 启用后,脚本会在页面处于后台时播放静音音乐以避免下载暂停 (查看 Issue)。只有遇到此问题时才需要启用,因为音频播放图标可能很烦人。\
\
\
- (6) Comic book archive is a file type to archive comic images, you can open it with some comic viewer like CDisplay/CDisplayEX, or just extract it as a Zip file. To keep the order of images, you can also enable numbering images.\
+ (6) 漫画书归档是一种用于归档漫画图片的文件类型,可以使用 CDisplay/CDisplayEX 等漫画阅读器打开,也可以直接解压为 Zip 文件。若要保持图片顺序,还可以启用图片编号。\
\
\
- (7) If you cannot original images, but you\'ve already logged in and your account is not blocked or used up your limits, it may caused by your cookies is not sent to the server. This feature may helps you to pass your current cookies to the download request, but please enable it ONLY if you cannot download any original images.\
+ (7) 如果无法下载原图,但已经登录且账号未被封禁或额度未用尽,可能是 Cookie 没有发送到服务器。此功能可以将当前 Cookie 传递给下载请求,但请仅在无法下载任何原图时启用。\
\
\
- (8) If you have already logged in, but the script detects that you\'re not logged in, you can enable this to skip login check. Please note that if you are not logged in actually, the script will not work as expect.\
+ (8) 如果已经登录,但脚本检测到未登录,可以启用此选项跳过登录检查。请注意,如果实际上未登录,脚本将无法正常工作。\
\
\
- (9) If you have problem to download on the same site, like account session is misleading, you can force redirect original download link to another domain. Pass cookies manually may be needed.\
+ (9) 如果在同一站点下载时遇到问题(例如账号会话状态异常),可以强制将原图下载链接重定向到另一个域名。可能需要手动传递 Cookie。\
\
\
- (10) Check the image file SHA-1 after downloading, in case the server (mostly H@H server) may return a broken file, or network miscellaneous errors.\
+ (10) 下载后检查图片文件的 SHA-1,以防服务器(尤其是 H@H 服务器)返回损坏文件或发生网络异常。\
\
\
- (11) If enabled it may fix the serialized request on latest Chrome (with Manifest V3 extension) + Tampermonkey 5.3.2+, but downloading progress, speed detect and timed out abort may be broken (See issue).\
+ (11) 启用后可能修复最新版 Chrome(Manifest V3 扩展)+ Tampermonkey 5.3.2+ 的序列化请求问题,但下载进度、速度检测和超时中止可能失效 (查看 Issue)。\
\
\
\
\
\
';
document.body.appendChild(ehDownloadSettingPanel);
@@ -14998,12 +14998,12 @@ function showSettings() {
if (setting['patch-tm-serialized-gm-xhr'] && !serializedRequestPatched) {
serializedRequestPatched = patchTMSerializedGMXhr();
if (!serializedRequestPatched) {
- alert('Patch GM_xhr failed, you may need a hard reload to take effect.')
+ alert('GM_xhr 补丁失败,可能需要硬刷新(Ctrl+Shift+R / Cmd+Shift+R)才能生效。')
}
} else if (!setting['patch-tm-serialized-gm-xhr'] && serializedRequestPatched) {
serializedRequestPatched = !revertTMSerializedGMXhrPatch();
if (serializedRequestPatched) {
- alert('Revert GM_xhr patch failed, you may need a hard reload to take effect.')
+ alert('还原 GM_xhr 补丁失败,可能需要硬刷新(Ctrl+Shift+R / Cmd+Shift+R)才能生效。')
}
}
@@ -15061,7 +15061,7 @@ function loadImageLimits(forced, host){
return showImageLimits();
}
- console.log('[EHD] Request Image Limits From ' + host);
+ console.log('[EHD] 从 ' + host + ' 请求图片额度');
GM_xmlhttpRequest({
method: 'GET',
@@ -15107,7 +15107,7 @@ function showImageLimits(){
}).sort().map(function(elem){
var curData = JSON.parse(localStorage.getItem(elem));
if (curData.suspended) {
- return '! Account Suspended !';
+ return '! 账号已暂停 !';
}
if (curData.ipBanned) {
return '! IP Banned !';
@@ -15118,7 +15118,7 @@ function showImageLimits(){
return curData.cur + '/' + curData.total;
});
- ehDownloadBox.getElementsByClassName('ehD-box-limit')[0].innerHTML = ' | Image Limits: ' + list.join('; ') + '';
+ ehDownloadBox.getElementsByClassName('ehD-box-limit')[0].innerHTML = ' | 图片额度:' + list.join('; ') + '';
}
function getFileSizeAndLength() {
@@ -15175,8 +15175,8 @@ function toggleFilenameConfirmInput(hide){
else if (!hide) {
extendNodes = document.createElement('div');
extendNodes.className = 'ehD-box-extend';
- extendNodes.innerHTML = '
' + ehDownloadArrow + '
' +
- '
' + ehDownloadArrow + '
';
+ extendNodes.innerHTML = '
' + ehDownloadArrow + '
' +
+ '
' + ehDownloadArrow + '
';
ehDownloadBox.appendChild(extendNodes);
dirName = getReplacedName(!setting['dir-name'] ? '{gid}_{token}' : setting['dir-name']);
@@ -15299,9 +15299,9 @@ function showPreCalcCost(){
target="_blank" \
title="' +
// (isUsingOriginal && isSourceNexus ? '...or ' + cost + ' if Source Nexus hath perk is not available.\n' : '') +
- (isUsingOriginal && !isUsingGP ? '...or ' + leastCost + ' + ' + gp + ' GP if you don\'t have enough viewing limits.\n' : '') +
- '1 point per 0.1 MB since August 2019, less than 0.1 MB will also be counted.\nDuring peak hours, downloading original images will cost GPs.\nFor gallery uploaded 1 year ago, downloading original images will cost GPs since July 2023.\nThe GP cost is the same as resetting viewing limits.\nEstimated GP cost is a bit more than using offical archive download, in case the sum of each images will be larger than the packed.">'
- + 'Estimated Costs: ' + (/* isSourceNexus ? leastCost : */ cost || '???') + '';
+ (isUsingOriginal && !isUsingGP ? '...或在浏览额度不足时,改为消耗 ' + leastCost + ' + ' + gp + ' GP。\n' : '') +
+ '自 2019 年 8 月起,每 0.1 MB 计 1 点,少于 0.1 MB 也会计入。\n高峰期下载原图将消耗 GP。\n自 2023 年 7 月起,上传满 1 年的画廊下载原图将消耗 GP。\nGP 消耗量与重置浏览额度相同。\n估算的 GP 消耗量比官方压缩包下载略多,因为单张图片之和可能比压缩后的文件更大。">'
+ + '预计消耗:' + (/* isSourceNexus ? leastCost : */ cost || '???') + '';
}
// EHD Box, thanks to JingJang@GitHub, source: https://github.com/JingJang/E-Hentai-Downloader
@@ -15318,13 +15318,13 @@ ehDownloadBox.appendChild(ehDownloadStylesheet);
var extraHint;
if (isInPeakHours() && !isRecentGallery()) {
extraHint = document.createElement('a');
- extraHint.setAttribute('title', 'Peak Hours: It\'s in peak hours now, during peak hours, downloading original images of 90 days ago cost GPs');
+ extraHint.setAttribute('title', '高峰时段:当前处于高峰时段,在高峰时段下载 90 天前画廊的原图将消耗 GP');
extraHint.textContent = '[P]';
ehDownloadBoxTitle.appendChild(extraHint);
}
if (isAncientGallery()) {
extraHint = document.createElement('a');
- extraHint.setAttribute('title', 'Ancient Gallery: Downloading original images of 1 year ago cost GPs');
+ extraHint.setAttribute('title', '老旧画廊:下载 1 年前画廊的原图将消耗 GP');
extraHint.textContent = '[A]';
ehDownloadBoxTitle.appendChild(extraHint);
}
@@ -15333,19 +15333,19 @@ var ehDownloadArrow = ' 0 && !confirm('There are ' + torrentsCount + ' torrent(s) available for this gallery. You can download the torrent(s) to get a stable and controllable download experience without spending your image limits, or even get bonus content.\n\nContinue downloading with E-Hentai Downloader (Yes) or use torrent(s) directly (No)?\n(You can disable this notification in the Settings)')) {
+ if (!setting['ignore-torrent'] && torrentsCount > 0 && !confirm('此画廊有 ' + torrentsCount + ' 个种子文件可用。下载种子文件可获得稳定且可控的下载体验,无需消耗图片额度,甚至能获得额外内容。\n\n继续使用 E-Hentai Downloader 下载(是)或直接使用种子(否)?\n(可在 设置 中关闭此提示)')) {
return torrentsNode.dispatchEvent(new MouseEvent('click'));
}
- if (!isTor && unsafeWindow.apiuid === -1 && !setting['force-as-login'] && !confirm('You are not logged in to E-Hentai Forums, so you can\'t download original images.\nIf you\'ve already logged in, please try logout and login again.\nContinue with resized images?')) return;
+ if (!isTor && unsafeWindow.apiuid === -1 && !setting['force-as-login'] && !confirm('你尚未登录 E-Hentai 论坛,因此无法下载原图。\n若已经登录,请尝试先登出再重新登录。\n是否继续下载重采样图片?')) return;
console.log('[EHD] Is Peak Hours >', isInPeakHours(), ' | Is Recent Gallery >', isRecentGallery(), ' | Is Ancient Gallery >', isAncientGallery(), ' | Is Donator >', isDonator());
@@ -15357,11 +15357,11 @@ ehDownloadAction.addEventListener('click', function(event){
// !isSourceNexusEnabled()
) {
if (isAncientGallery() && isDonator() < 1) {
- if (!confirm('The gallery has been uploaded for a very long time, downloading original images will cost your GPs instead of viewing limits.\nYou can download resized images or disable this notification in script\'s settings.\n\nContinue downloading with original images?')) {
+ if (!confirm('此画廊上传时间已久,下载原图将消耗你的 GP 而非浏览额度。\n你可以下载重采样图片,或在脚本设置中关闭此提示。\n\n是否继续下载原图?')) {
return;
}
} else {
- if (!confirm('It\'s peak hours now, downloading original images will cost your GPs instead of viewing limits.\nYou can download resized images or disable this notification in script\'s settings.\n\nContinue downloading with original images?')) {
+ if (!confirm('当前处于高峰时段,下载原图将消耗你的 GP 而非浏览额度。\n你可以下载重采样图片,或在脚本设置中关闭此提示。\n\n是否继续下载原图?')) {
return;
}
}
@@ -15376,7 +15376,7 @@ ehDownloadAction.addEventListener('click', function(event){
}
var finalLimits = +(limitsData.cur || 0) + totalLimitsCost;
if (finalLimits > limitsData.total) {
- if (!confirm('You may used up your image limits or will run it out, downloading images exceed your limits will cost GPs instead, or credits if you run out of GPs.\nUsed + Estimated = ' + (limitsData.cur || 0) + ' + ' + totalLimitsCost + ' = ' + finalLimits + ' > ' + limitsData.total + '\n\nContinue downloading?')) {
+ if (!confirm('你可能已用尽或即将用尽图片额度,超额下载将改为消耗 GP;若 GP 不足则会消耗 credits。\n已用 + 预估 = ' + (limitsData.cur || 0) + ' + ' + totalLimitsCost + ' = ' + finalLimits + ' > ' + limitsData.total + '\n\n是否继续下载?')) {
return;
}
}
@@ -15390,17 +15390,17 @@ ehDownloadBox.appendChild(ehDownloadAction);
var ehDownloadNumberInput = document.createElement('div');
ehDownloadNumberInput.className = 'g2';
-ehDownloadNumberInput.innerHTML = ehDownloadArrow + ' ';
+ehDownloadNumberInput.innerHTML = ehDownloadArrow + ' ';
ehDownloadBox.appendChild(ehDownloadNumberInput);
var ehDownloadRange = document.createElement('div');
ehDownloadRange.className = 'g2';
-ehDownloadRange.innerHTML = ehDownloadArrow + ' ';
+ehDownloadRange.innerHTML = ehDownloadArrow + ' ';
ehDownloadBox.appendChild(ehDownloadRange);
var ehDownloadSetting = document.createElement('div');
ehDownloadSetting.className = 'g2';
-ehDownloadSetting.innerHTML = ehDownloadArrow + ' Settings';
+ehDownloadSetting.innerHTML = ehDownloadArrow + ' 设置';
ehDownloadSetting.addEventListener('click', function(event){
event.preventDefault();
showSettings();
@@ -15422,11 +15422,11 @@ ehDownloadStatus.addEventListener('click', function(event){
var ehDownloadPauseBtn = document.createElement('button');
ehDownloadPauseBtn.className = 'ehD-pause';
-ehDownloadPauseBtn.textContent ='Pause';
+ehDownloadPauseBtn.textContent ='暂停';
ehDownloadPauseBtn.addEventListener('click', function(event){
if (!isPausing) {
isPausing = true;
- ehDownloadPauseBtn.textContent = 'Resume';
+ ehDownloadPauseBtn.textContent = '继续';
if (setting['force-pause']) {
// waiting Tampermonkey for transfering string to ArrayBuffer, it may stuck for a second
@@ -15436,7 +15436,7 @@ ehDownloadPauseBtn.addEventListener('click', function(event){
if (imageData[i] === 'Fetching' && retryCount[i] < (setting['retry-count'] !== undefined ? setting['retry-count'] : 3)) {
var elem = progressTable.querySelector('tr[data-index="' + i + '"] .ehD-pt-status-text');
- if (elem) elem.textContent = 'Force Paused';
+ if (elem) elem.textContent = '已强制暂停';
elem = progressTable.querySelector('tr[data-index="' + i + '"] .ehD-pt-progress-text');
if (elem) elem.textContent = '';
@@ -15457,7 +15457,7 @@ ehDownloadPauseBtn.addEventListener('click', function(event){
}
else {
isPausing = false;
- ehDownloadPauseBtn.textContent = setting['force-pause'] ? 'Pause (Downloading images will be aborted)' : 'Pause (Downloading images will keep downloading)';
+ ehDownloadPauseBtn.textContent = setting['force-pause'] ? '暂停(将中止正在下载的图片)' : '暂停(正在下载的图片将继续下载)';
checkFailed();
}
@@ -15467,20 +15467,20 @@ window.addEventListener('focus', function(){
if (setting['status-in-title'] === 'blur') {
if (!needTitleStatus) return;
document.title = pretitle;
- needTitleStatus = false;
+ needTitle状态 = false;
}
});
window.addEventListener('blur', function(){
if (isDownloading && setting['status-in-title'] === 'blur') {
- needTitleStatus = true;
+ needTitle状态 = true;
document.title = '[' + (isPausing ? '❙❙' : downloadedCount < totalCount ? '↓ ' + downloadedCount + '/' + totalCount : totalCount === 0 ? '↓' : '√' ) + '] ' + pretitle;
}
});
var forceDownloadTips = document.createElement('div');
forceDownloadTips.className = 'ehD-force-download-tips';
-forceDownloadTips.innerHTML = 'If an error occured and script doesn\'t work, click here to force get your downloaded images.';
+forceDownloadTips.innerHTML = '若出现错误且脚本无法正常工作,点击 此处 以强制获取已下载的图片。';
forceDownloadTips.getElementsByTagName('a')[0].addEventListener('click', function(event){
// fixed permission denied on GreaseMonkey
event.preventDefault();
@@ -15489,7 +15489,7 @@ forceDownloadTips.getElementsByTagName('a')[0].addEventListener('click', functio
var closeTips = document.createElement('div');
closeTips.className = 'ehD-close-tips';
-closeTips.innerHTML = 'E-Hentai Downloader is still running, please don\'t close this tab until it finished downloading.
If any bug occured and the script doesn\'t work correctly, you can move your mouse pointer onto the progress box, and force to save downloaded images before you leave.';
+closeTips.innerHTML = 'E-Hentai Downloader 仍在运行中,请勿关闭此标签页,直到下载完成。
若出现 bug 且脚本无法正常工作,可将鼠标移至进度框上,在离开前强制保存已下载的图片。';
unsafeWindow.getzip = window.getzip = function(){
saveDownloaded(true);
@@ -15513,7 +15513,7 @@ window.onbeforeunload = unsafeWindow.onbeforeunload = function(){
document.body.removeChild(closeTips);
}, 100);
- return 'E-Hentai Downloader is still running, please don\'t close this tab until it finished downloading.';
+ return 'E-Hentai Downloader 仍在运行中,请勿关闭此标签页,直到下载完成。';
}
clearRubbish();
};