pub struct MultiActionFormProps<ServFn, OutputProtocol>where
ServFn: Send + Sync + Clone + DeserializeOwned + ServerFn<Protocol = Http<PostUrl, OutputProtocol>> + 'static,
<ServFn as ServerFn>::Output: Send + Sync + 'static,
<<<ServFn as ServerFn>::Client as Client<<ServFn as ServerFn>::Error>>::Request as ClientReq<<ServFn as ServerFn>::Error>>::FormData: From<FormData>,
<ServFn as ServerFn>::Error: Send + Sync + 'static,
<ServFn as ServerFn>::Client: Client<<ServFn as ServerFn>::Error>,{
pub action: ServerMultiAction<ServFn>,
pub node_ref: Option<NodeRef<Form>>,
pub children: Box<dyn FnOnce() -> AnyView + Send>,
}Expand description
Props for the MultiActionForm component.
Automatically turns a server MultiAction into an HTML
form
progressively enhanced to use client-side routing.
§Required Props
- action:
ServerMultiAction<ServFn>- The action from which to build the form.
- children:
Children- Component children; should include the HTML of the form elements.
§Optional Props
- node_ref:
NodeRef<Form>- A
NodeRefin which the<form>element should be stored.
- A
Fields§
§action: ServerMultiAction<ServFn>The action from which to build the form.
node_ref: Option<NodeRef<Form>>A NodeRef in which the <form> element should be stored.
children: Box<dyn FnOnce() -> AnyView + Send>Component children; should include the HTML of the form elements.
Implementations§
Source§impl<ServFn, OutputProtocol> MultiActionFormProps<ServFn, OutputProtocol>where
ServFn: Send + Sync + Clone + DeserializeOwned + ServerFn<Protocol = Http<PostUrl, OutputProtocol>> + 'static,
<ServFn as ServerFn>::Output: Send + Sync + 'static,
<<<ServFn as ServerFn>::Client as Client<<ServFn as ServerFn>::Error>>::Request as ClientReq<<ServFn as ServerFn>::Error>>::FormData: From<FormData>,
<ServFn as ServerFn>::Error: Send + Sync + 'static,
<ServFn as ServerFn>::Client: Client<<ServFn as ServerFn>::Error>,
impl<ServFn, OutputProtocol> MultiActionFormProps<ServFn, OutputProtocol>where
ServFn: Send + Sync + Clone + DeserializeOwned + ServerFn<Protocol = Http<PostUrl, OutputProtocol>> + 'static,
<ServFn as ServerFn>::Output: Send + Sync + 'static,
<<<ServFn as ServerFn>::Client as Client<<ServFn as ServerFn>::Error>>::Request as ClientReq<<ServFn as ServerFn>::Error>>::FormData: From<FormData>,
<ServFn as ServerFn>::Error: Send + Sync + 'static,
<ServFn as ServerFn>::Client: Client<<ServFn as ServerFn>::Error>,
Sourcepub fn builder() -> MultiActionFormPropsBuilder<ServFn, OutputProtocol>
pub fn builder() -> MultiActionFormPropsBuilder<ServFn, OutputProtocol>
Create a builder for building MultiActionFormProps.
On the builder, call .action(...), .node_ref(...)(optional), .children(...) to set the values of the fields.
Finally, call .build() to create the instance of MultiActionFormProps.
Trait Implementations§
Source§impl<ServFn, OutputProtocol> Props for MultiActionFormProps<ServFn, OutputProtocol>where
ServFn: Send + Sync + Clone + DeserializeOwned + ServerFn<Protocol = Http<PostUrl, OutputProtocol>> + 'static,
<ServFn as ServerFn>::Output: Send + Sync + 'static,
<<<ServFn as ServerFn>::Client as Client<<ServFn as ServerFn>::Error>>::Request as ClientReq<<ServFn as ServerFn>::Error>>::FormData: From<FormData>,
<ServFn as ServerFn>::Error: Send + Sync + 'static,
<ServFn as ServerFn>::Client: Client<<ServFn as ServerFn>::Error>,
impl<ServFn, OutputProtocol> Props for MultiActionFormProps<ServFn, OutputProtocol>where
ServFn: Send + Sync + Clone + DeserializeOwned + ServerFn<Protocol = Http<PostUrl, OutputProtocol>> + 'static,
<ServFn as ServerFn>::Output: Send + Sync + 'static,
<<<ServFn as ServerFn>::Client as Client<<ServFn as ServerFn>::Error>>::Request as ClientReq<<ServFn as ServerFn>::Error>>::FormData: From<FormData>,
<ServFn as ServerFn>::Error: Send + Sync + 'static,
<ServFn as ServerFn>::Client: Client<<ServFn as ServerFn>::Error>,
Auto Trait Implementations§
impl<ServFn, OutputProtocol> Freeze for MultiActionFormProps<ServFn, OutputProtocol>
impl<ServFn, OutputProtocol> !RefUnwindSafe for MultiActionFormProps<ServFn, OutputProtocol>
impl<ServFn, OutputProtocol> Send for MultiActionFormProps<ServFn, OutputProtocol>
impl<ServFn, OutputProtocol> !Sync for MultiActionFormProps<ServFn, OutputProtocol>
impl<ServFn, OutputProtocol> Unpin for MultiActionFormProps<ServFn, OutputProtocol>
impl<ServFn, OutputProtocol> !UnwindSafe for MultiActionFormProps<ServFn, OutputProtocol>
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
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>
Converts
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>
Converts
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 moreSource§impl<T> SerializableKey for T
impl<T> SerializableKey for T
Source§impl<T> StorageAccess<T> for T
impl<T> StorageAccess<T> for T
Source§fn as_borrowed(&self) -> &T
fn as_borrowed(&self) -> &T
Borrows the value.
Source§fn into_taken(self) -> T
fn into_taken(self) -> T
Takes the value.