Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ const EXPECTED_PROVIDER_ORDER = [
"codex",
"gemini",
"qwen",
"qoder",
"grok",
"kimi",
"antigravity",
Expand Down
11 changes: 11 additions & 0 deletions src/renderer/components/providers/qoder/QoderIcon.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { createProviderIcon } from "../common/createProviderIcon";

// Official Qoder mark (ACP agent registry icon).
const QODER_PATH =
"M8 1C4.134 1 1 4.134 1 8s3.134 7 7 7c1.5 0 2.9-.47 4.05-1.28l1.12 1.12a.75.75 0 1 0 1.06-1.06l-1.12-1.12A6.97 6.97 0 0 0 15 8c0-3.866-3.134-7-7-7Zm0 2c2.761 0 5 2.239 5 5s-2.239 5-5 5-5-2.239-5-5 2.239-5 5-5Z";

export const QoderIcon = createProviderIcon({
cssPrefix: "poracode-qoder-icon",
path: QODER_PATH,
viewBox: "0 0 16 16",
});
73 changes: 73 additions & 0 deletions src/renderer/components/providers/qoder/index.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
// @vitest-environment node

import { describe, expect, it, vi } from "vitest";
import type { ComposerControl } from "@/renderer/components/thread/ThreadComposer";
import type { AgentCapability, ThreadConfig } from "@/shared/contracts";
import { getComposerControls } from "../providerComposer";
import "./index";

const capabilities: AgentCapability = {
models: [],
efforts: [],
modelEfforts: {},
modes: ["agent", "plan"],
approvalPolicies: [
{ id: "default", label: "Default" },
{ id: "acceptEdits", label: "Accept Edits" },
{ id: "bypassPermissions", label: "Bypass Permissions" },
],
sandboxModes: [],
supportsResume: true,
supportsDirectInput: true,
liveInputMode: "terminal",
presentationMode: "terminal",
presentationModes: ["terminal", "gui"],
defaultApprovalPolicy: "default",
settingDefs: [],
};

function isMenuControl(
control: ComposerControl,
): control is Extract<ComposerControl, { kind?: "menu" }> {
return control.kind === undefined || control.kind === "menu";
}

function isModeControl(control: ComposerControl): boolean {
return "iconKind" in control && control.iconKind === "mode";
}

describe("Qoder composer controls", () => {
it("shows Work mode with Default permissions by default", () => {
const onConfigChange = vi.fn<(patch: Partial<ThreadConfig>) => void>();
const controls = getComposerControls("qoder")?.({
capabilities,
config: { model: "auto", mode: "agent", approvalPolicy: "default" },
isDisabled: false,
onConfigChange,
presentationMode: "gui",
});

expect(controls?.find(isModeControl)).toMatchObject({
label: "Work",
isSelected: false,
});
expect(
controls?.find((control) => isMenuControl(control) && control.iconKind === "permission"),
).toMatchObject({ value: "default" });
});

it("keeps Plan as the alternate mode", () => {
const controls = getComposerControls("qoder")?.({
capabilities,
config: { model: "auto", mode: "plan", approvalPolicy: "default" },
isDisabled: false,
onConfigChange: vi.fn<(patch: Partial<ThreadConfig>) => void>(),
presentationMode: "gui",
});

expect(controls?.find(isModeControl)).toMatchObject({
label: "Plan",
isSelected: true,
});
});
});
25 changes: 25 additions & 0 deletions src/renderer/components/providers/qoder/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
export * from "./QoderIcon";

import { QoderIcon } from "./QoderIcon";
import providerManifest from "./manifest";
import { standardPlanApprovalControls } from "../composerControlBuilders";
import { registerProviderIcon } from "../ProviderIcon";
import { registerComposerControls } from "../providerComposer";
import { registerCommitGenDefaults } from "../commitGen";
import { registerConflictResolverDefaults } from "../conflictResolver";
import { registerTitleGenDefaults } from "../titleGen";

const PROVIDER_KIND = providerManifest.kind;
const QODER_UTILITY_DEFAULTS = {
label: "Qoder",
hint: "Auto",
model: "auto",
effort: "",
};

registerProviderIcon(PROVIDER_KIND, QoderIcon);
registerCommitGenDefaults(PROVIDER_KIND, QODER_UTILITY_DEFAULTS);
registerTitleGenDefaults(PROVIDER_KIND, QODER_UTILITY_DEFAULTS);
registerConflictResolverDefaults(PROVIDER_KIND, QODER_UTILITY_DEFAULTS);

registerComposerControls(PROVIDER_KIND, (input) => standardPlanApprovalControls(input));
8 changes: 8 additions & 0 deletions src/renderer/components/providers/qoder/manifest.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { msg } from "@lingui/core/macro";
import type { RendererProviderManifest } from "../providerManifest";

export default {
kind: "qoder",
label: msg`Qoder CLI`,
order: 37,
} satisfies RendererProviderManifest;
8 changes: 8 additions & 0 deletions src/renderer/locales/de/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Erstklassige OpenCode-Integration mithilfe der nativen SDK-Laufzeitumgeb
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Erstklassige Pi-Integration mit einem echten Terminal und Pis nativer SDK-Laufzeit."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Erstklassige Qoder CLI-Integration mit Poracodes nativen Terminal- und ACP-Laufzeiten."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Erstklassige Qwen Code-Integration mit Poracodes nativen Terminal- und ACP-Laufzeiten."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Push fehlgeschlagen: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Sende Aktualisierungen an gekoppelte Mobilgeräte, wenn Threads fertig sind oder dich brauchen, auch wenn die App geschlossen ist."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Fragen"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/en/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "First-class OpenCode integration using Poracode's native SDK runtime."
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "First-class Pi integration using a real terminal and Pi's native SDK runtime."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Push failed: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Questions"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/es/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Integración de primera clase de OpenCode usando el runtime nativo del S
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Integración Pi de primera clase con un terminal real y el entorno de ejecución SDK nativo de Pi."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Integración de primera clase con Qoder CLI mediante los entornos de ejecución nativos de terminal y ACP de Poracode."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Integración de primera clase con Qwen Code mediante los entornos de ejecución nativos de terminal y ACP de Poracode."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Error en el push: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Envía novedades a los dispositivos móviles emparejados cuando los hilos terminan o necesitan tu atención, incluso con la app cerrada."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Preguntas"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/fr/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Intégration OpenCode de première classe à l'aide du runtime SDK natif
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Intégration Pi de premier ordre avec un véritable terminal et l’environnement d’exécution SDK natif de Pi."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Intégration de premier ordre de Qoder CLI utilisant les environnements d’exécution natifs de terminal et ACP de Poracode."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Intégration de premier ordre de Qwen Code utilisant les environnements d’exécution natifs de terminal et ACP de Poracode."
Expand Down Expand Up @@ -7503,6 +7507,10 @@ msgstr "Échec du push : {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Envoyez des mises à jour aux appareils mobiles appairés lorsque les fils de discussion se terminent ou ont besoin de vous, même lorsque l’application est fermée."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Questions"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/ja/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4182,6 +4182,10 @@ msgstr "Poracode のネイティブ SDK ランタイムを使用したファー
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "実際のターミナルと Pi のネイティブ SDK ランタイムを使用する、完全な Pi 統合です。"

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Poracode のネイティブなターミナルおよび ACP ランタイムを使用する、Qoder CLI のファーストクラス統合です。"

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Poracode のネイティブなターミナルおよび ACP ランタイムを使用する、Qwen Code のファーストクラス統合です。"
Expand Down Expand Up @@ -7502,6 +7506,10 @@ msgstr "プッシュに失敗しました:{detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "スレッドが完了したり対応が必要になったりしたときに、アプリが閉じていてもペアリング済みのモバイルデバイスに更新をプッシュします。"

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "質問"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/ko/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Poracode의 기본 SDK 런타임을 사용한 최고 수준의 OpenCode
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "실제 터미널과 Pi의 네이티브 SDK 런타임을 사용하는 완전한 Pi 통합입니다."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Poracode의 네이티브 터미널 및 ACP 런타임을 사용하는 Qoder CLI의 일급 통합입니다."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Poracode의 네이티브 터미널 및 ACP 런타임을 사용하는 Qwen Code의 일급 통합입니다."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "푸시 실패: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "스레드가 완료되거나 응답이 필요할 때 앱이 닫혀 있어도 페어링된 모바일 기기로 업데이트를 푸시합니다."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "질문"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/pl/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Pierwszorzędna integracja OpenCode z wykorzystaniem natywnego środowis
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Pełna integracja Pi korzystająca z prawdziwego terminala i natywnego środowiska uruchomieniowego SDK Pi."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Pierwszorzędna integracja z Qoder CLI korzystająca z natywnych środowisk uruchomieniowych terminala i ACP w Poracode."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Pierwszorzędna integracja z Qwen Code korzystająca z natywnych środowisk uruchomieniowych terminala i ACP w Poracode."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Push nie powiódł się: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Wysyłaj aktualizacje na sparowane urządzenia mobilne, gdy wątki się kończą lub wymagają Twojej uwagi, nawet gdy aplikacja jest zamknięta."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Pytania"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/pt-BR/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Integração OpenCode de primeira classe usando o tempo de execução SD
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Integração Pi de primeira classe com um terminal real e o ambiente de execução SDK nativo do Pi."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Integração nativa com o Qoder CLI usando os runtimes de terminal e ACP do Poracode."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Integração nativa com o Qwen Code usando os runtimes de terminal e ACP do Poracode."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Falha no envio: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Envie atualizações para os dispositivos móveis pareados quando os tópicos terminarem ou precisarem de você, mesmo com o app fechado."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Perguntas"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/ru/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Первоклассная интеграция OpenCode с исполь
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Полноценная интеграция Pi с настоящим терминалом и нативной средой выполнения SDK Pi."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Первоклассная интеграция Qoder CLI с использованием встроенных сред терминала и ACP в Poracode."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Первоклассная интеграция Qwen Code с использованием встроенных сред терминала и ACP в Poracode."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Сбой push: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Отправляйте обновления на сопряжённые мобильные устройства, когда треды завершаются или требуют вашего внимания, даже когда приложение закрыто."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Вопросы"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/tr/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Poracode'un yerel SDK çalışma zamanını kullanan birinci sınıf Ope
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Gerçek bir terminal ve Pi'nin yerel SDK çalışma zamanı ile birinci sınıf Pi entegrasyonu."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Poracode'un yerel terminal ve ACP çalışma zamanlarını kullanan birinci sınıf Qoder CLI entegrasyonu."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Poracode'un yerel terminal ve ACP çalışma zamanlarını kullanan birinci sınıf Qwen Code entegrasyonu."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Push başarısız oldu: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Konular tamamlandığında veya ilginizi gerektirdiğinde, uygulama kapalıyken bile eşleştirilmiş mobil cihazlara güncellemeler gönderin."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Sorular"
Expand Down
8 changes: 8 additions & 0 deletions src/renderer/locales/uk/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4183,6 +4183,10 @@ msgstr "Першокласна інтеграція OpenCode з використ
msgid "First-class Pi integration using a real terminal and Pi's native SDK runtime."
msgstr "Повноцінна інтеграція Pi зі справжнім терміналом і нативним середовищем виконання SDK Pi."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qoder CLI integration using Poracode's native terminal and ACP runtimes."
msgstr "Повноцінна інтеграція Qoder CLI із використанням вбудованих середовищ термінала та ACP у Poracode."

#: src/renderer/views/SettingsOverlay/parts/agentRegistryNative.ts
msgid "First-class Qwen Code integration using Poracode's native terminal and ACP runtimes."
msgstr "Повноцінна інтеграція Qwen Code із використанням вбудованих середовищ термінала та ACP у Poracode."
Expand Down Expand Up @@ -7504,6 +7508,10 @@ msgstr "Збій push: {detail}"
msgid "Push updates to paired mobile devices when threads finish or need you, even when the app is closed."
msgstr "Надсилайте оновлення на спарені мобільні пристрої, коли треди завершуються або потребують вашої уваги, навіть коли застосунок закрито."

#: src/renderer/components/providers/qoder/manifest.ts
msgid "Qoder CLI"
msgstr "Qoder CLI"

#: src/renderer/components/thread/ThreadRuntimeRequestPanel/parts/QuestionSwitcher.tsx
msgid "Questions"
msgstr "Питання"
Expand Down
Loading