Skip to content

Commit 92ddb4f

Browse files
committed
chore: update xterm
1 parent 41e1383 commit 92ddb4f

File tree

3 files changed

+78
-78
lines changed

3 files changed

+78
-78
lines changed

site/package.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,12 @@
4545
"@mui/system": "5.14.0",
4646
"@mui/utils": "5.14.11",
4747
"@tanstack/react-query-devtools": "4.35.3",
48-
"@types/file-saver": "2.0.7",
48+
"@xterm/xterm": "5.5.0",
49+
"@xterm/addon-canvas": "0.7.0",
50+
"@xterm/addon-fit": "0.10.0",
51+
"@xterm/addon-unicode11": "0.8.0",
52+
"@xterm/addon-web-links": "0.11.0",
53+
"@xterm/addon-webgl": "0.18.0",
4954
"ansi-to-html": "0.7.2",
5055
"axios": "1.6.0",
5156
"canvas": "2.11.0",
@@ -89,12 +94,6 @@
8994
"undici": "6.19.2",
9095
"unique-names-generator": "4.7.1",
9196
"uuid": "9.0.0",
92-
"xterm": "5.2.0",
93-
"xterm-addon-canvas": "0.5.0",
94-
"xterm-addon-fit": "0.8.0",
95-
"xterm-addon-unicode11": "0.6.0",
96-
"xterm-addon-web-links": "0.9.0",
97-
"xterm-addon-webgl": "0.16.0",
9897
"yup": "1.3.2"
9998
},
10099
"devDependencies": {
@@ -120,6 +119,7 @@
120119
"@types/chroma-js": "2.4.0",
121120
"@types/color-convert": "2.0.0",
122121
"@types/express": "4.17.17",
122+
"@types/file-saver": "2.0.7",
123123
"@types/jest": "29.5.2",
124124
"@types/lodash": "4.14.196",
125125
"@types/node": "18.19.0",

site/pnpm-lock.yaml

Lines changed: 62 additions & 62 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

site/src/pages/TerminalPage/TerminalPage.tsx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
import "xterm/css/xterm.css";
1+
import "@xterm/xterm/css/xterm.css";
22
import type { Interpolation, Theme } from "@emotion/react";
3+
import { Terminal } from "@xterm/xterm";
4+
import { CanvasAddon } from "@xterm/addon-canvas";
5+
import { FitAddon } from "@xterm/addon-fit";
6+
import { Unicode11Addon } from "@xterm/addon-unicode11";
7+
import { WebLinksAddon } from "@xterm/addon-web-links";
8+
import { WebglAddon } from "@xterm/addon-webgl";
39
import { type FC, useCallback, useEffect, useRef, useState } from "react";
410
import { Helmet } from "react-helmet-async";
511
import { useQuery } from "react-query";
612
import { useNavigate, useParams, useSearchParams } from "react-router-dom";
713
import { v4 as uuidv4 } from "uuid";
8-
import * as XTerm from "xterm";
9-
import { CanvasAddon } from "xterm-addon-canvas";
10-
import { FitAddon } from "xterm-addon-fit";
11-
import { Unicode11Addon } from "xterm-addon-unicode11";
12-
import { WebLinksAddon } from "xterm-addon-web-links";
13-
import { WebglAddon } from "xterm-addon-webgl";
1414
import { deploymentConfig } from "api/queries/deployment";
1515
import {
1616
workspaceByOwnerAndName,
@@ -45,7 +45,7 @@ const TerminalPage: FC = () => {
4545
const terminalWrapperRef = useRef<HTMLDivElement>(null);
4646
// The terminal is maintained as a state to trigger certain effects when it
4747
// updates.
48-
const [terminal, setTerminal] = useState<XTerm.Terminal>();
48+
const [terminal, setTerminal] = useState<Terminal>();
4949
const [connectionStatus, setConnectionStatus] =
5050
useState<ConnectionStatus>("initializing");
5151
const [searchParams] = useSearchParams();
@@ -104,7 +104,7 @@ const TerminalPage: FC = () => {
104104
if (!terminalWrapperRef.current || config.isLoading) {
105105
return;
106106
}
107-
const terminal = new XTerm.Terminal({
107+
const terminal = new Terminal({
108108
allowProposedApi: true,
109109
allowTransparency: true,
110110
disableStdin: false,

0 commit comments

Comments
 (0)