mirror of
https://github.com/nexu-io/open-design.git
synced 2026-06-01 03:14:35 +07:00
Some checks failed
ci / Packaged mac smoke (push) Blocked by required conditions
ci / Packaged windows smoke (push) Blocked by required conditions
ci / Detect PR change scopes (push) Failing after 1s
ci / Validate workspace (push) Has been skipped
landing-page-ci / Validate landing page (push) Failing after 1s
landing-page-deploy / Deploy landing page (push) Has been skipped
nix-check / build (push) Failing after 1s
ci / Packaged linux headless smoke (push) Has been skipped
* fix(web): align Home prompt overlay with textarea so caret lands on click
Picking a chip such as Slide deck or Image loaded a default prompt
into the Home textarea and rendered an overlay with `{{key}}`
placeholders as interactive `<input>` / `<select>` controls. The
overlay controls and the underlying textarea text were laid out
independently:
- Inputs declared `min-width: 8ch` and `Math.max(displayValue.length
+ 1, 10)ch` of width.
- Selects added 18px of right-padding for the dropdown arrow.
- The textarea kept the raw substituted string in a proportional
font.
The two layouts no longer matched column-for-column, so every slot
shifted the textarea text to the left of where it appeared in the
overlay, compounding across the line. Clicking on visible prose to
position the caret hit a different character offset in the textarea
and subsequent typing or deletion landed in the wrong place.
For example, the Slide deck template
Create a {{slideCount}}-slide {{deckType}} for {{audience}} about
{{topic}}. ...
renders with slideCount=10 (~2 ch in the textarea) under a slot
input forced to 10 ch in the overlay — clicking right after the
literal `-slide` placed the caret several characters into `pitch
deck`. The Image / Video / Audio chips with their pre-filled
subject, style, aspect values reproduced the same drift.
Render the inline pills as read-only `<span>`s carrying the exact
substring the textarea shows at that position, mark them
`aria-hidden` so the textarea remains the single labelled control,
and surface every plugin input field — including the ones referenced
inline — in `PluginInputsForm` underneath. Editing flows through the
form, the parent's `updateActiveInputs` already re-renders the
prompt, and the pills stay aligned with the textarea on every
keystroke.
Also drop the now-unused inline helpers (updatePluginInput,
getTemplateInputNames, shouldRenderSlotAsText, inlineFieldType,
fileInputLabel, fileMetadata) and the dead
`.home-hero__prompt-slot-control/input/select/toggle/file/text` CSS
rules.
Verified:
- pnpm --filter @open-design/web typecheck
- vitest run on HomeHero.plugin-picker, HomeHero.rail, and
HomeView.prefill (29/29 pass; tests updated to reflect the new
read-only span + always-on form contract)
- Manual click-to-edit on Slide deck and Image chips in the
pnpm tools-dev web runtime — caret now lands where the user
clicked.
* Implement home audio essential workflow
* Fix Home media composer review issues
* Guard stale Home media apply results
---------
Co-authored-by: hahaplus <zmjdll@gmail.com>
73 lines
4.2 KiB
Markdown
73 lines
4.2 KiB
Markdown
# Open Design
|
|
|
|
Open Design is a local-first design workspace where projects contain generated design files and agent conversations. This glossary records domain language only, not implementation details.
|
|
|
|
## Language
|
|
|
|
**Project**:
|
|
A top-level design workspace that contains conversations and design files.
|
|
_Avoid_: repo, folder, session
|
|
|
|
**Normal Artifact**:
|
|
A project design output represented by an artifact entry file and its artifact manifest.
|
|
_Avoid_: live artifact, generic file upload
|
|
|
|
**Live Artifact**:
|
|
A refreshable project design output stored as a live-artifact record with source data and preview state.
|
|
_Avoid_: normal artifact, static artifact
|
|
|
|
**Artifact Entry File**:
|
|
The primary project file that opens or renders a normal artifact.
|
|
_Avoid_: support file, asset, sidecar
|
|
|
|
**Artifact Manifest**:
|
|
The sidecar metadata that identifies a project file as a normal artifact and records its kind, renderer, exports, and entry file.
|
|
_Avoid_: live-artifact document, project metadata
|
|
|
|
**Active Project**:
|
|
The project the user most recently interacted with in the Open Design UI and that MCP tools may use when no project is specified.
|
|
_Avoid_: latest project, default project
|
|
|
|
**Home Composer Media Surface**:
|
|
A Home-only composer intent that lets the prompt card expose media-specific defaults before project creation. The current media surfaces are `image`, `video`, `hyperframes`, and `audio`; they map onto the existing project kinds at submit time instead of extending the backend `ProjectKind` union.
|
|
_Avoid_: project kind, backend kind
|
|
|
|
**Chip Rail**:
|
|
The row of intent chips below the Home prompt card. A chip chooses the composer surface, default scenario plugin, default option state, and project kind stamp before the user presses Run.
|
|
_Avoid_: plugin list, template list
|
|
|
|
**HyperFrames Composer Surface**:
|
|
A standalone Home composer media surface shown between Video and Audio for HTML-based motion generation. It submits as `kind: "video"` with `videoModel: "hyperframes-html"` so persisted projects keep the existing video backend shape while the Home UI still gives HyperFrames its own entry point.
|
|
_Avoid_: new project kind, separate backend media kind
|
|
|
|
**Essential Audio Generation**:
|
|
A Home Audio entry workflow for the audio capabilities that the product can attempt directly in v1. It includes speech and sound effects, and excludes music until there is an integrated music generation path.
|
|
_Avoid_: audio studio, full music workflow
|
|
|
|
**Audio Source Field**:
|
|
The inline Home Audio option that provides the source content for generation. Speech uses a Text source because the content is spoken; sound effects use a Prompt source because the content describes a sound to synthesize.
|
|
_Avoid_: generic subject field, hidden prompt text
|
|
|
|
**ElevenLabs Fallback Voice**:
|
|
The default voice option shown when the Home Audio composer cannot load configured ElevenLabs voices. It keeps ElevenLabs speech runnable by selecting the same default voice id the daemon uses when no explicit voice is supplied.
|
|
_Avoid_: required credential setup, empty voice selector
|
|
|
|
## Relationships
|
|
|
|
- A **Project** contains zero or more **Normal Artifacts**.
|
|
- A **Normal Artifact** has exactly one **Artifact Entry File**.
|
|
- A **Normal Artifact** has exactly one **Artifact Manifest**.
|
|
- A **Live Artifact** belongs to a **Project** but is distinct from a **Normal Artifact**.
|
|
- An **Active Project** can be used as the target for MCP operations when the caller omits an explicit **Project**.
|
|
- A **Home Composer Media Surface** maps user intent to an existing project kind and project metadata at submit time.
|
|
- The **Chip Rail** is the visible Home entry point for choosing a **Home Composer Media Surface**.
|
|
- **Essential Audio Generation** uses an **Audio Source Field** plus model options before creating an audio **Project**.
|
|
|
|
## Example dialogue
|
|
|
|
> **Dev:** "When a coding agent creates a Codex deck through MCP, should it create a live artifact?"
|
|
> **Domain expert:** "No. Unless the user asked for refreshable data, create a **Normal Artifact**: write the **Artifact Entry File** and persist its **Artifact Manifest** in the **Active Project**."
|
|
|
|
## Flagged ambiguities
|
|
|
|
- "artifact creation" was used to mean both **Normal Artifact** creation and **Live Artifact** creation; resolved: this capability creates **Normal Artifacts** only.
|