mirror of
https://github.com/Unleash/unleash.git
synced 2025-11-10 01:19:53 +01:00
cleanup
This commit is contained in:
parent
a32a4590d0
commit
29af549799
@ -22,7 +22,6 @@ import {
|
|||||||
StyledBox,
|
StyledBox,
|
||||||
StyledH2Title,
|
StyledH2Title,
|
||||||
StyledEditIcon,
|
StyledEditIcon,
|
||||||
StyledDeleteIcon,
|
|
||||||
StyledProjectIcon,
|
StyledProjectIcon,
|
||||||
StyledDivInfo,
|
StyledDivInfo,
|
||||||
StyledDivInfoContainer,
|
StyledDivInfoContainer,
|
||||||
@ -49,7 +48,7 @@ export const ProjectCard = ({
|
|||||||
isFavorite = false,
|
isFavorite = false,
|
||||||
}: IProjectCardProps) => {
|
}: IProjectCardProps) => {
|
||||||
const { hasAccess } = useContext(AccessContext);
|
const { hasAccess } = useContext(AccessContext);
|
||||||
const { isOss, uiConfig } = useUiConfig();
|
const { isOss } = useUiConfig();
|
||||||
const [anchorEl, setAnchorEl] = useState<Element | null>(null);
|
const [anchorEl, setAnchorEl] = useState<Element | null>(null);
|
||||||
const [showDelDialog, setShowDelDialog] = useState(false);
|
const [showDelDialog, setShowDelDialog] = useState(false);
|
||||||
const navigate = useNavigate();
|
const navigate = useNavigate();
|
||||||
@ -61,9 +60,6 @@ export const ProjectCard = ({
|
|||||||
setAnchorEl(event.currentTarget);
|
setAnchorEl(event.currentTarget);
|
||||||
};
|
};
|
||||||
|
|
||||||
const canDeleteProject =
|
|
||||||
hasAccess(DELETE_PROJECT, id) && id !== DEFAULT_PROJECT_ID;
|
|
||||||
|
|
||||||
const onFavorite = async (e: React.SyntheticEvent) => {
|
const onFavorite = async (e: React.SyntheticEvent) => {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
if (isFavorite) {
|
if (isFavorite) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user