neo4j-documentation / asciidoctor-jupyter

A Jupyter converter for Asciidoctor.js. Write your Notebook in AsciiDoc!
16 stars 1 forks source link

embed images in notebook #3

Open prudhomm opened 2 years ago

prudhomm commented 2 years ago

Hi @Mogztter

is it already possible to embed an image in a jupyter notebook using this extension ? that would be great! I use already env-github and env-vscode to detect github or vscode and provide the path maybe env-jupyter is needed ?

For example here is the type of adoc that will be used to generate a jupyter notebook: https://github.com/feelpp/toolbox/edit/master/examples/modules/csm/pages/suspension/index.adoc here is how it looks in antora https://docs.feelpp.org/cases/latest/csm/suspension/index.html

I have often many images and I am adding python code as well atm to make the notebook more interesting

images in tables do not seem to be working properly

ggrossetie commented 2 years ago

I use already env-github and env-vscode to detect github or vscode and provide the path maybe env-jupyter is needed ?

I think you should use the attribute backend-jupyter. A converter should not set env- attribute since is meant to indicate which environment Asciidoctor is being integrated into. For instance, the env could be env-jupyterlab (desktop) or env-jupyterhub (web) if you are targeting one environment or the other.

images in tables do not seem to be working properly

For now, only text is supported in tables.

prudhomm commented 2 years ago

thanks!

backend-jupyter works nicely. However the control over the image sizes do not seem to work.

I will remove the images from the table then and try using asciidoc positioning

prudhomm commented 2 years ago

@Mogztter I have added at the top of the adoc a button to download the jupyter notebook. As you can see the images are not embedded. Otherwise it seems all good. https://docs.feelpp.org/cases/latest/csm/sensor/index.html

prudhomm commented 2 years ago

The images are not embedded in the jupyter notebook it seems. Would it be possible to do so in order to share the notebook ?