pub enum InputType {
Show 15 variants Boolean { tags: Option<Vec<String>>, }, Multiline, Color, Text, Date, DatetimeLocal, Email, Month, Number { min: Option<i32>, max: Option<i32>, }, Password, Range { min: i32, max: i32, }, Tel, Time, Url, Week,
}
Expand description

The possible types an input can have.

Variants

Boolean

Fields

tags: Option<Vec<String>>

A list of tags that will be accumulated if this boolean is set to true.

A boolean input.

Multiline

A multiline text input.

Color

A color picker (only in supported browsers).

Text

A simple text element (default).

Date

A date input.

DatetimeLocal

A datetime input, with no time offset (by UTC has been deprecated at the standard-level).

Email

An email input.

Month

A month input.

Number

Fields

min: Option<i32>

The smallest number the user can input.

max: Option<i32>

The largest number the user can input.

A numerical input.

Password

A password input (characters are obfuscated).

Range

Fields

min: i32

The minimum value on the slider.

max: i32

The maximum value on the slider.

A range slider.

Tel

A telephone number input.

Time

A time picker.

Url

A URL input.

Week

A week input.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Deserialize this value from the given Serde deserializer. Read more

Serialize this value into the given Serde serializer. Read more

Converts the given value to a String. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.