From 6dd0daa597a49775bca1fa9e5fec8cab1508a62c Mon Sep 17 00:00:00 2001 From: Huang Xin Date: Wed, 15 Oct 2025 00:01:23 +0800 Subject: [PATCH] txt: add chapter title pattern, closes #2232 (#2233) --- apps/readest-app/src/utils/txt.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/readest-app/src/utils/txt.ts b/apps/readest-app/src/utils/txt.ts index 7594cb09..8e6153a1 100644 --- a/apps/readest-app/src/utils/txt.ts +++ b/apps/readest-app/src/utils/txt.ts @@ -115,9 +115,10 @@ export class TxtToEpubConverter { [ String.raw`第[零〇一二三四五六七八九十0-9][零〇一二三四五六七八九十百千万0-9]*(?:[章卷节回讲篇封本册部话])(?:[::、  \(\)0-9]*[^\n-]{0,24})(?!\S)`, String.raw`(?:楔子|前言|简介|引言|序言|序章|总论|概论|后记)(?:[::  ][^\n-]{0,24})?(?!\S)`, + String.raw`chapter[\s.]*[0-9]+(?:[::.  ]+[^\n-]{0,50})?(?!\S)`, ].join('|') + ')', - 'gu', + 'gui', ), ); chapterRegexps.push(