pub struct ImageProps {Show 28 fields
pub src: &'static str,
pub alt: &'static str,
pub width: &'static str,
pub height: &'static str,
pub style: &'static str,
pub class: &'static str,
pub sizes: &'static str,
pub quality: &'static str,
pub priority: bool,
pub placeholder: &'static str,
pub on_loading_complete: Callback<()>,
pub object_fit: &'static str,
pub object_position: &'static str,
pub on_error: Callback<String>,
pub decoding: &'static str,
pub blur_data_url: &'static str,
pub lazy_boundary: &'static str,
pub unoptimized: bool,
pub layout: &'static str,
pub node_ref: NodeRef,
pub aria_current: &'static str,
pub aria_describedby: &'static str,
pub aria_expanded: &'static str,
pub aria_hidden: &'static str,
pub aria_live: &'static str,
pub aria_pressed: &'static str,
pub aria_controls: &'static str,
pub aria_labelledby: &'static str,
}Expand description
Properties for the Image component.
Fields§
§src: &'static strThe source URL for the image.
alt: &'static strThe alternative text for the image.
width: &'static strThe width of the image.
height: &'static strThe height of the image.
style: &'static strThe style attribute for the image.
class: &'static strThe CSS class for the image.
sizes: &'static strThe sizes attribute for the image.
quality: &'static strThe quality attribute for the image.
priority: boolIndicates if the image should have priority loading.
placeholder: &'static strThe placeholder attribute for the image.
on_loading_complete: Callback<()>Callback function for handling loading completion.
object_fit: &'static strThe object-fit attribute for the image.
object_position: &'static strThe object-position attribute for the image.
on_error: Callback<String>Callback function for handling errors during image loading.
decoding: &'static strThe decoding attribute for the image.
blur_data_url: &'static strThe blur data URL for placeholder image.
lazy_boundary: &'static strThe lazy boundary for lazy loading.
unoptimized: boolIndicates if the image should be unoptimized.
layout: &'static strImage layout.
node_ref: NodeRefReference to the DOM node.
aria_current: &'static strIndicates the current state of the image in a navigation menu. Valid values: “page”, “step”, “location”, “date”, “time”, “true”, “false”.
aria_describedby: &'static strDescribes the image using the ID of the element that provides a description.
aria_expanded: &'static strIndicates whether the content associated with the image is currently expanded or collapsed. Valid values: “true”, “false”.
Indicates whether the image is currently hidden from the user. Valid values: “true”, “false”.
aria_live: &'static strIndicates whether the content associated with the image is live and dynamic. Valid values: “off”, “assertive”, “polite”.
aria_pressed: &'static strIndicates whether the image is currently pressed or selected. Valid values: “true”, “false”, “mixed”, “undefined”.
aria_controls: &'static strID of the element that the image controls or owns.
aria_labelledby: &'static strID of the element that labels the image.
Trait Implementations§
Source§impl Clone for ImageProps
impl Clone for ImageProps
Source§fn clone(&self) -> ImageProps
fn clone(&self) -> ImageProps
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Default for ImageProps
impl Default for ImageProps
Source§impl PartialEq for ImageProps
impl PartialEq for ImageProps
Source§impl Properties for ImageProps
impl Properties for ImageProps
impl StructuralPartialEq for ImageProps
Auto Trait Implementations§
impl Freeze for ImageProps
impl !RefUnwindSafe for ImageProps
impl !Send for ImageProps
impl !Sync for ImageProps
impl Unpin for ImageProps
impl !UnwindSafe for ImageProps
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,
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> IntoPropValue<Option<T>> for T
impl<T> IntoPropValue<Option<T>> for T
Source§fn into_prop_value(self) -> Option<T>
fn into_prop_value(self) -> Option<T>
self to a value of a Properties struct.Source§impl<T> IntoPropValue<T> for T
impl<T> IntoPropValue<T> for T
Source§fn into_prop_value(self) -> T
fn into_prop_value(self) -> T
self to a value of a Properties struct.