Skip to content

Commit

Permalink
feat: 添加统计思维导图文件数量展示
Browse files Browse the repository at this point in the history
  • Loading branch information
super456 committed Apr 26, 2024
1 parent a397f4c commit de95481
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions scripts/generateReadme.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,8 @@ function generateList(list) {
} <img alt="" height="16" src="https://img.shields.io/github/size/super456/FE-MindMap/${encodeURI(
item.path
)}" align="center" />](/${encodeURI(item.path)})
- 创建时间: ${item.createdTime}
- 更新时间: ${item.updateTime}`
- 💡创建时间: ${item.createdTime}
- 🛠️更新时间: ${item.updateTime}`
)
.join('\n')
}
Expand All @@ -125,6 +125,9 @@ try {

// 组装列表数据
const result = await Promise.all(getXmindList('xmind'))
// 统计数量
md += `🧮 **总计**: ${result.length} 个思维导图文件 🎉🥳` + MD_FOOTER

md += generateList(result)

// 组装 MD 尾部
Expand Down
2 changes: 1 addition & 1 deletion src/components/DropdownMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const handleClick = (filePath: string, fileName: string) => {
stroke-linecap="round"
/>
</svg>
切换知识图谱
切换知识图谱(总计 {{ data.length }} 个思维导图文件)
</button>
<Teleport to="body">
<div
Expand Down

0 comments on commit de95481

Please sign in to comment.