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

Add OJS/OMD Preview WebviewPanelSerializer #10

Closed
RandomFractals opened this issue Oct 24, 2020 · 3 comments · Fixed by #11
Closed

Add OJS/OMD Preview WebviewPanelSerializer #10

RandomFractals opened this issue Oct 24, 2020 · 3 comments · Fixed by #11

Comments

@RandomFractals
Copy link

Gordon,

I added save as .ojs & .omd options to my JS notebook inspector:

RandomFractals/js-notebook-inspector#54

Everything looks good, except OJS/OMD Preview webview is not restored on vscode restart.

before:

js-notebook-inspector-omd-save

that OMD Preview panel is gone after that vscode instance restart:

ojs-preview-blank-restore

Expected to see same thing as in pic 1.

It would be nice if you could add WebviewPanelSerializer for those custom .ojs/.omd panels.

See my notebook.view.ts for an example of implementing that api:

https://github.com/RandomFractals/js-notebook-inspector/blob/master/src/views/notebook.view.ts

GordonSmith added a commit that referenced this issue Oct 25, 2020
Bump versions

Fixes #10

Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
GordonSmith added a commit that referenced this issue Oct 25, 2020
Bump versions

Fixes #10

Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
GordonSmith added a commit that referenced this issue Oct 26, 2020
Bump versions
Add optional param to "ojs.preview"

Fixes #10

Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
GordonSmith added a commit that referenced this issue Oct 26, 2020
Bump versions
Add optional param to "ojs.preview"

Fixes #10

Signed-off-by: Gordon Smith <GordonJSmith@gmail.com>
GordonSmith added a commit that referenced this issue Oct 27, 2020
fix(preview): Maintain preview state during VS Code restart
@RandomFractals
Copy link
Author

btw, I noticed you removed OJS: prefix from your command names. I kind of liked it. I believe most good vscode extensions use ext. prefix in command names for easy command search via Command Palette.

@GordonSmith
Copy link
Owner

I replaced it with "category" which should prefix it in the command list...

@RandomFractals
Copy link
Author

oh. I missed that. cool!

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

Successfully merging a pull request may close this issue.

2 participants