Skip to content

Commit 2f2f8dc

Browse files
[WEB-2880] chore: project detail response updated (#6281)
* chore: project detail response updated * chore: code refactor
1 parent 756a71c commit 2f2f8dc

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

packages/types/src/project/projects.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ export interface IProject {
1515
archived_at: string | null;
1616
archived_issues: number;
1717
archived_sub_issues: number;
18+
completed_issues: number;
1819
close_in: number;
1920
created_at: Date;
2021
created_by: string;

web/core/components/dropdowns/project.tsx

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { ReactNode, useRef, useState } from "react";
22
import { observer } from "mobx-react";
33
import { usePopper } from "react-popper";
4-
import { Check, ChevronDown, Search } from "lucide-react";
4+
import { Briefcase, Check, ChevronDown, Search } from "lucide-react";
55
import { Combobox } from "@headlessui/react";
66
// ui
77
import { ComboDropDown } from "@plane/ui";
@@ -143,10 +143,14 @@ export const ProjectDropdown: React.FC<Props> = observer((props) => {
143143
if (Array.isArray(value)) {
144144
return (
145145
<div className="flex items-center gap-0.5">
146-
{value.map((projectId) => {
147-
const projectDetails = getProjectById(projectId);
148-
return projectDetails ? renderIcon(projectDetails) : null;
149-
})}
146+
{value.length > 0 ? (
147+
value.map((projectId) => {
148+
const projectDetails = getProjectById(projectId);
149+
return projectDetails ? renderIcon(projectDetails) : null;
150+
})
151+
) : (
152+
<Briefcase className="size-3 text-custom-text-300" />
153+
)}
150154
</div>
151155
);
152156
} else {

0 commit comments

Comments
 (0)