fix: remove redundant settings overview
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<script lang="ts">
|
||||
import { workspaceRoute } from '$lib/workspace/api/http';
|
||||
import { SETTINGS_SECTIONS, SETTINGS_ROUTE, settingsSectionHref } from '$lib/workspace/settings/model';
|
||||
import { SETTINGS_SECTIONS, settingsSectionHref } from '$lib/workspace/settings/model';
|
||||
import type { SidebarSnippet } from './context';
|
||||
|
||||
let {
|
||||
@@ -13,8 +13,6 @@
|
||||
content?: SidebarSnippet | null;
|
||||
} = $props();
|
||||
|
||||
let settingsHref = $derived(workspaceId ? workspaceRoute(workspaceId, SETTINGS_ROUTE) : SETTINGS_ROUTE);
|
||||
|
||||
function sectionHref(path: string): string {
|
||||
return workspaceId ? workspaceRoute(workspaceId, path) : path;
|
||||
}
|
||||
@@ -25,24 +23,12 @@
|
||||
</script>
|
||||
|
||||
<div class="settings-sidebar">
|
||||
<div class="section-heading">
|
||||
<h2>Settings</h2>
|
||||
</div>
|
||||
|
||||
{#if content}
|
||||
{@render content()}
|
||||
{:else}
|
||||
<nav class="sidebar-sections" aria-label="Settings sections">
|
||||
<div class="sidebar-nav-section">
|
||||
<div class="sidebar-list">
|
||||
<a
|
||||
class:active={currentPath === settingsHref}
|
||||
class="sidebar-link"
|
||||
href={settingsHref}
|
||||
aria-current={currentPath === settingsHref ? 'page' : undefined}
|
||||
>
|
||||
<span class="sidebar-link-label">Overview</span>
|
||||
</a>
|
||||
{#each SETTINGS_SECTIONS as section}
|
||||
{@const href = sectionHref(settingsSectionHref(section.id))}
|
||||
<a
|
||||
|
||||
@@ -1,59 +0,0 @@
|
||||
<script lang="ts">
|
||||
import { workspaceRoute } from '$lib/workspace/api/http';
|
||||
import { SETTINGS_SECTIONS, settingsSectionHref } from '$lib/workspace/settings/model';
|
||||
import type { PageProps } from './$types';
|
||||
|
||||
let { data }: PageProps = $props();
|
||||
let workspaceId = $derived(data.workspace?.workspace_id ?? '');
|
||||
|
||||
function href(path: string): string {
|
||||
return workspaceId ? workspaceRoute(workspaceId, path) : path;
|
||||
}
|
||||
</script>
|
||||
|
||||
<section class="settings-card">
|
||||
<div class="settings-card-header">
|
||||
<div>
|
||||
<p class="eyebrow">Overview</p>
|
||||
<h2>Settings areas</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class="settings-section-grid">
|
||||
{#each SETTINGS_SECTIONS as section}
|
||||
<a class="settings-section-card" href={href(settingsSectionHref(section.id))}>
|
||||
<span class="section-status-pill">{section.status}</span>
|
||||
<h3>{section.label}</h3>
|
||||
<p>{section.summary}</p>
|
||||
</a>
|
||||
{/each}
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="settings-card">
|
||||
<div class="settings-card-header">
|
||||
<div>
|
||||
<p class="eyebrow">Backend pattern</p>
|
||||
<h2>Authority boundaries</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class="settings-pattern-grid">
|
||||
<article>
|
||||
<h3>Backend-owned state</h3>
|
||||
<p>
|
||||
Workspace metadata and Decodal profile sources are edited through Backend APIs, not direct frontend filesystem access.
|
||||
</p>
|
||||
</article>
|
||||
<article>
|
||||
<h3>Runtime inputs</h3>
|
||||
<p>
|
||||
Runtime execution receives explicit resources and WorkingDirectory handles; raw workspace paths stay out of Browser-facing payloads.
|
||||
</p>
|
||||
</article>
|
||||
<article>
|
||||
<h3>Diagnostics first</h3>
|
||||
<p>
|
||||
Settings mutations return typed diagnostics so validation issues are visible without exposing internal paths or credentials.
|
||||
</p>
|
||||
</article>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
Reference in New Issue
Block a user