From 5a81fae7d533a7b209fb7b6791dafe03e6c92f1c Mon Sep 17 00:00:00 2001 From: Abraham Williams <4braham@gmail.com> Date: Sat, 2 Mar 2024 16:03:21 -0600 Subject: [PATCH 1/4] Update marked v10 --- package-lock.json | 16 ++++++++-------- package.json | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/package-lock.json b/package-lock.json index fd3e0bba62..845bbaef51 100644 --- a/package-lock.json +++ b/package-lock.json @@ -35,7 +35,7 @@ "@vaadin/router": "^1.7.5", "firebase": "^10.8.1", "lit": "^2.8.0", - "marked": "^9.1.6", + "marked": "^10.0.0", "marked-gfm-heading-id": "^3.1.3", "pwa-helpers": "^0.9.1", "register-service-worker": "^1.7.2", @@ -16657,14 +16657,14 @@ } }, "node_modules/marked": { - "version": "9.1.6", - "resolved": "https://registry.npmjs.org/marked/-/marked-9.1.6.tgz", - "integrity": "sha512-jcByLnIFkd5gSXZmjNvS1TlmRhCXZjIzHYlaGkPlLIekG55JDR2Z4va9tZwCiP+/RDERiNhMOFu01xd6O5ct1Q==", + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-10.0.0.tgz", + "integrity": "sha512-YiGcYcWj50YrwBgNzFoYhQ1hT6GmQbFG8SksnYJX1z4BXTHSOrz1GB5/Jm2yQvMg4nN1FHP4M6r03R10KrVUiA==", "bin": { "marked": "bin/marked.js" }, "engines": { - "node": ">= 16" + "node": ">= 18" } }, "node_modules/marked-gfm-heading-id": { @@ -33582,9 +33582,9 @@ "dev": true }, "marked": { - "version": "9.1.6", - "resolved": "https://registry.npmjs.org/marked/-/marked-9.1.6.tgz", - "integrity": "sha512-jcByLnIFkd5gSXZmjNvS1TlmRhCXZjIzHYlaGkPlLIekG55JDR2Z4va9tZwCiP+/RDERiNhMOFu01xd6O5ct1Q==" + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-10.0.0.tgz", + "integrity": "sha512-YiGcYcWj50YrwBgNzFoYhQ1hT6GmQbFG8SksnYJX1z4BXTHSOrz1GB5/Jm2yQvMg4nN1FHP4M6r03R10KrVUiA==" }, "marked-gfm-heading-id": { "version": "3.1.3", diff --git a/package.json b/package.json index db271fafc6..99b8a6b3f2 100644 --- a/package.json +++ b/package.json @@ -61,7 +61,7 @@ "@vaadin/router": "^1.7.5", "firebase": "^10.8.1", "lit": "^2.8.0", - "marked": "^9.1.6", + "marked": "^10.0.0", "marked-gfm-heading-id": "^3.1.3", "pwa-helpers": "^0.9.1", "register-service-worker": "^1.7.2", From 8801ff9837cb95b1b91e81cbab152f11d5cd22da Mon Sep 17 00:00:00 2001 From: Abraham Williams <4braham@gmail.com> Date: Sat, 2 Mar 2024 16:05:04 -0600 Subject: [PATCH 2/4] Update marked v11 --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 845bbaef51..8a6682b1cd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -35,7 +35,7 @@ "@vaadin/router": "^1.7.5", "firebase": "^10.8.1", "lit": "^2.8.0", - "marked": "^10.0.0", + "marked": "^11.0.0", "marked-gfm-heading-id": "^3.1.3", "pwa-helpers": "^0.9.1", "register-service-worker": "^1.7.2", @@ -16657,9 +16657,9 @@ } }, "node_modules/marked": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-10.0.0.tgz", - "integrity": "sha512-YiGcYcWj50YrwBgNzFoYhQ1hT6GmQbFG8SksnYJX1z4BXTHSOrz1GB5/Jm2yQvMg4nN1FHP4M6r03R10KrVUiA==", + "version": "11.2.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-11.2.0.tgz", + "integrity": "sha512-HR0m3bvu0jAPYiIvLUUQtdg1g6D247//lvcekpHO1WMvbwDlwSkZAX9Lw4F4YHE1T0HaaNve0tuAWuV1UJ6vtw==", "bin": { "marked": "bin/marked.js" }, @@ -33582,9 +33582,9 @@ "dev": true }, "marked": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-10.0.0.tgz", - "integrity": "sha512-YiGcYcWj50YrwBgNzFoYhQ1hT6GmQbFG8SksnYJX1z4BXTHSOrz1GB5/Jm2yQvMg4nN1FHP4M6r03R10KrVUiA==" + "version": "11.2.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-11.2.0.tgz", + "integrity": "sha512-HR0m3bvu0jAPYiIvLUUQtdg1g6D247//lvcekpHO1WMvbwDlwSkZAX9Lw4F4YHE1T0HaaNve0tuAWuV1UJ6vtw==" }, "marked-gfm-heading-id": { "version": "3.1.3", diff --git a/package.json b/package.json index 99b8a6b3f2..65d2857f2f 100644 --- a/package.json +++ b/package.json @@ -61,7 +61,7 @@ "@vaadin/router": "^1.7.5", "firebase": "^10.8.1", "lit": "^2.8.0", - "marked": "^10.0.0", + "marked": "^11.0.0", "marked-gfm-heading-id": "^3.1.3", "pwa-helpers": "^0.9.1", "register-service-worker": "^1.7.2", From 30bd1b67aa329d479c351214e8d0f3f119fbeaf5 Mon Sep 17 00:00:00 2001 From: Abraham Williams <4braham@gmail.com> Date: Sat, 2 Mar 2024 16:11:30 -0600 Subject: [PATCH 3/4] Override type --- src/components/markdown/base.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/markdown/base.ts b/src/components/markdown/base.ts index a84837f981..9b7d061dd1 100644 --- a/src/components/markdown/base.ts +++ b/src/components/markdown/base.ts @@ -17,7 +17,8 @@ export class Markdown extends ThemedElement { get document(): DocumentFragment { const template = document.createElement('template'); - template.innerHTML = marked.parse(this.content); + // Override type as no async extensions are in use + template.innerHTML = marked.parse(this.content) as string; if (hasUnsupportedTags(template.content)) { console.warn(`Invalid Markedown contains some of the following tags ${unsupportedHtmlTags}`); // TODO: Enable From 2552d729077a7bfe5da176afda0422d87fee6fed Mon Sep 17 00:00:00 2001 From: Abraham Williams <4braham@gmail.com> Date: Sat, 2 Mar 2024 16:12:20 -0600 Subject: [PATCH 4/4] Update marked v12 --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 8a6682b1cd..1458b67254 100644 --- a/package-lock.json +++ b/package-lock.json @@ -35,7 +35,7 @@ "@vaadin/router": "^1.7.5", "firebase": "^10.8.1", "lit": "^2.8.0", - "marked": "^11.0.0", + "marked": "^12.0.0", "marked-gfm-heading-id": "^3.1.3", "pwa-helpers": "^0.9.1", "register-service-worker": "^1.7.2", @@ -16657,9 +16657,9 @@ } }, "node_modules/marked": { - "version": "11.2.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-11.2.0.tgz", - "integrity": "sha512-HR0m3bvu0jAPYiIvLUUQtdg1g6D247//lvcekpHO1WMvbwDlwSkZAX9Lw4F4YHE1T0HaaNve0tuAWuV1UJ6vtw==", + "version": "12.0.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-12.0.0.tgz", + "integrity": "sha512-Vkwtq9rLqXryZnWaQc86+FHLC6tr/fycMfYAhiOIXkrNmeGAyhSxjqu0Rs1i0bBqw5u0S7+lV9fdH2ZSVaoa0w==", "bin": { "marked": "bin/marked.js" }, @@ -33582,9 +33582,9 @@ "dev": true }, "marked": { - "version": "11.2.0", - "resolved": "https://registry.npmjs.org/marked/-/marked-11.2.0.tgz", - "integrity": "sha512-HR0m3bvu0jAPYiIvLUUQtdg1g6D247//lvcekpHO1WMvbwDlwSkZAX9Lw4F4YHE1T0HaaNve0tuAWuV1UJ6vtw==" + "version": "12.0.0", + "resolved": "https://registry.npmjs.org/marked/-/marked-12.0.0.tgz", + "integrity": "sha512-Vkwtq9rLqXryZnWaQc86+FHLC6tr/fycMfYAhiOIXkrNmeGAyhSxjqu0Rs1i0bBqw5u0S7+lV9fdH2ZSVaoa0w==" }, "marked-gfm-heading-id": { "version": "3.1.3", diff --git a/package.json b/package.json index 65d2857f2f..616f0dbd84 100644 --- a/package.json +++ b/package.json @@ -61,7 +61,7 @@ "@vaadin/router": "^1.7.5", "firebase": "^10.8.1", "lit": "^2.8.0", - "marked": "^11.0.0", + "marked": "^12.0.0", "marked-gfm-heading-id": "^3.1.3", "pwa-helpers": "^0.9.1", "register-service-worker": "^1.7.2",