CogniSync
CogniSync Design System

Input

An input is a single-line field for short text such as names, email, and search.

States

Every state covered

Default, hover, focus (selected), disabled, and error. Error either renders on its own (just a red border + alert icon) or paired with an inline error message.

Default
Hover

Hover the field to see the border darken.

Selected (focus)

Click into the field. It gets a blue border and a soft glow.

Filled + clearable
Disabled
Error (no message)
Error with message
Error selected

Focus the field to see the error glow.

Sizes

Three sizes

Height, padding, icon size, and label type all scale together.

Size · Small

32px height, 13px text. Filters, inline edits, tables.

Size · Default

40px height, 14px text. The default for most forms.

Size · Large

48px height, 16px text. Hero forms, onboarding, log-in.

Label

Label, description, required, optional

The label sits above the field; an optional description gives context below the label. Use `required` or `optional` to flag the field.

Label only
Label + description

Unique handle used in the public URL. Only lowercase letters and numbers.

https://
.cognisync.com
Required
Optional
Optional

We'll only call if your rule triggers a critical alert.

Icons

Leading, trailing, and clearable

Put a leading icon for context (search, email, lock) and a trailing icon for state. The clear button replaces the trailing icon when the field has a value.

Leading icon
Email
Password (toggle)
Clearable
Addons

Attached prefix & suffix

Put constant bits of the value outside the editable area so users only type the variable part.

URL prefix
https://
Domain suffix
.cognisync.com
Currency
$
USD
Event date
CTA

With and without an attached CTA

Use the `cta` slot for single-line forms where the action belongs with the field \u2014 invites, copy-to-clipboard, search with a dedicated button.

Without CTA
With CTA
Search with CTA
Newsletter (error)
Chat prompt

Multi-line prompt field

A taller, pill-shaped cousin of Input made for AI chat. Auto-resizes as you type, pressing Enter submits (Shift+Enter adds a newline), and the send button animates between idle, active, and busy.

AI

Press Enter to send, Shift + Enter for a new line.

Press the arrow to send. Try typing then hitting Enter.

Structure

Anatomy

An Input is composed of these parts.

Label

Geist Medium. Indicates what to type. Pair with required (*) or optional (pill) flags.

Description

Optional 13px #64748B line between label and field for context or short hints.

Shell

1px border container. Shifts to #94A3B8 on hover, #0D65FC with a glow on focus, #DC2626 on error.

Leading icon / addon

Inline context (icon) or constant text prefix (addon) pinned to the leading edge inside the shell.

Field

The actual <input>. 13/14/16px body text, transparent background, inherits padding from the shell.

Trailing controls

Clear button, password toggle, error icon, or trailing icon/addon — only one renders at a time.

CTA

Optional Button sitting outside the shell with an 8px gap, sharing the field's height.

Hint / error message

Small 13px line below the field. Error message replaces hint and adds an alert icon plus role=“alert”.

Usage

Do & Don't

Do

  • Use a label for every input — never rely on placeholder alone.
  • Show an error border and inline message when validation fails. Clear both as soon as the user fixes the problem.
  • Match input size to the surrounding form (sm in filters, md in forms, lg in hero forms).
  • Use the CTA slot for single-action flows (invite, copy, search) and place multi-action forms in a dedicated layout instead.

Don't

  • Don't combine an error border with a blue focus glow — the component handles this for you.
  • Don't stack a leading icon and a leading addon — pick one to keep the leading edge calm.
  • Don't put long helper sentences inside placeholder text. Use the description or hint slot instead.
  • Don't build chat experiences with Input — use ChatPrompt for multi-line, keyboard-driven prompting.