Skip to content

terminal/HostTerminalSurface

import { … } from 'zidane-ui/terminal'ui/src/terminal/HostTerminalSurface.tsx

Components#

HostTerminalSurfaceComponent#

One view of one of the host's terminals, attached for as long as it is mounted.

TypeScript
function HostTerminalSurface(props: HostTerminalSurfaceProps): Element
Parameters
NameTypeDescription
propsHostTerminalSurfaceProps

The terminal, its scope and label, where its paths resolve, focus and the PTY's size.

Element
HostTerminalSurface props
NameTypeDescription
autoFocus?boolean

Take keyboard focus on mount (the user opened or picked this terminal).

className?string

Extra classes on the root.

cwdstring

Where relative paths printed by the shell resolve; empty = don't link files.

focusSeq?number

A new value takes focus again while autoFocus stays on (the terminal shown on request a second time).

labelstring

The terminal's label, for "Add to chat" excerpts.

ptyColsnumber

The PTY's columns (from the host): the grid always has its size, whatever this view's container fits.

ptyRowsnumber

The PTY's rows.

ptySeqnumber

TerminalInfo.sizeSeq of that size: a view keeps the newest, whichever route it came by.

scopeTerminalScope

Whose terminal (handed to the app's link and chat actions).

serverName?string | null

The machine the terminal runs on when it is not this one: its loopback links are not this computer's.

terminalIdstring

The terminal this view attaches to.

ui/src/terminal/HostTerminalSurface.tsx:119

Interfaces#

HostTerminalSurfacePropsInterface#

Props for HostTerminalSurface.

TypeScript
interface HostTerminalSurfaceProps
HostTerminalSurfaceProps properties
NameTypeDescription
autoFocus?boolean

Take keyboard focus on mount (the user opened or picked this terminal).

className?string

Extra classes on the root.

cwdstring

Where relative paths printed by the shell resolve; empty = don't link files.

focusSeq?number

A new value takes focus again while autoFocus stays on (the terminal shown on request a second time).

labelstring

The terminal's label, for "Add to chat" excerpts.

ptyColsnumber

The PTY's columns (from the host): the grid always has its size, whatever this view's container fits.

ptyRowsnumber

The PTY's rows.

ptySeqnumber

TerminalInfo.sizeSeq of that size: a view keeps the newest, whichever route it came by.

scopeTerminalScope

Whose terminal (handed to the app's link and chat actions).

serverName?string | null

The machine the terminal runs on when it is not this one: its loopback links are not this computer's.

terminalIdstring

The terminal this view attaches to.

ui/src/terminal/HostTerminalSurface.tsx:77