mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-05 09:33:07 +00:00
Changes from pull-request
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
import { useEffect, useState, useCallback, useMemo, useRef } from "react";
|
import { useEffect, useState, useCallback, useMemo, useRef } from "react";
|
||||||
import {
|
import {
|
||||||
PointerSensor,
|
PointerSensor,
|
||||||
@@ -272,13 +271,16 @@ export function BoardView() {
|
|||||||
|
|
||||||
// Calculate unarchived card counts per branch
|
// Calculate unarchived card counts per branch
|
||||||
const branchCardCounts = useMemo(() => {
|
const branchCardCounts = useMemo(() => {
|
||||||
return hookFeatures.reduce((counts, feature) => {
|
return hookFeatures.reduce(
|
||||||
|
(counts, feature) => {
|
||||||
if (feature.status !== "completed") {
|
if (feature.status !== "completed") {
|
||||||
const branch = feature.branchName ?? "main";
|
const branch = feature.branchName ?? "main";
|
||||||
counts[branch] = (counts[branch] || 0) + 1;
|
counts[branch] = (counts[branch] || 0) + 1;
|
||||||
}
|
}
|
||||||
return counts;
|
return counts;
|
||||||
}, {} as Record<string, number>);
|
},
|
||||||
|
{} as Record<string, number>
|
||||||
|
);
|
||||||
}, [hookFeatures]);
|
}, [hookFeatures]);
|
||||||
|
|
||||||
// Custom collision detection that prioritizes columns over cards
|
// Custom collision detection that prioritizes columns over cards
|
||||||
@@ -341,7 +343,7 @@ export function BoardView() {
|
|||||||
const worktrees = useMemo(
|
const worktrees = useMemo(
|
||||||
() =>
|
() =>
|
||||||
currentProject
|
currentProject
|
||||||
? worktreesByProject[currentProject.path] ?? EMPTY_WORKTREES
|
? (worktreesByProject[currentProject.path] ?? EMPTY_WORKTREES)
|
||||||
: EMPTY_WORKTREES,
|
: EMPTY_WORKTREES,
|
||||||
[currentProject, worktreesByProject]
|
[currentProject, worktreesByProject]
|
||||||
);
|
);
|
||||||
@@ -429,7 +431,11 @@ export function BoardView() {
|
|||||||
worktree.path,
|
worktree.path,
|
||||||
worktree.branch
|
worktree.branch
|
||||||
);
|
);
|
||||||
if (result.success && result.result?.hasPR && result.result.prInfo) {
|
if (
|
||||||
|
result.success &&
|
||||||
|
result.result?.hasPR &&
|
||||||
|
result.result.prInfo
|
||||||
|
) {
|
||||||
fullPRInfo = result.result.prInfo;
|
fullPRInfo = result.result.prInfo;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1244,7 +1250,7 @@ export function BoardView() {
|
|||||||
open={showCreatePRDialog}
|
open={showCreatePRDialog}
|
||||||
onOpenChange={setShowCreatePRDialog}
|
onOpenChange={setShowCreatePRDialog}
|
||||||
worktree={selectedWorktreeForAction}
|
worktree={selectedWorktreeForAction}
|
||||||
<<<<<<< Updated upstream
|
projectPath={currentProject?.path || null}
|
||||||
onCreated={(prUrl) => {
|
onCreated={(prUrl) => {
|
||||||
// If a PR was created and we have the worktree branch, update all features on that branch with the PR URL
|
// If a PR was created and we have the worktree branch, update all features on that branch with the PR URL
|
||||||
if (prUrl && selectedWorktreeForAction?.branch) {
|
if (prUrl && selectedWorktreeForAction?.branch) {
|
||||||
@@ -1256,10 +1262,6 @@ export function BoardView() {
|
|||||||
persistFeatureUpdate(feature.id, { prUrl });
|
persistFeatureUpdate(feature.id, { prUrl });
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
=======
|
|
||||||
projectPath={currentProject?.path || null}
|
|
||||||
onCreated={() => {
|
|
||||||
>>>>>>> Stashed changes
|
|
||||||
setWorktreeRefreshKey((k) => k + 1);
|
setWorktreeRefreshKey((k) => k + 1);
|
||||||
setSelectedWorktreeForAction(null);
|
setSelectedWorktreeForAction(null);
|
||||||
}}
|
}}
|
||||||
|
|||||||
Reference in New Issue
Block a user