Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions dashboard/frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions dashboard/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
"@radix-ui/react-tabs": "^1.1.13",
"@radix-ui/react-tooltip": "^1.2.8",
"@tanstack/react-query": "^5.90.20",
"@xterm/addon-clipboard": "^0.2.0",
"@xterm/addon-fit": "^0.11.0",
"@xterm/addon-web-links": "^0.12.0",
"@xterm/addon-webgl": "^0.19.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

import { useRef, useEffect, useCallback } from "react";
import { Terminal as XTerm } from "@xterm/xterm";
import { ClipboardAddon } from "@xterm/addon-clipboard";
import { FitAddon } from "@xterm/addon-fit";
import { WebLinksAddon } from "@xterm/addon-web-links";
import "@xterm/xterm/css/xterm.css";
Expand Down Expand Up @@ -92,7 +93,6 @@ export function OutputPanel() {

const term = new XTerm({
cursorBlink: false,
copyOnSelect: true,
disableStdin: true,
fontSize: terminalFontSize,
fontFamily: "JetBrains Mono, Menlo, Monaco, monospace",
Expand Down Expand Up @@ -124,6 +124,7 @@ export function OutputPanel() {

const fitAddon = new FitAddon();
term.loadAddon(fitAddon);
term.loadAddon(new ClipboardAddon());
term.loadAddon(new WebLinksAddon());
Comment on lines 125 to 128
term.open(containerRef.current);

Expand Down
3 changes: 2 additions & 1 deletion dashboard/frontend/src/components/Terminal/Terminal.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { useRef, useEffect, useCallback, useState } from "react";
import { Terminal as XTerm } from "@xterm/xterm";
import { ClipboardAddon } from "@xterm/addon-clipboard";
import { FitAddon } from "@xterm/addon-fit";
import { WebLinksAddon } from "@xterm/addon-web-links";
import "@xterm/xterm/css/xterm.css";
Expand Down Expand Up @@ -82,7 +83,6 @@ function ActiveTerminal({

const term = new XTerm({
cursorBlink: true,
copyOnSelect: true,
scrollback: 5000,
scrollOnUserInput: true,
scrollSensitivity: 1,
Expand Down Expand Up @@ -117,6 +117,7 @@ function ActiveTerminal({
const fitAddon = new FitAddon();
term.loadAddon(fitAddon);
term.loadAddon(new WebLinksAddon());
term.loadAddon(new ClipboardAddon());
Comment on lines 117 to +120

term.open(containerRef.current);
termRef.current = term;
Expand Down
Loading