From 27da1cd4b09452c22a7c60f5d78a1e2c7f87c226 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 9 Dec 2025 17:24:02 +0000 Subject: [PATCH 1/2] Initial plan From d6ad55cea54f6778108394e79f35b2acc4a338d5 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 9 Dec 2025 17:28:44 +0000 Subject: [PATCH 2/2] Fix unsafe type assertions in nestLists.ts Co-authored-by: stipsan <81981+stipsan@users.noreply.github.com> --- src/nestLists.ts | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/nestLists.ts b/src/nestLists.ts index bf7776f..1609e11 100644 --- a/src/nestLists.ts +++ b/src/nestLists.ts @@ -89,7 +89,7 @@ export function nestLists currentList.level) { const newList = listFromBlock(block, i, mode) - if (mode === 'html') { + if (currentList.mode === 'html' && newList.mode === 'html') { // Because HTML is kinda weird, nested lists needs to be nested within list items. // So while you would think that we could populate the parent list with a new sub-list, // we actually have to target the last list element (child) of the parent. @@ -97,9 +97,10 @@ export function nestLists