fix : create issue modal (#875)

* fix: label list bug fix

* fix: assignee and label count removed

* fix: assignee and label fix
This commit is contained in:
Anmol Singh Bhatia 2023-04-19 15:41:17 +05:30 committed by GitHub
parent ac125965eb
commit fb1932e309
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 5 deletions

View File

@ -57,8 +57,7 @@ export const IssueAssigneeSelect: React.FC<Props> = ({ projectId, value = [], on
<div className="flex items-center gap-2 text-gray-500">
{value && value.length > 0 && Array.isArray(value) ? (
<div className="flex items-center justify-center gap-2">
<AssigneesList userIds={value} length={3} showLength={false} />
<span className="text-gray-500">{value.length} Assignees</span>
<AssigneesList userIds={value} length={3} showLength={true} />
</div>
) : (
<div className="flex items-center justify-center gap-2">

View File

@ -73,9 +73,8 @@ export const IssueLabelSelect: React.FC<Props> = ({ setIsOpen, value, onChange,
<IssueLabelsList
labels={value.map((v) => issueLabels?.find((l) => l.id === v)?.color) ?? []}
length={3}
showLength
showLength={true}
/>
<span className=" text-gray-600">{value.length} Labels</span>
</span>
) : (
<span className="flex items-center justify-center gap-2 px-3 py-1.5 text-xs">

View File

@ -14,7 +14,7 @@ export const IssueLabelsList: React.FC<IssueLabelsListProps> = ({
<>
{labels && (
<>
{labels.map((color, index) => (
{labels.slice(0, length).map((color, index) => (
<div className={`flex h-4 w-4 rounded-full ${index ? "-ml-3.5" : ""}`}>
<span
className={`h-4 w-4 flex-shrink-0 rounded-full border border-white