* 删除文件的所有高亮数据 * @param filePath 文件路径
(filePath: string)
| 134 | * @param filePath 文件路径 |
| 135 | */ |
| 136 | async deleteFileHighlights(filePath: string): Promise<void> { |
| 137 | const storagePath = this.getStoragePathForFile(filePath); |
| 138 | |
| 139 | try { |
| 140 | await this.app.vault.adapter.remove(storagePath); |
| 141 | this.fileMappingStore.delete(filePath); |
| 142 | await this.saveFileMapping(); |
| 143 | } catch { |
| 144 | // 文件可能不存在,忽略错误 |
| 145 | } |
| 146 | } |
| 147 | |
| 148 | /** |
| 149 | * 处理文件重命名 |
nothing calls this directly
no test coverage detected