feat(功能): 增加笔记重命名和导出功能- 在笔记列表和预览页面添加重命名功能

- 实现笔记内容自动保存机制
-增加笔记导出为 Markdown 文件的功能
- 优化后端接口,支持更新笔记标题
This commit is contained in:
2025-07-31 10:16:49 +08:00
parent 2f9e68c636
commit e0a99235ec
7 changed files with 230 additions and 34 deletions

View File

@@ -74,9 +74,25 @@ export const register = (data) => {
headers: {
'Content-Type': 'multipart/form-data'
}
})
}
// 更新分组名称
export const updateGroupingName = (id, newName) => {
return axiosApi.put(`/api/groupings/${id}`, { grouping: newName });
}
// 更新Markdown文件标题
export const updateMarkdownTitle = (id, newTitle) => {
return axiosApi.put(`/api/markdown/${id}/title`, newTitle, {
headers: {
'Content-Type': 'text/plain'
}
});
}