eQuantic.UIeQuantic.UI
Docs
Playground
GitHub
START HERE
Getting Started
WRITE-ONCE
Write-Once Components
Declarative Surface
Photon Engine
Design System
Capabilities
Storage
Forms
Code Editor
Markdown
Mermaid
Email Rendering
ARCHITECTURE
Architecture Overview
Package Architecture
Components
Styling
Localization
Analytics & GTM
COMPILATION
Compiler
Compile-Time Evaluation
Supported C# Features
External Type Resolution
Build Flow
Diagnostics
RUNTIME
Runtime (TypeScript)
Performance
SERVER
Server Integration
Assets
BunPackage
Security
ECOSYSTEM
Image
Charts
Icons
Lottie
DEVELOPMENT
Visual Editor
Debug
Roadmap
PT-BR
Analytics-pt-BR
Architecture-pt-BR
Assets-pt-BR
BuildFlow-pt-BR
BunPackage-pt-BR
Capabilities-pt-BR
Charts-pt-BR
CodeEditor-pt-BR
Compiler-pt-BR
CompileTimeEvaluation-pt-BR
Components-pt-BR
Debug-pt-BR
DeclarativeSurface-pt-BR
DesignSystem-pt-BR
Diagnostics-pt-BR
EmailRealizer-pt-BR
ExternalTypeResolution-pt-BR
Forms-pt-BR
GettingStarted-pt-BR
Home-pt-BR
Icons-pt-BR
Image-pt-BR
Localization-pt-BR
Lottie-pt-BR
Markdown-pt-BR
Mermaid-pt-BR
PackageArchitecture-pt-BR
Performance-pt-BR
Photon-pt-BR
Roadmap-pt-BR
Runtime-pt-BR
Security-pt-BR
ServerIntegration-pt-BR
Storage-pt-BR
Styling-pt-BR
SupportedFeatures-pt-BR
VisualEditor-pt-BR
WriteOnceComponents-pt-BR
ACTIONS & INPUTS
Button
IconButton
TextInput
Select
Checkbox
Switch
RadioGroup
SegmentedControl
Slider
Stepper
SearchField
SURFACES & DISPLAY
Card
Badge
Chip
Avatar
Banner
ProgressBar
EmptyState
Divider
NAVIGATION
Tabs
AppBar
BottomNavigation
Breadcrumb
Pagination
PageIndicator
Menu
Drawer
OVERLAYS
Dialog
BottomSheet
Toast
Popover
Tooltip
LISTS & DATA
List
ListView
Table
Accordion
CodeBlock
TOUCH INTERACTION
PullToRefresh
SwipeableRow
DocsActions & inputs
TextInput
View source
2 min read
Single-line entry in a stateful container: label above, bordered box, optional leading glyph, and a helper/error line that is always reserved so an error never shifts the form.
1
using eQuantic.UI.Components;
STATES
Label
default · 1dp BorderStrong
Label
Enter a valid address
Enter a valid address
error · Destructive
Label
disabled · SurfaceSubtle
Usage
1
2
3
4
5
6
new TextInput(_email, v => SetState(() => _email = v),
label: "Work email",
placeholder: "you@company.com",
error: _emailError,
leading: Icons.Mail,
size: SizeVariant.Large)
API
Prop
Type
Default
Description
Value
string
Controlled value; the component never owns the text.
OnChanged
Action<string>?
null
Fires per accepted keystroke.
Label
string
""
Persistent label above the field, TypeRole.Label, 6 dp gap.
Placeholder
string?
null
Hint inside the empty field, in TextMuted.
Helper
string?
null
Guidance under the field; Error replaces it.
Error
string?
null
Non-null switches the container and caption to Destructive. Validation is the app's call — on blur or submit, never per keystroke on first entry.
Leading
Icons?
null
20 dp leading glyph (IconSize.Dense).
Size
SizeVariant
Large
Small throws — text plus padding cannot fit 32 dp.
Disabled
bool
false
Paints the SurfaceSubtle fill.
Autofocus
bool
false
Claims the caret the first time it appears. Honoured once.
Obscure
bool
false
Password entry.
States
State
Rendering
Default
1 dp BorderStrong on Surface
Focused
2 dp Primary border; horizontal padding compensates −1 dp so nothing shifts
Error
Destructive border, kept through focus; caption carries the message
Disabled
SurfaceSubtle fill
Accessibility
Role textbox named by Label, described by Helper.
The error message is announced when it appears; the reserved caption line means layout never jumps.
Focus is internal state fed by the entry's focus callbacks — the positional reconciler keeps the instance across controlled re-renders.
When to use
One field per fact you need. Label every field.
Validate on blur or submit.
Avoid
Placeholder as the only label.
SizeVariant.Small — the constructor rejects it.
WARNINGv1 fences: keyboard hints and the trailing slot (clear / reveal / counter) land with IME at M4.
NOTEEvery dimension resolves through Sizing.*(SizeVariant) and the token scales — never a literal. Source: src/eQuantic.UI.Components/TextInput.cs.