mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-03 08:53:36 +00:00
feat: implement backlog plan management and UI enhancements
- Added functionality to save, clear, and load backlog plans within the application. - Introduced a new API endpoint for clearing saved backlog plans. - Enhanced the backlog plan dialog to allow users to review and apply changes to their features. - Integrated dependency management features in the UI, allowing users to select parent and child dependencies for features. - Improved the graph view with options to manage plans and visualize dependencies effectively. - Updated the sidebar and settings to include provider visibility toggles for better user control over model selection. These changes aim to enhance the user experience by providing robust backlog management capabilities and improving the overall UI for feature planning.
This commit is contained in:
@@ -23,6 +23,10 @@ interface GraphViewProps {
|
||||
onSpawnTask?: (feature: Feature) => void;
|
||||
onDeleteTask?: (feature: Feature) => void;
|
||||
onAddFeature?: () => void;
|
||||
onOpenPlanDialog?: () => void;
|
||||
hasPendingPlan?: boolean;
|
||||
planUseSelectedWorktreeBranch?: boolean;
|
||||
onPlanUseSelectedWorktreeBranchChange?: (value: boolean) => void;
|
||||
}
|
||||
|
||||
export function GraphView({
|
||||
@@ -42,6 +46,10 @@ export function GraphView({
|
||||
onSpawnTask,
|
||||
onDeleteTask,
|
||||
onAddFeature,
|
||||
onOpenPlanDialog,
|
||||
hasPendingPlan,
|
||||
planUseSelectedWorktreeBranch,
|
||||
onPlanUseSelectedWorktreeBranchChange,
|
||||
}: GraphViewProps) {
|
||||
const { currentProject } = useAppStore();
|
||||
|
||||
@@ -53,9 +61,6 @@ export function GraphView({
|
||||
const effectiveBranch = currentWorktreeBranch;
|
||||
|
||||
return features.filter((f) => {
|
||||
// Skip completed features (they're in archive)
|
||||
if (f.status === 'completed') return false;
|
||||
|
||||
const featureBranch = f.branchName as string | undefined;
|
||||
|
||||
if (!featureBranch) {
|
||||
@@ -178,15 +183,26 @@ export function GraphView({
|
||||
},
|
||||
onDeleteDependency: (sourceId: string, targetId: string) => {
|
||||
// Find the target feature and remove the source from its dependencies
|
||||
console.log('onDeleteDependency called', { sourceId, targetId });
|
||||
const targetFeature = features.find((f) => f.id === targetId);
|
||||
if (!targetFeature) return;
|
||||
if (!targetFeature) {
|
||||
console.error('Target feature not found:', targetId);
|
||||
return;
|
||||
}
|
||||
|
||||
const currentDeps = (targetFeature.dependencies as string[] | undefined) || [];
|
||||
console.log('Current dependencies:', currentDeps);
|
||||
const newDeps = currentDeps.filter((depId) => depId !== sourceId);
|
||||
console.log('New dependencies:', newDeps);
|
||||
|
||||
onUpdateFeature?.(targetId, {
|
||||
dependencies: newDeps,
|
||||
});
|
||||
if (onUpdateFeature) {
|
||||
console.log('Calling onUpdateFeature');
|
||||
onUpdateFeature(targetId, {
|
||||
dependencies: newDeps,
|
||||
});
|
||||
} else {
|
||||
console.error('onUpdateFeature is not defined!');
|
||||
}
|
||||
|
||||
toast.success('Dependency removed');
|
||||
},
|
||||
@@ -215,8 +231,13 @@ export function GraphView({
|
||||
nodeActionCallbacks={nodeActionCallbacks}
|
||||
onCreateDependency={handleCreateDependency}
|
||||
onAddFeature={onAddFeature}
|
||||
onOpenPlanDialog={onOpenPlanDialog}
|
||||
hasPendingPlan={hasPendingPlan}
|
||||
planUseSelectedWorktreeBranch={planUseSelectedWorktreeBranch}
|
||||
onPlanUseSelectedWorktreeBranchChange={onPlanUseSelectedWorktreeBranchChange}
|
||||
backgroundStyle={backgroundImageStyle}
|
||||
backgroundSettings={backgroundSettings}
|
||||
projectPath={projectPath}
|
||||
className="h-full"
|
||||
/>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user