diff --git a/package-lock.json b/package-lock.json index d954233..73ec202 100644 --- a/package-lock.json +++ b/package-lock.json @@ -18,9 +18,7 @@ "flux": "^4.0.1", "formik": "^2.2.9", "html-react-parser": "^1.2.7", - "linkify-html": "^3.0.3", - "linkify-react": "^3.0.3", - "linkifyjs": "^3.0.3", + "linkifyjs": "^2.1.9", "matrix-js-sdk": "^12.4.1", "micromark": "^3.0.3", "micromark-extension-gfm": "^1.0.0", @@ -8707,6 +8705,12 @@ "integrity": "sha512-+az2gi/hvex7eLTMTlbRLOhH6P6WFdk2ITI8HJsaH2VqYO0I594zXSYEP+tf4FW+8Cy68ScDXoAsQdyQanv3sw==", "dev": true }, + "node_modules/jquery": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.0.tgz", + "integrity": "sha512-JVzAR/AjBvVt2BmYhxRCSYysDsPcssdmTFnzyLEts9qNwmjmu4JTAMYubEfwVOSwpQ1I1sKKFcxhZCI2buerfw==", + "peer": true + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -9110,27 +9114,15 @@ "node": ">= 4.0.0" } }, - "node_modules/linkify-html": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/linkify-html/-/linkify-html-3.0.3.tgz", - "integrity": "sha512-yqfeq9WNGXlk36ka8j862D70L2Ddh+wJkExaHsUJTNTL7D5tDFZbLpFrcHGa6Zy3t8Kk/1Edw7WUPyPV09zbXQ==", - "peerDependencies": { - "linkifyjs": "^3.0.0" - } - }, - "node_modules/linkify-react": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/linkify-react/-/linkify-react-3.0.3.tgz", - "integrity": "sha512-CdERZyocGB+2sHYKMKltAWy5TyelgocnMI7SU5vdT0ojtZd1u8sRuntXrxjA3tvgTirtLm2nD7gDdJFaVXvDAw==", - "peerDependencies": { - "linkifyjs": "^3.0.0", - "react": ">= 15.0.0" - } - }, "node_modules/linkifyjs": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/linkifyjs/-/linkifyjs-3.0.3.tgz", - "integrity": "sha512-ba5opS5wRHSbDC8VaiDdN14nPGm6LqyRsIPQZGG4qXV4scFdrPneT/uoZOaq9QAPBf6W9I9D/6tNSzWH//815Q==" + "version": "2.1.9", + "resolved": "https://registry.npmjs.org/linkifyjs/-/linkifyjs-2.1.9.tgz", + "integrity": "sha512-74ivurkK6WHvHFozVaGtQWV38FzBwSTGNmJolEgFp7QgR2bl6ArUWlvT4GcHKbPe1z3nWYi+VUdDZk16zDOVug==", + "peerDependencies": { + "jquery": ">= 1.11.0", + "react": ">= 0.14.0", + "react-dom": ">= 0.14.0" + } }, "node_modules/load-bmfont": { "version": "1.4.1", @@ -22648,6 +22640,12 @@ "integrity": "sha512-+az2gi/hvex7eLTMTlbRLOhH6P6WFdk2ITI8HJsaH2VqYO0I594zXSYEP+tf4FW+8Cy68ScDXoAsQdyQanv3sw==", "dev": true }, + "jquery": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.6.0.tgz", + "integrity": "sha512-JVzAR/AjBvVt2BmYhxRCSYysDsPcssdmTFnzyLEts9qNwmjmu4JTAMYubEfwVOSwpQ1I1sKKFcxhZCI2buerfw==", + "peer": true + }, "js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -23002,22 +23000,11 @@ "computed-style": "~0.1.3" } }, - "linkify-html": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/linkify-html/-/linkify-html-3.0.3.tgz", - "integrity": "sha512-yqfeq9WNGXlk36ka8j862D70L2Ddh+wJkExaHsUJTNTL7D5tDFZbLpFrcHGa6Zy3t8Kk/1Edw7WUPyPV09zbXQ==", - "requires": {} - }, - "linkify-react": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/linkify-react/-/linkify-react-3.0.3.tgz", - "integrity": "sha512-CdERZyocGB+2sHYKMKltAWy5TyelgocnMI7SU5vdT0ojtZd1u8sRuntXrxjA3tvgTirtLm2nD7gDdJFaVXvDAw==", - "requires": {} - }, "linkifyjs": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/linkifyjs/-/linkifyjs-3.0.3.tgz", - "integrity": "sha512-ba5opS5wRHSbDC8VaiDdN14nPGm6LqyRsIPQZGG4qXV4scFdrPneT/uoZOaq9QAPBf6W9I9D/6tNSzWH//815Q==" + "version": "2.1.9", + "resolved": "https://registry.npmjs.org/linkifyjs/-/linkifyjs-2.1.9.tgz", + "integrity": "sha512-74ivurkK6WHvHFozVaGtQWV38FzBwSTGNmJolEgFp7QgR2bl6ArUWlvT4GcHKbPe1z3nWYi+VUdDZk16zDOVug==", + "requires": {} }, "load-bmfont": { "version": "1.4.1", diff --git a/package.json b/package.json index 41c044e..d53eb98 100644 --- a/package.json +++ b/package.json @@ -24,9 +24,7 @@ "flux": "^4.0.1", "formik": "^2.2.9", "html-react-parser": "^1.2.7", - "linkify-html": "^3.0.3", - "linkify-react": "^3.0.3", - "linkifyjs": "^3.0.3", + "linkifyjs": "^2.1.9", "matrix-js-sdk": "^12.4.1", "micromark": "^3.0.3", "micromark-extension-gfm": "^1.0.0", diff --git a/src/app/molecules/message/Message.jsx b/src/app/molecules/message/Message.jsx index e67da74..4ab0983 100644 --- a/src/app/molecules/message/Message.jsx +++ b/src/app/molecules/message/Message.jsx @@ -3,7 +3,7 @@ import React, { useState, useRef } from 'react'; import PropTypes from 'prop-types'; import './Message.scss'; -import linkifyHtml from 'linkify-html'; +import linkifyHtml from 'linkifyjs/html'; import parse from 'html-react-parser'; import twemoji from 'twemoji'; import dateFormat from 'dateformat'; @@ -106,8 +106,8 @@ function MessageBody({ if (typeof body !== 'string') return