doc: add comment about MarkdownPostProcessor behavior

This commit is contained in:
Kirill Gavrilov 2025-10-05 01:26:11 +03:00
parent 4ca783077d
commit f3ce484122

View file

@ -7,6 +7,11 @@ import { createTimecodedYouTubeLink, findYouTubeVideoId } from '../utils/youtube
let latestRequiredEnricher: TextTimecodeEnricher | null = null
let latestNoteBeingProcessed: string | null = null
/*
* From my observations, MarkdownPostProcessor:
* - gets called once for each paragraph in a note
* - doesn't get called again on subsequent switch to view-mode unless there was a change in paragraph
*/
export function turnRawTimecodesIntoClickableLinks(
root: HTMLElement,
ctx: MarkdownPostProcessorContext,