@@ -60,6 +60,7 @@ type Props = {
|
||||
settingsAutoCreateWorktree: boolean;
|
||||
getOrderedGroups: (projectId: string, groups: SessionGroup[]) => SessionGroup[];
|
||||
setGroupOrderByProject: React.Dispatch<React.SetStateAction<Map<string, string[]>>>;
|
||||
isInlineEditing: boolean;
|
||||
};
|
||||
|
||||
export function SidebarProjectsList(props: Props): React.ReactNode {
|
||||
@@ -198,7 +199,7 @@ export function SidebarProjectsList(props: Props): React.ReactNode {
|
||||
{orderedGroups.map((group) => {
|
||||
const groupKey = `${projectKey}:${group.id}`;
|
||||
return (
|
||||
<SortableGroupItem key={group.id} id={group.id}>
|
||||
<SortableGroupItem key={group.id} id={group.id} disabled={props.isInlineEditing}>
|
||||
{props.renderGroupSessions(group, groupKey, projectKey)}
|
||||
</SortableGroupItem>
|
||||
);
|
||||
|
||||
@@ -303,8 +303,9 @@ export const SortableProjectItem: React.FC<SortableProjectItemProps> = ({
|
||||
|
||||
const SortableGroupItemBase: React.FC<{
|
||||
id: string;
|
||||
disabled?: boolean;
|
||||
children: React.ReactNode;
|
||||
}> = ({ id, children }) => {
|
||||
}> = ({ id, disabled = false, children }) => {
|
||||
const {
|
||||
attributes,
|
||||
listeners,
|
||||
@@ -312,7 +313,7 @@ const SortableGroupItemBase: React.FC<{
|
||||
transform,
|
||||
transition,
|
||||
isDragging,
|
||||
} = useSortable({ id });
|
||||
} = useSortable({ id, disabled });
|
||||
|
||||
return (
|
||||
<div
|
||||
|
||||
Reference in New Issue
Block a user