Forms are groups of interactive controls used to submit information from users. Form elements include text fields, labels, buttons, indicators, and controls to submit user information. Each element has a label and an interaction specific to the data submitted.
Forms have validation logic that produce error messages/alerts/warnings when required information is missing or incorrect. Warnings are provided to help users input the correct information and avoid mistakes.
Text fields show required information from users before the form can be submitted. Fields can include words, numbers, and percentage symbols. The float label moves up to the top of input field on left when user starts inputting information.
Note: this is a new box height (44px) and line height (20px). This keeps button and input fields at uniform heights.
Field states (1. default, 2. hover, 3. focus, and 4. completed) have specific border styles.
Form elements (input fields, buttons, etc.) are html-based elements. Each form element has a label, or a “float label”, that is displayed above the form input field. Various input options can be used based on design needs. Form fields and button sizes have a touch height uniformity that allows for better interaction and visual flow between form elements and reduces potential input errors.
The form button has the same font style as input fields and includes an outline secondary button variation. To distinguish secondary buttons from input fields, use a grey form background.
Error messages that are provided to let the user know that their input was not valid. These messages provide some indication of what needs to be changed. These messages include an icon and are also placed in close proximity to the error. The top error message box summarizes all errors on the page and is displayed at the top of the page. It includes a brief instruction and number of errors that need correction. The summarized list also anchors to each specific input error. This is also an alert.
Touch affordance allows the user to select an item on a touch screen interface and is important to ensure users easily understand where they can physically interact with touch targets. Proper touch affordance allows users of all abilities to select the intended target and avoid tapping the wrong element.
Example: Buttons must be large enough (or far enough away from other buttons/interactive elements) so they are easily clicked or tapped. Buttons should have a minimum 40px high/wide and 4px spacing between buttons (or 44px high/wide when touching/no margin).
Ensure designs meet color/contrast requirements on Color Guidelines and follow Schwab Accessibility guidelines.