Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
14 commits
Select commit Hold shift + click to select a range
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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"private": true,
"homepage": "/dashboard",
"dependencies": {
"@devtron-labs/devtron-fe-common-lib": "4.0.3-pre-0",
"@devtron-labs/devtron-fe-common-lib": "4.0.4-pre-0",
"@esbuild-plugins/node-globals-polyfill": "0.2.3",
"@sentry/browser": "7.119.1",
"@sentry/integrations": "7.50.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,18 @@ const TerminalView = ({
}
}, [termDivRef.current])

const createNewTerminal = () => {
const createNewTerminal = async () => {
// Ensure the font is loaded before xterm measures character cell dimensions.
// Without this, xterm falls back to a system font and gets wrong cell widths.
await document.fonts.load('14px Inconsolata').catch(noop)

// eslint-disable-next-line no-param-reassign
terminalRef.current = new Terminal({
scrollback: 99999,
fontSize: 14,
lineHeight: 1.4,
cursorBlink: false,
fontFamily: 'Inconsolata',
fontFamily: 'Inconsolata, monospace',
screenReaderMode: true,
theme: {
// Cannot use variables here
Expand Down Expand Up @@ -208,9 +212,7 @@ const TerminalView = ({
useEffect(() => {
if (!terminalRef.current) {
elementDidMount('#terminal-id')
.then(() => {
createNewTerminal()
})
.then(() => createNewTerminal())
.catch(noop)
}
if (sessionId && terminalRef.current) {
Expand Down
30 changes: 25 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1738,9 +1738,9 @@ __metadata:
languageName: node
linkType: hard

"@devtron-labs/devtron-fe-common-lib@npm:4.0.3-pre-0":
version: 4.0.3-pre-0
resolution: "@devtron-labs/devtron-fe-common-lib@npm:4.0.3-pre-0"
"@devtron-labs/devtron-fe-common-lib@npm:4.0.4-pre-0":
version: 4.0.4-pre-0
resolution: "@devtron-labs/devtron-fe-common-lib@npm:4.0.4-pre-0"
dependencies:
"@codemirror/autocomplete": "npm:6.18.6"
"@codemirror/lang-json": "npm:6.0.1"
Expand All @@ -1758,6 +1758,7 @@ __metadata:
"@rjsf/utils": "npm:^6.2.4"
"@rjsf/validator-ajv8": "npm:^6.2.4"
"@tanstack/react-query": "npm:^5.90.21"
"@tanstack/react-virtual": "npm:^3.13.24"
"@uiw/codemirror-extensions-hyper-link": "npm:4.23.10"
"@uiw/codemirror-theme-github": "npm:4.23.7"
"@uiw/react-codemirror": "npm:4.23.7"
Expand Down Expand Up @@ -1793,7 +1794,7 @@ __metadata:
react-select: 5.8.0
rxjs: ^7.8.1
yaml: ^2.8.3
checksum: 10c0/2f576bacdda2d86b5cc15f360f85bb4a4cfbd8204f602c0bd6b906d9aab405f39a31631b4e05e761f4396d310ca49123fae71fe17d5ca49eb5a199b088ffd33b
checksum: 10c0/ae699b1673b72454475d699a6f593658bcb9f4fa5e8443a4c794429795ac060ef91fb1fdb371fd12b496fca9e146674585cd31cfd1d26b48f4fa7aae5d363ffc
languageName: node
linkType: hard

Expand Down Expand Up @@ -3494,6 +3495,25 @@ __metadata:
languageName: node
linkType: hard

"@tanstack/react-virtual@npm:^3.13.24":
version: 3.13.24
resolution: "@tanstack/react-virtual@npm:3.13.24"
dependencies:
"@tanstack/virtual-core": "npm:3.14.0"
peerDependencies:
react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
checksum: 10c0/f409b2bb67965a513b75a1403e622c0b86c88c67419f757c79f670615979e38dc7ad5569a02c924741697df3d4301a0f45208fd4b9f935a5d58dd83e1db5622a
languageName: node
linkType: hard

"@tanstack/virtual-core@npm:3.14.0":
version: 3.14.0
resolution: "@tanstack/virtual-core@npm:3.14.0"
checksum: 10c0/9e07e7f74f5e02dfc47b358f7b5089e680d8b14b9c5b90e9497be6f57c76ca98d185fbe5008795b89919346bfc3676ebe1c61b34980eefe6674c88ec6ff4b136
languageName: node
linkType: hard

"@tippyjs/react@npm:4.2.6":
version: 4.2.6
resolution: "@tippyjs/react@npm:4.2.6"
Expand Down Expand Up @@ -5509,7 +5529,7 @@ __metadata:
version: 0.0.0-use.local
resolution: "dashboard@workspace:."
dependencies:
"@devtron-labs/devtron-fe-common-lib": "npm:4.0.3-pre-0"
"@devtron-labs/devtron-fe-common-lib": "npm:4.0.4-pre-0"
"@esbuild-plugins/node-globals-polyfill": "npm:0.2.3"
"@playwright/test": "npm:^1.32.1"
"@sentry/browser": "npm:7.119.1"
Expand Down
Loading