Skip to main content

Module contract

Module contract 

Source
Expand description

moss HTML/CSS contract surface.

Federated sources for the moss design contract:

  • tokens: W3C Design Tokens (CSS variables, defaults, groups, descriptions)
  • components: emitter contract — class names, data attributes, examples

Consumed by the codegen binary at src-tauri/dev-bin/generate-artifacts.rs, by moss describe (Phase 2), and by snapshot tests.

Modules§

components
moss component contract — Source 2 of the federated contract.
custom_props
Theming escape hatches — Source 2b of the federated contract.
describe
Serializable payload for moss describe --json.
frontmatter
Serializer that maps [schema_fields::BUILTIN_FIELDS] into FrontmatterFieldJson entries for inclusion in the moss describe --json payload.
shortcodes
Shortcode authoring catalog — the single source for “what shortcodes exist, what attributes they take, and which of those name assets”.
sizes
sizes= attribute values for responsive image emission, per render context. Part of the theme-author surface: the values encode the DEFAULT theme’s layout (site.css). A theme that changes layout widths gets slightly suboptimal (never broken) fetches; overrides are a future contract extension, not built now (YAGNI).
tokens
W3C Design Tokens loader.