|
|
@ -146,6 +146,10 @@ export default {
|
|
|
|
showResult('error', '请填写完整信息')
|
|
|
|
showResult('error', '请填写完整信息')
|
|
|
|
return
|
|
|
|
return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if (!form.value.image) {
|
|
|
|
|
|
|
|
showResult('error', '请先选择帖子封面')
|
|
|
|
|
|
|
|
return
|
|
|
|
|
|
|
|
}
|
|
|
|
if (form.value.title.length < 3 || form.value.title.length > 50) {
|
|
|
|
if (form.value.title.length < 3 || form.value.title.length > 50) {
|
|
|
|
showResult('error', '标题长度需3-50字符')
|
|
|
|
showResult('error', '标题长度需3-50字符')
|
|
|
|
return
|
|
|
|
return
|
|
|
@ -200,7 +204,6 @@ export default {
|
|
|
|
</script>
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style scoped>
|
|
|
|
<style scoped>
|
|
|
|
/* 新增/修改的样式 */
|
|
|
|
|
|
|
|
.upload-wrapper {
|
|
|
|
.upload-wrapper {
|
|
|
|
display: flex;
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
align-items: center;
|
|
|
@ -268,7 +271,6 @@ export default {
|
|
|
|
font-size: 12px;
|
|
|
|
font-size: 12px;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/* 原有样式优化(保持整体风格一致) */
|
|
|
|
|
|
|
|
.post-container {
|
|
|
|
.post-container {
|
|
|
|
max-width: 600px;
|
|
|
|
max-width: 600px;
|
|
|
|
margin: 30px auto;
|
|
|
|
margin: 30px auto;
|
|
|
@ -381,5 +383,4 @@ export default {
|
|
|
|
background: #fde2e2;
|
|
|
|
background: #fde2e2;
|
|
|
|
color: #c0392b;
|
|
|
|
color: #c0392b;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
</style>
|
|
|
|
|
|
|
|
|