sium: v1.0 — schema core, domain types, i18n, Svelte adapter, AutoFields
Ship v1 of sium, the Schema-In-Use Module — soma's native validation layer.
Core (PR1): issue/result helpers, Schema<I,O> factory with ~standard + ~sium
wiring, 5 primitives (string/number/boolean/literal/enumOf), 3 modifiers
(optional/nullable/defaulted), 4 combinators (object/array/union/discriminated),
pipe + 4 step constructors (refine/transform/codec/meta), 7 refines
(min/max/length/regex/email/url/integer), barrel.
Domain types (PR2b): colorValue, dateValue, dateRange, timeValue + 15 segments
(year/month/day, hour/minute/second/dayPeriod, red/green/blue/hue/saturation/
lightness/brightness/alpha). All segments are kind:'number' + meta.channel —
keeps SchemaKind vocabulary tight at 14 entries.
i18n (PR2a): 15 stable issue codes, MESSAGES registry with English fallbacks,
siumLangs LangNode (es + en) for ext/lang integration, pure template resolver
with {{name}} syntax.
Svelte adapter (PR3): resolveIssue/resolveIssues bridge, createForm reactive
with $state/$derived + locale change reactivity + sync/async detection.
Form.AutoFields (PR4): Soma renderer driven by schema introspection. Widget
registry with 4-level priority (meta.widget → channel:X → kind:X → built-in).
Contract supports Component | Snippet widgets — compound widgets like
ColorPicker/Calendar compose inline without wrappers.
Polish (PR5): COOKBOOK with 12 recipes, GUIDE with vs-Zod comparison and
practical examples, kitchen-sink demo (src/routes/test/sium) with locale
switcher and live schema introspection panel, v1 readiness audit report,
doc consistency audit report, isColorValue hardening (rejects NaN + invalid
hex) after production bug report.
Coordination: all work tracked via protocol v2.1 (state.json + sharded orders
+ audit.mjs runner) in src/lib/sium/status/. 340+ tests, npm run check clean
(0 errors, 0 warnings against 28-budget).
Deferred to v1.1 (README §11.2): timeRange, lazy/recursive schemas, tuple/
record/intersection, bundle measurement, additional locales, jsDate coerce.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>