fix: type error

This commit is contained in:
adamelmore
2026-01-24 17:01:37 -06:00
parent 3fdd6ec120
commit e223d1a0e5

View File

@@ -1,6 +1,5 @@
import {
For,
Index,
onCleanup,
onMount,
Show,
@@ -41,7 +40,6 @@ import { useLayout } from "@/context/layout"
import { Terminal } from "@/components/terminal"
import { checksum, base64Encode, base64Decode } from "@opencode-ai/util/encode"
import { findLast } from "@opencode-ai/util/array"
import { getFilename } from "@opencode-ai/util/path"
import { useDialog } from "@opencode-ai/ui/context/dialog"
import { DialogSelectFile } from "@/components/dialog-select-file"
import { DialogSelectModel } from "@/components/dialog-select-model"
@@ -67,7 +65,6 @@ import {
SortableTerminalTab,
NewSessionView,
} from "@/components/session"
import { usePlatform } from "@/context/platform"
import { navMark, navParams } from "@/utils/perf"
import { same } from "@/utils/same"
@@ -103,7 +100,7 @@ function SessionReviewTab(props: SessionReviewTabProps) {
const sdk = useSDK()
const readFile = (path: string) => {
const readFile = async (path: string) => {
return sdk.client.file
.read({ path })
.then((x) => x.data)
@@ -192,7 +189,6 @@ export default function Page() {
const codeComponent = useCodeComponent()
const command = useCommand()
const language = useLanguage()
const platform = usePlatform()
const params = useParams()
const navigate = useNavigate()
const sdk = useSDK()
@@ -2475,13 +2471,11 @@ export default function Page() {
}}
>
<Show when={pty.id} keyed>
{() => (
<Terminal
pty={pty}
onCleanup={terminal.update}
onConnectError={() => terminal.clone(pty.id)}
/>
)}
</Show>
</div>
)}