New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

xes-customize-ui

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xes-customize-ui

A Component Library for Vue.js.

latest
Source
npmnpm
Version
0.1.5
Version published
Maintainers
1
Created
Source

xes-customize-ui

Project setup

yarn install

Compiles and hot-reloads for development

yarn serve

Compiles and minifies for production

yarn build
# Yarn
yarn add xes-customize-ui

# Npm
npm install xes-customize-ui --save

Attribute

参数说明类型默认值
v-model显示隐藏booleanfalse
img-list图片数据列表['url'] 或[{url: 'url', title: 'title'}]array-
z-indexcss 层级number2000
close-on-click-mask是否可以通过点击遮罩关闭 ImageViewerbooleantrue
close-on-press-escape是否可以通过按下 ESC 关闭 ImageViewerbooleantrue
current-image-index默认打开的图片索引number0
on-switch切换回调function(index)-
showPreNextBar是否展示上下一页按钮booleanfalse
spaceAction按空格键是否恢复图片原始大小booleanfalse

Keyboard Operation

Keyboard说明
SPACE(空格键)切换原图大小或屏幕缩放大小
LEFT_ARROW(左方向键)切换到上一张图片
RIGHT_ARROW (右方向键)切换到下一张图片
UP_ARROW(上方向键)放大图片
DOWN_ARROW(下方向键)缩小图片

示例

<template>
  <div>
    <button @click="showViewer = true">预览图片</button>
    <xes-imgs-viewer
      v-model="showViewer"
      :current-image-index="imageIndex"
      :show-pre-next-bar="false"
      :close-on-press-escape="false"
      :img-list="imgList"
    />
  </div>
</template>

<script>
import { xesImageViewer } from 'xes-customize-ui';
import 'xes-customize-ui/lib/index.css';
export default {
  components: {
      xesImageViewer
  },
  data() {

    return {
      showViewer: false,
      imageIndex: 0,
      imgList: [
        {
          url: '图片地址',
          title: '图片名称', //可以没有
        },
        {
          url: '图片地址',
          title: '图片名称', //可以没有
        },
      ],
    }
  },
  methods: {},
}
</script>

<style></style>

Customize configuration

See Configuration Reference.

FAQs

Package last updated on 11 Jun 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts