Workday Canvas

Search Input

Search Input and its consequential result views enable query functionality.

Sources
Figma

Anatomy

The basic elements of an alert dialog

  1. Input Container: Container of the input and its content.
  2. Search Icon: Fixed in the leading area of the input field to distinguish its functionality.
  3. Placeholder Hint Text: Customizable contextual information showing only when no text has been entered that highlights potential query capabilities.
  4. Back Navigation Tertiary Icon Only Button: Inactivates Search Input, returning a user back to their preceding view. Always appears when the input is active regardless of its context. May also appear in an inactive state if a user is exploring their query results. Navigational iconography here varies by platform.
  5. Input Text: Replaces Placeholder Hint Text when the user types.
  6. Close Tertiary Icon Only Button: Clears Input Text upon interaction.

Usage Guidance

When to Use

Use Search Input when content is not easily discoverable. When finding content proves time prohibitive, Search Input is a good option to quickly surface information.

When to Consider Something Else

  • Consider excluding Search Input in small datasets where information is easily findable. When a user presses on the input, a focus state is triggered where the Search Input temporarily disables other screen functionalities.
  • Consider using a more discoverable informational hierarchy when users heavily rely on search for orientation within a page or flow.

Please note that Search Input varies in how it can be surfaced across different features.

Persistent Search is when the input field is already visible on the screen without user action. Use Persistent Search when search is the primary focus of a feature, flow, or page.

Example of Search being viewable on a page by default

Expandable Search requires a user to tap on a search icon in order to access the input. Use Expandable Search when search is not the primary focus of a feature, flow, or page.

Example of Search being triggered from an icon in My Tasks

In addition to control over how it’s surfaced, feature teams may also control what content is available for querying.

Global Search queries content across the entire app. Global Search should always be Persistent.

Local Search queries content only within a certain feature or page. Local Search could be Persistent or Expandable.

Dataset Search queries content within a smaller UI element or pattern such as a Prompt. Dataset Search could be Persistent or Expandable.

Search results may also be populated differently using one or more than one of the following methods:

Typeahead

As users enter their queries, results populate using Lists, boldening what has been typed. Typeahead is recommended over other search paradigms such as controlled search where the results are not viewable until a user manually submits their query.

Example where matching strings in search results are being bolded

  1. <2 characters: no results display
  2. 3+ characters: Search results begin loading, using the skeleton loader until the results are available.
  3. Boldening: Matching strings from the user query are bolded. The ordering of these items may vary based on backend logic.

Suggestions

Suggested queries may be used in conjunction with Typeahead results. Suggestions are typically based on query history or semantic interpretations of a query. The addition of this search type should be accompanied by an added visual demarcation to separate these results from standard Typeahead.

Behaviors

Wrapping

Typed text stays in place until the input runs out of space. After running out of space, continuing to type will continue to move the text to the left.

Wrapping example with text scrolling off to the left to make space for new text

Clearing

Inputted text should always persist unless cleared by the user with the trailing Close Icon Button or an earlier screen is navigated back to. This allows users to quickly refine or refer back to their queries.

Example demonstrating the Clear Tertiary Icon Only Button pressed state

Exiting

To exit a search and return to their previous location, users must interact with the Back Navigation Icon Button.

Example demonstrating the Back Navigation Tertiary Icon Only Button pressed state

Scrolling

The Search Input should always revert to its inactive state with an upward or downward gesture. This allows a user to explore content on the rest of the page. A tap on the screen content without a gesture should not remove the focus state, as this may have been accidental.

Illustration of the input becoming inactive with either an upward or downward swipe on the screen

While inactive, the Search Input in Persistent Search should take over the Top App Bar when scrolling if it is querying content globally.

Search Input remains in the Top App Bar when scrolling

However, all other instances of an inactive Search Input should scroll away and reappear with gestures.

Search Input leaves the Top App Bar when scrolling

Examples

The Search Input only varies in its platform conventions for iconography.

iOS

Example with iOS navigation paradigm as a back chevron as opposed to an arrow

Android

Example with Android navigation paradigm as a back arrow as opposed to a chevron

API Guidelines

Methods

Class name: SearchInput Module name: UIComponentsPlugin

init( featureData: FeatureMetricsData, text: Binding<String>, placeholderHint: String?, backNavigationAction: (() -> Void)?, onSubmitAction: (() -> Void)?, localizer: LocalizationAdapting )

Parameters

NameDescription
featureDataThe feature name/context and the screen ID in which the component appears.
textThe search string
placeholderHintThe hint or prompt to display when text is empty. Defaults to “Search.”
backNavigationActionA back button is shown if a closure is provided
onSubmitActionA closure to run when the user submits their entry from the keyboard
localizerlocalizer for the field.

Accessibility Guidelines

Coming soon…

Can't Find What You Need?

Check out our FAQ section which may help you find the information you're looking for. For further information, contact the #ask-canvas-design or #ask-canvas-kitchannels on Slack.

On this Page: