mirror of
https://gitee.com/beecue/fastbee.git
synced 2025-12-18 08:55:53 +08:00
智慧宿舍系统小程序
This commit is contained in:
60
wechat/miniprogram/node_modules/@vant/weapp/dist/image/index.js
generated
vendored
Normal file
60
wechat/miniprogram/node_modules/@vant/weapp/dist/image/index.js
generated
vendored
Normal file
@@ -0,0 +1,60 @@
|
||||
import { VantComponent } from '../common/component';
|
||||
import { button } from '../mixins/button';
|
||||
VantComponent({
|
||||
mixins: [button],
|
||||
classes: ['custom-class', 'loading-class', 'error-class', 'image-class'],
|
||||
props: {
|
||||
src: {
|
||||
type: String,
|
||||
observer() {
|
||||
this.setData({
|
||||
error: false,
|
||||
loading: true,
|
||||
});
|
||||
},
|
||||
},
|
||||
round: Boolean,
|
||||
width: null,
|
||||
height: null,
|
||||
radius: null,
|
||||
lazyLoad: Boolean,
|
||||
useErrorSlot: Boolean,
|
||||
useLoadingSlot: Boolean,
|
||||
showMenuByLongpress: Boolean,
|
||||
fit: {
|
||||
type: String,
|
||||
value: 'fill',
|
||||
},
|
||||
showError: {
|
||||
type: Boolean,
|
||||
value: true,
|
||||
},
|
||||
showLoading: {
|
||||
type: Boolean,
|
||||
value: true,
|
||||
},
|
||||
},
|
||||
data: {
|
||||
error: false,
|
||||
loading: true,
|
||||
viewStyle: '',
|
||||
},
|
||||
methods: {
|
||||
onLoad(event) {
|
||||
this.setData({
|
||||
loading: false,
|
||||
});
|
||||
this.$emit('load', event.detail);
|
||||
},
|
||||
onError(event) {
|
||||
this.setData({
|
||||
loading: false,
|
||||
error: true,
|
||||
});
|
||||
this.$emit('error', event.detail);
|
||||
},
|
||||
onClick(event) {
|
||||
this.$emit('click', event.detail);
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user