Skip to content

Commit

Permalink
feat(uploader): update props and doc
Browse files Browse the repository at this point in the history
  • Loading branch information
PuffMeow committed May 7, 2024
1 parent fe8ee42 commit 1546ea4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/uploader/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ uploadFilePromise(fileName, chooseResult) {
| extension `v1.10.11` | 当 accept 为 `file` 时生效,根据文件拓展名过滤可选择文件。每一项都不能是空字符串。默认不过滤 | _string[] \| undefined_ | - |
| showmenu `v1.10.13` | 预览图片时,是否显示长按菜单 | _boolean_ | `true` |
| upload-icon | 上传区域图标,可选值见 [Icon 组件](#/icon) | _string_ | `plus` |
| video-referrer-policy | 格式固定为 https://servicewechat.com/{appid}/{version}/page-frame.html,其中 {appid} 为小程序的 appid,{version} 为小程序的版本号,版本号为 0 表示为开发版、体验版以及审核版本,版本号为 devtools 表示为开发者工具,其余为正式版本; | string | `no-referrer` |
| referrer-policy `v1.11.6` | 当 accept 为 video 时生效,具体用法参考 [微信官方 - 媒体组件 / video](https://developers.weixin.qq.com/miniprogram/dev/component/video.html) | string | `no-referrer` |

#### accept 的合法值

Expand Down
4 changes: 0 additions & 4 deletions packages/uploader/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,6 @@ VantComponent({
type: String,
value: 'contain',
},
videoReferrerPolicy: {
type: String,
value: 'no-referrer',
},
imageFit: {
type: String,
value: 'scaleToFill',
Expand Down
4 changes: 4 additions & 0 deletions packages/uploader/shared.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ export const videoProps = {
type: String,
value: 'back',
},
referrerPolicy: {
type: String,
value: 'no-referrer',
},
};

// props for media
Expand Down

0 comments on commit 1546ea4

Please sign in to comment.