Hello.
I guess I’m having a bug with ImageEditor in Uppy v5 with React, but I wanted to check.
The issue I am having is the following. The uppy dashboard and image editor work fine the first time I use the editor, but if I try to edit the image again, it gets buggy. Selection rectangle vanishes, if the image is small it gets positioned at the top left corner of the editor, and I can’t see the modifications I’m doing with it. I believe it’s a compatibility issue with Uppy being at version 5 and ImageEditor at version 4.
Here’s how to reproduce it:
-
Create a new nextjs project with app dir (i used js instead of ts);
-
Install uppy packages;
-
Edit app/page.js with this code:
‘use client’
import { useState } from ‘react’;
import Uppy from ‘@uppy/core’;
import ImageEditor from ‘@uppy/image-editor’;
import ‘@uppy/core/css/style.min.css’;
import ‘@uppy/dashboard/css/style.min.css’;
import ‘@uppy/image-editor/css/style.min.css’;
import Dashboard from ‘@uppy/react/dashboard’;
export default function App() {
const [uppy] = useState(() => new Uppy().use(ImageEditor));
return (
<Dashboard uppy={uppy} />
);
}
-
Add a new image to the dashboard;
-
Click on the edit icon and then cancel;
-
Try to edit the image again.
Here is the content of my package.json:
“dependencies”: {
"@uppy/core": "^5.2.0",
"@uppy/dashboard": "^5.1.1",
"@uppy/image-editor": "^4.2.0",
"@uppy/react": "^5.2.0",
"next": "16.2.6",
"react": "19.2.4",
"react-dom": "19.2.4"
}
Thank you very much.