img regex fix

This commit is contained in:
Martti Malmi 2023-08-09 15:12:45 +03:00
parent f9e5c60f5a
commit eb6fa247c9

View File

@ -7,7 +7,7 @@ import SafeImg from '../SafeImg';
import Embed from './index';
const Image: Embed = {
regex: /(https?:\/\/.*\.(?:png|jpg|jpeg|gif|svg|webp)(?:\?\S*)?)/gi,
regex: /(https?:\/\/.*?\.(?:png|jpg|jpeg|gif|svg|webp)(?:\?\S*?)?)/gi,
settingsKey: 'enableImages',
component: ({ match }) => {
const [showModal, setShowModal] = useState(false);