v0.1.4-pre.011

This commit is contained in:
2026-08-16 15:14:37 +02:00
parent f0f2954236
commit 00361f22f4
15 changed files with 523 additions and 20 deletions

View File

@@ -1,5 +1,5 @@
// file: crates/ksp-app-config-desk/frontend/ts/main.ts
// version: 5
// version: 6
import "bootstrap";
import ResizeObserver from "resize-observer-polyfill";
@@ -8,6 +8,7 @@ import { getCurrentWindow } from "@tauri-apps/api/window";
import type { AppSnapshotDto } from "./bindings/ksp_app_config_desk/dto_common/AppSnapshotDto.ts";
import { frontendDebug, frontendInfo, frontendTrace, installFrontendConsoleBridge } from "./frontend_log";
import { initializeDocumentsPanel } from "./documents";
import { initializeEnvironmentPanel } from "./environment";
import { initializeProfilesPanel } from "./profiles";
import { invokeKsp } from "./invoke";
@@ -31,7 +32,7 @@ const viewCopy: Record<ViewId, { title: string; description: string }> = {
},
environment: {
title: "Environnement / .env",
description: "Rapports et management des variables KSP/KSPB — surfaces fonctionnelles prévues en pre.011/pre.012.",
description: "Rapport sûr desired/effective/source/shadow des variables KSP/KSPB ; mutations .env prévues en pre.012.",
},
logging: {
title: "Logging",
@@ -79,9 +80,13 @@ function activateView(viewId: ViewId, source: "startup" | "user"): void {
if (profiles) {
profiles.hidden = viewId !== "profiles";
}
const environment = document.querySelector<HTMLElement>("#environmentPanel");
if (environment) {
environment.hidden = viewId !== "environment";
}
const placeholder = document.querySelector<HTMLElement>("#placeholderPanel");
if (placeholder) {
placeholder.hidden = viewId === "overview" || viewId === "documents" || viewId === "profiles";
placeholder.hidden = viewId !== "logging";
}
frontendTrace("main", "Main view DOM updated", { viewId, source });
}
@@ -142,6 +147,7 @@ async function initializeMain(): Promise<void> {
bindNavigation();
initializeDocumentsPanel();
initializeProfilesPanel();
initializeEnvironmentPanel();
activateView("overview", "startup");
try {
await loadSnapshot();