Ooidget Component Format 0.1Editor's Draft
Conformance
Documents
A conforming document is a component file or bundle that is valid against the specification’s JSON Schema
(schema/ooidget.schema.json in the repository, JSON Schema 2020-12 [JSON-SCHEMA])
and meets every requirement this specification places on documents. Validity against the schema alone is necessary
but not sufficient: expressions must parse, and names must be well-formed.
Runtimes
A conforming runtime implements one of the profiles below completely, applies the fallback rules to everything outside it, and passes that profile’s tests.
Profiles
| Profile | Requires |
|---|---|
| Static | Documents, layers, effects, colour, expressions, styles and tokens, children without behaviours, flex layout. Renders a view; takes no input. |
| Interactive | Static, plus behaviours, events, input mapping, focus, regions, writing state, commands, accessibility. |
| Application | Interactive, plus size classes and variants, host slots, the platform’s text input, and the OOIDGET_app extension (windows, menus and chrome). |
| Full | Application, plus motion and painters. |
| Embedded | Interactive, over compiled bundles, on microcontrollers: line-by-line rendering, no allocation after start-up. See Embedded devices. |
A runtime states the profile it conforms to and the version of this specification, as “Ooidget 0.1 Interactive”.
Tests
The conformance suite (conformance/ in the repository) holds, for each test: one or more documents, a sequence of
inputs, the expected state after each input, and reference images at stated sizes and scales. A runtime passes a
rendering test when, at every pixel, each channel differs from the reference by at most 2 of 255 outside anti-aliased
edges, and by at most 64 of 255 on them, with no more than 0.5% of pixels at the edge tolerance.
The suite is run through a small test protocol: the runtime under test reads requests from standard input, one JSON
object per line (load, size, input, state, render), and answers each on standard output.