refactor(frontend): deduplicate CSS keyframes, unify types, extract format utils, add UI states, trim mock data
CI - Build & Test / Backend (.NET) (push) Failing after 23s
CI - Build & Test / Frontend (Vue/TS) (push) Successful in 16s
CI - Build & Test / Security Check (push) Successful in 3s

- Remove duplicate @keyframes pulse-* from 3 component files (already in nexus-tokens.css)
- Rename AgentDetail → AgentDetailData in dashboard types to avoid collision with types/agent.ts
- Extract shared formatNumber/initials/formatTime to utils/format.ts
- Simplify FlowBoard: use agentStore modal/selection getters instead of duplicating local state
- Add error banner + empty state to IrisChat; add loading skeleton + error/empty states to TaskStrip
- Remove 105-line unused mockAgents array from useFlowLayout
- Reduce operations store fallbacks from hardcoded preview data to minimal safe defaults
- Update operations store tests to match lean fallback structure
- Net: -73 lines, cleaner imports, fewer magic strings
This commit is contained in:
2026-06-12 17:02:50 +02:00
parent 9033ff2973
commit 6cedd8410f
14 changed files with 173 additions and 246 deletions
@@ -8,6 +8,7 @@ import {
} from '@lucide/vue'
import { useRouter } from 'vue-router'
import { useAuthStore } from '../../stores/auth'
import { initials } from '../../utils/format'
const props = defineProps<{
activeView: string
@@ -23,7 +24,9 @@ const emit = defineEmits<{
const auth = useAuthStore()
const router = useRouter()
const ownerInitials = computed(() => auth.user?.displayName.split(' ').map(part => part[0]).join('').slice(0, 2).toUpperCase() ?? 'OW')
const ownerInitials = computed(() =>
auth.user?.displayName ? initials(auth.user.displayName) : 'OW'
)
const navigation = [
{ label: 'Dashboard', icon: LayoutDashboard },
+2 -2
View File
@@ -7,6 +7,7 @@ import { useTaskStore } from '../../stores/tasks'
import { navigation, icons } from '../../composables/icons'
import type { NavGroupDef } from '../../composables/icons'
import NavGroup from './NavGroup.vue'
import { initials } from '../../utils/format'
const auth = useAuthStore()
const router = useRouter()
@@ -14,8 +15,7 @@ const agentStore = useAgentStore()
const taskStore = useTaskStore()
const ownerInitials = computed(() =>
auth.user?.displayName?.split(' ').map(p => p[0]).join('').slice(0, 2).toUpperCase()
?? 'OW'
auth.user?.displayName ? initials(auth.user.displayName) : 'OW'
)
function logout() {
@@ -138,9 +138,4 @@ defineProps<{
height: 15px;
}
@keyframes pulse-work {
0% { box-shadow: 0 0 0 0 rgba(61,220,151,.55); }
70% { box-shadow: 0 0 0 7px rgba(61,220,151,0); }
100% { box-shadow: 0 0 0 0 rgba(61,220,151,0); }
}
</style>