Skip to content

Commit

Permalink
fix(route): update chapter name style of sis001 article (#16633)
Browse files Browse the repository at this point in the history
* update chapter name style of sis001 article

* use h3 for chaper name
  • Loading branch information
keocheung authored Sep 5, 2024
1 parent 6243bb2 commit 05b6533
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/routes/sis001/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ async function getThread(item) {
.html()
?.replaceAll('\n', '')
.replaceAll(/\u3000{2}.+?(((?:<br>){2})|(&nbsp;))/g, (str) => `<p>${str.replaceAll('<br>', '')}</p>`)
.replaceAll(/<p>\u3000{6,}(.+?)<\/p>/g, '<h3 style="text-align:center;">$1</h3>')
.replaceAll('&nbsp;', '')
.replace(/^.+?((?:作者)|(?:<p>))/, '$1') + ($('.defaultpost .postattachlist').html() ?? '');
return item;
Expand Down

0 comments on commit 05b6533

Please sign in to comment.