feat: add main features

Agents for developpement added + frontend add + backend added. Git viewer created + agent and template creator + layout and project creator
This commit is contained in:
2026-06-06 01:27:01 +02:00
parent 55b3bee2c8
commit 307ae71857
273 changed files with 48740 additions and 0 deletions

View File

@ -0,0 +1,56 @@
/**
* Tauri adapter for {@link LayoutGateway} (L4). Together with the sibling
* adapters this is the *only* place that calls `invoke()`; components reach it
* exclusively through the port.
*
* Commands and payload keys are camelCase, matching the backend DTO convention.
* The `load_layout`/`mutate_layout` commands return the layout tree directly
* (the backend `LayoutDto` is `#[serde(transparent)]` over the tree).
*/
import { invoke } from "@tauri-apps/api/core";
import type { LayoutKind, LayoutList, LayoutOperation, LayoutTree } from "@/domain";
import type { LayoutGateway } from "@/ports";
export class TauriLayoutGateway implements LayoutGateway {
loadLayout(projectId: string, layoutId?: string): Promise<LayoutTree> {
return invoke<LayoutTree>("load_layout", { projectId, layoutId });
}
mutateLayout(
projectId: string,
operation: LayoutOperation,
layoutId?: string,
): Promise<LayoutTree> {
return invoke<LayoutTree>("mutate_layout", { projectId, layoutId, operation });
}
listLayouts(projectId: string): Promise<LayoutList> {
return invoke<LayoutList>("list_layouts", { projectId });
}
createLayout(projectId: string, name: string, kind?: LayoutKind): Promise<{ layoutId: string }> {
return invoke<{ layoutId: string }>("create_layout", {
request: { projectId, name, kind },
});
}
renameLayout(projectId: string, layoutId: string, name: string): Promise<void> {
return invoke<void>("rename_layout", {
request: { projectId, layoutId, name },
});
}
deleteLayout(projectId: string, layoutId: string): Promise<{ activeId: string }> {
return invoke<{ activeId: string }>("delete_layout", {
request: { projectId, layoutId },
});
}
setActiveLayout(projectId: string, layoutId: string): Promise<void> {
return invoke<void>("set_active_layout", {
request: { projectId, layoutId },
});
}
}