修改选项卡显示逻辑

master
于肖磊 2025-02-12 10:45:26 +08:00
parent 12bb145f74
commit b8e6faa932
4 changed files with 13 additions and 8 deletions

View File

@ -432,9 +432,9 @@
//
let header_top_height = (header.com_data.content.data_alone_row_value.length > 0 ? parseInt(header.com_data.style.data_alone_row_space || 5) : 0) + 33 + (header.com_data.content.data_alone_row_value.length > 0 ? 33 : 0);
//
if (!(new_data.com_data.content.tabs_top_up == '1' && ['tabs', 'tabs-carousel'].includes(new_data.key))) {
// if (!(new_data.com_data.content.tabs_top_up == '1' && ['tabs', 'tabs-carousel'].includes(new_data.key))) {
new_data.com_data.style.common_style.padding_top = parseInt(new_data.com_data.style.common_style.padding_top) + header_top_height;
}
// }
return new_data;
}
return item;

View File

@ -363,7 +363,7 @@
.header-container {
width: 100%;
.header-around {
z-index: 11;
z-index: 12;
}
.model-top {
.roll {

View File

@ -54,7 +54,7 @@
</view>
</view>
<!-- 选项卡更多弹窗 -->
<componentPopup :propShow="popup_status" :propIsBar="propIsBar" propPosition="top" :propMask="true" :propTop="propTop" @onclose="quick_close_event">
<componentPopup :propShow="popup_status" :propIsBar="propIsBar" propPosition="top" :propMask="true" :propTop="'calc(' + propTop + 'px)'" @onclose="quick_close_event">
<view class="padding-vertical-lg">
<view class="padding-left-main padding-bottom-main">全部选项卡</view>
<view class="divider-b">

View File

@ -2,9 +2,11 @@
<!-- 选项卡 -->
<view class="tabs-container pr">
<view :class="top_up == '1' ? 'tabs-top' : ''" :style="tabs_top_style + (top_up == '1' ? propContentPadding : '')">
<view class="tabs-contents bs-bb" :style="style_container">
<view :class="top_up == '1' ? 'bs-bb' : 'wh-auto bs-bb'" :style="style_img_container">
<componentDiyModulesTabsView :propValue="tabs_data" :propIsTabsIcon="true" :propTop="propTop" :propsTabsContainer="propsTabsContainer" :propsTabsImgContainer="propsTabsImgContainer" :propStyle="propStyle" @onTabsTap="tabs_click_event"></componentDiyModulesTabsView>
<view :style="style_margin_top">
<view class="tabs-contents bs-bb" :style="style_container">
<view :class="top_up == '1' ? 'bs-bb' : 'wh-auto bs-bb'" :style="style_img_container">
<componentDiyModulesTabsView :propValue="tabs_data" :propIsTabsIcon="true" :propTop="propTop" :propsTabsContainer="propsTabsContainer" :propsTabsImgContainer="propsTabsImgContainer" :propStyle="propStyle" @onTabsTap="tabs_click_event"></componentDiyModulesTabsView>
</view>
</view>
</view>
</view>
@ -98,6 +100,7 @@
tabs_carousel_seat_height: 0,
//
tabs_top_style: '',
style_margin_top: '',
};
},
created() {
@ -157,8 +160,10 @@
tabs_data: new_tabs_data,
style_container: this.propIsCommon ? new_tabs_background + common_styles_computer(new_style.common_style) : new_content.tabs_top_up == '1' ? new_tabs_background + gradient_computer(new_style.common_style) + margin_computer(this.propSpacingCommonStyle) : '', //
// indexindex
style_img_container: this.propIsCommon ? common_img_computer(new_style.common_style, new_content.tabs_top_up == '1' ? -1 : this.propIndex) : new_content.tabs_top_up == '1' ? background_computer(new_style.common_style) + padding_computer(this.propSpacingCommonStyle, 1, true) + 'box-sizing: border-box;' : '', //
style_img_container: this.propIsCommon ? common_img_computer(new_style.common_style, this.propIndex) : new_content.tabs_top_up == '1' ? background_computer(new_style.common_style) + padding_computer(this.propSpacingCommonStyle, 1, true) + 'box-sizing: border-box;' : '', //
tabs_top_style: new_tabs_top_style,
// -margin
style_margin_top: this.propIsImmersionModel ? `margin-top: -${ this.propTop * 2 }rpx;` : '',
//
top_up: new_top_up,
});