File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 112112 # contrib
113113 "matplotlib.sphinxext.plot_directive" ,
114114 "numpydoc" ,
115+ "jupyterlite_sphinx" ,
115116 "sphinx_copybutton" ,
116117 "sphinx_design" ,
117118 "sphinx_gallery.gen_gallery" ,
470471
471472sphinx_gallery_parallel = int (os .getenv ("MNE_DOC_BUILD_N_JOBS" , "1" ))
472473sphinx_gallery_conf = {
474+ "jupyterlite" : {
475+ "use_jupyter_lab" : True ,
476+ },
477+ "first_notebook_cell" : (
478+ "# 💡 This cell is automatically added to the start of each notebook.\n "
479+ "import micropip\n "
480+ "await micropip.install(['mne', 'pyodide-http'])\n "
481+ "\n "
482+ "# 1. Patch networking so pooch can download datasets\n "
483+ "import pyodide_http\n "
484+ "pyodide_http.patch_all()\n "
485+ "\n "
486+ "# 2. Patch MNEBrowseFigure to auto-display in Pyodide's inline backend\n "
487+ "import mne\n "
488+ "import matplotlib.pyplot as plt\n "
489+ "orig_plt_show = mne.viz.utils.plt_show\n "
490+ "def pyodide_plt_show(fig=None, **kwargs):\n "
491+ " orig_plt_show(fig, **kwargs)\n "
492+ " import IPython.display\n "
493+ " IPython.display.display(plt.gcf())\n "
494+ "mne.viz.utils.plt_show = pyodide_plt_show\n "
495+ ),
473496 "doc_module" : ("mne" ,),
474497 "reference_url" : dict (mne = None ),
475498 "examples_dirs" : examples_dirs ,
Original file line number Diff line number Diff line change 99 " graphviz" ,
1010 " intersphinx_registry >= 0.2405.27" ,
1111 " ipython != 8.7.0" , # also in "full-no-qt" and "test"
12+ " jupyterlite-pyodide-kernel" ,
13+ " jupyterlite-sphinx" ,
1214 " memory_profiler >= 0.16" ,
1315 " mne-bids" ,
1416 " mne-connectivity" ,
You can’t perform that action at this time.
0 commit comments