pub struct field;Expand description
A control and its label, description, and optional error message.
Compose it with existing inputs, selects, checkboxes, or other controls.
Set for on field_label to the control’s id, and connect descriptions
and errors through the control’s aria-describedby. Set aria-invalid
to "true" on an invalid control; the field then colors its label too.
A data-invalid="true" attribute on the field also colors its label.
Validation and the visibility of error messages belong to the caller.
Attributes are forwarded to the wrapper and classes are appended.
Trait Implementations§
Source§impl Component for field
impl Component for field
Source§type Props<'__props> = FieldProps<'__props>
type Props<'__props> = FieldProps<'__props>
The component’s properties. The lifetime covers data borrowed from
the caller.
Source§fn render<'__a, '__props>(
self,
cx: &'__a Cx,
props: Self::Props<'__props>,
) -> impl Future<Output = Result<impl View>> + Send + '__awhere
Self: '__a,
Self::Props<'__props>: '__a,
'__props: '__a,
fn render<'__a, '__props>(
self,
cx: &'__a Cx,
props: Self::Props<'__props>,
) -> impl Future<Output = Result<impl View>> + Send + '__awhere
Self: '__a,
Self::Props<'__props>: '__a,
'__props: '__a,
fn props_builder<'a>() -> <Self::Props<'a> as Props>::Builder
Auto Trait Implementations§
impl Freeze for field
impl RefUnwindSafe for field
impl Send for field
impl Sync for field
impl Unpin for field
impl UnsafeUnpin for field
impl UnwindSafe for field
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
Mutably borrows from an owned value. Read more