OOUI/Layouts/Fields and Fieldsets

One of the most commonly used layouts is the FieldsetLayout, which is composed of one or more FieldLayouts that contain an individual widget, such as a form input.

Both FieldsetLayouts and FieldLayouts can be configured with a label. A FieldLayout can also be configured with help text, which is accessed by the user via a help icon in the upper right corner of the field.

Note that each FieldLayout requires a widget object (e.g., a button or input field), which should be specified by reference before any optional configuration settings. A FieldsetLayout can only contain FieldLayouts, and an error will be thrown if another type of object is included directly.'''

Field labels are aligned in one of four ways: For a full list of supported methods and configuration options, please see the code-level documentation for FieldsetLayouts and FieldLayouts.
 * left: The label is placed before the form field (or other object) and aligned with the left margin. A left-alignment is used for forms with many fields.
 * right: The label is placed before the form field and aligned to the right margin. A right-alignment is used for long but familiar forms which users tab through, verifying the current field with a quick glance at the label.
 * top: The label is placed above the form field. A top-alignment is used for brief forms that users fill out from top to bottom.
 * inline: The label is placed after the form field and aligned to the left. An inline-alignment is best used with checkboxes or radio buttons.