forked from github/plane
chore: clear custom attributes on modal close
This commit is contained in:
parent
121d4cb4eb
commit
3b682c2124
@ -118,6 +118,8 @@ export const CreateUpdateIssueModal: React.FC<IssuesModalProps> = observer(
|
|||||||
};
|
};
|
||||||
|
|
||||||
const onClose = () => {
|
const onClose = () => {
|
||||||
|
setCustomAttributesList({});
|
||||||
|
|
||||||
if (!showConfirmDiscard) handleClose();
|
if (!showConfirmDiscard) handleClose();
|
||||||
if (formDirtyState === null) return setActiveProject(null);
|
if (formDirtyState === null) return setActiveProject(null);
|
||||||
const data = JSON.stringify(formDirtyState);
|
const data = JSON.stringify(formDirtyState);
|
||||||
@ -125,6 +127,8 @@ export const CreateUpdateIssueModal: React.FC<IssuesModalProps> = observer(
|
|||||||
};
|
};
|
||||||
|
|
||||||
const onDiscardClose = () => {
|
const onDiscardClose = () => {
|
||||||
|
setCustomAttributesList({});
|
||||||
|
|
||||||
if (formDirtyState !== null) {
|
if (formDirtyState !== null) {
|
||||||
setShowConfirmDiscard(true);
|
setShowConfirmDiscard(true);
|
||||||
} else {
|
} else {
|
||||||
|
@ -21,9 +21,7 @@ export interface SidebarProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const Sidebar: React.FC<SidebarProps> = observer(({ toggleSidebar, setToggleSidebar }) => {
|
const Sidebar: React.FC<SidebarProps> = observer(({ toggleSidebar, setToggleSidebar }) => {
|
||||||
const store: any = useMobxStore();
|
const store = useMobxStore();
|
||||||
// theme
|
|
||||||
const { collapsed: sidebarCollapse } = useTheme();
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
|
Loading…
Reference in New Issue
Block a user