Skip to main content

MultipleCombobox

Note: There are deprecated versions of this component. For documentation, see the Dropdown (deprecated) page.

Usage​

Overview​

The dropdown component presents users with a set of options from which they select. Dropdowns progressively disclose options, preventing users from seeing too much information at one time. They can also be used to group information. Dropdowns are always supported by a field label or title that is positioned before the control.

This component comes in four variants: select, multiple select, combobox, and multiple combobox.

The multiple combobox variant of the dropdown enables users to filter longer lists to only the selections matching a query. The user can select multiple options from the list.

image depicting component variants dropdown left multiselect right

When to use​

  • There's a large number of options (6 or more) from which users can select multiple values.
  • The list of selections is complex enough to merit searching and filtering.

When not to use​

  • If the list of selections is not complex enough for a combobox, you can use the dropdown multiple select.
  • There's a small number of options (5 or fewer) from which users can choose. Use checkboxes for multiselect items.

Source: Nielsen Norman Group

Formatting​

Anatomy​

image depicting the anatomy of the dropdown component Anatomy of the dropdown component, multiple combobox variant.

  1. Label: Describes the purpose of the input field.
  2. Help text (optional): Gives extra context or helps the user choose the right selection.
  3. Dropdown input: Displays the user selected options. Users can type inside the input field to find an option that matches their query.
  4. Dropdown menu: Displays a list of options to choose from.

Typeahead​

Jutro accommodates dropdown menus with typeahead input fields. Users can manually enter text to filter the dropdown items. This feature is useful for helping users select from a long list.

Dropdowns with typeahead enabled provide suggestions as users begin typing. Selections appear based on the characters that users have entered. The more characters that users input into the field, the more refined the list becomes.

image depicting dropdown component with typeahead functionality

Order of options​

When using the dropdown for sorting purposes, consider arranging options in order. For example:

  • From most common to least common option
  • From simplest to most complex operation
  • From least to most risky option

The first option would appear at the top of the list.

Avoid arranging the list of options alphabetically unless it makes sense for your use case. Lists of countries and other known-item problems are often fine to alphabetize. However, you do need to ensure that users will know unambiguously the name of their selection.

Source: Nielsen Norman Group

Content​

General writing guidelines​

  • Use sentence case for all aspects of designing Guidewire product interfaces. Don't use title case.
  • Use present tense verbs and active voice in most situations.
  • Use common contractions to lend your copy a more natural and informal tone.
  • Use plain language. Avoid unnecessary jargon and complex language.
  • Keep words and sentences short.

Include a label​

Place the dropdown label outside of the field so that it's always visible. A dropdown without a label is not accessible.

Don't replace field labels with in-field placeholder text. This hurts usability and has many negative consequences.

Do position a permanent label outside the field.
Don't use placeholder text as a replacement for the field label.

Add help text if it's meaningful​

Use help text to show context and communicate what to select or how to select an option. Here are some examples of what you might include in help text:

  • An overall description of the dropdown options
  • Hints that assist the user in choosing the right selection
  • More context for why a user needs to make a selection

Only use help text for pertinent information. Avoid using help text that simply restates the same information that appears in the label.

Use sentence case for help text. Write 1-2 short, complete sentences that end with a period.

Do use help text to show context.
Don't use help text to simply restate the same information that appears in the label.

Don't use placeholder text​

Don't put placeholder text in the text entry field. Placeholder text strains users' short-term memory because it disappears once a value is entered. It also poses additional burdens for users with visual and cognitive impairments.

Instead, place hints and instructions outside of the field.

The input field for multiple combobox follows the content guidelines for text fields.

Source: Nielsen Norman Group

Do place hints and instructions outside of the field.
Don't add placeholders to text entry fields.

Use error text to guide users​

Error message text tells a user how to fix the error. In the case of the dropdown, errors are often related to something that must be fixed for in-line validation. For example, if someone doesn't select a risk factor and this is a required field, you can use error text to guide the user to a solution: “Select one or more risk factors.”

Use sentence case for error text. Write 1-2 short, complete sentences that end with a period.

Do use error text to guide the user and show them a solution.
Don't write ambiguous error messages or leave users guessing as to how to resolve a problem.

Mark required fields​

Use an asterisk (*) to indicate required fields. The asterisk precedes the field label. This helps users to easily locate which fields are required by scanning just the left-most character of the label.

In addition to marking required fields with an asterisk, it is recommended to include clear instructions at the top of the form, such as "All fields marked with an asterisk are mandatory," to ensure users understand the meaning of the asterisk.

Do use an asterisk to indicate that a field is required.
Don't use an asterisk to denote anything that is optional.

Use sentence case​

Field labels and menu items appear in sentence case.

Refer to the UI text style guide for more information on how to implement sentence case.

Do use sentence case.
Don't use title case.

Behaviors​

States​

The multiple combobox variant appears with no value (default), placeholder text, or a filled input.

VisualStateDescription
Multiple combobox input with no valueNo value (default)Indicates to the user that no value has been selected and there is no placeholder.
Multiple combobox input with placeholder textPlaceholderIndicates to the user that no value has been selected. The placeholder is grayed out.
Multiple combobox input filledFilled inputIndicates to the user that the input is filled with data.

Multiple combobox also has interactive states for enabled, focus, disabled, error, read-only, and display-only.

StateDescription
EnabledIndicates to the user that the element is enabled for interaction.
FocusIndicates to the user which UI element in the system is focused.
DisabledIndicates to the user that the input value can't be changed because of local factors. For example, a checkbox above the input field must be checked to access this input field. The user can take action to enable it by interacting with the page.
ErrorIndicates that the user has made a validation error. Error text provides corrective feedback to users.
Read-onlyIndicates to the user that the input value can't be changed because of outside factors. For example, lack of write access. The user can take action to enable it by, for example, contacting an administrator.
Display-onlyThe display-only state is used for two cases:
  • A UI element is used in display mode.
  • A UI element is displayed in edit mode, but is never editable.
This state was called “read-only” before.

The following image illustrates multiple combobox interactive states.

Image illustrating multiple combobox interactive states: enabled, focus, disabled, error, read-only, and display-only

Interactions​

Mouse​

Users can interact with this element by clicking in the area inside border.

Image illustrating user interaction with dropdown component using mouse

Keyboard​

The dropdown is expanded and collapsed using the Spacebar. Users navigate through the options using the arrow keys and select by means of the Spacebar or Enter key.

Screenreader​

The aria-labelledby establishes a programmatic association between the input field and its label. The WAI-ARIA attribute of aria-autocomplete='list' communicates that a list of choices will appear from which the user can choose, but the edit box retains focus. Selecting the 'required' option in Storybook adds both the 'required' and 'aria-required="true"' attributes to the input field.

Accessibility​

This component has been validated to meet the WCAG 2.2 AA accessibility guidelines in its default, base configuration. This includes ensuring:

  • The contrast ratio of textual elements against their background is above 4.5:1.
  • Non-textual content that needs to convey meaning (like icons and focus indicators) has a contrast ratio of at least 3:1 with its adjacent colors.
  • The item is operable using a keyboard, as well as using a mouse.
  • Content is accessible using screen readers, such as JAWS and VoiceOver.

Accessibility conformance ultimately depends on how this component is implemented and customized. Changes made by the content author can affect accessibility. For details on our shared responsibility model, please review our full Jutro accessibility statement.

When using this component within your application:

  • Assist users in understanding the content by avoiding very long option names.
  • Avoid using implicitly focusable elements such as buttons, checkboxes and links, or implicitly semantic content such as headings within your dropdown components.