diff --git a/open-isle-cli/src/assets/global.css b/open-isle-cli/src/assets/global.css
index e1ab977cc..a7285b650 100644
--- a/open-isle-cli/src/assets/global.css
+++ b/open-isle-cli/src/assets/global.css
@@ -45,7 +45,7 @@ body {
/*************************
* Vditor 自定义皮肤覆写
*************************/
-.comment-editor-container .vditor {
+.vditor {
/* 去掉整体背景与边框,让它融入父容器 */
--textarea-background-color: transparent;
border: none !important;
@@ -53,7 +53,7 @@ body {
}
/* 工具栏彻底无边框、透明背景 */
-.comment-editor-container .vditor-toolbar {
+.vditor-toolbar {
background: transparent !important;
border: none !important;
box-shadow: none !important;
diff --git a/open-isle-cli/src/router/index.js b/open-isle-cli/src/router/index.js
index 6d4b476ba..2833537c0 100644
--- a/open-isle-cli/src/router/index.js
+++ b/open-isle-cli/src/router/index.js
@@ -7,6 +7,7 @@ import LoginPageView from '../views/LoginPageView.vue'
import SignupPageView from '../views/SignupPageView.vue'
import NewPostPageView from '../views/NewPostPageView.vue'
import SettingsPageView from '../views/SettingsPageView.vue'
+import ProfileView from '../views/ProfileView.vue'
const routes = [
{
@@ -48,7 +49,12 @@ const routes = [
path: '/settings',
name: 'settings',
component: SettingsPageView
- }
+ },
+ {
+ path: '/users/:id',
+ name: 'users',
+ component: ProfileView
+ },
]
const router = createRouter({
diff --git a/open-isle-cli/src/views/MessagePageView.vue b/open-isle-cli/src/views/MessagePageView.vue
index 9503c72b2..ac7547e30 100644
--- a/open-isle-cli/src/views/MessagePageView.vue
+++ b/open-isle-cli/src/views/MessagePageView.vue
@@ -106,7 +106,20 @@ export default {
return
}
const data = await res.json()
- notifications.value = data.map(n => ({ ...n, icon: iconMap[n.type] }))
+
+ for (const n of data) {
+ if (n.type === 'COMMENT_REPLY') {
+ notifications.value.push({
+ ...n,
+ src: n.comment.author.avatar,
+ })
+ } else {
+ notifications.value.push({
+ ...n,
+ icon: iconMap[n.type],
+ })
+ }
+ }
} catch (e) {
console.error(e)
}
diff --git a/open-isle-cli/src/views/ProfileView.vue b/open-isle-cli/src/views/ProfileView.vue
new file mode 100644
index 000000000..bd383aa88
--- /dev/null
+++ b/open-isle-cli/src/views/ProfileView.vue
@@ -0,0 +1,222 @@
+
+
+
+
+
+
+
加入时间:
+
2024 年 1月 17 日
+
+
+
+
最后发帖时间:
+
2024 年 2月 17 日
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/main/java/com/openisle/service/SearchService.java b/src/main/java/com/openisle/service/SearchService.java
index edfa55d62..a81ee0c88 100644
--- a/src/main/java/com/openisle/service/SearchService.java
+++ b/src/main/java/com/openisle/service/SearchService.java
@@ -92,9 +92,9 @@ public class SearchService {
.map(c -> new SearchResult(
"comment",
c.getId(),
- extractSnippet(c.getContent(), keyword, false),
- c.getAuthor().getUsername(),
c.getPost().getTitle(),
+ c.getAuthor().getUsername(),
+ extractSnippet(c.getContent(), keyword, false),
c.getPost().getId()
));