We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8a994b6 commit 6f41c14Copy full SHA for 6f41c14
.github/workflows/upload.yml
@@ -24,12 +24,16 @@ jobs:
24
.replace(/<p>/g, '')
25
.replace(/<\/p>/g, '\n')
26
.replace(/<br>/g, '\n')
27
- .replace(/<a class="[^"]*" href="([^"]*)">([^<]*)<\/a>/g, '<a href="$1">$2</a>')
+ // 简化所有链接,只保留 href 和文本内容
28
+ .replace(/<a[^>]*href="([^"]*)"[^>]*>([^<]*)<\/a>/g, '<a href="$1">$2</a>')
29
.replace(/<tt>([^<]*)<\/tt>/g, '$1')
30
.replace(/<strong>([^<]*)<\/strong>/g, '<b>$1</b>')
- .replace(/"/g, '') // 移除所有引号
31
- .replace(/\n{3,}/g, '\n\n') // 将多个换行符替换为两个
32
- .trim() // 移除首尾空白
+ // 移除所有引号和多余的空格
+ .replace(/"/g, '')
33
+ .replace(/\s+/g, ' ')
34
+ // 规范化换行符
35
+ .replace(/\n{3,}/g, '\n\n')
36
+ .trim()
37
return processedHtml
38
39
- name: 发送Telegram通知
0 commit comments