pub struct LinkElement {
pub url: String,
pub text: Option<String>,
pub unsafe: Option<bool>,
pub from_llm: Option<bool>,
pub is_slack_url: Option<bool>,
pub truncated: Option<bool>,
pub style: Option<RichTextStyle>,
/* private fields */
}Expand description
Fields§
§url: String§text: Option<String>§unsafe: Option<bool>§from_llm: Option<bool>§is_slack_url: Option<bool>§truncated: Option<bool>§style: Option<RichTextStyle>Implementations§
Source§impl LinkElement
impl LinkElement
pub fn new(url: impl Into<String>) -> Self
pub fn text(self, text: impl Into<String>) -> Self
pub fn unsafe(self, unsafe: bool) -> Self
pub fn from_llm(self, from_llm: bool) -> Self
pub fn is_slack_url(self, is_slack_url: bool) -> Self
pub fn truncated(self, truncated: bool) -> Self
pub fn style(self, style: RichTextStyle) -> Self
Trait Implementations§
Source§impl Clone for LinkElement
impl Clone for LinkElement
Source§impl Debug for LinkElement
impl Debug for LinkElement
Source§impl<'de> Deserialize<'de> for LinkElement
impl<'de> Deserialize<'de> for LinkElement
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<LinkElement> for PreformattedElement
impl From<LinkElement> for PreformattedElement
Source§fn from(value: LinkElement) -> Self
fn from(value: LinkElement) -> Self
Converts to this type from the input type.
Source§impl From<LinkElement> for RichTextElement
impl From<LinkElement> for RichTextElement
Source§fn from(value: LinkElement) -> Self
fn from(value: LinkElement) -> Self
Converts to this type from the input type.
Source§impl PartialEq for LinkElement
impl PartialEq for LinkElement
Source§impl Serialize for LinkElement
impl Serialize for LinkElement
impl StructuralPartialEq for LinkElement
Auto Trait Implementations§
impl Freeze for LinkElement
impl RefUnwindSafe for LinkElement
impl Send for LinkElement
impl Sync for LinkElement
impl Unpin for LinkElement
impl UnsafeUnpin for LinkElement
impl UnwindSafe for LinkElement
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