修改选项卡内容处理
parent
256baa58a7
commit
7223d4791b
|
|
@ -305,19 +305,22 @@
|
||||||
tabs_height: ['2', '4'].includes(new_content.tabs_theme) ? height * 2 + 'rpx' : '100%;',
|
tabs_height: ['2', '4'].includes(new_content.tabs_theme) ? height * 2 + 'rpx' : '100%;',
|
||||||
tabs_adorn_img_style: this.get_tabs_adorn_img_style(new_style),
|
tabs_adorn_img_style: this.get_tabs_adorn_img_style(new_style),
|
||||||
});
|
});
|
||||||
setTimeout(() => {
|
// 只有居左居右的才重新获取dom
|
||||||
const query = uni.createSelectorQuery().in(this);
|
if (['center', 'right'].includes(this.form.justification)) {
|
||||||
query.select('.interior-area-' + this.propKey)
|
setTimeout(() => {
|
||||||
.fields({ size: true, scrollOffset: true},(res) => {
|
const query = uni.createSelectorQuery().in(this);
|
||||||
if ((res || null) != null) {
|
query.select('.interior-area-' + this.propKey)
|
||||||
const { scrollWidth, width } = res;
|
.fields({ size: true, scrollOffset: true},(res) => {
|
||||||
this.setData({
|
if ((res || null) != null) {
|
||||||
is_out_of_range: scrollWidth <= width
|
const { scrollWidth, width } = res;
|
||||||
});
|
this.setData({
|
||||||
}
|
is_out_of_range: scrollWidth <= width
|
||||||
})
|
});
|
||||||
.exec();
|
}
|
||||||
}, 0)
|
})
|
||||||
|
.exec();
|
||||||
|
}, 0)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
get_tabs_adorn_img_style(new_style) {
|
get_tabs_adorn_img_style(new_style) {
|
||||||
return radius_computer(new_style?.tabs_adorn_img_radius || this.old_radius) + `height: ${(new_style?.tabs_adorn_img_height || 10) * 2}rpx;${ new_style.is_tabs_adorn_img_background == '1' ? tabs_check.value : ''}`;
|
return radius_computer(new_style?.tabs_adorn_img_radius || this.old_radius) + `height: ${(new_style?.tabs_adorn_img_height || 10) * 2}rpx;${ new_style.is_tabs_adorn_img_background == '1' ? tabs_check.value : ''}`;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue