|
1 | 1 | import type { JSX } from "react";
|
2 | 2 |
|
3 |
| -import { Flex, Divider } from "@lib-components"; |
| 3 | +import { |
| 4 | + LightbulbFilled, |
| 5 | + SearchFilled, |
| 6 | + HandshakeFilled, |
| 7 | +} from "@fluentui/react-icons"; |
| 8 | + |
| 9 | +import { Flex, Divider, TabList, Tab, Tooltip } from "@lib-components"; |
4 | 10 | import { Logo } from "@lib-theme";
|
5 | 11 |
|
6 | 12 | import useSidebarClasses from "@app-ui/layout/partials/Sidebar/styles";
|
7 | 13 |
|
8 | 14 | type TProps = {
|
| 15 | + defaultTab: "overview" | "browse" | "contribute"; |
9 | 16 | isExpanded: boolean;
|
10 | 17 | toggleExpandAction: (isExpanded: boolean) => void;
|
| 18 | + overviewTabAction: () => void; |
| 19 | + browseTabAction: () => void; |
11 | 20 | };
|
12 | 21 |
|
13 | 22 | export default function Sidebar({
|
| 23 | + defaultTab, |
14 | 24 | isExpanded,
|
15 | 25 | toggleExpandAction,
|
| 26 | + overviewTabAction, |
| 27 | + browseTabAction, |
16 | 28 | }: TProps): JSX.Element {
|
17 | 29 | const classes = useSidebarClasses();
|
18 | 30 | return (
|
19 | 31 | <Flex
|
20 | 32 | className={classes.root}
|
21 | 33 | direction="column"
|
22 | 34 | justifyContent="start"
|
| 35 | + alignItems="center" |
23 | 36 | padding={["SNudge"]}
|
| 37 | + gap="S" |
24 | 38 | >
|
25 | 39 | <Logo size="extraLarge" />
|
26 | 40 | <Divider appearance="subtle" />
|
27 |
| - <Flex shHeight="100%" shWidth="100%"> |
28 |
| - Content |
| 41 | + <Flex |
| 42 | + shHeight="100%" |
| 43 | + shWidth="100%" |
| 44 | + // justifyContent="center" |
| 45 | + margin={["None", "XS", "None", "M"]} |
| 46 | + > |
| 47 | + <TabList vertical defaultSelectedValue={defaultTab}> |
| 48 | + <Tab icon={<LightbulbFilled />} value="overview"> |
| 49 | + Overview |
| 50 | + </Tab> |
| 51 | + <Tab icon={<SearchFilled />} value="browse"> |
| 52 | + Browse |
| 53 | + </Tab> |
| 54 | + <Tooltip |
| 55 | + content="Will be available in 2.0" |
| 56 | + relationship="label" |
| 57 | + appearance="inverted" |
| 58 | + withArrow |
| 59 | + positioning="below-end" |
| 60 | + > |
| 61 | + <Tab icon={<HandshakeFilled />} value="contribute" disabled> |
| 62 | + Contribute |
| 63 | + </Tab> |
| 64 | + </Tooltip> |
| 65 | + </TabList> |
29 | 66 | </Flex>
|
30 | 67 | </Flex>
|
31 | 68 | );
|
|
0 commit comments