diff --git a/app/package.json b/app/package.json index 555fa8afb..8066f2461 100644 --- a/app/package.json +++ b/app/package.json @@ -207,6 +207,7 @@ "@jupyterlab/mathjax2-extension", "@jupyterlab/markedparser-extension", "@jupyterlab/notebook-extension", + "@jupyterlab/pdf-extension", "@jupyterlab/rendermime-extension", "@jupyterlab/running-extension", "@jupyterlab/shortcuts-extension", diff --git a/packages/application/src/app.ts b/packages/application/src/app.ts index 5f1acc1e6..b11430932 100644 --- a/packages/application/src/app.ts +++ b/packages/application/src/app.ts @@ -6,6 +6,8 @@ import { JupyterFrontEndPlugin } from '@jupyterlab/application'; +import { Base64ModelFactory } from '@jupyterlab/docregistry'; + import { createRendermimePlugins } from '@jupyterlab/application/lib/mimerenderers'; import { LabStatus } from '@jupyterlab/application/lib/status'; @@ -29,6 +31,9 @@ export class NotebookApp extends JupyterFrontEnd { */ constructor(options: NotebookApp.IOptions = { shell: new NotebookShell() }) { super({ ...options, shell: options.shell ?? new NotebookShell() }); + + // Add initial model factory. + this.docRegistry.addModelFactory(new Base64ModelFactory()); if (options.mimeExtensions) { for (const plugin of createRendermimePlugins(options.mimeExtensions)) { this.registerPlugin(plugin);