Page MenuHomePhabricator

Investigate default error behavior of Codex components in light of updated error styles
Closed, ResolvedPublic1 Estimated Story Points

Description

Background

As a result of error style changes made in T377977 and in reference to T370641, the style of the error states in form elements are being updated. For those who can see the style update (a subtle red background color within the inputs), this calls even more attention to the input as an error. This means that we should be really intentional about when we build in error states natively into Codex components to be sure that we want to show this state. The error state should be shown when something is wrong and needs to be fixed. The error message within the field that houses the input should explain how to fix the error, but the style of the input helps to draw more attention to the item that needs to be fixed. More explanation can be found in a comment on T377977.

Examples

Compare the old version:

Screenshot 2024-10-27 at 1.30.10 PM.png (1,312×314 px, 26 KB)

With the new version:

Screenshot 2024-10-27 at 1.30.42 PM.png (1,304×310 px, 25 KB)

...I do think we might want to reconsider what we consider an "error" by default in that case (and duplicate text inside a ChipInput might not meet that threshold).

The more prominent an error style is, the more cautious we should be about applying it IMO – otherwise we may be causing the user some unnecessary stress/anxiety.

Outcome

ChipInput is the only component which has built-in validation behavior of this sort. We will address this in T378631.

Acceptance criteria

  • Determine if and which Codex components' native error behavior needs to be updated.
  • Make updates to components which we determine need to be updated

Event Timeline

DTorsani-WMF renamed this task from [placeholder] Investigate default error behavior of Codex components in light of updated error styles to Investigate default error behavior of Codex components in light of updated error styles.Oct 28 2024, 6:46 PM
DTorsani-WMF updated the task description. (Show Details)

After going through demos for all input type components, ChipInput is the only one I have determined has default error behavior built in. We should discuss if this is something we want to keep as-is, keep but reconsider the behavior, or remove.

Ok – I've filed T378631 which we can pick up next sprint potentially. It should be a simple change.

egardner updated the task description. (Show Details)