Files
Kairo-Jinkendo/frontend/src/composition/providerComponents.jsx
T
LarsandCursor 3a0ef3a734
Deploy Development / deploy (push) Successful in 52s
Test Suite / pytest-backend (push) Failing after 5m3s
Test Suite / k6 /api/health Baseline (push) Has been skipped
Test Suite / playwright-smoke (push) Has been skipped
Test Suite / lint-backend (push) Successful in 3s
Test Suite / compose-smoke (push) Has been skipped
feat(A1): Progression Join-Graph und Multi-Strang-Horizon
join_gate, strand_project_id, Join-Auto-Schalten, multi-active Gates, Progression-Demo und PO-Lock-Spec. FE: Today strang-gruppiert, Join-Warteliste in Kontrolle.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-28 16:28:08 +02:00

60 lines
2.2 KiB
React

import { Link } from 'react-router-dom'
import { scopedPath } from '../utils/routes.js'
import { SteeringSnapshotPanel } from '../components/SteeringSnapshotPanel.jsx'
import { CriticalPathPanel } from '../components/CriticalPathPanel.jsx'
import { JoinWaitlistPanel } from '../components/JoinWaitlistPanel.jsx'
import { MaturityStagePanel } from '../components/MaturityStagePanel.jsx'
import { RecurringRhythmPanel } from '../components/RecurringRhythmPanel.jsx'
import { AgentSlotsPanel } from '../components/AgentSlotsPanel.jsx'
import { SteeringProposalsPanel } from '../components/SteeringProposalsPanel.jsx'
import { NextActionWidget } from '../widgets/NextActionWidget.jsx'
import { WorkTodayPracticePanel } from '../components/WorkTodayPracticePanel.jsx'
import { WorkActionsPanel } from './WorkActionsPanel.jsx'
/** Roadblocker-Strip — extrahiert aus InitiativeOverviewPage für Composition. */
export function RoadblockersStrip({ initiativeId, actionsBlocked = 0, blockersOpen = 0 }) {
if (actionsBlocked <= 0 && blockersOpen <= 0) return null
return (
<section className="card initiative-summary-strip">
<h2 className="card-title">Roadblocker</h2>
<p className="muted">
{actionsBlocked > 0 && <span>{actionsBlocked} blockierte Arbeitspakete</span>}
{actionsBlocked > 0 && blockersOpen > 0 && ' · '}
{blockersOpen > 0 && <span>{blockersOpen} offene Blocker</span>}
</p>
<Link to={scopedPath('/work/today', { initiativeId })} className="btn btn-secondary btn-sm">
Zur Ausführung
</Link>
</section>
)
}
export function WidgetHost({ widget }) {
if (!widget?.component) return null
const Component = widget.component
return <Component key={widget.key} />
}
/** @type {Record<string, import('react').ComponentType<any>>} */
export const PROVIDER_COMPONENTS = {
SteeringSnapshotPanel,
CriticalPathPanel,
MaturityStagePanel,
RecurringRhythmPanel,
NextActionWidget,
AgentSlotsPanel,
SteeringProposalsPanel,
RoadblockersStrip,
WidgetHost,
WorkActionsPanel,
WorkTodayPracticePanel,
JoinWaitlistPanel,
}
/**
* @param {string} componentKey
*/
export function getProviderComponent(componentKey) {
return PROVIDER_COMPONENTS[componentKey] || null
}