ImageOverlayProps interface
ImageOverlay 的 props 中。
属性
| alt |
用作图像的替换文本的可选字符串。 |
| image |
用于大比例显示图像的图像源。 |
| is |
Boolean (布尔值),用于控制是否显示模态。 |
| on |
关闭 ImageOverlay 模态框时调用的回调 |
| on |
可选 单击下载按钮时调用的回调。 如果未提供,则不会呈现下载按钮。 |
| title | 可选字符串,用作图像的标题,显示在 ImageOverlay 的左上角。 |
| title |
可选的 JSX 元素,用作标题图标并显示在 title 元素的左侧。 |
属性详细信息
altText
用作图像的替换文本的可选字符串。
altText?: string
属性值
string
imageSrc
用于大比例显示图像的图像源。
imageSrc: string
属性值
string
isOpen
Boolean (布尔值),用于控制是否显示模态。
isOpen: boolean
属性值
boolean
onDismiss
关闭 ImageOverlay 模态框时调用的回调
onDismiss: () => void
属性值
() => void
onDownloadButtonClicked
可选 单击下载按钮时调用的回调。 如果未提供,则不会呈现下载按钮。
onDownloadButtonClicked?: (imageSrc: string) => void
属性值
(imageSrc: string) => void
title
可选字符串,用作图像的标题,显示在 ImageOverlay 的左上角。
title?: string
属性值
string
titleIcon
可选的 JSX 元素,用作标题图标并显示在 title 元素的左侧。
titleIcon?: Element
属性值
Element