feat(auth): 重构统一认证并支持平级服务无感登录
This commit is contained in:
1 parent
d79def5519
commit
ca312ea751
64 files changed
+3713
-449
No files matched your search
@@ -6,6 +6,7 @@
|
||||
import { onBeforeUnmount, onMounted, ref } from 'vue';
|
||||
import { BookOpen, History, LayoutGrid } from 'lucide-vue-next';
|
||||
import AgentCategoryList from '@/shared/components/AgentCategoryList.vue';
|
||||
import { ExternalSystemLinks } from '@/features/sso';
|
||||
import type { AgentWithCategory } from '@/shared/utils/agent-category.utils';
|
||||
|
||||
export interface ChatMobileHeaderAgent extends AgentWithCategory {}
|
||||
@@ -76,6 +77,7 @@ onBeforeUnmount(() => {
|
||||
</button>
|
||||
</div>
|
||||
<div class="flex items-center gap-1">
|
||||
<ExternalSystemLinks compact :show-label="false" />
|
||||
<button
|
||||
type="button"
|
||||
class="flex h-9 w-9 items-center justify-center rounded-full text-muted transition-colors hover-surface-soft"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/**
|
||||
* features/chat/components/ChatSidebar.vue
|
||||
* 用途:桌面端聊天侧栏,承载 Agent 信息、会话历史、Agent 切换面板与底部用户菜单。
|
||||
* 依赖:lucide-vue-next、LocaleToggleButton、AgentCategoryList、chat.types。
|
||||
* 依赖:lucide-vue-next、LocaleToggleButton、ExternalSystemLinks、AgentCategoryList、chat.types。
|
||||
* 逻辑:由聊天页面传入当前 Agent、历史记录与用户可用 Agent;通过事件把新会话、切换 Agent、反馈、进入管理控制台等操作回传给页面。
|
||||
* 管理员通过底部右侧工具图标进入管理控制台;用户下拉菜单仅保留退出登录。
|
||||
*/
|
||||
@@ -25,6 +25,7 @@ import {
|
||||
X,
|
||||
} from 'lucide-vue-next';
|
||||
import LocaleToggleButton from '@/shared/components/LocaleToggleButton.vue';
|
||||
import { ExternalSystemLinks } from '@/features/sso';
|
||||
import AgentCategoryList from '@/shared/components/AgentCategoryList.vue';
|
||||
import { isHrFocusedAgent, type AgentRegistryFields } from '@/shared/utils/agent-registry.utils';
|
||||
import type { AgentWithCategory } from '@/shared/utils/agent-category.utils';
|
||||
@@ -128,6 +129,7 @@ const userInitial = (fallback: string) => {
|
||||
</button>
|
||||
|
||||
<div class="mt-auto flex flex-col items-center gap-6 pb-2 text-muted">
|
||||
<ExternalSystemLinks compact :show-label="false" />
|
||||
<button type="button" class="transition-colors hover:text-secondary"><Sparkles class="h-5 w-5" /></button>
|
||||
<div class="flex h-8 w-8 items-center justify-center rounded-full bg-brand-600 text-sm font-bold text-white shadow-sm shadow-brand-500/20">
|
||||
{{ userInitial('I') }}
|
||||
@@ -301,6 +303,7 @@ const userInitial = (fallback: string) => {
|
||||
</div>
|
||||
|
||||
<div class="flex gap-3">
|
||||
<ExternalSystemLinks compact :show-label="false" />
|
||||
<button
|
||||
type="button"
|
||||
class="transition-colors hover:text-secondary"
|
||||
|
||||
Reference in new issue
Block a user