Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable editing of a schema loaded from the schema viewer #162

Open
gtsueng opened this issue Jun 14, 2022 · 8 comments
Open

Enable editing of a schema loaded from the schema viewer #162

gtsueng opened this issue Jun 14, 2022 · 8 comments
Assignees
Labels
enhancement New feature or request

Comments

@gtsueng
Copy link
Collaborator

gtsueng commented Jun 14, 2022

Is your feature request related to a problem? Please describe.
When working with a more exhaustive schema, there's no way to resume from already saved progress. Eg- If I start creating a schema via extension and save my work to github, I can't reload my jsonld schema and resume working on it. This feature was also requested by members of the bioschemas community.

Describe the solution you'd like
Allow "editing" of a schema from a jsonld file instead of just registered schemas. Not necessarily editing the actual file, but at least loading the content of schema into the DDE schema editor and allowing the user to save as a new file or update the file (if it's in their own repo).

Describe alternatives you've considered
Currently the only work arounds are:

  1. know json and edit the json directly
  2. Start from scratch in the DDE
  3. Complete the schema creation process from start to finish in one sitting
  4. Attempt to register the draft schema, attempt to extend from it, edit parent in the JSON, save your work, and delete the draft schema

Additional context
Maybe instead of just the "Change view" button available loading a schema in the schema viewer, there could be an "edit schema" button to go to the schema editor

@gtsueng gtsueng added the enhancement New feature or request label Jun 14, 2022
@gtsueng
Copy link
Collaborator Author

gtsueng commented Jun 24, 2022

This feature is not longer needed with Marco's addition of save/load functions

@gtsueng gtsueng closed this as completed Jun 24, 2022
@sneumann
Copy link

Hi, indeed I can now save/load my edits locally and resume editing, and I can also save a version to a github repo where I have write access.

What does not work if someone else might want to continue editing my schema I pushed to github.

So as described above, this could mean to load a json-ld file from GitHub, or by uploading a file .

Yours, Steffen

@gtsueng gtsueng reopened this Oct 31, 2023
@gtsueng
Copy link
Collaborator Author

gtsueng commented Oct 31, 2023

@marcodarko is there a work around? Can they copy/paste the cached save file to share/collaboratively edit it?

@marcodarko
Copy link
Collaborator

I can see about loading a file from GitHub, we already something like that in other parts of the application. It would involve selecting an option "Paste link from GitHub" and editing and then you'd have to download/save the file manually back to GitHub (only downside). It's a bit clunky but it's the best solution that our current setup will allow for. GitHub permissions can be difficult to handle so we leave that up to the user.

@sneumann
Copy link

sneumann commented Nov 1, 2023

No problem to "save file manually to github", people might want to download your fork and upload to my fork.
The local storage saving gets less appealing with multiple browsers (on which computer in which of the installed browsers did I save that ?!) or if some installations wipe local storage.
Yours, Steffen

@marcodarko
Copy link
Collaborator

Ok I will see if this will even work, we only export/download the "processed" version so I will see if it's possible to make it backwards compatible. Right now you are able to save progress because we save the configuration/unprocessed version not seen by the user but if it's a "progress" that needs to be saved to an outside source/repository that complicates things. I will take a look and gage the complexity to do this request.

@sneumann
Copy link

Hi, any progress here? We have a hackathon this week, happy to test-drive. Yours, Steffen

@marcodarko
Copy link
Collaborator

Unfortunately no, like I said there's a complexity that exists right now that doesn't allow us to save "progress" to an outside repository because it will include settings that are only used by the DDE. The final schema doesn't get assembled until you manually trigger it by hitting a point where you either save or download the schema. Until that point it's just an unprocessed version I put together and if someone were to change things they're not supposed to it could compromise the application or break it, so that's why right now it's not possible to collaboratively work on the same schema by multiple users.
Not saying it's impossible but I would have to rewrite a big part of this codebase. I do see value in this so I will look into it again. If an idea comes to mind I will definitely inform you, I still have this on my list of things so it won't be forgotten.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants