Gathering detailed insights and metrics for vue-dark-photo
Gathering detailed insights and metrics for vue-dark-photo
Gathering detailed insights and metrics for vue-dark-photo
Gathering detailed insights and metrics for vue-dark-photo
npm install vue-dark-photo
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
170 Stars
154 Commits
39 Forks
12 Watching
5 Branches
5 Contributors
Updated on 07 Aug 2024
Vue (60.3%)
JavaScript (34.23%)
CSS (3.46%)
HTML (2.01%)
Cumulative downloads
Total Downloads
Last day
975%
43
Compared to previous day
Last week
783.3%
53
Compared to previous week
Last month
209.1%
68
Compared to previous month
Last year
-37.3%
1,042
Compared to previous year
https://dark2017.github.io/vue-dark-photo.github.io/
npm i vue-dark-photo
// 在入口(main.js)中引入并挂载
import VDPhoto from 'vue-dark-photo'
// 引入vue-dark-photo 样式
import 'vue-dark-photo/lib/vue-dark-photo.css'
Vue.use(VDPhoto)
//若通过cdn引入 请引入以下链接 版本号自行调整
https://cdn.jsdelivr.net/npm/vue-dark-photo@{verison}/lib/vue-dark-photo.umd.min.js
https://cdn.jsdelivr.net/npm/vue-dark-photo@{verison}/lib/vue-dark-photo.css
this.$VDPhoto.show({
imgData: "url",
publish: (val) => {
console.log(val)
}
});
<VDPhoto
ref="VDPhoto"
:imgData='imgData'
@publish='publish'
....
/>
this.$refs.VDPhoto.show()
属性值 | 类型 | 描述 | 默认值 |
---|---|---|---|
imgData | string | 图片地址(url) | - |
imgArr | Array | 图片地址(数组) | - |
isHint | Boolean | 是否展示提示(第一张或最后一张) | true |
customAction | Object | 自定义操作栏 | null |
ifWave | Boolean | 是否点击波纹特效 | false |
属性值 | 类型 | 描述 | 默认值 |
---|---|---|---|
lastCard | Boolean | 是否需要上一张 | true |
narrow | Boolean | 是否需要缩小 | true |
reduction | Boolean | 是否需要复原 | true |
enlarge | Boolean | 是否需要放大 | true |
leftRotate | Boolean | 是否需要逆时针旋转 | true |
rightRotate | Boolean | 是否需要顺时针旋转 | true |
downloadFile | Boolean | 是否需要下载 | true |
publish | Boolean | 是否需要打印 | true |
nextCard | Boolean | 是否需要下一张 | true |
mouseWheel | Boolean | 是否需要滚轮缩放 | true |
mouseDown | Boolean | 是否需要拖拽功能 | true |
custom | Array | 自定义操作栏 | - |
属性值 | 类型 | 描述 | 默认值 |
---|---|---|---|
title | String | 悬浮标题 | - |
onClick | function | 点击回调 | - |
style | Object | 操作按钮样式 | - |
content | String | 操作按钮内容 | - |
事件名 | 说明 | 回调参数 |
---|---|---|
publish | 打印后的回调 | 打印的内容 |
close | 关闭后的回调 | - |
方法名 | 说明 |
---|---|
show | 打开photo |
··· | ··· |
2021-7-7
travis 小版本自动部署迭代
node 大版本手动迭代版本号
2021-6-3
新增波纹特效
优化项目结构
2021-6-1
新增自定义操作栏
2021-5-22
新增提示功能
添加图片旋转动画
优化图片旋转功能
2021-5-21
新增图片数组功能;移除默认插槽和图片名
下载时截取文件名作为图片名
2021-5-20
解耦elementui、引用阿里图标库
去除word等文档预览功能
2021-5-17
支持更多图片格式、代码优化
2021-5-14
去除打印的页眉、页脚优化打印相关功能
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 4/16 approved changesets -- score normalized to 2
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
70 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-25
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More