gxd-uni-library-editx 1.0.166 → 1.0.167
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<view v-if="status" :style="[
|
|
2
|
+
<view v-if="status" :style="[cusBoxComp]">
|
|
3
3
|
<button
|
|
4
4
|
v-if="openType === 'getPhoneNumber' || openType === 'getUserInfo' || openType === 'chooseAvatar'"
|
|
5
5
|
:disabled="disabled"
|
|
@@ -173,7 +173,11 @@
|
|
|
173
173
|
type: Object|Array,
|
|
174
174
|
default() {
|
|
175
175
|
return {}
|
|
176
|
-
}
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
isAuto:{
|
|
179
|
+
type: Boolean,
|
|
180
|
+
default: true
|
|
177
181
|
}
|
|
178
182
|
},
|
|
179
183
|
data(){
|
|
@@ -276,7 +280,15 @@
|
|
|
276
280
|
}
|
|
277
281
|
}
|
|
278
282
|
return {}
|
|
279
|
-
}
|
|
283
|
+
},
|
|
284
|
+
cusBoxComp(){
|
|
285
|
+
let item = this.wrapStyle;
|
|
286
|
+
if(this.isAuto) {
|
|
287
|
+
if(this.$xdUniHelper.checkVarType(item) === 'object') item = {...item, margin: '0 auto'}
|
|
288
|
+
if(this.$xdUniHelper.checkVarType(item) === 'array') item = [{margin: '0 auto'}].concat(item);
|
|
289
|
+
}
|
|
290
|
+
return item;
|
|
291
|
+
},
|
|
280
292
|
},
|
|
281
293
|
async created(){
|
|
282
294
|
let pageStyle = this.systemStyle || {};
|