pub struct AutocompleteProps {
pub list: String,
pub type: String,
pub options: Vec<SelectOption>,
pub class: Option<String>,
pub oninput: Option<EventHandler<FormEvent>>,
pub onchange: Option<EventHandler<FormEvent>>,
pub attributes: Vec<Attribute>,
}Expand description
Props for Autocomplete.
Fields§
§list: StringId of the <datalist> that holds the suggestions.
type: StringThe native input type. Defaults to search.
options: Vec<SelectOption>Suggestions to render as a <datalist> with the list id, right after the input. Leave
empty (the default) to point list at a datalist you render yourself, like lumen-react.
class: Option<String>Extra classes appended after the Lumen classes.
oninput: Option<EventHandler<FormEvent>>Fires on every edit.
onchange: Option<EventHandler<FormEvent>>Fires when the value is committed.
attributes: Vec<Attribute>Any other <input> or global attribute, such as value, name, or placeholder.
Implementations§
Source§impl AutocompleteProps
impl AutocompleteProps
Sourcepub fn builder() -> AutocompletePropsBuilder<((), (), (), (), (), (), ())>
pub fn builder() -> AutocompletePropsBuilder<((), (), (), (), (), (), ())>
Create a builder for building AutocompleteProps.
On the builder, call .list(...), .r#type(...)(optional), .options(...)(optional), .class(...)(optional), .oninput(...)(optional), .onchange(...)(optional), .attributes(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of AutocompleteProps.
Trait Implementations§
Source§impl Clone for AutocompleteProps
impl Clone for AutocompleteProps
Source§impl PartialEq for AutocompleteProps
impl PartialEq for AutocompleteProps
Source§impl Properties for AutocompletePropswhere
Self: Clone,
impl Properties for AutocompletePropswhere
Self: Clone,
Source§type Builder = AutocompletePropsBuilder<((), (), (), (), (), (), ())>
type Builder = AutocompletePropsBuilder<((), (), (), (), (), (), ())>
Source§fn memoize(&mut self, new: &Self) -> bool
fn memoize(&mut self, new: &Self) -> bool
Source§fn into_vcomponent<M>(
self,
render_fn: impl ComponentFunction<Self, M>,
) -> VComponentwhere
M: 'static,
fn into_vcomponent<M>(
self,
render_fn: impl ComponentFunction<Self, M>,
) -> VComponentwhere
M: 'static,
impl StructuralPartialEq for AutocompleteProps
Auto Trait Implementations§
impl !RefUnwindSafe for AutocompleteProps
impl !Send for AutocompleteProps
impl !Sync for AutocompleteProps
impl !UnwindSafe for AutocompleteProps
impl Forget for AutocompleteProps
impl Freeze for AutocompletePropswhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<SelectOption>: Freeze,
&'static UnsyncStorage: Freeze,
NonZero<u64>: Freeze,
&'static Location<'static>: Freeze,
PhantomData<Option<ExternalListenerCallback<Event<FormData>, ()>>>: Freeze,
PhantomData<Attribute>: Freeze,
impl Move for AutocompleteProps
impl Unpin for AutocompleteProps
impl UnsafeUnpin for AutocompletePropswhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<SelectOption>: UnsafeUnpin,
&'static UnsyncStorage: UnsafeUnpin,
NonZeroU64Inner: UnsafeUnpin,
&'static Location<'static>: UnsafeUnpin,
PhantomData<Option<ExternalListenerCallback<Event<FormData>, ()>>>: UnsafeUnpin,
PhantomData<Attribute>: UnsafeUnpin,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DependencyElement for T
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> InitializeFromFunction<T> for T
impl<T> InitializeFromFunction<T> for T
Source§fn initialize_from_function(f: fn() -> T) -> T
fn initialize_from_function(f: fn() -> T) -> T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more