[WEB-4208]chore: refactored work item quick actions (#7136)

* chore: refactored work item quick actions

* chore: update event handling for menu

* chore: reverted unwanted changes

* fix: update archive copy link

* chore: handled undefined function implementation
This commit is contained in:
Vamsi Krishna 2025-06-06 13:21:00 +05:30 committed by GitHub
parent 14d2d69120
commit 6be3f0ea73
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
21 changed files with 1602 additions and 517 deletions

View file

@ -0,0 +1,22 @@
import { Copy } from "lucide-react";
import { TContextMenuItem } from "@plane/ui";
export interface CopyMenuHelperProps {
baseItem: {
key: string;
title: string;
icon: typeof Copy;
action: () => void;
shouldRender: boolean;
};
activeLayout: string;
setTrackElement: (element: string) => void;
setCreateUpdateIssueModal: (open: boolean) => void;
setDuplicateWorkItemModal?: (open: boolean) => void;
}
export const createCopyMenuWithDuplication = (props: CopyMenuHelperProps): TContextMenuItem => {
const { baseItem } = props;
return baseItem;
};

View file

@ -0,0 +1,11 @@
import { FC } from "react";
type TDuplicateWorkItemModalProps = {
workItemId: string;
onClose: () => void;
isOpen: boolean;
workspaceSlug: string;
projectId: string;
};
export const DuplicateWorkItemModal: FC<TDuplicateWorkItemModalProps> = () => <></>;

View file

@ -0,0 +1,2 @@
export * from "./duplicate-modal";
export * from "./copy-menu-helper";

View file

@ -0,0 +1,18 @@
import { makeObservable } from "mobx";
import { TIssueServiceType } from "@plane/types";
import {
IssueDetail as IssueDetailCore,
IIssueDetail as IIssueDetailCore,
} from "@/store/issue/issue-details/root.store";
import { IIssueRootStore } from "@/store/issue/root.store";
export type IIssueDetail = IIssueDetailCore;
export class IssueDetail extends IssueDetailCore {
constructor(rootStore: IIssueRootStore, serviceType: TIssueServiceType) {
super(rootStore, serviceType);
makeObservable(this, {
// observables
});
}
}