nshenderov / strapi-plugin-ckeditor

Integrates CKEditor 5 into your Strapi project as a fully customizable custom field. (Unofficial integration)
https://www.npmjs.com/package/@_sh/strapi-plugin-ckeditor
MIT License
95 stars 58 forks source link

Changed current folder to the root folder after uploading a new image #123

Closed avkluchko closed 2 months ago

avkluchko commented 10 months ago

When you try to upload an image to the selected folder, the image is uploaded to the specified folder, but the current view changes to the root folder. The breadcrumbs still display the selected one, not the root one.

Steps to reproduce the behavior:

  1. Click "Insert image from media library".
  2. Switch current folder to any inner folder.
  3. Click "Add more assets" and select image files.
  4. After uploading files your current location switched to root folder.

Expected behavior It was expected that my current location would not change and I would immediately see the downloaded files in the current folder.

Screenshots

Снимок экрана 2023-11-14 в 10 45 24 Снимок экрана 2023-11-14 в 10 46 04 Снимок экрана 2023-11-14 в 10 46 15 Снимок экрана 2023-11-14 в 10 47 32 Снимок экрана 2023-11-14 в 10 47 39
avkluchko commented 10 months ago

I assume that the problem is due to incorrect substitution of the folder id in the path.

Response after upload new assets:

Снимок экрана 2023-11-14 в 10 50 42

Trying open folder with incorrect params:

Снимок экрана 2023-11-14 в 10 51 08

The parameter value should be "&filters[$and][0][folderPath][$eq]=/4" instead of "&filters[$and][0][folderPath][$eq]=/&folder=4"

avkluchko commented 8 months ago

I found same issues with Strapi Media Dialog:

https://github.com/strapi/strapi/issues/18555 https://github.com/strapi/strapi/issues/18540

It looks like a problem in the core of strapi