(comments: Record<string, LineComment[]>)
| 42 | } |
| 43 | |
| 44 | function aggregate(comments: Record<string, LineComment[]>) { |
| 45 | return Object.keys(comments) |
| 46 | .flatMap((file) => comments[file] ?? []) |
| 47 | .slice() |
| 48 | .sort((a, b) => a.time - b.time) |
| 49 | } |
| 50 | |
| 51 | function cloneSelection(selection: SelectedLineRange): SelectedLineRange { |
| 52 | const next: SelectedLineRange = { |