From e831450f6f629a7bc17a5699d8d1e0d9c691cc60 Mon Sep 17 00:00:00 2001 From: Tilman Vatteroth Date: Mon, 24 Oct 2022 20:48:28 +0200 Subject: [PATCH] fix(deps): Replace deprecated packages with @hedgedoc/markdown-it-plugins Signed-off-by: Renovate Bot Signed-off-by: Tilman Vatteroth --- package.json | 3 +-- .../generic-syntax-markdown-extension.ts | 2 +- .../task-list/task-list-markdown-extension.ts | 4 ++-- yarn.lock | 20 +++++-------------- 4 files changed, 9 insertions(+), 20 deletions(-) diff --git a/package.json b/package.json index 0fd0aecc5..80bd926da 100644 --- a/package.json +++ b/package.json @@ -46,8 +46,7 @@ "@codemirror/view": "6.4.0", "@fontsource/source-sans-pro": "4.5.11", "@hedgedoc/html-to-react": "1.4.5", - "@hedgedoc/markdown-it-image-size": "2.0.2", - "@hedgedoc/markdown-it-task-lists": "2.0.1", + "@hedgedoc/markdown-it-plugins": "1.0.0", "@hedgedoc/realtime": "0.3.0", "@hpcc-js/wasm": "1.17.1", "@mrdrogdrog/optional": "1.0.0", diff --git a/src/components/markdown-renderer/extensions/generic-syntax-markdown-extension.ts b/src/components/markdown-renderer/extensions/generic-syntax-markdown-extension.ts index 3ea349a44..ad7b3e8f1 100644 --- a/src/components/markdown-renderer/extensions/generic-syntax-markdown-extension.ts +++ b/src/components/markdown-renderer/extensions/generic-syntax-markdown-extension.ts @@ -13,7 +13,7 @@ import superscript from 'markdown-it-sup' import inserted from 'markdown-it-ins' import marked from 'markdown-it-mark' import footnote from 'markdown-it-footnote' -import { imageSize } from '@hedgedoc/markdown-it-image-size' +import { imageSize } from '@hedgedoc/markdown-it-plugins' /** * Adds some common markdown syntaxes to the markdown rendering. diff --git a/src/extensions/extra-integrations/task-list/task-list-markdown-extension.ts b/src/extensions/extra-integrations/task-list/task-list-markdown-extension.ts index 7e08c2acd..9c609217b 100644 --- a/src/extensions/extra-integrations/task-list/task-list-markdown-extension.ts +++ b/src/extensions/extra-integrations/task-list/task-list-markdown-extension.ts @@ -6,16 +6,16 @@ import type MarkdownIt from 'markdown-it' import { TaskListReplacer } from './task-list-replacer' -import markdownItTaskLists from '@hedgedoc/markdown-it-task-lists' import type { ComponentReplacer } from '../../../components/markdown-renderer/replace-components/component-replacer' import { MarkdownRendererExtension } from '../../../components/markdown-renderer/extensions/base/markdown-renderer-extension' +import { tasksLists } from '@hedgedoc/markdown-it-plugins' /** * Adds support for interactive checkbox lists to the markdown rendering using the github checklist syntax. */ export class TaskListMarkdownExtension extends MarkdownRendererExtension { public configureMarkdownIt(markdownIt: MarkdownIt): void { - markdownItTaskLists(markdownIt, { + tasksLists(markdownIt, { enabled: true, label: true, lineNumber: true diff --git a/yarn.lock b/yarn.lock index 4b3ba6466..7b99e2e31 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1891,21 +1891,12 @@ __metadata: languageName: node linkType: hard -"@hedgedoc/markdown-it-image-size@npm:2.0.2": - version: 2.0.2 - resolution: "@hedgedoc/markdown-it-image-size@npm:2.0.2" +"@hedgedoc/markdown-it-plugins@npm:1.0.0": + version: 1.0.0 + resolution: "@hedgedoc/markdown-it-plugins@npm:1.0.0" peerDependencies: markdown-it: ">=12" - checksum: 9b27c453da07256ce884040e9ded7a18d400eb318f370d97b563efba28d015e8223561d90ff6670730451924a625f2ecaa1d5a20087f3c7fa728f646dc6fce5b - languageName: node - linkType: hard - -"@hedgedoc/markdown-it-task-lists@npm:2.0.1": - version: 2.0.1 - resolution: "@hedgedoc/markdown-it-task-lists@npm:2.0.1" - peerDependencies: - markdown-it: ">=12" - checksum: 356fbca24538d99100317faf57d13d5adab4c13906374aaf3d2c3e505aa22d5efa817cf1058081d209e3423aaa8b4f811320d622717f640542e0182e0c98b624 + checksum: d8536d548d370d7c81a67fbf666d3e2bcedd5774fd933f3e1a3f432b7d2007b5d7c1790685a33e5a443d66648d5d0e8269c3e507d367c247b821679deba89407 languageName: node linkType: hard @@ -1924,8 +1915,7 @@ __metadata: "@codemirror/view": 6.4.0 "@fontsource/source-sans-pro": 4.5.11 "@hedgedoc/html-to-react": 1.4.5 - "@hedgedoc/markdown-it-image-size": 2.0.2 - "@hedgedoc/markdown-it-task-lists": 2.0.1 + "@hedgedoc/markdown-it-plugins": 1.0.0 "@hedgedoc/realtime": 0.3.0 "@hpcc-js/wasm": 1.17.1 "@mrdrogdrog/optional": 1.0.0