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

[Feature request] ability to add user's own circuits to menu #941

Open
mpictor opened this issue May 19, 2024 · 0 comments
Open

[Feature request] ability to add user's own circuits to menu #941

mpictor opened this issue May 19, 2024 · 0 comments

Comments

@mpictor
Copy link

mpictor commented May 19, 2024

I'd like to be able to add my own circuits to the menu, so that I can more easily go back and look at them.

My thought is to allow the user to specify a url; circuitjs loads the file at the url and turns the content into menu items. The url is stored in a cookie so the user doesn't need to re-enter it.

As far as the format for the data at the url, my thought is markdown, though with circuitjs only parsing markdown links (i.e [text](http://link)) and ignoring the rest of the file.
The text of the link would be used as the name in the menu, while the url would be data. The data could be in two forms:

  • a "circuit link", where the circuit is encoded in the url (same format as that used by File|Export as Link...)
    • detect this form by looking for circuitjs.html?ctz= within the url
  • a save file, where the link points to another file (same format as File|Save as...)

I'm a little unclear on how CSRF protections (or other security protections, for that matter) would interact with this feature. For example, would I be able to use a file directly from github as the markdown or data file? If not, my hope is that github user pages would allow it.

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

No branches or pull requests

1 participant