mirror of
https://github.com/ialley-workshop-open/uni-halo.git
synced 2025-05-19 10:00:13 +09:00
新增:留言评论头像形状设置;
修复:修复文章管理设置文章标签在小程序端不显示的bug; 修复:修复后台管理工作台因为无法读取用户信息页面不显示bug; 优化:优化友情链接动画效果
This commit is contained in:
parent
9d3ebac076
commit
70c5b34de0
@ -1,8 +1,22 @@
|
||||
<template>
|
||||
<view class=" comment-item flex flex-col mt-30 pt-24" :class="{ 'child-comment-item': isChild, 'no-solid': !useSolid, classItem }">
|
||||
<view class="comment-item_user flex">
|
||||
<image v-if="comment.isAdmin" class="user-avatar" :src="bloggerInfo.avatar" mode="aspectFill" @error="fnOnImageError(comment)"></image>
|
||||
<image v-else class="user-avatar" :src="comment.avatar" mode="aspectFill" @error="fnOnImageError(comment)"></image>
|
||||
<image
|
||||
v-if="comment.isAdmin"
|
||||
class="user-avatar"
|
||||
:class="{ 'is-radius': globalAppSettings.isAvatarRadius }"
|
||||
:src="bloggerInfo.avatar"
|
||||
mode="aspectFill"
|
||||
@error="fnOnImageError(comment)"
|
||||
></image>
|
||||
<image
|
||||
v-else
|
||||
class="user-avatar"
|
||||
:class="{ 'is-radius': globalAppSettings.isAvatarRadius }"
|
||||
:src="comment.avatar"
|
||||
mode="aspectFill"
|
||||
@error="fnOnImageError(comment)"
|
||||
></image>
|
||||
<view class="user-info pl-14">
|
||||
<view class="author">
|
||||
<text class="mr-6 text-grey-darken-1 text-size-m">{{ comment.author }}</text>
|
||||
@ -11,7 +25,7 @@
|
||||
<tm-tags v-else :dense="true" color="bg-gradient-light-blue-lighten " size="xs" model="fill">游客</tm-tags>
|
||||
</view>
|
||||
<view class="flex mt-4">
|
||||
<view v-if="false" class="text-size-s text-grey mr-12">IP属地:浙江省杭州市</view>
|
||||
<view v-if="false" class="text-size-s text-grey mr-12">IP属地:暂无信息</view>
|
||||
<view class="time text-size-xs text-grey">
|
||||
<text class="">{{ $tm.dayjs(comment.createTime).format('YYYY年MM月DD日') }}</text>
|
||||
<text class="ml-12">{{ $tm.dayjs(comment.createTime).fromNow(true) }}前</text>
|
||||
@ -25,7 +39,6 @@
|
||||
</view>
|
||||
|
||||
<view class="comment-item_content mt-12" :class="{ 'has-bg': useContentBg, 'not-ml': isChild }" @click="$emit('on-detail', comment)" v-html="comment.content"></view>
|
||||
|
||||
<!-- <view v-if="useActions" class="comment-item_info text-size-s text-grey">
|
||||
<text v-if="false" @click="$emit('on-todo')">点赞</text>
|
||||
<text @click="$emit('on-comment', { type: 'user', comment: comment })">回复</text>
|
||||
@ -111,10 +124,13 @@ export default {
|
||||
.user-avatar {
|
||||
width: 70rpx;
|
||||
height: 70rpx;
|
||||
border-radius: 50%;
|
||||
box-sizing: border-box;
|
||||
border: 4rpx solid #ffffff;
|
||||
box-shadow: 0rpx 2rpx 24rpx rgba(0, 0, 0, 0.05);
|
||||
border: 4rpx solid #ffffff;
|
||||
border-radius: 12rpx;
|
||||
&.is-radius {
|
||||
border-radius: 50%;
|
||||
}
|
||||
}
|
||||
.user-info {
|
||||
width: 0;
|
||||
|
@ -50,9 +50,7 @@
|
||||
"dSYMs" : false,
|
||||
"capabilities" : {
|
||||
"entitlements" : {
|
||||
"com.apple.developer.associated-domains": [
|
||||
"applinks:static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com"
|
||||
]
|
||||
"com.apple.developer.associated-domains" : [ "applinks:static-699a26a5-a6cd-4b54-b603-5155b312a5f5.bspapp.com" ]
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<view class="app-page pb-24">
|
||||
<!-- 博主信息 -->
|
||||
<view class="blogger-info" :style="calcProfileStyle">
|
||||
<view class="blogger-info" :style="[calcProfileStyle]">
|
||||
<image class="avatar" :src="$utils.checkAvatarUrl(bloggerInfo.avatar)" mode="aspectFill" @click="miniProfileCard.show = true"></image>
|
||||
<view class="profile">
|
||||
<view class="author mt-24 text-size-g text-weight-b">{{ bloggerInfo.nickname }}</view>
|
||||
|
@ -33,14 +33,15 @@
|
||||
<!-- 如果大于一个分组:使用联系人的索引形式 result.length > 1 -->
|
||||
<block v-else>
|
||||
<block v-for="(team, index) in result" :key="index">
|
||||
<tm-translate animation-name="fadeUp" :wait="(index + 1) * 50">
|
||||
<view class="grey-lighten-4 text text-size-s text-weight-b px-32 py-12">{{ team.title }}</view>
|
||||
<block v-for="(link, linkIndex) in team.children" :key="link.id">
|
||||
<tm-translate animation-name="fadeUp" :wait="(linkIndex + 1) * 30">
|
||||
<tm-translate animation-name="fadeUp" :wait="(linkIndex + 1) * 50">
|
||||
<!-- 色彩版本 -->
|
||||
<view
|
||||
v-if="!globalAppSettings.links.useSimple"
|
||||
class="info flex pa-36"
|
||||
:class="{ 'border-b-1': linkIndex != team.children.length - 1 }"
|
||||
:class="{ 'border-b-1': linkIndex != team.children.length - 1 || index == result.length - 1 }"
|
||||
@click="fnOnLinkEvent(link)"
|
||||
>
|
||||
<view class="link-logo">
|
||||
@ -69,6 +70,7 @@
|
||||
</view>
|
||||
</tm-translate>
|
||||
</block>
|
||||
</tm-translate>
|
||||
</block>
|
||||
</block>
|
||||
|
||||
|
@ -9,8 +9,8 @@
|
||||
<view class="sheet-content">内容区域</view>
|
||||
</tm-sheet> -->
|
||||
<tm-sheet :shadow="6" :padding="[12, 24]" :margin="[24, 24]">
|
||||
<view class="py-12 px-24 mx-12 round-3 border-b-1 grey text">
|
||||
<text class="text-size-n text-weight-b ">布局</text>
|
||||
<view class="py-12 px-24 mx-12 round-3 grey text">
|
||||
<text class="text-size-n text-weight-b text-grey-darken-3">布局</text>
|
||||
<text class="text-grey text-size-xs px-10 ml-12">应用以及文章列表布局设置</text>
|
||||
</view>
|
||||
<view class="sheet-content">
|
||||
@ -54,7 +54,7 @@
|
||||
</tm-sheet>
|
||||
|
||||
<tm-sheet v-if="false" :shadow="24" :padding="[12, 24]" :margin="[24, 24]">
|
||||
<view class="py-12 px-24 mx-12 round-3 border-b-1 grey text">
|
||||
<view class="py-12 px-24 mx-12 round-3 grey text">
|
||||
<text class="text-size-n text-weight-b ">外观</text>
|
||||
<text class="text-grey text-size-xs px-10">设置应用主题色/暗黑模式等</text>
|
||||
</view>
|
||||
@ -65,19 +65,11 @@
|
||||
</tm-sheet>
|
||||
|
||||
<tm-sheet :shadow="6" :padding="[12, 24]" :margin="[24, 24]">
|
||||
<view class="py-12 px-24 mx-12 round-3 border-b-1 grey text">
|
||||
<text class="text-size-n text-weight-b ">功能</text>
|
||||
<view class="py-12 px-24 mx-12 round-3 grey text">
|
||||
<text class="text-size-n text-weight-b text-grey-darken-3">功能</text>
|
||||
<text class="text-grey text-size-xs px-10 ml-12">一些常用的功能性设置</text>
|
||||
</view>
|
||||
<view class="sheet-content">
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m">显示完整统计</text>
|
||||
<tm-switch v-model="appSettings.about.showAllCount" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
</view>
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m ">链接直接打开</text>
|
||||
<tm-switch v-model="appSettings.contact.isLinkCopy" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
</view>
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m ">图库瀑布流模式</text>
|
||||
<tm-switch v-model="appSettings.gallery.useWaterfull" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
@ -86,6 +78,10 @@
|
||||
<text class="text-size-m ">友链简洁模式</text>
|
||||
<tm-switch v-model="appSettings.links.useSimple" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
</view>
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m">是否圆形头像</text>
|
||||
<tm-switch v-model="appSettings.isAvatarRadius" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
</view>
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m ">轮播图指示器</text>
|
||||
<tm-switch v-model="appSettings.banner.useDot" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
@ -104,6 +100,15 @@
|
||||
></tm-radio>
|
||||
</tm-groupradio>
|
||||
</view>
|
||||
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m">显示完整统计</text>
|
||||
<tm-switch v-model="appSettings.about.showAllCount" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
</view>
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m ">链接直接打开</text>
|
||||
<tm-switch v-model="appSettings.contact.isLinkCopy" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
</view>
|
||||
<view class="mx-32 my-24 border-b-1 pb-24 flex-between">
|
||||
<text class="text-size-m ">显示后台入口</text>
|
||||
<tm-switch v-model="appSettings.about.showAdmin" color="light-blue" :text="['是', '否']"></tm-switch>
|
||||
@ -189,7 +194,7 @@ export default {
|
||||
this.fnSetPageTitle('应用设置');
|
||||
},
|
||||
created() {
|
||||
this.appSettings = uni.$tm.vx.getters().getSettings;
|
||||
this.appSettings = Object.assign({}, _DefaultAppSettings, uni.$tm.vx.getters().getSettings);
|
||||
this.fnHandleFormatSelect();
|
||||
uni.showLoading({
|
||||
title: '加载中...',
|
||||
@ -247,6 +252,7 @@ export default {
|
||||
// 保存
|
||||
fnOnSave() {
|
||||
this.isSaved = true;
|
||||
console.log('this.appSettings', this.appSettings);
|
||||
this.$tm.vx.commit('setting/setSettings', this.appSettings);
|
||||
uni.$tm.toast('保存成功,部分设置在重启后生效!');
|
||||
},
|
||||
|
@ -146,13 +146,12 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
bloggerInfo() {
|
||||
return this.$tm.vx.getters().blogger.getBlogger;
|
||||
return this.$tm.vx.getters().getBlogger;
|
||||
}
|
||||
},
|
||||
created() {
|
||||
// this.fnGetData();
|
||||
this.fnSetPageTitle('欢迎登录工作台');
|
||||
console.log(this.bloggerInfo);
|
||||
},
|
||||
onPullDownRefresh() {
|
||||
uni.stopPullDownRefresh();
|
||||
|
@ -60,9 +60,7 @@
|
||||
<view>
|
||||
<tm-groupcheckbox name="categoryIds">
|
||||
<tm-checkbox :dense="true" :name="item.id" v-for="(item, index) in categories" :key="index" v-model="item.checked">
|
||||
<template v-slot:default="{ checkData }">
|
||||
<tm-button :flat="true" size="s" :theme="checkData.checked ? 'light-blue' : 'grey-lighten-4'" :plan="true">{{ item.name }}</tm-button>
|
||||
</template>
|
||||
<tm-button v-slot:default :flat="true" size="s" :theme="item.checked ? 'light-blue' : 'grey-lighten-4'" :plan="true">{{ item.name }}</tm-button>
|
||||
</tm-checkbox>
|
||||
</tm-groupcheckbox>
|
||||
</view>
|
||||
@ -76,9 +74,7 @@
|
||||
<view>
|
||||
<tm-groupcheckbox name="tagIds">
|
||||
<tm-checkbox :dense="true" :name="item.id" v-for="(item, index) in tags" :key="index" v-model="item.checked">
|
||||
<template v-slot:default="{ checkData }">
|
||||
<tm-button :flat="true" size="s" :theme="checkData.checked ? 'light-blue' : 'grey-lighten-4'" :plan="true">{{ item.name }}</tm-button>
|
||||
</template>
|
||||
<tm-button v-slot:default :flat="true" size="s" :theme="item.checked ? 'light-blue' : 'grey-lighten-4'" :plan="true">{{ item.name }}</tm-button>
|
||||
</tm-checkbox>
|
||||
</tm-groupcheckbox>
|
||||
</view>
|
||||
|
@ -177,7 +177,7 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
journalInfo() {
|
||||
return uni.$tm.vx.getters().journal.getJournalInfo;
|
||||
return uni.$tm.vx.getters().getJournalInfo;
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
|
@ -97,7 +97,7 @@ export default {
|
||||
},
|
||||
|
||||
onLoad() {
|
||||
this.fnSetPageTitle('我的个人信息');
|
||||
this.fnSetPageTitle('个人资料');
|
||||
},
|
||||
created() {
|
||||
this.fnGetData();
|
||||
|
@ -13,6 +13,7 @@ export const checkPlatform = (name) => {
|
||||
// 默认的应用设置
|
||||
export const _DefaultAppSettings = {
|
||||
showStartPage: false, // 是否每次启动都显示启动页
|
||||
isAvatarRadius: false, // 评论头像是否圆形
|
||||
banner: {
|
||||
useDot: true,
|
||||
dotPosition: 'right'
|
||||
@ -47,7 +48,6 @@ export const _DefaultAppSettings = {
|
||||
showAdmin: false, // 显示后台登录入口
|
||||
showAllCount: true, // 默认显示所有的统计信息(关于页面)
|
||||
},
|
||||
|
||||
// 文章配置
|
||||
article: {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user