GHHG10/CodeServer / opencode /packages /tui /src /component /workspace-label.tsx
GHHG10's picture
download
raw
669 Bytes
import { useTheme } from "../context/theme"
export type WorkspaceStatus = "connected" | "connecting" | "disconnected" | "error"
export function WorkspaceLabel(props: { type: string; name: string; status?: WorkspaceStatus; icon?: boolean }) {
const { theme } = useTheme()
const color = () => {
if (props.status === "connected") return theme.success
if (props.status === "error") return theme.error
return theme.textMuted
}
return (
<>
{props.icon ? <span style={{ fg: color() }}></span> : undefined}
<span style={{ fg: theme.text }}>{props.name}</span> <span style={{ fg: theme.textMuted }}>({props.type})</span>
</>
)
}

Xet Storage Details

Size:
669 Bytes
·
Xet hash:
3bd9d9c96336f1413801d7ba6583cbabbc999328c5fda0c2ae54c3f11d46c9f2

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.