AlaskaAirlines / auro-input

Custom HTML element for inputting string data in forms
https://auro.alaskaair.com/components/auro/input
Apache License 2.0
2 stars 4 forks source link

auro-input: documentation is incorrect for "required" attribute error messages #282

Closed ethanwmiller closed 7 months ago

ethanwmiller commented 7 months ago

General Support Request

The docs at https://auro.alaskaair.com/components/auro/input#required are incorrect when describing how to add a custom error string on a required field.

What the docs say: "The error message for the valueMissing validityState can be changed to a custom string using the customValidityValueMissing."

However, customValidityValueMissing is incorrect. The actual attribute to use in code is setCustomValidityValueMissing. Seen here in the source code: https://github.com/AlaskaAirlines/auro-input/blob/3e30aa9e302bca440910b6fe9c7d326821b419e5/src/base-input.js#L31C38-L31C38

Possible Solution

Change customValidityValueMissing to setCustomValidityValueMissing in the documentation and include a code example of this being used.

Additional context

No response

Exit criteria

Documentation is corrected.

pgm369 commented 7 months ago

@Patrick-Daly-AA I have verified and validated this issue!