Text Inputs
Free-text and numeric editors — themed native primitives
(TextBox, Label, ContentControl) with placeholder text,
leading/trailing icons, and the IBeepValidatable surface (IsRequired, HasError,
ValidationError) wired into the field-presenter flow.
TheTechIdea.Beep.WPF.Controls ·
XAML namespace:
xmlns:beep="clr-namespace:TheTechIdea.Beep.WPF.Controls;assembly=TheTechIdea.Beep.WPF.Controls"
ControlStyle
(BeepControlStyle) and Theme (string) — CLR wrappers over the
inherited BeepChrome attached properties, so they are not repeated in the tables below.
On this page
BeepTextBox
The main single/multi-line text editor — a native TextBox with placeholder, size and
chrome variants, leading/trailing icon slots, an optional clear button, digit-only input, and the
full validation surface.
class BeepTextBox : System.Windows.Controls.TextBox, IBeepValidatable, IBeepIconHost| Property | Type | Description |
|---|---|---|
| PlaceholderText | string | Hint text shown while the box is empty (rendered by the PART_Placeholder TextBlock). |
| ErrorText | string | Error / helper text shown beneath the input. |
| InputVariant | InputVariant | Chrome variant of the input (e.g. filled / outlined). Default Default. |
| SizeVariant | SizeVariant | Size preset of the input. Default Medium. |
| IsSearchMode | bool | When true, styles the box as a search field (icon + clear button). |
| ShowClearButton | bool | When true (default), a clear (×) button appears whenever the box has text. |
| LeadingIcon | string | Icon shown before the text (embedded SVG name, path, or geometry). Empty = none. |
| TrailingIcon | string | Icon shown after the text. Empty = none. |
| IconSize | double | Leading/trailing icon size in device-independent pixels. Default 16. |
| OnlyDigits | bool | When true, only digit characters (0–9) are accepted (typing and paste). |
| IsMultiline | bool | When true, sets AcceptsReturn and wraps text — an alias for the native multi-line knobs. |
| IsRequired | bool | IBeepValidatable: marks the field mandatory; empty fails ValidateData. |
| IsEditable | bool | IBeepValidatable: whether the field accepts edits. Default true. |
| ToolTipText | string | IBeepValidatable: tooltip / helper text for the field. |
| HasError | bool | IBeepValidatable: current error flag; drives error chrome. |
| ValidationError | string | IBeepValidatable: current validation message. |
| ComponentName | string | IBeepValidatable: component identifier used by the field-presenter flow. |
<beep:BeepTextBox PlaceholderText="Email"
LeadingIcon="fi-tr-envelope"
IsRequired="True"
ControlStyle="Material3"/>
BeepPasswordBox
A themed wrapper around the sealed native PasswordBox. Because
PasswordBox.Password is not a DependencyProperty, this control exposes a bindable
two-way BindablePassword that mirrors the inner box.
class BeepPasswordBox : ContentControl| Property | Type | Description |
|---|---|---|
| BindablePassword | string | Bindable two-way mirror of the inner password box value. (A non-bindable Password CLR alias is also provided for code-behind call sites.) |
<beep:BeepPasswordBox BindablePassword="{Binding Password, Mode=TwoWay}"
ControlStyle="Fluent"/>
BeepSearchBox
A compact search field built on ContentControl, with a bindable
SearchText and its own placeholder default of "Search...".
class BeepSearchBox : ContentControl| Property | Type | Description |
|---|---|---|
| SearchText | string | Current search text, bound two-way to the embedded editor. |
| PlaceholderText | string | Placeholder shown when SearchText is empty. Default "Search...". |
<beep:BeepSearchBox SearchText="{Binding Filter, Mode=TwoWay}"
PlaceholderText="Filter results…"
ControlStyle="Material3"/>
BeepNumericUpDown
A numeric spinner over ContentControl with clamped range, step increment, up/down
template parts, a ValueChanged event, and the validation surface.
class BeepNumericUpDown : ContentControl, IBeepValidatable| Property | Type | Description |
|---|---|---|
| Value | decimal | Current numeric value; binds two-way and is coerced into [Minimum, Maximum]. |
| Minimum | decimal | Minimum allowed value. Default decimal.MinValue. |
| Maximum | decimal | Maximum allowed value. Default decimal.MaxValue. |
| Increment | decimal | Step applied by the up/down buttons. Default 1. |
| IsRequired | bool | IBeepValidatable: marks the field mandatory. |
| IsEditable | bool | IBeepValidatable: whether the field accepts edits. Default true. |
| ToolTipText | string | IBeepValidatable: tooltip / helper text. |
| HasError | bool | IBeepValidatable: current error flag. |
| ValidationError | string | IBeepValidatable: current validation message. |
| ComponentName | string | IBeepValidatable: component identifier for the field-presenter flow. |
<beep:BeepNumericUpDown Value="{Binding Quantity, Mode=TwoWay}"
Minimum="0" Maximum="100" Increment="5"
ControlStyle="Fluent"/>
BeepLabel
A themed Label that adds a Text DP (forwarded to Content), a
muted/secondary tone, and wrapping/alignment knobs the native Label lacks.
class BeepLabel : Label| Property | Type | Description |
|---|---|---|
| Text | string | Text content; forwarded to the inherited Content. OneWay by default (opt into Mode=TwoWay when needed). |
| Muted | bool | Renders in the skin's muted/secondary tone ({Skin}OnSurfaceVariant) for captions and hints. |
| TextWrapping | TextWrapping | Wrapping for the inner TextBlock. Default NoWrap. |
| TextAlignment | TextAlignment | Horizontal text alignment. Default Left. |
<beep:BeepLabel Text="Signed in as admin"
Muted="True" TextWrapping="Wrap"
ControlStyle="Apple"/>