Skip to content

Commit f23e2c3

Browse files
committed
fix(tui): detect Orca image support
1 parent 9b50b04 commit f23e2c3

2 files changed

Lines changed: 13 additions & 0 deletions

File tree

‎packages/tui/src/terminal-image.ts‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ export function detectCapabilities(tmuxForwardsHyperlink: () => boolean = probeT
8383
return { images: null, trueColor: hasTrueColorHint, hyperlinks: false };
8484
}
8585

86+
if (termProgram === "orca") {
87+
return { images: "kitty", trueColor: true, hyperlinks: true };
88+
}
89+
8690
if (process.env.KITTY_WINDOW_ID || termProgram === "kitty") {
8791
return { images: "kitty", trueColor: true, hyperlinks: true };
8892
}

‎packages/tui/test/terminal-image.test.ts‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,15 @@ describe("detectCapabilities", () => {
279279
});
280280
});
281281

282+
it("enables images and hyperlinks for Orca", () => {
283+
withEnv({ TERM_PROGRAM: "Orca" }, () => {
284+
const caps = detectCapabilities();
285+
assert.strictEqual(caps.images, "kitty");
286+
assert.strictEqual(caps.trueColor, true);
287+
assert.strictEqual(caps.hyperlinks, true);
288+
});
289+
});
290+
282291
it("enables images and hyperlinks for Warp via TERM_PROGRAM", () => {
283292
withEnv({ TERM_PROGRAM: "WarpTerminal" }, () => {
284293
const caps = detectCapabilities();

0 commit comments

Comments
 (0)