xverse-components-image-viewer
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

API

参数名 类型 说明 默认值 是否必填 备注
imageConfig IImageConfig[] 图片配置 - true -
originIndex number 打开后,第一张显示图片的下标(0 开始) - false -
maxZoom number 最大缩放比例 10 false -
showPageIndex boolean 是否显示页数 true false -
imageWidth number 图片宽度 - false 宽度和高度传入任意一个,另一个自适应,二者都传,则定死宽高
imageHeight number 图片高度 - false 宽度和高度传入任意一个,另一个自适应,二者都传,则定死宽高
imageBorder string 图片边框 - false -
imageBorderRadius string 图片边角 - false -
preButtonProps IButtonProps 上一个按钮的样式 - false 样式中有默认自带位置,如果需要调整位置,只需要 absolute 然后调整水平位置即可
nextButtonProps IButtonProps 下一个按钮的样式 - false 样式中有默认自带位置,如果需要调整位置,只需要 absolute 然后调整水平位置即可
closeButtonProps IButtonProps 关闭按钮的样式 - false 样式中有默认自带位置,如果需要调整位置,只需要 absolute 然后按 ui 调整位置即可
onClose (visibility: boolean) => void 关闭时的回调 - false -
onIndexChange (idx: number) => void 当前图片变更的回调(初始化时,也会返回一次) - false -
className string 类名 - false -

Readme

Keywords

Package Sidebar

Install

npm i xverse-components-image-viewer

Weekly Downloads

24

Version

1.0.3

License

MIT

Unpacked Size

102 kB

Total Files

8

Last publish

Collaborators

  • canny_1207
  • joycess
  • shi2800