diff --git a/src/language/en.ts b/src/language/en.ts
index fa03d144..f39994f4 100644
--- a/src/language/en.ts
+++ b/src/language/en.ts
@@ -211,7 +211,11 @@ export default {
publish: 'Confirm to publish?',
publishSuccess: 'Publish Successfully',
publishCancel: 'Cancel Publish',
+ rewrite: 'Confirm to Rewrite?',
+ rewriteSuccess: 'Rewrite Successfully',
+ rewriteCancel: 'Cancel Rewrite',
draft: 'The draft has been saved successfully!',
+ leave: 'Confirm leaving the page? Your changes will not be saved.',
},
login: {
success: 'Login Successfully! Welcome to KUN Visual Novel ~ ',
diff --git a/src/language/zh.ts b/src/language/zh.ts
index 269fbcc0..cf37f86b 100644
--- a/src/language/zh.ts
+++ b/src/language/zh.ts
@@ -214,6 +214,7 @@ export default {
rewriteSuccess: 'Rewrite 成功',
rewriteCancel: '取消 Rewrite',
draft: '草稿已经保存成功!',
+ leave: '确认离开界面吗?您的更改将不会保存',
},
login: {
login: '登陆成功!欢迎来到 鲲 Galgame ~ ',
diff --git a/src/views/edit/Edit.vue b/src/views/edit/Edit.vue
index 5974ff84..ba7d8ed7 100644
--- a/src/views/edit/Edit.vue
+++ b/src/views/edit/Edit.vue
@@ -1,20 +1,50 @@
@@ -37,6 +67,7 @@ const editPageWidth = computed(() => {
+
()
+// 是否具有重新编辑的权限
+/**
+ * 这里只是简单起见,不显示重新编辑
+ * 实际上如果用户自己修改了 localStorage 中保存的信息,这个验证就失效了
+ * 但是修改了也没有用,验证逻辑位于后端
+ */
+const isShowRewrite = useKUNGalgameUserStore().uid === props.rUser.uid
+
// 点击回复打开回复面板
const handelReply = async () => {
// 保存必要信息,以便发表回复
@@ -112,7 +122,7 @@ const handleClickEdit = () => {
-
+
diff --git a/src/views/topic/components/reply/ReplyPanelBtn.vue b/src/views/topic/components/reply/ReplyPanelBtn.vue
index 6b11fb5c..d2ba5f5f 100644
--- a/src/views/topic/components/reply/ReplyPanelBtn.vue
+++ b/src/views/topic/components/reply/ReplyPanelBtn.vue
@@ -121,6 +121,11 @@ const handleShowAdvance = () => {
background-color: var(--kungalgame-blue-4);
transition: 0.1s;
}
+.confirm-btn:active {
+ background-color: var(--kungalgame-blue-3);
+ transform: scale(0.8);
+}
+
/* 保存按钮的样式 */
.save-btn {
color: var(--kungalgame-pink-4);
@@ -135,6 +140,7 @@ const handleShowAdvance = () => {
background-color: var(--kungalgame-pink-3);
transform: scale(0.8);
}
+
/* 高级选项按钮的样式 */
.advance-btn {
color: var(--kungalgame-purple-4);
@@ -146,7 +152,7 @@ const handleShowAdvance = () => {
transition: 0.1s;
}
.advance-btn:active {
- background-color: var(--kungalgame-red-3);
+ background-color: var(--kungalgame-purple-4);
transform: scale(0.8);
}