mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-02-24 07:00:49 +08:00
Compare commits
19 Commits
codex/sepa
...
codex/migr
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
67d80a4edd | ||
|
|
78498c0ac3 | ||
|
|
47c997ad22 | ||
|
|
2cd220e8eb | ||
|
|
8023fa1810 | ||
|
|
04b1b32b9c | ||
|
|
f5d8f37f96 | ||
|
|
4a4c256568 | ||
|
|
3bb14ca6a3 | ||
|
|
4ed679c4f4 | ||
|
|
50848e0da1 | ||
|
|
51819913a0 | ||
|
|
741bd115d5 | ||
|
|
d13ee2257f | ||
|
|
06dea47bec | ||
|
|
f89a17f14d | ||
|
|
ac433d6a45 | ||
|
|
62e7795e11 | ||
|
|
722d784691 |
@@ -25,7 +25,7 @@
|
|||||||
class="app-new-post-icon"
|
class="app-new-post-icon"
|
||||||
@click="goToNewPost"
|
@click="goToNewPost"
|
||||||
>
|
>
|
||||||
<i class="fas fa-edit"></i>
|
<edit />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<GlobalPopups />
|
<GlobalPopups />
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="base-input">
|
<div class="base-input">
|
||||||
<i v-if="icon" :class="['base-input-icon', icon]" />
|
<component v-if="icon" :is="icon" class="base-input-icon" size="14" />
|
||||||
|
|
||||||
<!-- 普通输入框 -->
|
<!-- 普通输入框 -->
|
||||||
<input
|
<input
|
||||||
@@ -29,7 +29,7 @@ export default {
|
|||||||
inheritAttrs: false,
|
inheritAttrs: false,
|
||||||
props: {
|
props: {
|
||||||
modelValue: { type: [String, Number], default: '' },
|
modelValue: { type: [String, Number], default: '' },
|
||||||
icon: { type: String, default: '' },
|
icon: { type: [String, Object], default: '' },
|
||||||
type: { type: String, default: 'text' },
|
type: { type: String, default: 'text' },
|
||||||
textarea: { type: Boolean, default: false },
|
textarea: { type: Boolean, default: false },
|
||||||
},
|
},
|
||||||
@@ -66,7 +66,6 @@ export default {
|
|||||||
|
|
||||||
.base-input-icon {
|
.base-input-icon {
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
font-size: 14px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.base-input-text {
|
.base-input-text {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="base-placeholder">
|
<div class="base-placeholder">
|
||||||
<i :class="['base-placeholder-icon', icon]" />
|
<component :is="icon" class="base-placeholder-icon" theme="outline" size="48" />
|
||||||
<div class="base-placeholder-text">
|
<div class="base-placeholder-text">
|
||||||
<slot>{{ text }}</slot>
|
<slot>{{ text }}</slot>
|
||||||
</div>
|
</div>
|
||||||
@@ -12,7 +12,7 @@ export default {
|
|||||||
name: 'BasePlaceholder',
|
name: 'BasePlaceholder',
|
||||||
props: {
|
props: {
|
||||||
text: { type: String, default: '' },
|
text: { type: String, default: '' },
|
||||||
icon: { type: String, default: 'fas fa-inbox' },
|
icon: { type: String, default: 'Inbox' },
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -8,7 +8,11 @@
|
|||||||
:class="['base-tabs-item', { selected: modelValue === tab.key }]"
|
:class="['base-tabs-item', { selected: modelValue === tab.key }]"
|
||||||
@click="$emit('update:modelValue', tab.key)"
|
@click="$emit('update:modelValue', tab.key)"
|
||||||
>
|
>
|
||||||
<i v-if="tab.icon" :class="tab.icon"></i>
|
<component
|
||||||
|
v-if="tab.icon && (typeof tab.icon !== 'string' || !tab.icon.includes(' '))"
|
||||||
|
:is="tab.icon"
|
||||||
|
class="base-tabs-item-icon"
|
||||||
|
/>
|
||||||
<div class="base-tabs-item-label">{{ tab.label }}</div>
|
<div class="base-tabs-item-label">{{ tab.label }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -72,6 +76,7 @@ function onTouchEnd(e) {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.base-tabs-item-icon,
|
||||||
.base-tabs-item i {
|
.base-tabs-item i {
|
||||||
margin-right: 6px;
|
margin-right: 6px;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
class="option-icon"
|
class="option-icon"
|
||||||
:alt="option.name"
|
:alt="option.name"
|
||||||
/>
|
/>
|
||||||
<i v-else :class="['option-icon', option.icon]"></i>
|
<!-- <i v-else :class="['option-icon', option.icon]"></i> -->
|
||||||
</template>
|
</template>
|
||||||
<span>{{ option.name }}</span>
|
<span>{{ option.name }}</span>
|
||||||
<span class="option-count" v-if="option.count > 0"> x {{ option.count }}</span>
|
<span class="option-count" v-if="option.count > 0"> x {{ option.count }}</span>
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
<div class="comment-bottom-container">
|
<div class="comment-bottom-container">
|
||||||
<div class="comment-submit" :class="{ disabled: isDisabled }" @click="submit">
|
<div class="comment-submit" :class="{ disabled: isDisabled }" @click="submit">
|
||||||
<template v-if="!loading"> 发布评论 </template>
|
<template v-if="!loading"> 发布评论 </template>
|
||||||
<template v-else> <i class="fa-solid fa-spinner fa-spin"></i> 发布中... </template>
|
<template v-else> <loading-four /> 发布中... </template>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -15,19 +15,23 @@
|
|||||||
<div class="common-info-content-header">
|
<div class="common-info-content-header">
|
||||||
<div class="info-content-header-left">
|
<div class="info-content-header-left">
|
||||||
<span class="user-name">{{ comment.userName }}</span>
|
<span class="user-name">{{ comment.userName }}</span>
|
||||||
<i class="fas fa-medal medal-icon"></i>
|
<medal-one class="medal-icon" />
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
v-if="comment.medal"
|
v-if="comment.medal"
|
||||||
class="medal-name"
|
class="medal-name"
|
||||||
:to="`/users/${comment.userId}?tab=achievements`"
|
:to="`/users/${comment.userId}?tab=achievements`"
|
||||||
>{{ getMedalTitle(comment.medal) }}</NuxtLink
|
>{{ getMedalTitle(comment.medal) }}</NuxtLink
|
||||||
>
|
>
|
||||||
<i v-if="comment.pinned" class="fas fa-thumbtack pin-icon"></i>
|
<pin v-if="comment.pinned" class="pin-icon" />
|
||||||
<span v-if="level >= 2" class="reply-item">
|
<span v-if="level >= 2" class="reply-item">
|
||||||
<i class="fas fa-reply reply-icon"></i>
|
<next class="reply-icon" />
|
||||||
<span class="reply-info">
|
<span class="reply-info">
|
||||||
<BaseImage class="reply-avatar" :src="comment.parentUserAvatar || '/default-avatar.svg'" alt="avatar"
|
<BaseImage
|
||||||
@click="comment.parentUserClick && comment.parentUserClick()" />
|
class="reply-avatar"
|
||||||
|
:src="comment.parentUserAvatar || '/default-avatar.svg'"
|
||||||
|
alt="avatar"
|
||||||
|
@click="comment.parentUserClick && comment.parentUserClick()"
|
||||||
|
/>
|
||||||
<span class="reply-user-name">{{ comment.parentUserName }}</span>
|
<span class="reply-user-name">{{ comment.parentUserName }}</span>
|
||||||
</span>
|
</span>
|
||||||
</span>
|
</span>
|
||||||
@@ -36,7 +40,7 @@
|
|||||||
<div class="info-content-header-right">
|
<div class="info-content-header-right">
|
||||||
<DropdownMenu v-if="commentMenuItems.length > 0" :items="commentMenuItems">
|
<DropdownMenu v-if="commentMenuItems.length > 0" :items="commentMenuItems">
|
||||||
<template #trigger>
|
<template #trigger>
|
||||||
<i class="fas fa-ellipsis-vertical action-menu-icon"></i>
|
<more-one class="action-menu-icon" />
|
||||||
</template>
|
</template>
|
||||||
</DropdownMenu>
|
</DropdownMenu>
|
||||||
</div>
|
</div>
|
||||||
@@ -49,10 +53,10 @@
|
|||||||
<div class="article-footer-container">
|
<div class="article-footer-container">
|
||||||
<ReactionsGroup v-model="comment.reactions" content-type="comment" :content-id="comment.id">
|
<ReactionsGroup v-model="comment.reactions" content-type="comment" :content-id="comment.id">
|
||||||
<div class="make-reaction-item comment-reaction" @click="toggleEditor">
|
<div class="make-reaction-item comment-reaction" @click="toggleEditor">
|
||||||
<i class="far fa-comment"></i>
|
<comment-icon />
|
||||||
</div>
|
</div>
|
||||||
<div class="make-reaction-item copy-link" @click="copyCommentLink">
|
<div class="make-reaction-item copy-link" @click="copyCommentLink">
|
||||||
<i class="fas fa-link"></i>
|
<link-icon />
|
||||||
</div>
|
</div>
|
||||||
</ReactionsGroup>
|
</ReactionsGroup>
|
||||||
</div>
|
</div>
|
||||||
@@ -67,8 +71,8 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="replyCount && level < 2" class="reply-toggle" @click="toggleReplies">
|
<div v-if="replyCount && level < 2" class="reply-toggle" @click="toggleReplies">
|
||||||
<i v-if="showReplies" class="fas fa-chevron-up reply-toggle-icon"></i>
|
<up v-if="showReplies" class="reply-toggle-icon" />
|
||||||
<i v-else class="fas fa-chevron-down reply-toggle-icon"></i>
|
<down v-else class="reply-toggle-icon" />
|
||||||
{{ replyCount }}条回复
|
{{ replyCount }}条回复
|
||||||
</div>
|
</div>
|
||||||
<div v-if="showReplies && level < 2" class="reply-list">
|
<div v-if="showReplies && level < 2" class="reply-list">
|
||||||
@@ -371,7 +375,6 @@ const handleContentClick = (e) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.reply-toggle-icon {
|
.reply-toggle-icon {
|
||||||
margin-right: 5px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.common-info-content-header {
|
.common-info-content-header {
|
||||||
@@ -381,7 +384,8 @@ const handleContentClick = (e) => {
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
|
|
||||||
.reply-item, .reply-info {
|
.reply-item,
|
||||||
|
.reply-info {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
@@ -397,13 +401,16 @@ const handleContentClick = (e) => {
|
|||||||
|
|
||||||
.reply-icon {
|
.reply-icon {
|
||||||
color: var(--primary-color);
|
color: var(--primary-color);
|
||||||
margin-right: 10px;
|
|
||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
|
margin-right: 10px;
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
|
transform: scaleX(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.reply-user-name {
|
.reply-user-name {
|
||||||
opacity: 0.3;
|
opacity: 0.3;
|
||||||
|
display: none;
|
||||||
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
.medal-name {
|
.medal-name {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<div class="header-content-left">
|
<div class="header-content-left">
|
||||||
<div v-if="showMenuBtn" class="menu-btn-wrapper">
|
<div v-if="showMenuBtn" class="menu-btn-wrapper">
|
||||||
<button class="menu-btn" ref="menuBtn" @click="$emit('toggle-menu')">
|
<button class="menu-btn" ref="menuBtn" @click="$emit('toggle-menu')">
|
||||||
<i class="fas fa-bars micon"></i>
|
<application-menu class="micon"></application-menu>
|
||||||
</button>
|
</button>
|
||||||
<span
|
<span
|
||||||
v-if="isMobile && (unreadMessageCount > 0 || hasChannelUnread)"
|
v-if="isMobile && (unreadMessageCount > 0 || hasChannelUnread)"
|
||||||
@@ -25,34 +25,34 @@
|
|||||||
<ClientOnly>
|
<ClientOnly>
|
||||||
<div class="header-content-right">
|
<div class="header-content-right">
|
||||||
<div v-if="isMobile" class="search-icon" @click="search">
|
<div v-if="isMobile" class="search-icon" @click="search">
|
||||||
<i class="fas fa-search"></i>
|
<search-icon />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="isMobile" class="theme-icon" @click="cycleTheme">
|
<div v-if="isMobile" class="theme-icon" @click="cycleTheme">
|
||||||
<i :class="iconClass"></i>
|
<component :is="iconClass" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="!isMobile" class="invite_text" @click="copyInviteLink">
|
<div v-if="!isMobile" class="invite_text" @click="copyInviteLink">
|
||||||
<i class="fas fa-copy"></i>
|
<copy />
|
||||||
邀请
|
邀请
|
||||||
<i v-if="isCopying" class="fas fa-spinner fa-spin"></i>
|
<loading v-if="isCopying" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<ToolTip content="复制RSS链接" placement="bottom">
|
<ToolTip content="复制RSS链接" placement="bottom">
|
||||||
<div class="rss-icon" @click="copyRssLink">
|
<div class="rss-icon" @click="copyRssLink">
|
||||||
<i class="fas fa-rss"></i>
|
<rss />
|
||||||
</div>
|
</div>
|
||||||
</ToolTip>
|
</ToolTip>
|
||||||
|
|
||||||
<ToolTip v-if="!isMobile && isLogin" content="发帖" placement="bottom">
|
<ToolTip v-if="!isMobile && isLogin" content="发帖" placement="bottom">
|
||||||
<div class="new-post-icon" @click="goToNewPost">
|
<div class="new-post-icon" @click="goToNewPost">
|
||||||
<i class="fas fa-edit"></i>
|
<edit />
|
||||||
</div>
|
</div>
|
||||||
</ToolTip>
|
</ToolTip>
|
||||||
|
|
||||||
<ToolTip v-if="isLogin" content="站内信和频道" placement="bottom">
|
<ToolTip v-if="isLogin" content="站内信和频道" placement="bottom">
|
||||||
<div class="messages-icon" @click="goToMessages">
|
<div class="messages-icon" @click="goToMessages">
|
||||||
<i class="fas fa-comments"></i>
|
<message-emoji />
|
||||||
<span v-if="unreadMessageCount > 0" class="unread-badge">{{
|
<span v-if="unreadMessageCount > 0" class="unread-badge">{{
|
||||||
unreadMessageCount
|
unreadMessageCount
|
||||||
}}</span>
|
}}</span>
|
||||||
@@ -64,7 +64,7 @@
|
|||||||
<template #trigger>
|
<template #trigger>
|
||||||
<div class="avatar-container">
|
<div class="avatar-container">
|
||||||
<img class="avatar-img" :src="avatar" alt="avatar" />
|
<img class="avatar-img" :src="avatar" alt="avatar" />
|
||||||
<i class="fas fa-caret-down dropdown-icon"></i>
|
<down />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</DropdownMenu>
|
</DropdownMenu>
|
||||||
@@ -226,11 +226,11 @@ const headerMenuItems = computed(() => [
|
|||||||
const iconClass = computed(() => {
|
const iconClass = computed(() => {
|
||||||
switch (themeState.mode) {
|
switch (themeState.mode) {
|
||||||
case ThemeMode.DARK:
|
case ThemeMode.DARK:
|
||||||
return 'fas fa-moon'
|
return 'Moon'
|
||||||
case ThemeMode.LIGHT:
|
case ThemeMode.LIGHT:
|
||||||
return 'fas fa-sun'
|
return 'SunOne'
|
||||||
default:
|
default:
|
||||||
return 'fas fa-desktop'
|
return 'ComputerOne'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<div class="invite-code-activity">
|
<div class="invite-code-activity">
|
||||||
<div class="invite-code-description">
|
<div class="invite-code-description">
|
||||||
<div class="invite-code-description-title">
|
<div class="invite-code-description-title">
|
||||||
<i class="fas fa-info-circle"></i>
|
<info />
|
||||||
<span class="invite-code-description-title-text">邀请规则说明</span>
|
<span class="invite-code-description-title-text">邀请规则说明</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="invite-code-description-content">
|
<div class="invite-code-description-content">
|
||||||
@@ -17,7 +17,7 @@
|
|||||||
<div v-if="inviteLink" class="invite-code-link-content">
|
<div v-if="inviteLink" class="invite-code-link-content">
|
||||||
<p class="invite-code-link-content-text">
|
<p class="invite-code-link-content-text">
|
||||||
邀请链接:{{ inviteLink }}
|
邀请链接:{{ inviteLink }}
|
||||||
<span @click="copyLink"><i class="fas fa-copy copy-icon"></i></span>
|
<span @click="copyLink"><copy class="copy-icon" /></span>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
<div class="login-overlay">
|
<div class="login-overlay">
|
||||||
<div class="login-overlay-blur"></div>
|
<div class="login-overlay-blur"></div>
|
||||||
<div class="login-overlay-content">
|
<div class="login-overlay-content">
|
||||||
<i class="fa-solid fa-user login-overlay-icon"></i>
|
<user-icon class="login-overlay-icon" />
|
||||||
<div class="login-overlay-text">请先登录,点击跳转到登录页面</div>
|
<div class="login-overlay-text">请先登录,点击跳转到登录页面</div>
|
||||||
<div class="login-overlay-button" @click="goLogin">登录</div>
|
<div class="login-overlay-button" @click="goLogin">登录</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<div class="menu-content">
|
<div class="menu-content">
|
||||||
<div class="menu-item-container">
|
<div class="menu-item-container">
|
||||||
<NuxtLink class="menu-item" exact-active-class="selected" to="/" @click="handleItemClick">
|
<NuxtLink class="menu-item" exact-active-class="selected" to="/" @click="handleItemClick">
|
||||||
<i class="menu-item-icon fas fa-hashtag"></i>
|
<hashtag-key class="menu-item-icon" />
|
||||||
<span class="menu-item-text">话题</span>
|
<span class="menu-item-text">话题</span>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
@@ -13,7 +13,7 @@
|
|||||||
to="/new-post"
|
to="/new-post"
|
||||||
@click="handleItemClick"
|
@click="handleItemClick"
|
||||||
>
|
>
|
||||||
<i class="menu-item-icon fas fa-edit"></i>
|
<edit class="menu-item-icon" />
|
||||||
<span class="menu-item-text">发帖</span>
|
<span class="menu-item-text">发帖</span>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
@@ -22,7 +22,7 @@
|
|||||||
to="/message"
|
to="/message"
|
||||||
@click="handleItemClick"
|
@click="handleItemClick"
|
||||||
>
|
>
|
||||||
<i class="menu-item-icon fas fa-envelope"></i>
|
<remind class="menu-item-icon" />
|
||||||
<span class="menu-item-text">我的消息</span>
|
<span class="menu-item-text">我的消息</span>
|
||||||
<span v-if="unreadCount > 0" class="unread-container">
|
<span v-if="unreadCount > 0" class="unread-container">
|
||||||
<span class="unread"> {{ showUnreadCount }} </span>
|
<span class="unread"> {{ showUnreadCount }} </span>
|
||||||
@@ -34,7 +34,7 @@
|
|||||||
to="/about"
|
to="/about"
|
||||||
@click="handleItemClick"
|
@click="handleItemClick"
|
||||||
>
|
>
|
||||||
<i class="menu-item-icon fas fa-info-circle"></i>
|
<info class="menu-item-icon" />
|
||||||
<span class="menu-item-text">关于</span>
|
<span class="menu-item-text">关于</span>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
@@ -43,7 +43,7 @@
|
|||||||
to="/activities"
|
to="/activities"
|
||||||
@click="handleItemClick"
|
@click="handleItemClick"
|
||||||
>
|
>
|
||||||
<i class="menu-item-icon fas fa-gift"></i>
|
<gift class="menu-item-icon" />
|
||||||
<span class="menu-item-text">🔥 活动</span>
|
<span class="menu-item-text">🔥 活动</span>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
@@ -53,7 +53,7 @@
|
|||||||
to="/about/stats"
|
to="/about/stats"
|
||||||
@click="handleItemClick"
|
@click="handleItemClick"
|
||||||
>
|
>
|
||||||
<i class="menu-item-icon fas fa-chart-line"></i>
|
<chart-line class="menu-item-icon" />
|
||||||
<span class="menu-item-text">站点统计</span>
|
<span class="menu-item-text">站点统计</span>
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink
|
<NuxtLink
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
to="/points"
|
to="/points"
|
||||||
@click="handleItemClick"
|
@click="handleItemClick"
|
||||||
>
|
>
|
||||||
<i class="menu-item-icon fas fa-coins"></i>
|
<finance class="menu-item-icon" />
|
||||||
<span class="menu-item-text">
|
<span class="menu-item-text">
|
||||||
积分商城
|
积分商城
|
||||||
<span v-if="myPoint !== null" class="point-count">{{ myPoint }}</span>
|
<span v-if="myPoint !== null" class="point-count">{{ myPoint }}</span>
|
||||||
@@ -74,7 +74,8 @@
|
|||||||
<div class="menu-section">
|
<div class="menu-section">
|
||||||
<div class="section-header" @click="categoryOpen = !categoryOpen">
|
<div class="section-header" @click="categoryOpen = !categoryOpen">
|
||||||
<span>类别</span>
|
<span>类别</span>
|
||||||
<i :class="categoryOpen ? 'fas fa-chevron-up' : 'fas fa-chevron-down'"></i>
|
<up v-if="categoryOpen" class="menu-item-icon" />
|
||||||
|
<down v-else class="menu-item-icon" />
|
||||||
</div>
|
</div>
|
||||||
<div v-if="categoryOpen" class="section-items">
|
<div v-if="categoryOpen" class="section-items">
|
||||||
<div v-if="isLoadingCategory" class="menu-loading-container">
|
<div v-if="isLoadingCategory" class="menu-loading-container">
|
||||||
@@ -94,7 +95,7 @@
|
|||||||
class="section-item-icon"
|
class="section-item-icon"
|
||||||
:alt="c.name"
|
:alt="c.name"
|
||||||
/>
|
/>
|
||||||
<i v-else :class="['section-item-icon', c.smallIcon || c.icon]"></i>
|
<component v-else :is="c.smallIcon || c.icon" class="section-item-icon" />
|
||||||
</template>
|
</template>
|
||||||
<span class="section-item-text">
|
<span class="section-item-text">
|
||||||
{{ c.name }}
|
{{ c.name }}
|
||||||
@@ -107,7 +108,8 @@
|
|||||||
<div class="menu-section">
|
<div class="menu-section">
|
||||||
<div class="section-header" @click="tagOpen = !tagOpen">
|
<div class="section-header" @click="tagOpen = !tagOpen">
|
||||||
<span>标签</span>
|
<span>标签</span>
|
||||||
<i :class="tagOpen ? 'fas fa-chevron-up' : 'fas fa-chevron-down'"></i>
|
<up v-if="tagOpen" class="menu-item-icon" />
|
||||||
|
<down v-else class="menu-item-icon" />
|
||||||
</div>
|
</div>
|
||||||
<div v-if="tagOpen" class="section-items">
|
<div v-if="tagOpen" class="section-items">
|
||||||
<div v-if="isLoadingTag" class="menu-loading-container">
|
<div v-if="isLoadingTag" class="menu-loading-container">
|
||||||
@@ -120,7 +122,7 @@
|
|||||||
class="section-item-icon"
|
class="section-item-icon"
|
||||||
:alt="t.name"
|
:alt="t.name"
|
||||||
/>
|
/>
|
||||||
<i v-else class="section-item-icon fas fa-hashtag"></i>
|
<tag-one v-else class="section-item-icon" />
|
||||||
<span class="section-item-text"
|
<span class="section-item-text"
|
||||||
>{{ t.name }} <span class="section-item-text-count">x {{ t.count }}</span></span
|
>{{ t.name }} <span class="section-item-text-count">x {{ t.count }}</span></span
|
||||||
>
|
>
|
||||||
@@ -133,7 +135,7 @@
|
|||||||
<ClientOnly v-if="!isMobile">
|
<ClientOnly v-if="!isMobile">
|
||||||
<div class="menu-footer">
|
<div class="menu-footer">
|
||||||
<div class="menu-footer-btn" @click="cycleTheme">
|
<div class="menu-footer-btn" @click="cycleTheme">
|
||||||
<i :class="iconClass"></i>
|
<component :is="iconClass" class="menu-item-icon" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ClientOnly>
|
</ClientOnly>
|
||||||
@@ -193,11 +195,11 @@ const {
|
|||||||
const iconClass = computed(() => {
|
const iconClass = computed(() => {
|
||||||
switch (themeState.mode) {
|
switch (themeState.mode) {
|
||||||
case ThemeMode.DARK:
|
case ThemeMode.DARK:
|
||||||
return 'fas fa-moon'
|
return 'Moon'
|
||||||
case ThemeMode.LIGHT:
|
case ThemeMode.LIGHT:
|
||||||
return 'fas fa-sun'
|
return 'SunOne'
|
||||||
default:
|
default:
|
||||||
return 'fas fa-desktop'
|
return 'ComputerOne'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -16,8 +16,8 @@
|
|||||||
<div class="prize-count">x {{ lottery.prizeCount }}</div>
|
<div class="prize-count">x {{ lottery.prizeCount }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="prize-end-time prize-info-right">
|
<div class="prize-end-time prize-info-right">
|
||||||
<i class="fas fa-stopwatch prize-end-time-icon"></i>
|
<i v-if="!lotteryEnded" class="fas fa-stopwatch prize-end-time-icon"></i>
|
||||||
<div v-if="!isMobile" class="prize-end-time-title">离结束</div>
|
<div v-if="!isMobile && !lotteryEnded" class="prize-end-time-title">离结束</div>
|
||||||
<div class="prize-end-time-value">{{ countdown }}</div>
|
<div class="prize-end-time-value">{{ countdown }}</div>
|
||||||
<div v-if="!isMobile" class="join-prize-button-container-desktop">
|
<div v-if="!isMobile" class="join-prize-button-container-desktop">
|
||||||
<div
|
<div
|
||||||
@@ -193,6 +193,7 @@ const joinLottery = async () => {
|
|||||||
|
|
||||||
.prize-end-time-icon {
|
.prize-end-time-icon {
|
||||||
font-size: 13px;
|
font-size: 13px;
|
||||||
|
margin-right: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.prize-end-time-title {
|
.prize-end-time-title {
|
||||||
|
|||||||
@@ -19,8 +19,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="reactions-viewer-item placeholder" @click="openPanel">
|
<div class="reactions-viewer-item placeholder" @click="openPanel">
|
||||||
<i class="far fa-smile reactions-viewer-item-placeholder-icon"></i>
|
<sly-face-whit-smile class="reactions-viewer-item-placeholder-icon" />
|
||||||
<!-- <span class="reactions-viewer-item-placeholder-text">点击以表态</span> -->
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="displayedReactions.length">
|
<template v-else-if="displayedReactions.length">
|
||||||
@@ -42,7 +41,7 @@
|
|||||||
class="make-reaction-item like-reaction"
|
class="make-reaction-item like-reaction"
|
||||||
@click="toggleReaction('LIKE')"
|
@click="toggleReaction('LIKE')"
|
||||||
>
|
>
|
||||||
<i v-if="!userReacted('LIKE')" class="far fa-heart"></i>
|
<like v-if="!userReacted('LIKE')" />
|
||||||
<i v-else class="fas fa-heart"></i>
|
<i v-else class="fas fa-heart"></i>
|
||||||
<span class="reactions-count" v-if="likeCount">{{ likeCount }}</span>
|
<span class="reactions-count" v-if="likeCount">{{ likeCount }}</span>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="user-list">
|
<div class="user-list">
|
||||||
<BasePlaceholder v-if="users.length === 0" text="暂无用户" icon="fas fa-inbox" />
|
<BasePlaceholder v-if="users.length === 0" text="暂无用户" icon="Inbox" />
|
||||||
<div v-for="u in users" :key="u.id" class="user-item" @click="handleUserClick(u)">
|
<div v-for="u in users" :key="u.id" class="user-item" @click="handleUserClick(u)">
|
||||||
<BaseImage :src="u.avatar" alt="avatar" class="user-avatar" />
|
<BaseImage :src="u.avatar" alt="avatar" class="user-avatar" />
|
||||||
<div class="user-info">
|
<div class="user-info">
|
||||||
|
|||||||
@@ -15,7 +15,12 @@ export default defineNuxtConfig({
|
|||||||
telegramBotId: process.env.NUXT_PUBLIC_TELEGRAM_BOT_ID || '',
|
telegramBotId: process.env.NUXT_PUBLIC_TELEGRAM_BOT_ID || '',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
css: ['vditor/dist/index.css', '~/assets/fonts.css', '~/assets/global.css'],
|
css: [
|
||||||
|
'vditor/dist/index.css',
|
||||||
|
'~/assets/fonts.css',
|
||||||
|
'~/assets/global.css',
|
||||||
|
'@icon-park/vue-next/styles/index.css',
|
||||||
|
],
|
||||||
app: {
|
app: {
|
||||||
pageTransition: { name: 'page', mode: 'out-in' },
|
pageTransition: { name: 'page', mode: 'out-in' },
|
||||||
head: {
|
head: {
|
||||||
@@ -72,11 +77,11 @@ export default defineNuxtConfig({
|
|||||||
rel: 'manifest',
|
rel: 'manifest',
|
||||||
href: '/manifest.webmanifest',
|
href: '/manifest.webmanifest',
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
rel: 'stylesheet',
|
// rel: 'stylesheet',
|
||||||
href: 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css',
|
// href: 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css',
|
||||||
referrerpolicy: 'no-referrer',
|
// referrerpolicy: 'no-referrer',
|
||||||
},
|
// },
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
baseURL: '/',
|
baseURL: '/',
|
||||||
|
|||||||
17
frontend_nuxt/package-lock.json
generated
17
frontend_nuxt/package-lock.json
generated
@@ -6,6 +6,7 @@
|
|||||||
"": {
|
"": {
|
||||||
"name": "frontend_nuxt",
|
"name": "frontend_nuxt",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@icon-park/vue-next": "^1.4.2",
|
||||||
"@nuxt/image": "^1.11.0",
|
"@nuxt/image": "^1.11.0",
|
||||||
"@stomp/stompjs": "^7.0.0",
|
"@stomp/stompjs": "^7.0.0",
|
||||||
"cropperjs": "^1.6.2",
|
"cropperjs": "^1.6.2",
|
||||||
@@ -25,6 +26,9 @@
|
|||||||
"vue-echarts": "^7.0.3",
|
"vue-echarts": "^7.0.3",
|
||||||
"vue-flatpickr-component": "^12.0.0",
|
"vue-flatpickr-component": "^12.0.0",
|
||||||
"vue-toastification": "^2.0.0-rc.5"
|
"vue-toastification": "^2.0.0-rc.5"
|
||||||
|
},
|
||||||
|
"engines": {
|
||||||
|
"node": ">=20.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@ampproject/remapping": {
|
"node_modules/@ampproject/remapping": {
|
||||||
@@ -990,6 +994,19 @@
|
|||||||
"integrity": "sha512-m9FVDXU3GT2ITSe0UaMA5rU3QkfC/UXtCU8y0gSN/GugTqtVldOBWIB5V6V3sbmenVZUIpU6f+mPEO2+m5iTaA==",
|
"integrity": "sha512-m9FVDXU3GT2ITSe0UaMA5rU3QkfC/UXtCU8y0gSN/GugTqtVldOBWIB5V6V3sbmenVZUIpU6f+mPEO2+m5iTaA==",
|
||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
|
"node_modules/@icon-park/vue-next": {
|
||||||
|
"version": "1.4.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/@icon-park/vue-next/-/vue-next-1.4.2.tgz",
|
||||||
|
"integrity": "sha512-+QklF255wkfBOabY+xw6FAI0Bwln/RhdwCunNy/9sKdKuChtaU67QZqU67KGAvZUTeeBgsL+yaHHxqfQeGZXEQ==",
|
||||||
|
"license": "Apache-2.0",
|
||||||
|
"engines": {
|
||||||
|
"node": ">= 8.0.0",
|
||||||
|
"npm": ">= 5.0.0"
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"vue": "3.x"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@img/sharp-darwin-arm64": {
|
"node_modules/@img/sharp-darwin-arm64": {
|
||||||
"version": "0.34.3",
|
"version": "0.34.3",
|
||||||
"resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.3.tgz",
|
"resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.3.tgz",
|
||||||
|
|||||||
@@ -12,6 +12,7 @@
|
|||||||
"generate": "nuxt generate"
|
"generate": "nuxt generate"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@icon-park/vue-next": "^1.4.2",
|
||||||
"@nuxt/image": "^1.11.0",
|
"@nuxt/image": "^1.11.0",
|
||||||
"@stomp/stompjs": "^7.0.0",
|
"@stomp/stompjs": "^7.0.0",
|
||||||
"cropperjs": "^1.6.2",
|
"cropperjs": "^1.6.2",
|
||||||
|
|||||||
@@ -4,18 +4,18 @@
|
|||||||
<div class="forgot-title">找回密码</div>
|
<div class="forgot-title">找回密码</div>
|
||||||
|
|
||||||
<div v-if="step === 0" class="step-content">
|
<div v-if="step === 0" class="step-content">
|
||||||
<BaseInput icon="fas fa-envelope" v-model="email" placeholder="邮箱" />
|
<BaseInput icon="mail" v-model="email" placeholder="邮箱" />
|
||||||
<div v-if="emailError" class="error-message">{{ emailError }}</div>
|
<div v-if="emailError" class="error-message">{{ emailError }}</div>
|
||||||
<div class="primary-button" @click="sendCode" v-if="!isSending">发送验证码</div>
|
<div class="primary-button" @click="sendCode" v-if="!isSending">发送验证码</div>
|
||||||
<div class="primary-button disabled" v-else>发送中...</div>
|
<div class="primary-button disabled" v-else>发送中...</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-else-if="step === 1" class="step-content">
|
<div v-else-if="step === 1" class="step-content">
|
||||||
<BaseInput icon="fas fa-envelope" v-model="code" placeholder="邮箱验证码" />
|
<BaseInput icon="mail" v-model="code" placeholder="邮箱验证码" />
|
||||||
<div class="primary-button" @click="verifyCode" v-if="!isVerifying">验证</div>
|
<div class="primary-button" @click="verifyCode" v-if="!isVerifying">验证</div>
|
||||||
<div class="primary-button disabled" v-else>验证中...</div>
|
<div class="primary-button disabled" v-else>验证中...</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-else class="step-content">
|
<div v-else class="step-content">
|
||||||
<BaseInput icon="fas fa-lock" v-model="password" type="password" placeholder="新密码" />
|
<BaseInput icon="lock" v-model="password" type="password" placeholder="新密码" />
|
||||||
<div v-if="passwordError" class="error-message">{{ passwordError }}</div>
|
<div v-if="passwordError" class="error-message">{{ passwordError }}</div>
|
||||||
<div class="primary-button" @click="resetPassword" v-if="!isResetting">重置密码</div>
|
<div class="primary-button" @click="resetPassword" v-if="!isResetting">重置密码</div>
|
||||||
<div class="primary-button disabled" v-else>提交中...</div>
|
<div class="primary-button disabled" v-else>提交中...</div>
|
||||||
|
|||||||
@@ -68,13 +68,10 @@
|
|||||||
>
|
>
|
||||||
<div class="article-main-container">
|
<div class="article-main-container">
|
||||||
<NuxtLink class="article-item-title main-item" :to="`/posts/${article.id}`">
|
<NuxtLink class="article-item-title main-item" :to="`/posts/${article.id}`">
|
||||||
<i v-if="article.pinned" class="fas fa-thumbtack pinned-icon"></i>
|
<pin v-if="article.pinned" theme="outline" class="pinned-icon" />
|
||||||
<i v-if="article.type === 'LOTTERY'" class="fa-solid fa-gift lottery-icon"></i>
|
<gift v-if="article.type === 'LOTTERY'" class="lottery-icon" />
|
||||||
<i
|
<ranking-list v-else-if="article.type === 'POLL'" class="poll-icon" />
|
||||||
v-else-if="article.type === 'POLL'"
|
<star v-if="!article.rssExcluded" class="featured-icon" />
|
||||||
class="fa-solid fa-square-poll-vertical poll-icon"
|
|
||||||
></i>
|
|
||||||
<i v-if="!article.rssExcluded" class="fa-solid fa-star featured-icon"></i>
|
|
||||||
{{ article.title }}
|
{{ article.title }}
|
||||||
</NuxtLink>
|
</NuxtLink>
|
||||||
<NuxtLink class="article-item-description main-item" :to="`/posts/${article.id}`">
|
<NuxtLink class="article-item-description main-item" :to="`/posts/${article.id}`">
|
||||||
@@ -141,7 +138,6 @@ import { getToken } from '~/utils/auth'
|
|||||||
import { stripMarkdown } from '~/utils/markdown'
|
import { stripMarkdown } from '~/utils/markdown'
|
||||||
import { useIsMobile } from '~/utils/screen'
|
import { useIsMobile } from '~/utils/screen'
|
||||||
import TimeManager from '~/utils/time'
|
import TimeManager from '~/utils/time'
|
||||||
|
|
||||||
useHead({
|
useHead({
|
||||||
title: 'OpenIsle - 全面开源的自由社区',
|
title: 'OpenIsle - 全面开源的自由社区',
|
||||||
meta: [
|
meta: [
|
||||||
|
|||||||
@@ -6,9 +6,9 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="email-login-page-content">
|
<div class="email-login-page-content">
|
||||||
<BaseInput icon="fas fa-envelope" v-model="username" placeholder="邮箱/用户名" />
|
<BaseInput icon="mail" v-model="username" placeholder="邮箱/用户名" />
|
||||||
|
|
||||||
<BaseInput icon="fas fa-lock" v-model="password" type="password" placeholder="密码" />
|
<BaseInput icon="lock" v-model="password" type="password" placeholder="密码" />
|
||||||
|
|
||||||
<div v-if="!isWaitingForLogin" class="login-page-button-primary" @click="submitLogin">
|
<div v-if="!isWaitingForLogin" class="login-page-button-primary" @click="submitLogin">
|
||||||
<div class="login-page-button-text">登录</div>
|
<div class="login-page-button-text">登录</div>
|
||||||
|
|||||||
@@ -56,7 +56,7 @@
|
|||||||
<BasePlaceholder
|
<BasePlaceholder
|
||||||
v-if="messages.length === 0"
|
v-if="messages.length === 0"
|
||||||
text="暂无会话,发送消息试试 🎉"
|
text="暂无会话,发送消息试试 🎉"
|
||||||
icon="fas fa-inbox"
|
icon="Inbox"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -351,7 +351,7 @@ onMounted(async () => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
const subscribeToConversation = () => {
|
const subscribeToConversation = () => {
|
||||||
if (!currentUser.value) return;
|
if (!currentUser.value) return
|
||||||
const destination = `/topic/conversation/${conversationId}`
|
const destination = `/topic/conversation/${conversationId}`
|
||||||
|
|
||||||
subscribe(destination, async (message) => {
|
subscribe(destination, async (message) => {
|
||||||
@@ -375,7 +375,7 @@ const subscribeToConversation = () => {
|
|||||||
scrollToBottomSmooth()
|
scrollToBottomSmooth()
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error("Failed to parse websocket message", e)
|
console.error('Failed to parse websocket message', e)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="!loading && conversations.length === 0" class="empty-container">
|
<div v-if="!loading && conversations.length === 0" class="empty-container">
|
||||||
<BasePlaceholder v-if="conversations.length === 0" text="暂无会话" icon="fas fa-inbox" />
|
<BasePlaceholder v-if="conversations.length === 0" text="暂无会话" icon="Inbox" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
@@ -73,7 +73,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div v-else>
|
<div v-else>
|
||||||
<div v-if="channels.length === 0" class="empty-container">
|
<div v-if="channels.length === 0" class="empty-container">
|
||||||
<BasePlaceholder text="暂无频道" icon="fas fa-inbox" />
|
<BasePlaceholder text="暂无频道" icon="Inbox" />
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
v-for="ch in channels"
|
v-for="ch in channels"
|
||||||
@@ -273,7 +273,7 @@ onActivated(async () => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
const subscribeToUserMessages = () => {
|
const subscribeToUserMessages = () => {
|
||||||
if (!currentUser.value) return;
|
if (!currentUser.value) return
|
||||||
const destination = `/topic/user/${currentUser.value.id}/messages`
|
const destination = `/topic/user/${currentUser.value.id}/messages`
|
||||||
|
|
||||||
subscribe(destination, (message) => {
|
subscribe(destination, (message) => {
|
||||||
|
|||||||
@@ -15,7 +15,11 @@
|
|||||||
<div class="message-control-title">通知设置</div>
|
<div class="message-control-title">通知设置</div>
|
||||||
<div class="message-control-item-container">
|
<div class="message-control-item-container">
|
||||||
<template v-for="pref in notificationPrefs">
|
<template v-for="pref in notificationPrefs">
|
||||||
<div v-if="canShowNotification(pref.type)" :key="pref.type" class="message-control-item">
|
<div
|
||||||
|
v-if="canShowNotification(pref.type)"
|
||||||
|
:key="pref.type"
|
||||||
|
class="message-control-item"
|
||||||
|
>
|
||||||
<div class="message-control-item-label">{{ formatType(pref.type) }}</div>
|
<div class="message-control-item-label">{{ formatType(pref.type) }}</div>
|
||||||
<BaseSwitch
|
<BaseSwitch
|
||||||
:model-value="pref.enabled"
|
:model-value="pref.enabled"
|
||||||
@@ -47,7 +51,7 @@
|
|||||||
<BasePlaceholder
|
<BasePlaceholder
|
||||||
v-else-if="notifications.length === 0"
|
v-else-if="notifications.length === 0"
|
||||||
text="暂时没有消息 :)"
|
text="暂时没有消息 :)"
|
||||||
icon="fas fa-inbox"
|
icon="Inbox"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<div class="timeline-container" v-if="notifications.length > 0">
|
<div class="timeline-container" v-if="notifications.length > 0">
|
||||||
@@ -757,7 +761,12 @@ const formatType = (t) => {
|
|||||||
|
|
||||||
const isAdmin = computed(() => authState.role === 'ADMIN')
|
const isAdmin = computed(() => authState.role === 'ADMIN')
|
||||||
|
|
||||||
const needAdminSet = new Set(['POST_REVIEW_REQUEST','REGISTER_REQUEST', 'POINT_REDEEM', 'ACTIVITY_REDEEM'])
|
const needAdminSet = new Set([
|
||||||
|
'POST_REVIEW_REQUEST',
|
||||||
|
'REGISTER_REQUEST',
|
||||||
|
'POINT_REDEEM',
|
||||||
|
'ACTIVITY_REDEEM',
|
||||||
|
])
|
||||||
|
|
||||||
const canShowNotification = (type) => {
|
const canShowNotification = (type) => {
|
||||||
return !needAdminSet.has(type) || isAdmin.value
|
return !needAdminSet.has(type) || isAdmin.value
|
||||||
|
|||||||
@@ -63,11 +63,7 @@
|
|||||||
<div class="loading-points-container" v-if="historyLoading">
|
<div class="loading-points-container" v-if="historyLoading">
|
||||||
<l-hatch size="28" stroke="4" speed="3.5" color="var(--primary-color)"></l-hatch>
|
<l-hatch size="28" stroke="4" speed="3.5" color="var(--primary-color)"></l-hatch>
|
||||||
</div>
|
</div>
|
||||||
<BasePlaceholder
|
<BasePlaceholder v-else-if="histories.length === 0" text="暂无积分记录" icon="Inbox" />
|
||||||
v-else-if="histories.length === 0"
|
|
||||||
text="暂无积分记录"
|
|
||||||
icon="fas fa-inbox"
|
|
||||||
/>
|
|
||||||
<div class="timeline-container" v-else>
|
<div class="timeline-container" v-else>
|
||||||
<BaseTimeline :items="histories">
|
<BaseTimeline :items="histories">
|
||||||
<template #item="{ item }">
|
<template #item="{ item }">
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="form-row username-row">
|
<div class="form-row username-row">
|
||||||
<BaseInput
|
<BaseInput
|
||||||
icon="fas fa-user"
|
icon="user-icon"
|
||||||
v-model="username"
|
v-model="username"
|
||||||
@input="usernameError = ''"
|
@input="usernameError = ''"
|
||||||
placeholder="用户名"
|
placeholder="用户名"
|
||||||
|
|||||||
@@ -6,16 +6,11 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="emailStep === 0" class="email-signup-page-content">
|
<div v-if="emailStep === 0" class="email-signup-page-content">
|
||||||
<BaseInput
|
<BaseInput icon="mail" v-model="email" @input="emailError = ''" placeholder="邮箱" />
|
||||||
icon="fas fa-envelope"
|
|
||||||
v-model="email"
|
|
||||||
@input="emailError = ''"
|
|
||||||
placeholder="邮箱"
|
|
||||||
/>
|
|
||||||
<div v-if="emailError" class="error-message">{{ emailError }}</div>
|
<div v-if="emailError" class="error-message">{{ emailError }}</div>
|
||||||
|
|
||||||
<BaseInput
|
<BaseInput
|
||||||
icon="fas fa-user"
|
icon="user-icon"
|
||||||
v-model="username"
|
v-model="username"
|
||||||
@input="usernameError = ''"
|
@input="usernameError = ''"
|
||||||
placeholder="用户名"
|
placeholder="用户名"
|
||||||
@@ -23,7 +18,7 @@
|
|||||||
<div v-if="usernameError" class="error-message">{{ usernameError }}</div>
|
<div v-if="usernameError" class="error-message">{{ usernameError }}</div>
|
||||||
|
|
||||||
<BaseInput
|
<BaseInput
|
||||||
icon="fas fa-lock"
|
icon="lock"
|
||||||
v-model="password"
|
v-model="password"
|
||||||
@input="passwordError = ''"
|
@input="passwordError = ''"
|
||||||
type="password"
|
type="password"
|
||||||
@@ -51,7 +46,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="emailStep === 1" class="email-signup-page-content">
|
<div v-if="emailStep === 1" class="email-signup-page-content">
|
||||||
<BaseInput icon="fas fa-envelope" v-model="code" placeholder="邮箱验证码" />
|
<BaseInput icon="mail" v-model="code" placeholder="邮箱验证码" />
|
||||||
<div
|
<div
|
||||||
v-if="!isWaitingForEmailVerified"
|
v-if="!isWaitingForEmailVerified"
|
||||||
class="signup-page-button-primary"
|
class="signup-page-button-primary"
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
class="profile-page-header-subscribe-button"
|
class="profile-page-header-subscribe-button"
|
||||||
@click="subscribeUser"
|
@click="subscribeUser"
|
||||||
>
|
>
|
||||||
<i class="fas fa-user-plus"></i>
|
<add-user />
|
||||||
关注
|
关注
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
@@ -26,11 +26,11 @@
|
|||||||
class="profile-page-header-unsubscribe-button"
|
class="profile-page-header-unsubscribe-button"
|
||||||
@click="unsubscribeUser"
|
@click="unsubscribeUser"
|
||||||
>
|
>
|
||||||
<i class="fas fa-user-minus"></i>
|
<reduce-user />
|
||||||
取消关注
|
取消关注
|
||||||
</div>
|
</div>
|
||||||
<div v-if="!isMine" class="profile-page-header-subscribe-button" @click="sendMessage">
|
<div v-if="!isMine" class="profile-page-header-subscribe-button" @click="sendMessage">
|
||||||
<i class="fas fa-paper-plane"></i>
|
<message-one />
|
||||||
发私信
|
发私信
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
content="经验值可通过发帖、评论等操作获得,达到目标后即可提升等级,解锁更多功能。"
|
content="经验值可通过发帖、评论等操作获得,达到目标后即可提升等级,解锁更多功能。"
|
||||||
placement="bottom"
|
placement="bottom"
|
||||||
>
|
>
|
||||||
<i class="fas fa-info-circle profile-exp-info"></i>
|
<info class="profile-exp-info" />
|
||||||
</ToolTip>
|
</ToolTip>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -207,7 +207,7 @@
|
|||||||
<BasePlaceholder
|
<BasePlaceholder
|
||||||
v-if="filteredTimelineItems.length === 0"
|
v-if="filteredTimelineItems.length === 0"
|
||||||
text="暂无时间线"
|
text="暂无时间线"
|
||||||
icon="fas fa-inbox"
|
icon="Inbox"
|
||||||
/>
|
/>
|
||||||
<div class="timeline-list">
|
<div class="timeline-list">
|
||||||
<BaseTimeline :items="filteredTimelineItems">
|
<BaseTimeline :items="filteredTimelineItems">
|
||||||
@@ -305,7 +305,7 @@
|
|||||||
</BaseTimeline>
|
</BaseTimeline>
|
||||||
</div>
|
</div>
|
||||||
<div v-else>
|
<div v-else>
|
||||||
<BasePlaceholder text="暂无收藏文章" icon="fas fa-inbox" />
|
<BasePlaceholder text="暂无收藏文章" icon="Inbox" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -368,11 +368,11 @@ const selectedTab = ref(
|
|||||||
: 'summary',
|
: 'summary',
|
||||||
)
|
)
|
||||||
const tabs = [
|
const tabs = [
|
||||||
{ key: 'summary', label: '总结', icon: 'fas fa-chart-line' },
|
{ key: 'summary', label: '总结', icon: 'ChartLine' },
|
||||||
{ key: 'timeline', label: '时间线', icon: 'fas fa-clock' },
|
{ key: 'timeline', label: '时间线', icon: 'AlarmClock' },
|
||||||
{ key: 'following', label: '关注', icon: 'fas fa-user-plus' },
|
{ key: 'following', label: '关注', icon: 'AddUser' },
|
||||||
{ key: 'favorites', label: '收藏', icon: 'fas fa-bookmark' },
|
{ key: 'favorites', label: '收藏', icon: 'Bookmark' },
|
||||||
{ key: 'achievements', label: '勋章', icon: 'fas fa-medal' },
|
{ key: 'achievements', label: '勋章', icon: 'MedalOne' },
|
||||||
]
|
]
|
||||||
const followTab = ref('followers')
|
const followTab = ref('followers')
|
||||||
|
|
||||||
|
|||||||
88
frontend_nuxt/plugins/iconpark.client.ts
Normal file
88
frontend_nuxt/plugins/iconpark.client.ts
Normal file
@@ -0,0 +1,88 @@
|
|||||||
|
import { defineNuxtPlugin } from 'nuxt/app'
|
||||||
|
import {
|
||||||
|
Pin,
|
||||||
|
Fireworks,
|
||||||
|
Gift,
|
||||||
|
RankingList,
|
||||||
|
Star,
|
||||||
|
Edit,
|
||||||
|
HashtagKey,
|
||||||
|
Remind,
|
||||||
|
Info,
|
||||||
|
ChartLine,
|
||||||
|
Finance,
|
||||||
|
Up,
|
||||||
|
Down,
|
||||||
|
TagOne,
|
||||||
|
MedalOne,
|
||||||
|
Next,
|
||||||
|
DropDownList,
|
||||||
|
MoreOne,
|
||||||
|
SunOne,
|
||||||
|
Moon,
|
||||||
|
ComputerOne,
|
||||||
|
Comment,
|
||||||
|
Link,
|
||||||
|
SlyFaceWhitSmile,
|
||||||
|
Like,
|
||||||
|
ApplicationMenu,
|
||||||
|
Search,
|
||||||
|
Copy,
|
||||||
|
Loading,
|
||||||
|
Rss,
|
||||||
|
MessageEmoji,
|
||||||
|
AddUser,
|
||||||
|
ReduceUser,
|
||||||
|
MessageOne,
|
||||||
|
AlarmClock,
|
||||||
|
Bookmark,
|
||||||
|
Inbox,
|
||||||
|
LoadingFour,
|
||||||
|
Mail,
|
||||||
|
Lock,
|
||||||
|
User,
|
||||||
|
} from '@icon-park/vue-next'
|
||||||
|
|
||||||
|
export default defineNuxtPlugin((nuxtApp) => {
|
||||||
|
nuxtApp.vueApp.component('Pin', Pin)
|
||||||
|
nuxtApp.vueApp.component('Fireworks', Fireworks)
|
||||||
|
nuxtApp.vueApp.component('Gift', Gift)
|
||||||
|
nuxtApp.vueApp.component('RankingList', RankingList)
|
||||||
|
nuxtApp.vueApp.component('Star', Star)
|
||||||
|
nuxtApp.vueApp.component('Edit', Edit)
|
||||||
|
nuxtApp.vueApp.component('HashtagKey', HashtagKey)
|
||||||
|
nuxtApp.vueApp.component('Remind', Remind)
|
||||||
|
nuxtApp.vueApp.component('Info', Info)
|
||||||
|
nuxtApp.vueApp.component('ChartLine', ChartLine)
|
||||||
|
nuxtApp.vueApp.component('Finance', Finance)
|
||||||
|
nuxtApp.vueApp.component('Up', Up)
|
||||||
|
nuxtApp.vueApp.component('Down', Down)
|
||||||
|
nuxtApp.vueApp.component('TagOne', TagOne)
|
||||||
|
nuxtApp.vueApp.component('MedalOne', MedalOne)
|
||||||
|
nuxtApp.vueApp.component('Next', Next)
|
||||||
|
nuxtApp.vueApp.component('DropDownList', DropDownList)
|
||||||
|
nuxtApp.vueApp.component('MoreOne', MoreOne)
|
||||||
|
nuxtApp.vueApp.component('SunOne', SunOne)
|
||||||
|
nuxtApp.vueApp.component('Moon', Moon)
|
||||||
|
nuxtApp.vueApp.component('ComputerOne', ComputerOne)
|
||||||
|
nuxtApp.vueApp.component('CommentIcon', Comment)
|
||||||
|
nuxtApp.vueApp.component('LinkIcon', Link)
|
||||||
|
nuxtApp.vueApp.component('SlyFaceWhitSmile', SlyFaceWhitSmile)
|
||||||
|
nuxtApp.vueApp.component('Like', Like)
|
||||||
|
nuxtApp.vueApp.component('ApplicationMenu', ApplicationMenu)
|
||||||
|
nuxtApp.vueApp.component('SearchIcon', Search)
|
||||||
|
nuxtApp.vueApp.component('Copy', Copy)
|
||||||
|
nuxtApp.vueApp.component('Loading', Loading)
|
||||||
|
nuxtApp.vueApp.component('Rss', Rss)
|
||||||
|
nuxtApp.vueApp.component('MessageEmoji', MessageEmoji)
|
||||||
|
nuxtApp.vueApp.component('AddUser', AddUser)
|
||||||
|
nuxtApp.vueApp.component('ReduceUser', ReduceUser)
|
||||||
|
nuxtApp.vueApp.component('MessageOne', MessageOne)
|
||||||
|
nuxtApp.vueApp.component('AlarmClock', AlarmClock)
|
||||||
|
nuxtApp.vueApp.component('Bookmark', Bookmark)
|
||||||
|
nuxtApp.vueApp.component('Inbox', Inbox)
|
||||||
|
nuxtApp.vueApp.component('LoadingFour', LoadingFour)
|
||||||
|
nuxtApp.vueApp.component('UserIcon', User)
|
||||||
|
nuxtApp.vueApp.component('Mail', Mail)
|
||||||
|
nuxtApp.vueApp.component('Lock', Lock)
|
||||||
|
})
|
||||||
Reference in New Issue
Block a user