Commit c79374a9 authored by spc's avatar spc

fixed

parent cbf03a3f
...@@ -191,7 +191,8 @@ ...@@ -191,7 +191,8 @@
{ {
"path": "pages/XingmaLabPublishPage/XingmaLabPublishPage", "path": "pages/XingmaLabPublishPage/XingmaLabPublishPage",
"style": { "style": {
"navigationBarTitleText": "" "navigationBarTitleText": "",
"navigationStyle": "custom"
} }
} }
], ],
......
...@@ -17,19 +17,37 @@ ...@@ -17,19 +17,37 @@
background-position: center; background-position: center;
} }
// 返回按钮
.xingmalabpublishpagebackbtn {
width: 20rpx;
height: 33rpx;
left: 31rpx;
top: 88rpx;
position: absolute;
background-size: contain;
background-repeat: no-repeat;
background-position: center;
z-index: 1000;
transition: opacity 0.3s ease;
&:hover {
opacity: 0.8;
}
}
// 未选择状态 // 未选择状态
.xingmalabpublishpagenosel { .xingmalabpublishpagenosel {
width: 750rpx; width: 750rpx;
height: 1416rpx; height: 1416rpx;
left: 0rpx; left: 0rpx;
top: 208rpx; top: 308rpx;
position: absolute; position: absolute;
.xingmalabpublishpagenoseltextplaceholder { .xingmalabpublishpagenoseltextplaceholder {
width: 684rpx; width: 684rpx;
height: 160rpx; height: 160rpx;
left: 33rpx; left: 33rpx;
top: 949rpx; top: 1129rpx;
position: absolute; position: absolute;
font-size: 32rpx; font-size: 32rpx;
line-height: 1.5; line-height: 1.5;
...@@ -48,7 +66,7 @@ ...@@ -48,7 +66,7 @@
width: 750rpx; width: 750rpx;
height: 218rpx; height: 218rpx;
left: 0rpx; left: 0rpx;
top: 1198rpx; top: 1378rpx;
position: absolute; position: absolute;
.xingmalabpublishpagenoselbottomconbg { .xingmalabpublishpagenoselbottomconbg {
...@@ -84,7 +102,7 @@ ...@@ -84,7 +102,7 @@
width: 686rpx; width: 686rpx;
height: 912rpx; height: 912rpx;
left: 32rpx; left: 32rpx;
top: 0rpx; top: 180rpx;
position: absolute; position: absolute;
background-size: cover; background-size: cover;
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -106,7 +124,7 @@ ...@@ -106,7 +124,7 @@
width: 684rpx; width: 684rpx;
height: 160rpx; height: 160rpx;
left: 33rpx; left: 33rpx;
top: 949rpx; top: 1129rpx;
color: rgba(0, 0, 0, 1); color: rgba(0, 0, 0, 1);
} }
...@@ -115,7 +133,7 @@ ...@@ -115,7 +133,7 @@
width: 750rpx; width: 750rpx;
height: 218rpx; height: 218rpx;
left: 0rpx; left: 0rpx;
top: 1198rpx; top: 1378rpx;
position: absolute; position: absolute;
.xingmalabpublishpageselbottomconpublishbtnbg { .xingmalabpublishpageselbottomconpublishbtnbg {
...@@ -150,7 +168,7 @@ ...@@ -150,7 +168,7 @@
opacity: 0.5; opacity: 0.5;
cursor: not-allowed; cursor: not-allowed;
pointer-events: none; pointer-events: none;
&:hover { &:hover {
opacity: 0.5; opacity: 0.5;
} }
...@@ -163,7 +181,7 @@ ...@@ -163,7 +181,7 @@
width: 686rpx; width: 686rpx;
height: 912rpx; height: 912rpx;
left: 32rpx; left: 32rpx;
top: 0rpx; top: 180rpx;
position: absolute; position: absolute;
object-fit: contain; object-fit: contain;
border-radius: 16rpx; border-radius: 16rpx;
...@@ -174,7 +192,7 @@ ...@@ -174,7 +192,7 @@
width: 686rpx; width: 686rpx;
height: 189rpx; height: 189rpx;
left: 32rpx; left: 32rpx;
top: 723rpx; top: 903rpx;
position: absolute; position: absolute;
opacity: 0.3; opacity: 0.3;
background-size: cover; background-size: cover;
...@@ -186,7 +204,7 @@ ...@@ -186,7 +204,7 @@
width: 270rpx; width: 270rpx;
height: 76rpx; height: 76rpx;
left: 240rpx; left: 240rpx;
top: 804rpx; top: 984rpx;
position: absolute; position: absolute;
background-size: cover; background-size: cover;
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -205,14 +223,14 @@ ...@@ -205,14 +223,14 @@
width: 750rpx; width: 750rpx;
height: 1416rpx; height: 1416rpx;
left: 0rpx; left: 0rpx;
top: 208rpx; top: 308rpx;
position: absolute; position: absolute;
.xingmalabpublishpagesucbottomconicon { .xingmalabpublishpagesucbottomconicon {
width: 125rpx; width: 133rpx;
height: 148rpx; height: 152rpx;
left: 312rpx; left: 314rpx;
top: 0rpx; top: 182rpx;
position: absolute; position: absolute;
background-size: cover; background-size: cover;
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -223,7 +241,7 @@ ...@@ -223,7 +241,7 @@
width: 750rpx; width: 750rpx;
height: 218rpx; height: 218rpx;
left: 0rpx; left: 0rpx;
top: 1195rpx; top: 1375rpx;
position: absolute; position: absolute;
.xingmalabpublishpagesucbottomconbg { .xingmalabpublishpagesucbottomconbg {
...@@ -259,7 +277,7 @@ ...@@ -259,7 +277,7 @@
width: 538rpx; width: 538rpx;
height: 117rpx; height: 117rpx;
left: 111rpx; left: 111rpx;
top: 191rpx; top: 371rpx;
position: absolute; position: absolute;
font-size: 30rpx; font-size: 30rpx;
color: rgba(29, 30, 37, 1); color: rgba(29, 30, 37, 1);
...@@ -271,7 +289,7 @@ ...@@ -271,7 +289,7 @@
width: 576rpx; width: 576rpx;
height: 812rpx; height: 812rpx;
left: 87rpx; left: 87rpx;
top: 341rpx; top: 521rpx;
position: absolute; position: absolute;
background-size: cover; background-size: cover;
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -282,7 +300,7 @@ ...@@ -282,7 +300,7 @@
width: 534rpx; width: 534rpx;
height: 708rpx; height: 708rpx;
left: 108rpx; left: 108rpx;
top: 356rpx; top: 536rpx;
position: absolute; position: absolute;
object-fit: contain; object-fit: contain;
border-radius: 16rpx; border-radius: 16rpx;
...@@ -293,7 +311,7 @@ ...@@ -293,7 +311,7 @@
width: 222rpx; width: 222rpx;
height: 25rpx; height: 25rpx;
left: 271rpx; left: 271rpx;
top: 1081rpx; top: 1261rpx;
position: absolute; position: absolute;
font-size: 32rpx; font-size: 32rpx;
line-height: 25rpx; line-height: 25rpx;
...@@ -654,22 +672,22 @@ ...@@ -654,22 +672,22 @@
} }
} }
// 调试信息样式 // 调试信息样式
.debug-info { .debug-info {
position: absolute; position: absolute;
top: 20rpx; top: 20rpx;
right: 20rpx; right: 20rpx;
background-color: rgba(0, 0, 0, 0.7); background-color: rgba(0, 0, 0, 0.7);
color: white; color: white;
padding: 20rpx; padding: 20rpx;
border-radius: 10rpx; border-radius: 10rpx;
font-size: 24rpx; font-size: 24rpx;
z-index: 100; z-index: 100;
max-width: 300rpx; max-width: 300rpx;
.debug-text { .debug-text {
display: block; display: block;
margin-bottom: 10rpx; margin-bottom: 10rpx;
line-height: 1.4; line-height: 1.4;
} }
} }
...@@ -3,6 +3,11 @@ ...@@ -3,6 +3,11 @@
<span class="xingmalabpublishpagebg" <span class="xingmalabpublishpagebg"
:style="{ backgroundImage: `url(${$baseUrl}${getImageUrl(config.images.background)})` }"></span> :style="{ backgroundImage: `url(${$baseUrl}${getImageUrl(config.images.background)})` }"></span>
<!-- 返回按钮 -->
<span class="xingmalabpublishpagebackbtn"
:style="{ backgroundImage: `url(${$baseUrl}${getImageUrl(config.images.backBtn)})` }"
@click="handleGoBack"></span>
<!-- 主内容区域 --> <!-- 主内容区域 -->
<div class="xingmalabpublishpagenosel" v-if="currentState !== config.states.SUC"> <div class="xingmalabpublishpagenosel" v-if="currentState !== config.states.SUC">
<!-- 文案输入框 --> <!-- 文案输入框 -->
...@@ -365,9 +370,32 @@ const handleRejectAuth = () => { ...@@ -365,9 +370,32 @@ const handleRejectAuth = () => {
// 允许授权 // 允许授权
const handleAllowAuth = () => { const handleAllowAuth = () => {
if (!tempUserInfo.value.avatarUrl || !tempUserInfo.value.nickName) { // 检查头像和昵称是否为空
const hasAvatar = tempUserInfo.value.avatarUrl
const hasNickname = tempUserInfo.value.nickName
// 如果头像和昵称都为空
if (!hasAvatar && !hasNickname) {
uni.showToast({
title: '请输入头像',
icon: 'none'
})
return
}
// 如果仅头像为空
if (!hasAvatar && hasNickname) {
uni.showToast({
title: '请输入头像',
icon: 'none'
})
return
}
// 如果仅昵称为空
if (hasAvatar && !hasNickname) {
uni.showToast({ uni.showToast({
title: '请选择头像和输入昵称', title: '请输入昵称',
icon: 'none' icon: 'none'
}) })
return return
...@@ -552,6 +580,15 @@ const handleSuccessBtnClick = () => { ...@@ -552,6 +580,15 @@ const handleSuccessBtnClick = () => {
}) })
} }
// 返回按钮点击处理
const handleGoBack = () => {
console.log('点击返回按钮')
// uni.navigateBack()
uni.redirectTo({
url: '/pages/xingmaLab/xingmaLab'
})
}
// 生命周期 // 生命周期
onMounted(async () => { onMounted(async () => {
console.log('星妈实验室发布页面已加载') console.log('星妈实验室发布页面已加载')
......
...@@ -8,6 +8,9 @@ export const xingmaLabConfig = { ...@@ -8,6 +8,9 @@ export const xingmaLabConfig = {
// 背景图片 // 背景图片
background: `XingmaLabPublishPage/${version}/XingmaLabPublishPageBg.png`, background: `XingmaLabPublishPage/${version}/XingmaLabPublishPageBg.png`,
// 返回按钮
backBtn: `XingmaLabDetailPage/${version}/XingmaLabDetailPageBackBtn.png`,
xingmaLogo: `XingmaLabPublishPage/${version}/XingmaLogo.png`, xingmaLogo: `XingmaLabPublishPage/${version}/XingmaLogo.png`,
xingmaDefaultAvatar: `XingmaLabPublishPage/${version}/XingmaLabDefaultAvatar.png`, xingmaDefaultAvatar: `XingmaLabPublishPage/${version}/XingmaLabDefaultAvatar.png`,
...@@ -30,7 +33,7 @@ export const xingmaLabConfig = { ...@@ -30,7 +33,7 @@ export const xingmaLabConfig = {
// 成功状态图片 // 成功状态图片
suc: { suc: {
bottomConIcon: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucBottomConIcon.png`, bottomConIcon: `XingmaLabPublishPage/${version}/suc_icon3.png`,
bottomConBg: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucBottomConBg.png`, bottomConBg: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucBottomConBg.png`,
bottomConBtn: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucBottomConBtn.png`, bottomConBtn: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucBottomConBtn.png`,
picBg: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucPicBg.png`, picBg: `XingmaLabPublishPage/${version}/XingmaLabPublishPageSucPicBg.png`,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment