ControlCore-Project / concore-editor

The concore Editor
http://controlcore-project.github.io/concore-editor
BSD 3-Clause "New" or "Revised" License
9 stars 19 forks source link

Uploaded directory automatically closes when one of the graphml file is closed #83

Closed Rahuljagwani closed 1 year ago

Rahuljagwani commented 1 year ago

So when two or more graphml files are uploaded, on closing one graph file the uploaded directory is closed automatically. It can be inconvenient for user to open the directory again and again. To face this issue:

  1. Upload directory on concore editor.
  2. Open 2 or more graphml files.
  3. Close one of them, the whole directory will disappear. @pradeeban
Rahuljagwani commented 1 year ago

I have found the solution will be sending PR shortly.

pradeeban commented 1 year ago

This is the expected behavior, @Rahuljagwani.

The reasoning is, we are tracking the folder to the browser memory. When we click "Save," the changed files are saved into the original location (works only in Chrome).

If you upload multiple folders, this "Save" (and all the server features - such as run, build, ...) will be broken.

So, even if you like to support uploading multiple directories, that will be an enhancement of feature (and not a fix to a bug). I believe your attempt to fix this issue will introduce additional issues at this point and suggest a "Won't Fix."

Rahuljagwani commented 1 year ago

This is the expected behavior, @Rahuljagwani.

The reasoning is, we are tracking the folder to the browser memory. When we click "Save," the changed files are saved into the original location (works only in Chrome).

If you upload multiple folders, this "Save" (and all the server features - such as run, build, ...) will be broken.

So, even if you like to support uploading multiple directories, that will be an enhancement of feature (and not a fix to a bug). I believe your attempt to fix this issue will introduce additional issues at this point and suggest a "Won't Fix."

Actually it is not about uploading multiple directories it is about uploading 2 graphml files from a single directory. So the issue with "Save" you mentioned is not a problem. I meant to say that suppose in one uploaded directory 'demo' there are 2 graphml files so when we close one of them the whole directory disappears.

pradeeban commented 1 year ago

wow, yes.

Just tried and confirmed this bug. Seems like a new bug.

Please send the PR. I will test and merge right away.

pradeeban commented 1 year ago

Fix merged. Thanks @Rahuljagwani.