2023-07-20 09:44:57 +00:00
|
|
|
// icons
|
2023-10-16 14:57:22 +00:00
|
|
|
import { ContrastIcon, DiceIcon, LayersIcon, PhotoFilterIcon } from "@plane/ui";
|
|
|
|
import { FileText } from "lucide-react";
|
2023-07-12 14:25:08 +00:00
|
|
|
// types
|
|
|
|
import { TTourSteps } from "./root";
|
|
|
|
|
|
|
|
const sidebarOptions: {
|
|
|
|
key: TTourSteps;
|
2023-07-20 09:44:57 +00:00
|
|
|
Icon: any;
|
2023-07-12 14:25:08 +00:00
|
|
|
}[] = [
|
|
|
|
{
|
|
|
|
key: "issues",
|
2023-10-16 14:57:22 +00:00
|
|
|
Icon: LayersIcon,
|
2023-07-12 14:25:08 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
key: "cycles",
|
2023-10-16 14:57:22 +00:00
|
|
|
Icon: ContrastIcon,
|
2023-07-12 14:25:08 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
key: "modules",
|
2023-10-16 14:57:22 +00:00
|
|
|
Icon: DiceIcon,
|
2023-07-12 14:25:08 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
key: "views",
|
2023-10-16 14:57:22 +00:00
|
|
|
Icon: PhotoFilterIcon,
|
2023-07-12 14:25:08 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
key: "pages",
|
2023-10-16 14:57:22 +00:00
|
|
|
Icon: FileText,
|
2023-07-12 14:25:08 +00:00
|
|
|
},
|
|
|
|
];
|
|
|
|
|
|
|
|
type Props = {
|
|
|
|
step: TTourSteps;
|
|
|
|
setStep: React.Dispatch<React.SetStateAction<TTourSteps>>;
|
|
|
|
};
|
|
|
|
|
|
|
|
export const TourSidebar: React.FC<Props> = ({ step, setStep }) => (
|
2023-12-10 10:18:10 +00:00
|
|
|
<div className="col-span-3 hidden bg-custom-background-90 p-8 lg:block">
|
|
|
|
<h3 className="text-lg font-medium">
|
2023-07-12 14:25:08 +00:00
|
|
|
Let{"'"}s get started!
|
|
|
|
<br />
|
|
|
|
Get more out of Plane.
|
|
|
|
</h3>
|
|
|
|
<div className="mt-8 space-y-5">
|
|
|
|
{sidebarOptions.map((option) => (
|
|
|
|
<h5
|
|
|
|
key={option.key}
|
2023-12-10 10:18:10 +00:00
|
|
|
className={`flex cursor-pointer items-center gap-2 border-l-[3px] py-0.5 pl-3 pr-2 text-sm font-medium capitalize ${
|
2023-07-12 14:25:08 +00:00
|
|
|
step === option.key
|
2023-12-10 10:18:10 +00:00
|
|
|
? "border-custom-primary-100 text-custom-primary-100"
|
|
|
|
: "border-transparent text-custom-text-200"
|
2023-07-12 14:25:08 +00:00
|
|
|
}`}
|
|
|
|
onClick={() => setStep(option.key)}
|
2023-11-23 09:39:46 +00:00
|
|
|
role="button"
|
2023-07-12 14:25:08 +00:00
|
|
|
>
|
2023-10-16 14:57:22 +00:00
|
|
|
<option.Icon className="h-4 w-4" aria-hidden="true" />
|
2023-07-12 14:25:08 +00:00
|
|
|
{option.key}
|
|
|
|
</h5>
|
|
|
|
))}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
);
|