custom-element
formData The values of named form fields are populated into the slice as form-data on change or submit event. The field values can be used in form validation via custom-validity attribute and in condition to enabling the form parts formData MDN
custom-validity attribute applied on the form itself or on the form field. The value is an XPath over DCE datadom. When evaluated as boolean, it would enable(true) or disable(false) the form submission, acting as form validation mechanism. Alternatively, the value can be evaluated as a string which would be treated as an error and can be used as validation error message set as @validation-message attribute on the form slice. Look for email-form/@validation-message example on the page.
When custom-validity attribute is set on the field, its XPath evaluated value is propagated to validationMessage property. Which would be shown via browser system popup as the field validation error.
@validation-message is set either by custom-validity attribute or by browser as system message. By default, it is shown as popup on the field validation. But also is available for template as a string via form field attribute. Like in email-form/@validation-message.
//email-form/@validation-message: {//email-form/@validation-message}
//slice/username: {//slice/username}