feat(web): draft a custom preset in a creator-mode session

The settings section gains the conversational authoring entry beside
copying: a dashed add-card (the Models page's affordance) that stages the
self-referential cordis preset and starts a new session on it, closing the
settings panel through the shell's new section owner-prop `close` — the
one shell affordance a section receives, for flows that leave settings.

The seat learns the difference between picking and staging: `select()`'s
immediate apply meets the still-current running session and drops the
stage as unservable, so the entry uses `stage()` and leaves the apply to
the list-change applier that fires when the started session becomes
current. `load()` stops regressing the display when its reply lands after
an applied stage was consumed — staged pick first, then the composition
the current session already carries, then the deployment default.

The authoring lane connects a workspace and drives the gesture to a
composed host session; the section goldens gain the entry.
This commit is contained in:
Yichen Jiang
2026-08-09 00:19:18 +08:00
parent 564337997a
commit 43e93c6a67
16 changed files with 288 additions and 23 deletions

View File

@@ -87,7 +87,7 @@ function SettingsPanel({ rows, renderSlot, activeId, onSelect, onClose }: PanelP
</button>
</div>
<div className={css.options}>
{active !== undefined && renderSlot('settings.section', {}, { only: active })}
{active !== undefined && renderSlot('settings.section', { close: onClose }, { only: active })}
</div>
</div>
</div>

View File

@@ -83,12 +83,14 @@ export interface SettingsHeaderOwnerProps {
/**
* Owner share of a settings section entry. The shell owns modal visibility
* and navigation; sections receive nothing but the render site (their data
* arrives through their own inject faces and stores).
* and navigation; a section's data arrives through its own inject faces and
* stores. `close` is the one shell affordance a section receives, for flows
* that leave settings altogether (starting a session from a section) — the
* onboarding coordinator's `openSection`/`complete` precedent, inverted.
*/
export interface SettingsSectionOwnerProps {
/** Marker field: section owner props are intentionally empty for now. */
children?: never
/** Close the settings panel (the shell owns the open state). */
close: () => void
}
/** Owner share of the currently active settings-backed onboarding step. */