# Struct ui::TextInput

> A text field.

`zaun_client::ui::TextInput` · Struct

```rust
pub struct TextInput(…)
```

A text field.

## Methods

### `short`

```rust
pub fn short<impl Into<String>>(custom_id: impl Into<String>) -> Self
```

One line.

### `paragraph`

```rust
pub fn paragraph<impl Into<String>>(custom_id: impl Into<String>) -> Self
```

Several lines.

### `length`

```rust
pub const fn length(self, min: u32, max: u32) -> Self
```

Length bounds.

### `required`

```rust
pub const fn required(self, required: bool) -> Self
```

Whether it must be filled (default yes).

### `placeholder`

```rust
pub fn placeholder<impl Into<String>>(self, text: impl Into<String>) -> Self
```

Grey text shown while empty.

## Trait implementations

`Clone`, `Debug`, `Eq`, `PartialEq`, `StructuralPartialEq`

[Full rustdoc page](/docs/api/rust/zaun-client/zaun_client/ui/modal/struct.TextInput.html)
