Rituals pattern: slot form (fill in what a ritual needs) #178
Labels
No labels
build-dist
priority
P1
priority
P2
priority
P3
priority
P4
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Toilville/toilville-design#178
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of #177.
What it's for: the standard form for "fill in what this ritual or intent needs". The fields come from the ritual's slot list rather than a hand-built screen. This is the most-used pattern, and most of the others build on it.
Where it shows up today (four different versions)
_ParametersPanelinritual_execution_screen.dart:253RitualComposerView.swiftEnter <field>:text prompt per missing field (run_command.dart:88)ritual run:--field key=valueflags only, no promptingWhat the field list can describe today
key,label,type(text / textarea / enum / int / bool),required,mutability(sealed / fungible) anddefault_value. That's thin. Please design for these as well (engineering will add them to the API):Acceptance criteria
GateExpressionrules are needed (today there are onlyalwaysandrequired_filled; candidates arelength_at_least,matches_pattern,equals).Decisions for #178 (slot form). They answer the four acceptance criteria. The schema and API design belong to engineering.
Layout and marking
*. Optional fields have no marker. Each form says "* Required" once. The*has the accessible name "required" and uses the text colour, not the error colour.sectionblock.Field kinds
States
sealed(the author fixed the value) is separate from the sealed block in #189 (Grammar stops a lens from hiding it).Validation
Conditional fields
Rules
GateExpressionstays a step-level mechanism. #178 needs no newGateExpressiontypes.equals(conditional visibility, for example Audience = My team), andlength_at_leastandmatches_pattern(validation). They may share one rule vocabulary, so authors do not write the same check twice.CLI
*, and* Requiredis printed once at the start. Empty input skips an optional field. A required field is asked again.--field.Accessibility (Grammar)
Engineering follow-up, not part of this decision: schema fields for help text, placeholder, options, rules, visibility and field groups; renderers for radio, checkbox, secret, file and entity;
evaluateGatein Flutter; the required check ignoring hidden fields; existing labels that contain "(optional)" or "e.g."; blank optional fields in the Dart CLI.@peterswimm
Accepted (2026-10-20). The 2026-10-16 decision covers all four acceptance criteria:
Keep the 44px target. It's stricter than the WCAG 2.2 AA minimum of 24px, which is fine. The engineering follow-up is tracked separately, so this can close.
Closing — decided, and the engineering follow-up now exists.
Accepted on 2026-10-20. All four acceptance criteria are answered by the 2026-10-16 decision: the field kinds, the default/filled/invalid/disabled/sealed states, conditional fields, and the CLI prompts. The 44px target stays.
My acceptance said the engineering follow-up was "tracked separately". It was not — it is now: Toilville/rituals-api-spec#23.
Two things I found filing it, both worth you knowing because they affect what can be built from this decision rather than the decision itself:
slotscolumn oncore.patternsand no route emits one, so macOS always falls through to synthesising slots fromattributes.input_schemawithmutabilityhardcoded tofungible. The sealed state you specified is undeliverable until the contract carries it. The client's own test records this as an assertion rather than a bug (ForgeAPIClientPatternsTests.swift:131).form_schemais untyped in the API spec (additionalProperties: true), andattributes— the field the slot list actually travels in — is not declared at all. So there is no contract to add help text, option descriptions, rules, visibility or field groups to. That is the first item in #23.Neither needs a design answer.
GateExpressionstays step-level and needs no new types, as you decided.