[WEB-2568] chore: minor improvements related to issue identifier and issue modal. (#5723)

* [WEB-2568] chore: minor improvements related to issue identifier and issue modal.

* fix: error handling for session recorder script.

* chore: minor improvement
This commit is contained in:
Prateek Shourya 2024-09-30 14:07:22 +05:30 committed by GitHub
parent b1dccf3773
commit c25fa594fe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 49 additions and 23 deletions

View file

@ -1,2 +1,3 @@
export * from "./issue-identifier";
export * from "./issue-properties-activity";
export * from "./issue-type-switcher";

View file

@ -0,0 +1,24 @@
import { observer } from "mobx-react";
// store hooks
import { useIssueDetail } from "@/hooks/store";
// plane web components
import { IssueIdentifier } from "@/plane-web/components/issues";
export type TIssueTypeSwitcherProps = {
issueId: string;
disabled: boolean;
};
export const IssueTypeSwitcher: React.FC<TIssueTypeSwitcherProps> = observer((props) => {
const { issueId } = props;
// store hooks
const {
issue: { getIssueById },
} = useIssueDetail();
// derived values
const issue = getIssueById(issueId);
if (!issue || !issue.project_id) return <></>;
return <IssueIdentifier issueId={issueId} projectId={issue.project_id} size="md" />;
});