diff --git a/src/components/ui/Field.tsx b/src/components/ui/Field.tsx index 88d6c74a9..32e2a900a 100644 --- a/src/components/ui/Field.tsx +++ b/src/components/ui/Field.tsx @@ -16,8 +16,27 @@ export type FieldProps = { * or an empty string when the field is fine. */ error?: ReactNode; - /** Appends the conventional asterisk and sets `required` semantics visually. */ + /** + * Appends the conventional asterisk and carries the semantics through + * context, so the wrapped control also gets `aria-required` — the asterisk + * itself is `aria-hidden` and invisible to a screen reader. + * + * Presentation and ARIA, not constraint validation: this does **not** put the + * native `required` attribute on the wrapped control, so no `:required` + * styling and no browser "fill out this field" popup appear. The forms in + * this app validate themselves — guarded submit buttons, inline errors — and + * a label-level flag should not switch browser validation on behind their + * backs. Pass `required` to the control itself when the native attribute is + * wanted; the two stay separate on purpose. + */ required?: boolean; + /** + * Appends a visible "(optional)" to the label, the counterpart for fields the + * form genuinely does not need. Rendered inside the `