123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990 |
- import computeOffset from '../behaviors/computeOffset';
- Component({
- behaviors: [computeOffset],
- externalClasses: ['l-container-class', 'l-class'],
- options: {
- multipleSlots: true
- },
- properties: {
-
- show: {
- type: Boolean,
- value: false
- },
- opacity:{
- type: String,
- value: '1'
- },
- bgColor: {
- type: String,
- value: '#fff'
- },
- zIndex:{
- type: Number,
- value: 776
- },
-
- type: {
- type: String,
- value: 'rotate'
- },
-
- color: {
- type: String,
- value: ''
- },
-
- size: {
- type: String,
- value: 'medium',
- },
-
- custom: Boolean,
-
- fullScreen: Boolean
- },
- attached() {
- this._init();
- },
- pageLifetimes: {
- show() {
- this._init();
- },
- },
- methods: {
- _init() {
- wx.lin = wx.lin || {};
- wx.lin.showLoading = (options) => {
- const {
- custom = false,
- fullScreen = false,
- color = '',
- type = 'rotate',
- size = 'medium',
- opacity = '1'
- } = { ...options };
- this.setData({
- custom,
- fullScreen,
- color,
- type,
- size,
- opacity,
- show: true
- });
- };
- wx.lin.hideLoading = () => {
- this.setData({
- show: false
- });
- };
- },
-
- doNothingMove() {
-
- },
- }
- });
|