mirror of
https://github.com/the1812/Bilibili-Evolved.git
synced 2025-11-04 21:22:45 +08:00
Add switch options for simplifyComments (#2381)
This commit is contained in:
parent
3fc6b3130c
commit
46e9d791ac
@ -4,21 +4,8 @@ $prefix: 'simplifyComments-switch';
|
|||||||
|
|
||||||
.bili-comment {
|
.bili-comment {
|
||||||
.reply-item {
|
.reply-item {
|
||||||
// body.#{$prefix}-level & {
|
// [布局微调]
|
||||||
.user-level,
|
// 回复项
|
||||||
.sub-user-level {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
// }
|
|
||||||
// body.#{$prefix}-subReplyNewline & {
|
|
||||||
.sub-user-info {
|
|
||||||
display: flex !important;
|
|
||||||
}
|
|
||||||
// }
|
|
||||||
// body.#{$prefix}-layout & {
|
|
||||||
.reply-decorate {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
.sub-user-info,
|
.sub-user-info,
|
||||||
.sub-user-name {
|
.sub-user-name {
|
||||||
line-height: 1.5 !important;
|
line-height: 1.5 !important;
|
||||||
@ -27,32 +14,38 @@ $prefix: 'simplifyComments-switch';
|
|||||||
margin-bottom: 4px !important;
|
margin-bottom: 4px !important;
|
||||||
max-height: 19.5px !important;
|
max-height: 19.5px !important;
|
||||||
}
|
}
|
||||||
.reply-content-container {
|
// 笔记
|
||||||
display: block !important;
|
|
||||||
flex-basis: 100% !important;
|
|
||||||
}
|
|
||||||
.root-reply:not(.reply-content-container) {
|
|
||||||
padding: 0 !important;
|
|
||||||
display: flex !important;
|
|
||||||
align-items: center !important;
|
|
||||||
flex-wrap: wrap !important;
|
|
||||||
}
|
|
||||||
.note-content {
|
.note-content {
|
||||||
flex-basis: 100% !important;
|
flex-basis: 100% !important;
|
||||||
margin-bottom: 4px !important;
|
margin-bottom: 4px !important;
|
||||||
}
|
}
|
||||||
|
// 笔记图片
|
||||||
.image-exhibition {
|
.image-exhibition {
|
||||||
flex-basis: 100% !important;
|
flex-basis: 100% !important;
|
||||||
margin-bottom: 8px !important;
|
margin-bottom: 8px !important;
|
||||||
}
|
}
|
||||||
.root-reply,
|
// 右侧操作菜单
|
||||||
.reply-info,
|
.reply-operation-warp,
|
||||||
.sub-reply-info {
|
.sub-reply-operation-warp {
|
||||||
position: static !important;
|
right: -5px !important;
|
||||||
}
|
}
|
||||||
.reply-info,
|
|
||||||
.sub-reply-info {
|
body.#{$prefix}-userLevel & {
|
||||||
display: inline-flex !important;
|
.user-level,
|
||||||
|
.sub-user-level {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
body.#{$prefix}-userPendent & {
|
||||||
|
.bili-avatar-pendent-dom {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
body.#{$prefix}-decorateAndTime & {
|
||||||
|
.reply-decorate {
|
||||||
|
display: none !important;
|
||||||
}
|
}
|
||||||
.reply-time,
|
.reply-time,
|
||||||
.sub-reply-time {
|
.sub-reply-time {
|
||||||
@ -65,9 +58,30 @@ $prefix: 'simplifyComments-switch';
|
|||||||
.sub-reply-time {
|
.sub-reply-time {
|
||||||
top: 8px !important;
|
top: 8px !important;
|
||||||
}
|
}
|
||||||
.reply-operation-warp,
|
// .sub-user-info {
|
||||||
.sub-reply-operation-warp {
|
// display: flex !important;
|
||||||
right: -5px !important;
|
// }
|
||||||
|
}
|
||||||
|
|
||||||
|
body.#{$prefix}-subReplyNewLine & {
|
||||||
|
.root-reply:not(.reply-content-container) {
|
||||||
|
padding: 0 !important;
|
||||||
|
display: flex !important;
|
||||||
|
align-items: center !important;
|
||||||
|
flex-wrap: wrap !important;
|
||||||
|
}
|
||||||
|
.reply-content-container {
|
||||||
|
display: block !important;
|
||||||
|
flex-basis: 100% !important;
|
||||||
|
}
|
||||||
|
.root-reply,
|
||||||
|
.reply-info,
|
||||||
|
.sub-reply-info {
|
||||||
|
position: static !important;
|
||||||
|
}
|
||||||
|
.reply-info,
|
||||||
|
.sub-reply-info {
|
||||||
|
display: inline-flex !important;
|
||||||
}
|
}
|
||||||
.reply-tag-list {
|
.reply-tag-list {
|
||||||
display: inline-flex !important;
|
display: inline-flex !important;
|
||||||
@ -76,9 +90,10 @@ $prefix: 'simplifyComments-switch';
|
|||||||
padding: 4px 6px !important;
|
padding: 4px 6px !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
// body.#{$prefix}-replyEditor & {
|
}
|
||||||
|
|
||||||
|
body.#{$prefix}-replyEditor & {
|
||||||
.reply-box-send {
|
.reply-box-send {
|
||||||
.send-text {
|
.send-text {
|
||||||
font-size: 14px !important;
|
font-size: 14px !important;
|
||||||
@ -87,5 +102,5 @@ $prefix: 'simplifyComments-switch';
|
|||||||
.reply-box-textarea {
|
.reply-box-textarea {
|
||||||
line-height: normal !important;
|
line-height: normal !important;
|
||||||
}
|
}
|
||||||
// }
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,10 +1,11 @@
|
|||||||
- 删除热评头像下方的关注按钮
|
去除或优化评论区内的元素, 可配置以下选项 (描述的是勾选时的效果):
|
||||||
- 删除用户的等级标识
|
|
||||||
- 删除发送源信息(\`来自安卓客户端\` 这种)
|
|
||||||
- 删除用户名右边的勋章
|
|
||||||
- 删除评论区顶部的横幅
|
|
||||||
- 发送时间移动到右上角
|
|
||||||
- 位图图标全部换用矢量图标, 高分屏不会模糊
|
|
||||||
- 投票仅显示链接, 隐藏下面的大框.
|
|
||||||
|
|
||||||
> 注: 关注和等级可以通过鼠标停留在头像上, 在弹出的资料卡小窗中查看.
|
> 配置项仅对新版评论区有效
|
||||||
|
|
||||||
|
- `用户等级`: 隐藏用户等级标识. (隐藏后, 可以通过鼠标停留在头像上, 在弹出的资料卡小窗中查看)
|
||||||
|
- `装扮 & 时间`: 隐藏装扮图片, 并把发送时间移动到装扮的位置.
|
||||||
|
- `头像框`: 隐藏头像框.
|
||||||
|
- `回复换行`:
|
||||||
|
- 楼中楼回复也另起一行显示, 和一级回复保持一致.
|
||||||
|
- `热评`, `UP 主点赞` 等标记和点赞栏放在同一行.
|
||||||
|
- `编辑框`: 将提示文本居上, 符合用户实际输入文字的位置, 并将发布按钮的字号略微调小.
|
||||||
|
|||||||
@ -1,8 +1,38 @@
|
|||||||
import { defineComponentMetadata } from '@/components/define'
|
import { wrapSwitchOptions } from '@/components/switch-options'
|
||||||
|
|
||||||
const name = 'simplifyComments'
|
const name = 'simplifyComments'
|
||||||
export const component = defineComponentMetadata({
|
export const component = wrapSwitchOptions({
|
||||||
|
name: 'simplifyOptions',
|
||||||
|
switchProps: {
|
||||||
|
checkedIcon: 'mdi-checkbox-marked-circle',
|
||||||
|
notCheckedIcon: 'mdi-checkbox-blank-circle-outline',
|
||||||
|
},
|
||||||
|
dimAt: false,
|
||||||
|
switches: {
|
||||||
|
userLevel: {
|
||||||
|
defaultValue: true,
|
||||||
|
displayName: '用户等级',
|
||||||
|
},
|
||||||
|
decorateAndTime: {
|
||||||
|
defaultValue: true,
|
||||||
|
displayName: '装扮 & 时间',
|
||||||
|
},
|
||||||
|
userPendent: {
|
||||||
|
defaultValue: false,
|
||||||
|
displayName: '头像框',
|
||||||
|
},
|
||||||
|
subReplyNewLine: {
|
||||||
|
defaultValue: true,
|
||||||
|
displayName: '回复换行',
|
||||||
|
},
|
||||||
|
replyEditor: {
|
||||||
|
defaultValue: true,
|
||||||
|
displayName: '编辑框',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})({
|
||||||
name,
|
name,
|
||||||
|
displayName: '简化评论区',
|
||||||
entry: async ({ metadata }) => {
|
entry: async ({ metadata }) => {
|
||||||
const { addComponentListener } = await import('@/core/settings')
|
const { addComponentListener } = await import('@/core/settings')
|
||||||
addComponentListener(
|
addComponentListener(
|
||||||
@ -23,6 +53,5 @@ export const component = defineComponentMetadata({
|
|||||||
style: () => import('./comments-v2.scss'),
|
style: () => import('./comments-v2.scss'),
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
displayName: '简化评论区',
|
|
||||||
tags: [componentsTags.style],
|
tags: [componentsTags.style],
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user