From f3ce48412217239f8ff52cb34743aa7374edafe6 Mon Sep 17 00:00:00 2001 From: Kirill Gavrilov Date: Sun, 5 Oct 2025 01:26:11 +0300 Subject: [PATCH] doc: add comment about `MarkdownPostProcessor` behavior --- src/ui/timecodes-md-post-processor.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ui/timecodes-md-post-processor.ts b/src/ui/timecodes-md-post-processor.ts index d5f6463..9cc7bc3 100644 --- a/src/ui/timecodes-md-post-processor.ts +++ b/src/ui/timecodes-md-post-processor.ts @@ -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,