fix: 多语言翻译问题

This commit is contained in:
sophie committed 2026-04-04 14:49:11 +08:00
1 parent c380248502
commit 57ee1e522c
5 files changed
+515 -80

No files matched your search

+59 -46
View File
@@ -1,4 +1,4 @@
<script setup lang="ts">
/**
@@ -233,7 +233,7 @@ const openEditUserModal = (user: UserRow) => {
email: user.email,
department: user.department || '',
role: user.role,
password: '', // 留空表示不修改
password: '', // Keep empty unless user updates password.
real_name: user.real_name || '',
employee_id: user.employee_id || '',
phone_number: user.phone_number || '',
@@ -416,7 +416,7 @@ const openReportTab = (table: string) => {
} else {
const newTab: ReportTab = {
id: Date.now().toString(),
label: table.replace(/_/g, ' ').replace(/\b\w/g, l => l.toUpperCase()),
label: getReportTableLabel(table),
type: 'table',
table: table,
filter: {}
@@ -1492,6 +1492,18 @@ const visibleReportKeys = computed(() => {
if (chatLogsColumns.value.length === 0) return Object.keys(tableData.value[0] || {});
return chatLogsColumns.value.filter((c) => c.visible).map((c) => c.key);
});
const getReportColumnLabel = (key: string) => {
const i18nKey = `admin.report.columns.${key}`;
const translated = t(i18nKey);
if (translated && translated !== i18nKey) return translated;
return key.replace(/_/g, ' ').replace(/\b\w/g, (m) => m.toUpperCase());
};
const getReportTableLabel = (table: string) => {
const i18nKey = `admin.report.tables.${table}`;
const translated = t(i18nKey);
if (translated && translated !== i18nKey) return translated;
return table.replace(/_/g, ' ').replace(/\b\w/g, (m) => m.toUpperCase());
};
const getReportRowId = (row: any) => Number(row?.id);
const allReportRowsSelected = computed(() => {
if (!isChatLogsTable.value || paginatedSortedTableData.value.length === 0) return false;
@@ -1595,7 +1607,7 @@ const onReportHeaderClick = (key: string) => {
};
const getHeaderSortMark = (key: string) => {
if (reportHeaderSort.value?.key !== key) return '';
return reportHeaderSort.value.direction === 'asc' ? '▲' : '▼';
return reportHeaderSort.value.direction === 'asc' ? '↑' : '↓';
};
const addChatLogsSortRule = () => {
const keys = visibleReportKeys.value;
@@ -2019,7 +2031,7 @@ const handlePermissionImport = async (event: Event) => {
:class="(activeModule === 'reports' && currentTable === table) ? 'bg-brand-50 text-brand-700' : 'text-slate-500 dark:text-slate-400 hover:bg-slate-50 dark:hover:bg-slate-800 hover:text-slate-900 dark:hover:text-slate-100'"
>
<div class="w-1.5 h-1.5 rounded-full" :class="(activeModule === 'reports' && currentTable === table) ? 'bg-brand-600' : 'bg-slate-300'"></div>
{{ table.replace(/_/g, ' ').replace(/\b\w/g, l => l.toUpperCase()) }}
{{ getReportTableLabel(table) }}
</button>
</div>
</div>
@@ -2044,7 +2056,7 @@ const handlePermissionImport = async (event: Event) => {
<div class="p-3 bg-brand-50 rounded-xl group-hover:bg-brand-100 transition-colors">
<Bot class="w-6 h-6 text-brand-600" />
</div>
<span class="text-xs font-medium text-green-600 bg-green-50 px-2 py-1 rounded-full">+2 new</span>
<span class="text-xs font-medium text-green-600 bg-green-50 px-2 py-1 rounded-full">+2 {{ t('admin.dash.new') }}</span>
</div>
<div class="text-3xl font-bold text-slate-900 dark:text-slate-100 mb-1">{{ agents.length }}</div>
<div class="text-sm text-slate-500 dark:text-slate-400 font-medium">{{ t('admin.dash.activeAgents') }}</div>
@@ -2317,19 +2329,19 @@ const handlePermissionImport = async (event: Event) => {
<div class="space-y-4">
<div class="space-y-1.5">
<label class="text-xs font-semibold text-gray-500 uppercase">{{ t('admin.dept.fields.name') }}</label>
<input v-model="editingDept.name" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" placeholder="e.g. IT Department" />
<input v-model="editingDept.name" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" :placeholder="t('admin.dept.fields.namePlaceholder')" />
</div>
<div class="space-y-1.5">
<label class="text-xs font-semibold text-gray-500 uppercase">{{ t('admin.dept.fields.code') }}</label>
<input v-model="editingDept.code" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" placeholder="e.g. DEPT-001" />
<input v-model="editingDept.code" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" :placeholder="t('admin.dept.fields.codePlaceholder')" />
</div>
<div class="space-y-1.5">
<label class="text-xs font-semibold text-gray-500 uppercase">{{ t('admin.dept.fields.company') }}</label>
<input v-model="editingDept.company" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" placeholder="e.g. HQ" />
<input v-model="editingDept.company" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" :placeholder="t('admin.dept.fields.companyPlaceholder')" />
</div>
<div class="space-y-1.5">
<label class="text-xs font-semibold text-gray-500 uppercase">{{ t('admin.dept.fields.description') }}</label>
<textarea v-model="editingDept.description" rows="3" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" placeholder="Department description..."></textarea>
<textarea v-model="editingDept.description" rows="3" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" :placeholder="t('admin.dept.fields.descriptionPlaceholder')"></textarea>
</div>
<div class="flex justify-end gap-2 pt-2">
@@ -2404,7 +2416,7 @@ const handlePermissionImport = async (event: Event) => {
v-model="newAgent.name"
type="text"
class="w-full border-gray-200 rounded-xl px-4 py-3 text-base focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none transition-all shadow-sm"
placeholder="e.g. HR Assistant"
:placeholder="t('admin.agent.fields.namePlaceholder')"
/>
</div>
<div class="space-y-2">
@@ -2438,7 +2450,7 @@ const handlePermissionImport = async (event: Event) => {
v-model="newAgent.api_base_url"
type="text"
class="w-full border-gray-200 rounded-xl px-4 py-3 text-sm font-mono bg-white focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none shadow-sm"
placeholder="Default: Dify Config"
:placeholder="t('admin.agent.fields.baseUrlPlaceholder')"
/>
</div>
</template>
@@ -2620,7 +2632,7 @@ const handlePermissionImport = async (event: Event) => {
<div class="space-y-4">
<div class="space-y-1.5">
<label class="text-xs font-semibold text-gray-500 uppercase">{{ t('admin.question.fields.title') }}</label>
<input v-model="newQuestion.title" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" placeholder="e.g. Write Report" />
<input v-model="newQuestion.title" class="w-full px-3 py-2 border rounded-xl text-sm focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 outline-none" :placeholder="t('admin.question.fields.titlePlaceholder')" />
</div>
<div class="space-y-1.5">
<label class="text-xs font-semibold text-gray-500 uppercase">{{ t('admin.question.fields.targetAgent') }}</label>
@@ -2992,17 +3004,17 @@ const handlePermissionImport = async (event: Event) => {
<span class="inline-flex h-8 w-8 items-center justify-center rounded-xl bg-gradient-to-br from-sky-600 to-cyan-500 shadow-md shadow-cyan-200/70">
<BarChart2 class="w-4 h-4 text-white" />
</span>
{{ t('admin.report.title', { table: currentTable.replace(/_/g, ' ').replace(/\b\w/g, l => l.toUpperCase()) }) }}
{{ t('admin.report.title', { table: getReportTableLabel(currentTable) }) }}
</h2>
<div class="flex flex-wrap items-center gap-2 text-xs">
<span class="inline-flex items-center rounded-full border border-slate-200 bg-slate-50 px-3 py-1 font-medium text-slate-600">
{{ t('admin.report.subtitle') }}
</span>
<span v-if="isChatLogsTable" class="inline-flex items-center rounded-full border border-cyan-200 bg-cyan-50 px-3 py-1 font-semibold text-cyan-700">
Total: {{ chatLogsTotal }}
{{ t('admin.report.totalRows', { total: chatLogsTotal }) }}
</span>
<span class="inline-flex items-center rounded-full border border-indigo-200 bg-indigo-50 px-3 py-1 font-semibold text-indigo-700">
Showing: {{ reportRangeStart }}-{{ reportRangeEnd }} / {{ reportTotalRows }}
{{ t('admin.report.showingRange', { start: reportRangeStart, end: reportRangeEnd, total: reportTotalRows }) }}
</span>
</div>
</div>
@@ -3010,17 +3022,17 @@ const handlePermissionImport = async (event: Event) => {
<button
@click="showChatLogsColumnPanel = !showChatLogsColumnPanel"
class="inline-flex items-center gap-2 px-5 py-2.5 rounded-xl text-sm font-semibold text-slate-700 border border-slate-300 bg-white hover:bg-slate-50 hover:border-slate-400 transition-colors"
title="Column Settings"
:title="t('admin.report.columnSettings')"
>
<Settings2 class="w-4 h-4" />
<span>Column Settings</span>
<span>{{ t('admin.report.columnSettings') }}</span>
</button>
<button
v-if="isChatLogsTable"
@click="showChatLogsSelection = !showChatLogsSelection"
class="px-3 py-2 border border-slate-300 rounded-xl text-xs font-medium text-slate-600 hover:bg-slate-50"
>
{{ showChatLogsSelection ? 'Hide Selection' : 'Show Selection' }}
{{ showChatLogsSelection ? t('admin.report.hideSelection') : t('admin.report.showSelection') }}
</button>
<button
v-if="isChatLogsTable && showChatLogsSelection"
@@ -3028,7 +3040,7 @@ const handlePermissionImport = async (event: Event) => {
:disabled="selectedReportRowIds.length === 0 || isDeletingChatLogs"
class="flex items-center gap-2 px-4 py-2 bg-rose-600 text-white text-sm font-medium rounded-xl hover:bg-rose-700 transition-all shadow-md shadow-rose-200 active:scale-95 disabled:opacity-50 disabled:cursor-not-allowed"
>
{{ isDeletingChatLogs ? 'Deleting...' : `Delete Selected (${selectedReportRowIds.length})` }}
{{ isDeletingChatLogs ? t('admin.report.deleting') : t('admin.report.deleteSelected', { count: selectedReportRowIds.length }) }}
</button>
<button
@@ -3056,21 +3068,21 @@ const handlePermissionImport = async (event: Event) => {
class="p-4 md:p-5 rounded-2xl border border-slate-200 bg-white/90 shadow-sm"
>
<div class="flex items-center justify-between mb-3">
<div class="text-sm font-semibold text-slate-800">Table Settings</div>
<div class="text-sm font-semibold text-slate-800">{{ t('admin.report.tableSettings') }}</div>
<button
@click="resetChatLogsColumns"
class="text-xs px-3 py-1.5 rounded-lg bg-slate-50 border border-slate-200 hover:bg-slate-100 text-slate-700"
>
Reset Layout
{{ t('admin.report.resetLayout') }}
</button>
</div>
<div class="grid grid-cols-1 md:grid-cols-2 gap-3 mb-3">
<label class="flex items-center gap-2 px-3 py-2 bg-slate-50 rounded-lg border border-slate-200 text-xs text-slate-700">
<input type="checkbox" v-model="chatLogsWrapEnabled" class="w-4 h-4 rounded text-blue-600 focus:ring-blue-500" />
<span>换行</span>
<span>{{ t('admin.report.wrapText') }}</span>
</label>
<label class="flex items-center gap-2 px-3 py-2 bg-slate-50 rounded-lg border border-slate-200 text-xs text-slate-700">
<span>换行最大高度(px)</span>
<span>{{ t('admin.report.wrapMaxHeightPx') }}</span>
<input
v-model.number="chatLogsWrapMaxHeight"
type="number"
@@ -3081,15 +3093,15 @@ const handlePermissionImport = async (event: Event) => {
</div>
<div class="mb-3 p-3 bg-slate-50 rounded-xl border border-slate-200">
<div class="flex items-center justify-between mb-2">
<span class="text-xs font-semibold text-slate-700">高级排序规则(按顺序优先)</span>
<span class="text-xs font-semibold text-slate-700">{{ t('admin.report.advancedSortRules') }}</span>
<button
@click="addChatLogsSortRule"
class="text-xs px-2 py-1 rounded border border-slate-300 hover:bg-white text-slate-700"
>
+ 添加规则
+ {{ t('admin.report.addRule') }}
</button>
</div>
<div v-if="chatLogsSortRules.length === 0" class="text-xs text-slate-500">未设置高级排序,将使用列头点击排序。</div>
<div v-if="chatLogsSortRules.length === 0" class="text-xs text-slate-500">{{ t('admin.report.noAdvancedSort') }}</div>
<div v-else class="space-y-2">
<div
v-for="(rule, ridx) in chatLogsSortRules"
@@ -3098,16 +3110,16 @@ const handlePermissionImport = async (event: Event) => {
>
<span class="col-span-1 text-slate-500">{{ ridx + 1 }}.</span>
<select v-model="rule.key" class="col-span-4 px-2 py-1 border border-slate-300 rounded">
<option v-for="k in Object.keys(tableData[0] || {})" :key="`rule-key-${k}`" :value="k">{{ k }}</option>
<option v-for="k in Object.keys(tableData[0] || {})" :key="`rule-key-${k}`" :value="k">{{ getReportColumnLabel(k) }}</option>
</select>
<select v-model="rule.direction" class="col-span-3 px-2 py-1 border border-slate-300 rounded">
<option value="asc">正序</option>
<option value="desc">倒序</option>
<option value="asc">{{ t('admin.report.sortAsc') }}</option>
<option value="desc">{{ t('admin.report.sortDesc') }}</option>
</select>
<div class="col-span-4 flex items-center justify-end gap-1">
<button @click="moveChatLogsSortRule(ridx, -1)" class="px-2 py-1 rounded border border-slate-300 hover:bg-slate-50">上移</button>
<button @click="moveChatLogsSortRule(ridx, 1)" class="px-2 py-1 rounded border border-slate-300 hover:bg-slate-50">下移</button>
<button @click="removeChatLogsSortRule(ridx)" class="px-2 py-1 rounded border border-red-200 text-red-600 hover:bg-red-50">删除</button>
<button @click="moveChatLogsSortRule(ridx, -1)" class="px-2 py-1 rounded border border-slate-300 hover:bg-slate-50">{{ t('admin.report.moveUp') }}</button>
<button @click="moveChatLogsSortRule(ridx, 1)" class="px-2 py-1 rounded border border-slate-300 hover:bg-slate-50">{{ t('admin.report.moveDown') }}</button>
<button @click="removeChatLogsSortRule(ridx)" class="px-2 py-1 rounded border border-red-200 text-red-600 hover:bg-red-50">{{ t('admin.report.remove') }}</button>
</div>
</div>
</div>
@@ -3120,11 +3132,11 @@ const handlePermissionImport = async (event: Event) => {
>
<label class="flex items-center gap-2 min-w-0">
<input type="checkbox" v-model="col.visible" class="w-4 h-4 rounded text-blue-600 focus:ring-blue-500" />
<span class="text-xs text-slate-700 truncate">{{ col.key }}</span>
<span class="text-xs text-slate-700 truncate">{{ getReportColumnLabel(col.key) }}</span>
</label>
<div class="flex items-center gap-1">
<button @click="moveChatLogsColumn(col.key, -1)" class="text-xs px-1.5 py-0.5 rounded border border-slate-300 hover:bg-white">◀</button>
<button @click="moveChatLogsColumn(col.key, 1)" class="text-xs px-1.5 py-0.5 rounded border border-slate-300 hover:bg-white">▶</button>
<button @click="moveChatLogsColumn(col.key, -1)" class="text-xs px-1.5 py-0.5 rounded border border-slate-300 hover:bg-white">&lt;</button>
<button @click="moveChatLogsColumn(col.key, 1)" class="text-xs px-1.5 py-0.5 rounded border border-slate-300 hover:bg-white">&gt;</button>
</div>
</div>
</div>
@@ -3161,14 +3173,14 @@ const handlePermissionImport = async (event: Event) => {
@click="onReportHeaderClick(String(key))"
class="text-left hover:text-blue-700 transition-colors"
>
{{ key }} <span class="text-[10px] text-blue-600">{{ getHeaderSortMark(String(key)) }}</span>
{{ getReportColumnLabel(String(key)) }} <span class="text-[10px] text-blue-600">{{ getHeaderSortMark(String(key)) }}</span>
</button>
<input
v-model="columnFilters[key]"
@input="handleFilterChange"
type="text"
class="w-full px-2 py-1 text-xs border border-slate-300 rounded focus:ring-1 focus:ring-sky-500 outline-none font-normal normal-case bg-white/95"
placeholder="Filter..."
:placeholder="t('admin.report.filterPlaceholder')"
/>
</div>
<span
@@ -3206,11 +3218,11 @@ const handlePermissionImport = async (event: Event) => {
<div v-if="tableData.length > 0" class="flex flex-col gap-3 rounded-2xl border border-slate-200 bg-white/80 px-4 py-3 md:flex-row md:items-center md:justify-between">
<div class="text-sm text-slate-600">
共 {{ reportTotalRows }} 条,当前第 {{ reportCurrentPage }} / {{ reportTotalPages }} 页
{{ t('admin.report.paginationSummary', { total: reportTotalRows, page: reportCurrentPage, pages: reportTotalPages }) }}
</div>
<div class="flex flex-wrap items-center gap-2">
<label class="flex items-center gap-2 text-xs text-slate-600">
<span>每页</span>
<span>{{ t('admin.report.perPage') }}</span>
<span class="relative inline-flex items-center">
<select
v-model.number="reportPageSize"
@@ -3222,14 +3234,14 @@ const handlePermissionImport = async (event: Event) => {
<path fill-rule="evenodd" d="M5.23 7.21a.75.75 0 0 1 1.06.02L10 11.168l3.71-3.938a.75.75 0 1 1 1.08 1.04l-4.25 4.5a.75.75 0 0 1-1.08 0l-4.25-4.5a.75.75 0 0 1 .02-1.06Z" clip-rule="evenodd" />
</svg>
</span>
<span>条</span>
<span>{{ t('admin.report.itemsUnit') }}</span>
</label>
<button
@click="prevReportPage"
:disabled="reportCurrentPage <= 1"
class="rounded-lg border border-slate-300 px-2.5 py-1.5 text-xs text-slate-700 hover:bg-slate-50 disabled:opacity-40 disabled:cursor-not-allowed"
>
上一页
{{ t('admin.report.prevPage') }}
</button>
<button
v-for="btn in reportPageButtons"
@@ -3250,17 +3262,17 @@ const handlePermissionImport = async (event: Event) => {
:disabled="reportCurrentPage >= reportTotalPages"
class="rounded-lg border border-slate-300 px-2.5 py-1.5 text-xs text-slate-700 hover:bg-slate-50 disabled:opacity-40 disabled:cursor-not-allowed"
>
下一页
{{ t('admin.report.nextPage') }}
</button>
</div>
</div>
<!-- Statistics Charts -->
<div v-if="currentTable === 'chat_logs' && usageReport" class="mt-10 border-t border-slate-200 pt-10">
<h3 class="font-bold text-lg mb-6 text-slate-900">Usage Analytics</h3>
<h3 class="font-bold text-lg mb-6 text-slate-900">{{ t('admin.report.usage') }}</h3>
<div class="grid grid-cols-1 md:grid-cols-2 gap-8">
<div class="bg-white border border-slate-200 rounded-2xl p-6 shadow-sm">
<h4 class="text-sm font-bold text-slate-500 uppercase tracking-wider mb-4">Requests by User</h4>
<h4 class="text-sm font-bold text-slate-500 uppercase tracking-wider mb-4">{{ t('admin.report.byUser') }}</h4>
<div class="space-y-3">
<div v-for="u in usageReport.by_user" :key="u.username" class="flex items-center justify-between p-3 bg-slate-50 rounded-xl">
<span class="font-medium text-slate-700">{{ u.username }}</span>
@@ -3269,7 +3281,7 @@ const handlePermissionImport = async (event: Event) => {
</div>
</div>
<div class="bg-white border border-slate-200 rounded-2xl p-6 shadow-sm">
<h4 class="text-sm font-bold text-slate-500 uppercase tracking-wider mb-4">Requests by Agent</h4>
<h4 class="text-sm font-bold text-slate-500 uppercase tracking-wider mb-4">{{ t('admin.report.byAgent') }}</h4>
<div class="space-y-3">
<div v-for="a in usageReport.by_agent" :key="a.agent" class="flex items-center justify-between p-3 bg-slate-50 rounded-xl">
<span class="font-medium text-slate-700">{{ a.agent }}</span>
@@ -3654,3 +3666,4 @@ const handlePermissionImport = async (event: Event) => {
</div>
</div>
</template>
+4 -4
View File
@@ -290,7 +290,7 @@ onMounted(() => {
<h2 class="text-xl font-bold text-slate-900 dark:text-slate-100">{{ user.real_name || user.username }}</h2>
<p class="text-slate-500 dark:text-slate-400 text-sm mt-1">{{ user.email }}</p>
<div class="mt-4 inline-flex items-center px-3 py-1 rounded-full bg-slate-100 dark:bg-slate-800 text-slate-600 dark:text-slate-300 text-xs font-medium">
{{ user.role === 'admin' ? 'Administrator' : 'User' }}
{{ user.role === 'admin' ? ($t('profile.roleAdmin') || 'Administrator') : ($t('profile.roleUser') || 'User') }}
</div>
</div>
@@ -315,7 +315,7 @@ onMounted(() => {
{{ isEditing ? ($t('profile.edit') || 'Edit') : ($t('profile.personalInfo') || 'Personal Information') }}
</div>
<div class="text-xs text-slate-500 dark:text-slate-400">
{{ isEditing ? 'You have unsaved changes' : 'Switch to edit mode to update profile details' }}
{{ isEditing ? ($t('profile.unsavedChanges') || 'You have unsaved changes') : ($t('profile.editHint') || 'Switch to edit mode to update profile details') }}
</div>
</div>
<div class="flex items-center gap-2">
@@ -379,7 +379,7 @@ onMounted(() => {
<div>
<label class="text-xs font-medium text-slate-500 uppercase flex items-center gap-1.5 mb-1.5">
<Building class="w-3.5 h-3.5" /> {{ $t('admin.user.dept') || 'Department' }}
<Building class="w-3.5 h-3.5" /> {{ $t('profile.department') || 'Department' }}
</label>
<input v-if="isEditing" v-model="user.department" type="text" class="input-field" />
<div v-else class="p-2.5 bg-slate-50 dark:bg-slate-800 rounded-lg text-slate-700 dark:text-slate-300 border border-slate-200 dark:border-slate-700 text-sm font-medium">
@@ -418,7 +418,7 @@ onMounted(() => {
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
<div>
<label class="text-xs font-medium text-slate-500 uppercase mb-1.5 block">Language</label>
<label class="text-xs font-medium text-slate-500 uppercase mb-1.5 block">{{ $t('profile.language') || 'Language' }}</label>
<select
v-model="user.language"
:disabled="!isEditing"
+4 -2
View File
@@ -791,6 +791,7 @@ onMounted(async () => {
<div class="w-full max-w-6xl grid grid-cols-1 lg:grid-cols-2 gap-12 items-center p-4">
<!-- Hero Section -->
<div class="hidden lg:block space-y-8 animate-slide-up">
<!--
<div class="inline-flex items-center gap-2 px-3 py-1 rounded-full bg-brand-50 text-brand-600 text-sm font-medium border border-brand-100">
<span class="relative flex h-2 w-2">
<span class="animate-ping absolute inline-flex h-full w-full rounded-full bg-brand-400 opacity-75"></span>
@@ -798,6 +799,7 @@ onMounted(async () => {
</span>
{{ $t('title') }}
</div>
-->
<h1 class="text-5xl font-bold text-slate-900 leading-tight">
{{ $t('landing.hero.prefix') }} <br/>
<span class="text-transparent bg-clip-text bg-gradient-to-r from-brand-600 to-purple-600">{{ $t('landing.hero.highlight') }}</span>
@@ -825,7 +827,7 @@ onMounted(async () => {
</div>
</div>
<div class="grid grid-cols-2 gap-4">
<div v-if="isLoggedIn" class="grid grid-cols-2 gap-4">
<div v-for="agent in publicAgents.slice(0, 4)" :key="agent.id"
class="bg-white dark:bg-slate-900 p-4 rounded-xl border border-slate-100 dark:border-slate-700 shadow-sm flex items-center gap-3">
<div class="w-10 h-10 bg-brand-50 rounded-lg flex items-center justify-center text-brand-600 shrink-0">
@@ -892,7 +894,7 @@ onMounted(async () => {
</div>
<!-- Public Agents Showcase Mobile -->
<div v-if="publicAgents.length > 0" class="mt-8 pt-6 border-t border-slate-100 lg:hidden">
<div v-if="isLoggedIn && publicAgents.length > 0" class="mt-8 pt-6 border-t border-slate-100 lg:hidden">
<div class="grid grid-cols-4 gap-3">
<div v-for="agent in publicAgents.slice(0, 4)" :key="agent.id"
class="flex flex-col items-center">