fix: RSS 订阅数一列太窄,导致字看不清;链接有些行太宽,导致表格需要左右滑动; (#1576)

This commit is contained in:
tiezhudotwang 2023-09-15 10:27:36 +08:00 committed by GitHub
parent c99a873d97
commit d72e7cce9c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -58,16 +58,17 @@ async function getResultAndUpdateREADME() {
const getFeedsPubBtn = (feedLink, followCount) =>
`[<img src="https://img.shields.io/static/v1?label=follow&message=${followCount}&style=social&logo=rss">](https://feeds.pub/feed/${encodeURIComponent(feedLink)})`;
const newTable = table.map(row => {
const url = new URL(row[1])
return [
row[2] ? getFeedsPubBtn(row[2], row[4]) : '',
row[0].replace(/\|/g, '&#124;'),
row[1],
`[${url.protocol}//${url.host}/](${url.href})`,
row[3]
]
});
// update README
const tableContentInMD = markdownTable([['RSS 订阅数 <img width=110/> ', '简介', '链接', '标签'], ...newTable]);
const tableContentInMD = markdownTable([['<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; RSS 订阅数</p>', '简介', '链接', '标签'], ...newTable]);
const readmeContent = `
# 中文独立博客列表