Skip to content

Events on image preview open/close. #3231

Closed
@kieste

Description

@kieste

This function solves the problem (这个功能解决的问题)

The app cannot react to the image preview.

For example I would like to display custom controls in front of the current image preview.

Expected API (期望的 API)

<n-image
    width="100"
    src="https://07akioni.oss-cn-beijing.aliyuncs.com/07akioni.jpeg"
    on-preview-open="handleImagePreviewOpen"
    on-preview-close="handleImagePreviewClose"
/>

When moving to the previous/next image in an image group, the close-handler of the current image is called and the open-handler of the previous/next image.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions