Field
Connect a label, input, and supporting text.
Before you adopt
- Item
- component/field
- Status / implementation
- Native HTML · CSS · DOM
- Data scope
- Local example · product persistence, authentication and operations require separate implementation
- Framework
- 7 Dimensions · Primitive → Brand → Semantic → Component
- Tokens
- klic.
Original DESIGN.md is Korean. Token IDs and source code are not translated.
klic_get_item({"kind":"component","id":"field"})Use the package
bun add [email protected]import component from 'klic-design/components/field';
import 'klic-design/components.css';
// Native HTML reference; initialize the needed behavior separately.
const html = component.forms[0].html;Includes 5 HTML reference forms. Initialize the required behavior separately.
Get source files
Creates a standalone workspace with editable source, dependencies and licenses. It does not insert files into an existing project.
curl --fail --location --output klic.mjs https://design.klic.co.kr/integrations/klic.mjs
bun ./klic.mjs add component field --out ./klic-fieldView shared design criteria
Shared design criteria
Policy revision: 6f9c8f5e4d7c767f79a7db999670fb4d0936e07acb1b472fe162a7a9ade60c97
Canonical policy: https://design.klic.co.kr/api/v1/design-system.json
Read the same criteria and revision in API, CLI, MCP and WebMCP designSystem responses and the bundled KLIC-DESIGN-SYSTEM.json. Item contracts link through item.design.system.
| Dimension | Token responsibility | Structure and behavior responsibility |
|---|---|---|
| Size and proportion | Control sizes, icons and content width | Component recipes and the DOM ensure min-height, padding, wrapping and actual hit areas. |
| Typography | Registered font families, role sizes and weights | Supported recipes define line height, tracking, wrapping and responsive conditions without assuming unregistered token types. |
| Color and contrast | Role colors for actions, selection, text, borders and status | Labels, icons and state attributes convey meaning; measure actual composited-surface contrast separately. |
| Layout and alignment | Registered spatial roles, including maximum content and panel widths | DOM reading order, layout transitions, scroll ownership and Portal structure |
| Spacing and grouping | Internal gaps, padding, group spacing and approved density mappings | Maintain label, fieldset, legend and describedby relationships; window width alone does not change density. |
| Surface and depth | Surface colors, radii, borders and supported color/dimension material leaves | Blur and shadow recipes, stacking, auxiliary-panel versus modal behavior and opaque fallbacks |
| Interaction and feedback | Visual roles for focus, selection, progress, success, warnings and errors | Keyboard operation, focus movement, asynchronous transitions, execution blocking, input preservation and recovery |
Only Primitive owns literals. Preserve adjacent Brand→Primitive, Semantic→Brand and Component→Semantic references.
Distinguish token definitions, structural conditions in DOM/CSS recipes and compiled final literals.
Keep motion recipes in a read-only catalog separate from component and block installation items, with browser search and details in the existing KLIC Interface Library #motion view. The read API, CLI, MCP and WebMCP use one canonical catalog. The scope is all 884 user-supplied source patterns in 67 categories, grouped within the existing KLIC category/item navigation. Remove the previous simplified 280-item catalog and its dedicated routes and aliases; do not retain them as compatibility entries. Preserve source id + pattern identity, source engine, choreography, timing, paths, layers, SVG/inline/WAAPI alpha, and original notices including Copyright © 2026 acc0mplish. All rights reserved. and the supplied license. Never label this source material KLIC-authored. Adapt appearance through existing four-layer KLIC token paths for color, fonts, surfaces, borders, radius and spacing. Canvas uses the same palette and font tokens; scope demo CSS to each item. Use one owned runtime for previews and JavaScript/React delivery; do not claim CSS alone reproduces Canvas playback. KLIC adaptations use the blue/navy/neutral palette and reduced-motion, replay and cleanup contracts; verify real playback in light/dark and mobile before release. The npm package remains separate from the homepage: describe candidate exports only after checking the published manifest, and do not infer release contents from current source.
Allowed preset scope
A preset combines approved settings of an existing API. It is not a fifth token layer.
Use an explicit allowlist of size, variant, density, layout and other settings supported by the actual component API.
- Labels, descriptions and business data
- Value, selection, validation and request state
- Event handlers, recovery actions and permissions
- Raw style values, unregistered CSS variables and arbitrary token overrides
Component defaults → selected preset → permitted explicit settings. Pass business data, state and permissions separately.
Validate allowed keys, enums and combinations; diagnose unknown values. Distinguish type declarations from actual DOM and behavior verification.
Conflict resolution order
- Preserve information, operability and accessibility first: Preserve essential information, state meaning, input, focus and operation paths. Dimension numbers do not override other required contracts.
- Reflow structure and reading order: Adjust wrapping, columns, action groups and panel arrangement first. Use local scrolling only for areas whose meaning requires two dimensions.
- Adjust spacing and surfaces within approved bounds: Respect the selected density and text scale while adjusting spacing and decoration within approved recipes. Limited space alone does not justify automatic compact mode or smaller text.
- Record remaining constraints and verification: If defaults cannot resolve a constraint, record scope, alternatives, impact, FR/AT references and actual verification. Do not skip token layers or conceal failed checks with exception approval.
sources/checks identify supporting references, not certification. Record actual product-environment results in the existing FR/AT evidence.
Application and verification
Read the shared criteria, item DESIGN.md and actual source first. Assign token, DOM, CSS recipe and state responsibilities for each rule, then apply the conditions your product needs.
Compare revision in the policy and item contract. release identifies a registry publication; do not combine paginated results from different publications.
Use the latest CLI and local registry and restart stdio sessions. Reload the page to register WebMCP again. source prints raw code. Read DESIGN.md for source bundles or README.md for theme kits together with KLIC-DESIGN-SYSTEM.json.
Selective adoption of references
Treat external documents and drafts as proposals. Check current KLIC problems, implementation and contracts, adopt only necessary rules, and record scope and reasons for deferral or rejection.
Do not present product names, example APIs or references from a draft as facts about KLIC. Connect adopted rules to actual tokens, DOM, CSS recipes, state handling and verification evidence.
Scope to review together when making changes
Use a reported problem to assess impact across related usage paths. Changing only the named screen or tool does not complete that review.
- Implementation sources, tokens, components, types and schemas
- DOCS, web guides, developer documentation and examples
- MCP, CLI, WebMCP and API descriptions, inputs and responses
- AI prompts, llms.txt, source exports and theme exports
- Regression checks, builds, production publication and actual responses
After changing the canonical policy, regenerate affected guides, examples, tools, prompts and exports together and verify a matching revision. Explain unaffected paths and distinguish observed results from conditions that remain unverified.
designSystem JSON · Full architecture guide · Change and verification guide
Troubleshooting design choices
| Avoid this condition | Decision criterion |
|---|---|
| Do not communicate errors only through a toast that quickly disappears. | Use when requirements, validation results, or examples need to accompany an input. |
| Do not treat every keystroke as a final validation decision while the user is still entering a value. | Preserve input values and the user's position after failed submission. |
field · Inputs and selection · Component · Ready example · Sample data
When to use
- Use when requirements, validation results, or examples need to accompany an input.
- Preserve input values and the user's position after failed submission.
When to avoid
- Do not communicate errors only through a toast that quickly disappears.
- Do not treat every keystroke as a final validation decision while the user is still entering a value.
Accessibility and keyboard
- Communicate required conditions through required, not only a decorative asterisk.
- Keep aria-invalid, error text, and aria-describedby consistent with the same state.
- Do not reset values, focus, or user-authored content merely to clear an error.
Recommended density
- compact: Use only for repetitive administrative input. Preserve help text, errors, and actual click targets.
- normal: The recommended default density. Preserve reading order and the grouping of labels, controls, and feedback.
- relaxed: Recommended for first-time forms and detailed guidance. Increase spacing between field groups.
States and recovery
- loading: Indicate progress and prevent duplicate requests. Preserve existing data while updates are in progress.
- empty: Do not mark initially empty inputs as errors. Explain requirements before submission.
- filtered: Distinguish an empty search result from missing data and provide an action to reset filters.
- error: Preserve input values and associate each error description with its field.
Four-layer token mapping
| Token path | CSS variable | Purpose |
|---|---|---|
klic.component.field.spacing.internal | --klic-component-field-spacing-internal | Internal spacing between label, input, and help text |
klic.component.input.size.default.height | --klic-component-input-size-default-height | Minimum height of input controls |
klic.semantic.color.danger | --klic-semantic-color-danger | Error text and border |
klic.semantic.color.focus | --klic-semantic-color-focus | Focus indicator that coexists with errors |
Implementation scope and verification
- The current field-demo uses a native email input with a directly associated error message. Submission performs a simple email-format check; there is no real email delivery or server validation.
- Test the complete sequence: invalid value → focus → correction → resubmission.
- Check the associated reading of help and error text.
- Press Enter using an actual Korean IME.
Adoption guidance, not a verification certificate. Preview data and behavior are local demonstrations.
Field Download DESIGN.md · Design contract JSON
Compare alternatives
| Item | When to choose it | Status |
|---|---|---|
| Autocomplete | Combine free-form input with familiar suggestions. | ready |
| Button | Make intent clear and actions natural. | ready |
| Cascader | Update child choices based on a parent selection. | ready |
| Checkbox | Make one or several explicit selections. | ready |