We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 425b014 commit ccdd39cCopy full SHA for ccdd39c
1 file changed
DownloadAllContent/DownloadAllContent.user.js
@@ -4,7 +4,7 @@
4
// @name:zh-TW 懶人小説下載器
5
// @name:ja 怠惰者小説ダウンロードツール
6
// @namespace hoothin
7
-// @version 1.09
+// @version 1.10
8
// @description Fetch and download main content on current page,provide special support for chinese novel
9
// @description:zh-CN 通用网站内容抓取工具,可批量抓取小说、论坛内容等并保存为TXT文档
10
// @description:zh-TW 通用網站內容抓取工具,可批量抓取小說、論壇內容等並保存為TXT文檔
@@ -164,6 +164,9 @@
164
for(let j=0;j<childNodes.length;j++){
165
let childNode=childNodes[j];
166
if(childNode.nodeType==3 && childNode.data && !/^\s*$/.test(childNode.data))hasText=true;
167
+ if(childNode.innerHTML){
168
+ childNode.innerHTML=childNode.innerHTML.replace(/\<\s*br\s*\>/gi,"\r\n");
169
+ }
170
if(childNode.textContent){
171
cStr+=childNode.textContent.replace(/ +/g," ").replace(/([^\r]|^)\n([^\r]|$)/g,"$1\r\n$2");
172
}
0 commit comments