mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-03-05 16:13:08 +08:00
- Renamed `team-lifecycle-v5` to `team-lifecycle` across various documentation files for consistency. - Updated references in code examples and usage sections to reflect the new skill name. - Added a new command file for the `monitor` functionality in the `team-iterdev` skill, detailing the coordinator's monitoring events and task management. - Introduced new components for dynamic pipeline visualization and session coordinates display in the frontend. - Implemented utility functions for pipeline stage detection and status derivation based on message history. - Enhanced the team role panel to map members to their respective pipeline roles with status indicators. - Updated Chinese documentation to reflect the changes in skill names and descriptions.
64 lines
2.3 KiB
TypeScript
64 lines
2.3 KiB
TypeScript
// ========================================
|
|
// Team Store
|
|
// ========================================
|
|
// UI state for team execution visualization
|
|
|
|
import { create } from 'zustand';
|
|
import { devtools, persist } from 'zustand/middleware';
|
|
import type { TeamMessageFilter } from '@/types/team';
|
|
|
|
export type TeamDetailTab = 'pipeline' | 'artifacts' | 'messages';
|
|
|
|
interface TeamStore {
|
|
selectedTeam: string | null;
|
|
autoRefresh: boolean;
|
|
messageFilter: TeamMessageFilter;
|
|
timelineExpanded: boolean;
|
|
viewMode: 'list' | 'detail';
|
|
locationFilter: 'active' | 'archived' | 'all';
|
|
searchQuery: string;
|
|
detailTab: TeamDetailTab;
|
|
setSelectedTeam: (name: string | null) => void;
|
|
toggleAutoRefresh: () => void;
|
|
setMessageFilter: (filter: Partial<TeamMessageFilter>) => void;
|
|
clearMessageFilter: () => void;
|
|
setTimelineExpanded: (expanded: boolean) => void;
|
|
setViewMode: (mode: 'list' | 'detail') => void;
|
|
setLocationFilter: (filter: 'active' | 'archived' | 'all') => void;
|
|
setSearchQuery: (query: string) => void;
|
|
setDetailTab: (tab: TeamDetailTab) => void;
|
|
selectTeamAndShowDetail: (name: string) => void;
|
|
backToList: () => void;
|
|
}
|
|
|
|
export const useTeamStore = create<TeamStore>()(
|
|
devtools(
|
|
persist(
|
|
(set) => ({
|
|
selectedTeam: null,
|
|
autoRefresh: true,
|
|
messageFilter: {},
|
|
timelineExpanded: true,
|
|
viewMode: 'list',
|
|
locationFilter: 'active',
|
|
searchQuery: '',
|
|
detailTab: 'pipeline',
|
|
setSelectedTeam: (name) => set({ selectedTeam: name }),
|
|
toggleAutoRefresh: () => set((s) => ({ autoRefresh: !s.autoRefresh })),
|
|
setMessageFilter: (filter) =>
|
|
set((s) => ({ messageFilter: { ...s.messageFilter, ...filter } })),
|
|
clearMessageFilter: () => set({ messageFilter: {} }),
|
|
setTimelineExpanded: (expanded) => set({ timelineExpanded: expanded }),
|
|
setViewMode: (mode) => set({ viewMode: mode }),
|
|
setLocationFilter: (filter) => set({ locationFilter: filter }),
|
|
setSearchQuery: (query) => set({ searchQuery: query }),
|
|
setDetailTab: (tab) => set({ detailTab: tab }),
|
|
selectTeamAndShowDetail: (name) => set({ selectedTeam: name, viewMode: 'detail', detailTab: 'pipeline' }),
|
|
backToList: () => set({ viewMode: 'list', detailTab: 'pipeline' }),
|
|
}),
|
|
{ name: 'ccw-team-store' }
|
|
),
|
|
{ name: 'TeamStore' }
|
|
)
|
|
);
|