跳到主要內容

Sample contract · AUP cross-device · ARC 2.0.0-beta.28

`input` primitive

Author an unbound form control on document; keep bind and write paths off docs pages.

input is an AUP cross-device primitive, not a Web Device layout component and not a Web-only widget. It is one of the 18 names in AUP_PRIMITIVES and appears in every target's DeviceCaps.primitives map as native, webview, partial, or unsupported.

Contract

FieldValue
Primitive nameinput
LayerAUP cross-device primitive (AUP_PRIMITIVES)
Public statusreleased
Document capabilitynative
Shared degradation chainNone (document reports native)
Author entryAUP tree · Markdown ::input{…} (generic directive → type)
Document renderer / notesrenderer/primitives/input.ts; content-reader id promotion (arc#3321)
Showcase evidenceform-* Showcase pages; document path verified on live-example-contract

When to use

You need a form control (text, select, checkbox, …) as a semantic node.

When not to use

Do not put bind, multi-field forms, or session writes on a public docs page. Give every field an explicit id.

Sample contract

FieldValue
PurposeUnbound document-target input
BoundariesNo bind, session patch, AFS write, exec, or multi-field form product
Author entry::input{…}
SurfaceWeb Device document
Public statusreleased
Fallback / failureMissing id → unstable DOM id across fields; unknown type may degrade presentation
VerificationRoutes below · arc --version = 2.0.0-beta.28

Document sample (unbound text input)

This field is an unbound AUP input. Typing changes only the browser form control. No document, manifest, AFS record, or session setting is written.

Source:

markdown
::input{id="docs-prim-input-name" type="text" label="Name" placeholder="Type only in this example" value="Ada"}

Rendered:

Additional control (checkbox)

Source:

markdown
::input{id="docs-prim-input-ack" type="checkbox" label="I understand this stays local"}

Rendered:

Full shared contract: Live examples: scope and contract.

Failure and limits

SituationExpected result
No id on ::inputField still renders; DOM id is unstable across fields on the same page
bind / session fields in Markdown hereNot part of this contract; do not invent them on a docs page
Multi-field live form with submitOut of contract for public docs
Narrow viewportLabel, control, and placeholder remain readable

Verification evidence

ItemValue
Baseline2026-08-09 · arc --version → 2.0.0-beta.28
Capability rowdocs/aup/capability-matrix.md (internal, non-routed) · input · ::input
Implementationcontent-reader.ts (id promotion); renderer/primitives/input.ts
Public routes/en/docs/aup/primitives/input/ · /zh/docs/aup/primitives/input/
Local runarc service start --blocklet blocklets/arcblock --port 4900 · type in the field; reload may restore browser form state only
AcceptSource matches control; typing stays local; no network write on change

Evidence anchors

ItemValue
Registrypackages/aup/src/aup-types.ts · AUP_PRIMITIVES
Document capsproviders/runtime/web-device/src/device-caps.ts · DEVICE_CAPS_DOCUMENT
Degradationpackages/aup/src/degradation.ts · DEGRADATION_CHAINS
Internal matrixdocs/aup/capability-matrix.md (internal, non-routed)
Taxonomy hubPrimitive taxonomy and evidence
Sample contract rulesLive examples: scope and contract

Nearby pages