Skip to content

Commit 88df25f

Browse files
committed
update: 兼容新旧编译器下的节点选择
1 parent 0102ec8 commit 88df25f

4 files changed

Lines changed: 5 additions & 5 deletions

File tree

‎components/uni-calendar/uni-calendar.vue‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@
8888
*/
8989
selected: {
9090
type: Array,
91-
default: () => {
91+
default () {
9292
return []
9393
}
9494
},
@@ -133,7 +133,7 @@
133133
}
134134
},
135135
data() {
136-
const elClass = `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
136+
const elClass = this.__call_hook ? 'uni_canlender' : `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
137137
return {
138138
dateShow: false, // 日期是否选择
139139
selectDay: '', // 当前选择日期

‎components/uni-collapse-item/uni-collapse-item.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
}
5454
},
5555
data() {
56-
const elId = `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
56+
const elId = this.__callback_hook ? 'uni_collapse_item' : `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
5757
return {
5858
isOpen: false,
5959
height: 'auto',

‎components/uni-notice-bar/uni-notice-bar.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
}
6969
},
7070
data() {
71-
const elId = `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
71+
const elId = this.__call_hook ? 'uni_notice_bar' : `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
7272
return {
7373
elId: elId,
7474
show: true,

‎components/uni-swipe-action/uni-swipe-action.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
}
4343
},
4444
data() {
45-
const elId = `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
45+
const elId = this.__call_hook ? 'uni_swipe_action' : `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}`
4646
return {
4747
elId: elId,
4848
isShowBtn: false,

0 commit comments

Comments
 (0)