pub struct LinkPreview {Show 13 fields
pub url: String,
pub display_url: String,
pub site_name: String,
pub title: String,
pub description: FormattedText,
pub author: String,
pub type: LinkPreviewType,
pub has_large_media: bool,
pub show_large_media: bool,
pub show_media_above_description: bool,
pub skip_confirmation: bool,
pub show_above_text: bool,
pub instant_view_version: i32,
}Expand description
Describes a link preview
Fields§
§url: StringOriginal URL of the link
display_url: StringURL to display
site_name: StringShort name of the site (e.g., Google Docs, App Store)
title: StringTitle of the content
description: FormattedTextDescription of the content
Author of the content
type: LinkPreviewTypeType of the link preview
has_large_media: boolTrue, if size of media in the preview can be changed
show_large_media: boolTrue, if large media preview must be shown; otherwise, the media preview must be shown small and only the first frame must be shown for videos
show_media_above_description: boolTrue, if media must be shown above link preview description; otherwise, the media must be shown below the description
skip_confirmation: boolTrue, if there is no need to show an ordinary open URL confirmation, when opening the URL from the preview, because the URL is shown in the message text in clear
show_above_text: boolTrue, if the link preview must be shown above message text; otherwise, the link preview must be shown below the message text
instant_view_version: i32Version of instant view (currently, can be 1 or 2) for the web page; 0 if none
Trait Implementations§
Source§impl Clone for LinkPreview
impl Clone for LinkPreview
Source§fn clone(&self) -> LinkPreview
fn clone(&self) -> LinkPreview
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more