@jupyterlite/terminal 1.1.0 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -5,13 +5,11 @@
5
5
 
6
6
  A terminal for JupyterLite.
7
7
 
8
- ⚠️ This extension is still in development and not yet ready for general use. ⚠️
9
-
10
8
  ![a screenshot showing a terminal running in JupyterLite](https://raw.githubusercontent.com/jupyterlite/terminal/main/screenshot.png)
11
9
 
12
10
  ## Requirements
13
11
 
14
- - JupyterLite >= 0.6.0, < 0.8.0
12
+ - JupyterLite >= 0.7.0, < 0.8.0
15
13
 
16
14
  ## Install
17
15
 
@@ -52,11 +50,14 @@ Each `jupyterlite-terminal` release is built against a specific version of `cock
52
50
  include imports from both `jupyterlite-terminal` and `cockle`, such as if you are implementing
53
51
  `cockle` external commands, you should ensure that you are using the correct version combination.
54
52
 
55
- | `jupyterlite-terminal` | `cockle` | `jupyterlite-core` |
56
- | ---------------------- | -------- | ------------------ |
57
- | 1.0.1 | 1.0.0 | >= 0.6, < 0.8 |
58
- | 1.0.0 | 1.0.0 | >= 0.6, < 0.7 |
59
- | 0.2.2 | 0.1.3 | >= 0.6, < 0.7 |
53
+ | `jupyterlite-terminal` | `cockle` | `jupyterlite-core` | Release date |
54
+ | ---------------------- | -------- | ------------------ | ------------ |
55
+ | 1.3.0 | 1.4.0 | >= 0.7, < 0.8 | 2026-03-02 |
56
+ | 1.2.0 | 1.3.0 | >= 0.7, < 0.8 | 2025-12-03 |
57
+ | 1.1.0 | 1.2.0 | >= 0.6, < 0.8 | 2025-10-27 |
58
+ | 1.0.1 | 1.0.0 | >= 0.6, < 0.8 | 2025-09-03 |
59
+ | 1.0.0 | 1.0.0 | >= 0.6, < 0.7 | 2025-08-11 |
60
+ | 0.2.2 | 0.1.3 | >= 0.6, < 0.7 | 2025-06-27 |
60
61
 
61
62
  ## Contributing
62
63
 
package/lib/client.d.ts CHANGED
@@ -1,7 +1,8 @@
1
- import { ServerConnection, Terminal } from '@jupyterlab/services';
2
- import { IExternalCommand, IStdinReply, IStdinRequest } from '@jupyterlite/cockle';
3
- import { ISignal } from '@lumino/signaling';
4
- import { ILiteTerminalAPIClient } from './tokens';
1
+ import type { Terminal } from '@jupyterlab/services';
2
+ import { ServerConnection } from '@jupyterlab/services';
3
+ import type { IExternalCommand, IStdinReply, IStdinRequest } from '@jupyterlite/cockle';
4
+ import type { ISignal } from '@lumino/signaling';
5
+ import type { ILiteTerminalAPIClient } from './tokens';
5
6
  export declare class LiteTerminalAPIClient implements ILiteTerminalAPIClient {
6
7
  constructor(options?: {
7
8
  serverSettings?: ServerConnection.ISettings;
package/lib/client.js CHANGED
@@ -38,6 +38,7 @@ export class LiteTerminalAPIClient {
38
38
  const { baseUrl, wsUrl } = this.serverSettings;
39
39
  const shell = new Shell({
40
40
  mountpoint: '/drive',
41
+ cwd: options === null || options === void 0 ? void 0 : options.cwd,
41
42
  baseUrl,
42
43
  wasmBaseUrl: URLExt.join(baseUrl, 'extensions/@jupyterlite/terminal/static/wasm/'),
43
44
  browsingContextId: this._browsingContextId,
package/lib/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { JupyterFrontEndPlugin } from '@jupyterlab/application';
2
- import { ServiceManagerPlugin, Terminal } from '@jupyterlab/services';
1
+ import type { JupyterFrontEndPlugin } from '@jupyterlab/application';
2
+ import type { ServiceManagerPlugin, Terminal } from '@jupyterlab/services';
3
3
  import { ILiteTerminalAPIClient } from './tokens';
4
4
  declare const _default: (ServiceManagerPlugin<Terminal.ITerminalAPIClient> | ServiceManagerPlugin<Terminal.IManager> | JupyterFrontEndPlugin<void>)[];
5
5
  export default _default;
package/lib/index.js CHANGED
@@ -2,7 +2,7 @@
2
2
  // Distributed under the terms of the Modified BSD License.
3
3
  import { IThemeManager } from '@jupyterlab/apputils';
4
4
  import { IServerSettings, ITerminalManager, ServerConnection, TerminalManager } from '@jupyterlab/services';
5
- import { IServiceWorkerManager } from '@jupyterlite/server';
5
+ import { IServiceWorkerManager } from '@jupyterlite/apputils';
6
6
  import { ISettingRegistry } from '@jupyterlab/settingregistry';
7
7
  import { WebSocket } from 'mock-socket';
8
8
  import { LiteTerminalAPIClient } from './client';
package/lib/shell.d.ts CHANGED
@@ -1,5 +1,6 @@
1
- import { BaseShell, IShell } from '@jupyterlite/cockle';
2
- import { Client as WebSocketClient } from 'mock-socket';
1
+ import type { IShell } from '@jupyterlite/cockle';
2
+ import { BaseShell } from '@jupyterlite/cockle';
3
+ import type { Client as WebSocketClient } from 'mock-socket';
3
4
  /**
4
5
  * Shell class that uses web worker that plugs into a DriveFS via the service worker.
5
6
  */
package/lib/tokens.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { Terminal } from '@jupyterlab/services';
2
- import { IExternalCommand, IStdinReply, IStdinRequest } from '@jupyterlite/cockle';
1
+ import type { Terminal } from '@jupyterlab/services';
2
+ import type { IExternalCommand, IStdinReply, IStdinRequest } from '@jupyterlite/cockle';
3
3
  import { Token } from '@lumino/coreutils';
4
- import { ISignal } from '@lumino/signaling';
4
+ import type { ISignal } from '@lumino/signaling';
5
5
  export declare const ILiteTerminalAPIClient: Token<ILiteTerminalAPIClient>;
6
6
  export interface ILiteTerminalAPIClient extends Terminal.ITerminalAPIClient {
7
7
  /**
package/lib/worker.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { expose } from 'comlink';
2
2
  import { BaseShellWorker } from '@jupyterlite/cockle';
3
- import { DriveFS } from '@jupyterlite/contents';
3
+ import { DriveFS } from '@jupyterlite/services';
4
4
  /**
5
5
  * Shell web worker that uses DriveFS via service worker.
6
6
  * Note that this is not exported as it is accessed from Shell via the filename.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jupyterlite/terminal",
3
- "version": "1.1.0",
3
+ "version": "1.3.0",
4
4
  "description": "A terminal for JupyterLite",
5
5
  "keywords": [
6
6
  "jupyter",
@@ -59,20 +59,21 @@
59
59
  "watch:labextension": "jupyter labextension watch ."
60
60
  },
61
61
  "dependencies": {
62
- "@jupyterlab/apputils": "^4.5.3",
63
- "@jupyterlab/coreutils": "^6.4.3",
64
- "@jupyterlab/services": "^7.4.3",
65
- "@jupyterlab/settingregistry": "^4.4.3",
66
- "@jupyterlite/cockle": "^1.2.0",
67
- "@jupyterlite/contents": "^0.6.0",
68
- "@jupyterlite/server": "^0.6.0",
62
+ "@jupyterlab/apputils": "^4.6.0",
63
+ "@jupyterlab/coreutils": "^6.5.0",
64
+ "@jupyterlab/pluginmanager": "^4.5.0",
65
+ "@jupyterlab/services": "^7.5.0",
66
+ "@jupyterlab/settingregistry": "^4.5.0",
67
+ "@jupyterlite/apputils": "^0.7.0",
68
+ "@jupyterlite/cockle": "^1.4.0",
69
+ "@jupyterlite/services": "^0.7.0",
69
70
  "@lumino/coreutils": "^2.2.1",
70
71
  "@lumino/signaling": "^2.1.4",
71
72
  "mock-socket": "^9.3.1"
72
73
  },
73
74
  "devDependencies": {
74
- "@jupyterlab/builder": "^4.4.3",
75
- "@jupyterlab/testutils": "^4.4.3",
75
+ "@jupyterlab/builder": "^4.5.0",
76
+ "@jupyterlab/testutils": "^4.5.0",
76
77
  "@types/jest": "^29.2.0",
77
78
  "@types/json-schema": "^7.0.11",
78
79
  "@types/react": "^18.0.26",
@@ -123,11 +124,11 @@
123
124
  "bundled": false,
124
125
  "singleton": true
125
126
  },
126
- "@jupyterlite/contents": {
127
+ "@jupyterlite/apputils": {
127
128
  "bundled": false,
128
129
  "singleton": true
129
130
  },
130
- "@jupyterlite/server": {
131
+ "@jupyterlite/services": {
131
132
  "bundled": false,
132
133
  "singleton": true
133
134
  }
@@ -158,6 +159,13 @@
158
159
  "@typescript-eslint"
159
160
  ],
160
161
  "rules": {
162
+ "@typescript-eslint/consistent-type-imports": [
163
+ "error",
164
+ {
165
+ "prefer": "type-imports",
166
+ "fixStyle": "separate-type-imports"
167
+ }
168
+ ],
161
169
  "@typescript-eslint/naming-convention": [
162
170
  "error",
163
171
  {
package/src/client.ts CHANGED
@@ -1,22 +1,22 @@
1
1
  import { PageConfig, URLExt } from '@jupyterlab/coreutils';
2
- import { ServerConnection, Terminal } from '@jupyterlab/services';
3
- import {
2
+ import type { Terminal } from '@jupyterlab/services';
3
+ import { ServerConnection } from '@jupyterlab/services';
4
+ import type {
4
5
  IExternalCommand,
5
6
  IShellManager,
6
7
  IStdinReply,
7
- IStdinRequest,
8
- ShellManager
8
+ IStdinRequest
9
9
  } from '@jupyterlite/cockle';
10
- import { JSONPrimitive } from '@lumino/coreutils';
11
- import { ISignal, Signal } from '@lumino/signaling';
10
+ import { ShellManager } from '@jupyterlite/cockle';
11
+ import type { JSONPrimitive } from '@lumino/coreutils';
12
+ import type { ISignal } from '@lumino/signaling';
13
+ import { Signal } from '@lumino/signaling';
12
14
 
13
- import {
14
- Server as WebSocketServer,
15
- Client as WebSocketClient
16
- } from 'mock-socket';
15
+ import type { Client as WebSocketClient } from 'mock-socket';
16
+ import { Server as WebSocketServer } from 'mock-socket';
17
17
 
18
18
  import { Shell } from './shell';
19
- import { ILiteTerminalAPIClient } from './tokens';
19
+ import type { ILiteTerminalAPIClient } from './tokens';
20
20
 
21
21
  export class LiteTerminalAPIClient implements ILiteTerminalAPIClient {
22
22
  constructor(options: { serverSettings?: ServerConnection.ISettings } = {}) {
@@ -55,6 +55,7 @@ export class LiteTerminalAPIClient implements ILiteTerminalAPIClient {
55
55
  const { baseUrl, wsUrl } = this.serverSettings;
56
56
  const shell = new Shell({
57
57
  mountpoint: '/drive',
58
+ cwd: options?.cwd,
58
59
  baseUrl,
59
60
  wasmBaseUrl: URLExt.join(
60
61
  baseUrl,
package/src/index.ts CHANGED
@@ -1,20 +1,19 @@
1
1
  // Copyright (c) Jupyter Development Team.
2
2
  // Distributed under the terms of the Modified BSD License.
3
3
 
4
- import {
4
+ import type {
5
5
  JupyterFrontEnd,
6
6
  JupyterFrontEndPlugin
7
7
  } from '@jupyterlab/application';
8
8
  import { IThemeManager } from '@jupyterlab/apputils';
9
+ import type { ServiceManagerPlugin, Terminal } from '@jupyterlab/services';
9
10
  import {
10
11
  IServerSettings,
11
12
  ITerminalManager,
12
13
  ServerConnection,
13
- ServiceManagerPlugin,
14
- Terminal,
15
14
  TerminalManager
16
15
  } from '@jupyterlab/services';
17
- import { IServiceWorkerManager } from '@jupyterlite/server';
16
+ import { IServiceWorkerManager } from '@jupyterlite/apputils';
18
17
  import { ISettingRegistry } from '@jupyterlab/settingregistry';
19
18
 
20
19
  import { WebSocket } from 'mock-socket';
package/src/shell.ts CHANGED
@@ -1,6 +1,7 @@
1
- import { BaseShell, IShell } from '@jupyterlite/cockle';
1
+ import type { IShell } from '@jupyterlite/cockle';
2
+ import { BaseShell } from '@jupyterlite/cockle';
2
3
 
3
- import { Client as WebSocketClient } from 'mock-socket';
4
+ import type { Client as WebSocketClient } from 'mock-socket';
4
5
 
5
6
  /**
6
7
  * Shell class that uses web worker that plugs into a DriveFS via the service worker.
package/src/tokens.ts CHANGED
@@ -1,11 +1,11 @@
1
- import { Terminal } from '@jupyterlab/services';
2
- import {
1
+ import type { Terminal } from '@jupyterlab/services';
2
+ import type {
3
3
  IExternalCommand,
4
4
  IStdinReply,
5
5
  IStdinRequest
6
6
  } from '@jupyterlite/cockle';
7
7
  import { Token } from '@lumino/coreutils';
8
- import { ISignal } from '@lumino/signaling';
8
+ import type { ISignal } from '@lumino/signaling';
9
9
 
10
10
  export const ILiteTerminalAPIClient = new Token<ILiteTerminalAPIClient>(
11
11
  '@jupyterlite/terminal:client'
package/src/worker.ts CHANGED
@@ -1,7 +1,8 @@
1
1
  import { expose } from 'comlink';
2
2
 
3
- import { BaseShellWorker, IDriveFSOptions } from '@jupyterlite/cockle';
4
- import { DriveFS } from '@jupyterlite/contents';
3
+ import type { IDriveFSOptions } from '@jupyterlite/cockle';
4
+ import { BaseShellWorker } from '@jupyterlite/cockle';
5
+ import { DriveFS } from '@jupyterlite/services';
5
6
 
6
7
  /**
7
8
  * Shell web worker that uses DriveFS via service worker.