mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
fix: bug fixes (#1394)
* fix: multi level dropdown fix * style: spreadsheet view add issue button * fix: spreadsheet view sub-issue label mutation
This commit is contained in:
parent
06ce89a03a
commit
1a48fdd142
@ -127,7 +127,11 @@ export const SingleSpreadsheetIssue: React.FC<Props> = ({
|
|||||||
user
|
user
|
||||||
)
|
)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
mutate(fetchKey);
|
if (issue.parent) {
|
||||||
|
mutate(SUB_ISSUES(issue.parent as string));
|
||||||
|
} else {
|
||||||
|
mutate(fetchKey);
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch((error) => {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
|
@ -75,16 +75,21 @@ export const SpreadsheetView: React.FC<Props> = ({
|
|||||||
userAuth={userAuth}
|
userAuth={userAuth}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
<button
|
<div
|
||||||
className="flex items-center gap-1.5 pl-7 py-2.5 text-sm text-brand-secondary hover:text-brand-base hover:bg-brand-surface-2 border-b border-brand-base w-full min-w-max"
|
className="relative group grid auto-rows-[minmax(44px,1fr)] hover:rounded-sm hover:bg-brand-surface-2 border-b border-brand-base w-full min-w-max"
|
||||||
onClick={() => {
|
style={{ gridTemplateColumns }}
|
||||||
const e = new KeyboardEvent("keydown", { key: "c" });
|
|
||||||
document.dispatchEvent(e);
|
|
||||||
}}
|
|
||||||
>
|
>
|
||||||
<PlusIcon className="h-4 w-4" />
|
<button
|
||||||
Add Issue
|
className="flex gap-1.5 items-center pl-7 py-2.5 text-sm sticky left-0 z-[1] text-brand-secondary bg-brand-base group-hover:text-brand-base group-hover:bg-brand-surface-2 border-brand-base w-full"
|
||||||
</button>
|
onClick={() => {
|
||||||
|
const e = new KeyboardEvent("keydown", { key: "c" });
|
||||||
|
document.dispatchEvent(e);
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<PlusIcon className="h-4 w-4" />
|
||||||
|
Add Issue
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
) : (
|
) : (
|
||||||
<Spinner />
|
<Spinner />
|
||||||
|
@ -3,7 +3,7 @@ import { Fragment, useState } from "react";
|
|||||||
// headless ui
|
// headless ui
|
||||||
import { Menu, Transition } from "@headlessui/react";
|
import { Menu, Transition } from "@headlessui/react";
|
||||||
// icons
|
// icons
|
||||||
import { ChevronDownIcon } from "@heroicons/react/24/outline";
|
import { CheckIcon, ChevronDownIcon } from "@heroicons/react/24/outline";
|
||||||
import { ChevronRightIcon, ChevronLeftIcon } from "@heroicons/react/20/solid";
|
import { ChevronRightIcon, ChevronLeftIcon } from "@heroicons/react/20/solid";
|
||||||
|
|
||||||
type MultiLevelDropdownProps = {
|
type MultiLevelDropdownProps = {
|
||||||
@ -127,9 +127,14 @@ export const MultiLevelDropdown: React.FC<MultiLevelDropdownProps> = ({
|
|||||||
}}
|
}}
|
||||||
className={`${
|
className={`${
|
||||||
child.selected ? "bg-brand-surface-2" : ""
|
child.selected ? "bg-brand-surface-2" : ""
|
||||||
} flex w-full items-center whitespace-nowrap break-words rounded px-1 py-1.5 text-left capitalize text-brand-secondary hover:bg-brand-surface-2`}
|
} flex w-full items-center justify-between whitespace-nowrap break-words rounded px-1 py-1.5 text-left capitalize text-brand-secondary hover:bg-brand-surface-2`}
|
||||||
>
|
>
|
||||||
{child.label}
|
{child.label}
|
||||||
|
<CheckIcon
|
||||||
|
className={`h-3.5 w-3.5 opacity-0 ${
|
||||||
|
child.selected ? "opacity-100" : ""
|
||||||
|
}`}
|
||||||
|
/>
|
||||||
</button>
|
</button>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user