Some checks failed
CodeQL / Analyze (javascript) (push) Failing after 16s
CodeQL / Analyze (python) (push) Failing after 3s
i18n sync check / check:sync (push) Failing after 3s
React Doctor / react-doctor (push) Failing after 16s
Branch Build CE / Build-Push Admin Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Admin Manifest (push) Has been cancelled
Branch Build CE / Build-Push Web Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Web Manifest (push) Has been cancelled
Branch Build CE / Build-Push Space Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Proxy Manifest (push) Has been cancelled
Branch Build CE / Merge Space Manifest (push) Has been cancelled
Branch Build CE / Prepare AIO Assets (push) Has been cancelled
Branch Build CE / Build Setup (push) Has been cancelled
Branch Build CE / Build-Push Live Collaboration Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge Live Collaboration Manifest (push) Has been cancelled
Branch Build CE / Build-Push API Server Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge API Server Manifest (push) Has been cancelled
Branch Build CE / Build-Push Proxy Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Build-Push AIO Docker Image (${{ matrix.arch }}) (push) Has been cancelled
Branch Build CE / Merge AIO Manifest (push) Has been cancelled
Branch Build CE / Upload Build Assets (push) Has been cancelled
Branch Build CE / Build Release (push) Has been cancelled
66 lines
2.2 KiB
TypeScript
66 lines
2.2 KiB
TypeScript
/**
|
|
* Copyright (c) 2023-present Plane Software, Inc. and contributors
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
* See the LICENSE file for details.
|
|
*/
|
|
|
|
import { observer } from "mobx-react";
|
|
import Link from "next/link";
|
|
import { useTranslation } from "@plane/i18n";
|
|
// ui
|
|
import { Button, getButtonStyling } from "@plane/propel/button";
|
|
import { Logo } from "@plane/propel/emoji-icon-picker";
|
|
import { Row } from "@plane/ui";
|
|
// components
|
|
// hooks
|
|
import { useProject } from "@/hooks/store/use-project";
|
|
// plane web imports
|
|
import { ProjectFeaturesList } from "@/components/project/settings/features-list";
|
|
|
|
type Props = {
|
|
workspaceSlug: string;
|
|
projectId: string | null;
|
|
onClose: () => void;
|
|
};
|
|
|
|
export const ProjectFeatureUpdate = observer(function ProjectFeatureUpdate(props: Props) {
|
|
const { workspaceSlug, projectId, onClose } = props;
|
|
// store hooks
|
|
const { t } = useTranslation();
|
|
const { getProjectById } = useProject();
|
|
|
|
if (!workspaceSlug || !projectId) return null;
|
|
const currentProjectDetails = getProjectById(projectId);
|
|
if (!currentProjectDetails) return null;
|
|
|
|
return (
|
|
<>
|
|
<Row className="py-6">
|
|
<ProjectFeaturesList workspaceSlug={workspaceSlug} projectId={projectId} isAdmin />
|
|
</Row>
|
|
<div className="mt-4 flex items-center justify-between gap-2 border-t border-subtle px-6 py-4">
|
|
<div className="flex gap-1 text-13 font-medium text-tertiary">
|
|
{t("congrats")}
|
|
<Logo logo={currentProjectDetails.logo_props} /> <p className="break-all">{currentProjectDetails.name}</p>{" "}
|
|
{t("created").toLowerCase()}.
|
|
</div>
|
|
<div className="flex gap-2">
|
|
{/* eslint-disable-next-line jsx-a11y/tabindex-no-positive */}
|
|
<Button variant="secondary" size="lg" onClick={onClose} tabIndex={1}>
|
|
{t("close")}
|
|
</Button>
|
|
<Link
|
|
href={`/${workspaceSlug}/projects/${projectId}/issues`}
|
|
onClick={onClose}
|
|
className={getButtonStyling("primary", "lg")}
|
|
// oxlint-disable-next-line jsx-a11y/tabindex-no-positive
|
|
tabIndex={2}
|
|
>
|
|
{t("open_project")}
|
|
</Link>
|
|
</div>
|
|
</div>
|
|
</>
|
|
);
|
|
});
|