Skip to content

Restricting user input

JC Franco edited this page Jan 21, 2025 · 8 revisions

tags: [draft, conventions, components, development]

Intercepting and restricting user input is not always desired and can lead to unexpected behavior, so we have been moving away from this approach and leaving it up to developers to prevent input if this is necessary.

Considerations

  1. Handling of pasted data
  2. Assuming user text workflows – related to 1, but some users might be working with an existing piece of text that can be edited down to the desired input

Exceptions

  • When input is restricted to a deterministic range of values (e.g., hex color characters)