1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 import * as React from "react";
6 import { MenuItem, Typography, ListSubheader } from "@material-ui/core";
7 import { DropdownMenu } from "~/components/dropdown-menu/dropdown-menu";
8 import { ImportContactsIcon, HelpIcon } from "~/components/icon/icon";
9 import { ArvadosTheme } from '~/common/custom-theme';
10 import { StyleRulesCallback, WithStyles, withStyles } from '@material-ui/core/styles';
12 type CssRules = 'link' | 'icon' | 'title' | 'linkTitle';
14 const styles: StyleRulesCallback<CssRules> = (theme: ArvadosTheme) => ({
16 textDecoration: 'none',
26 paddingBottom: theme.spacing.unit * 0.5,
27 paddingLeft: theme.spacing.unit * 2,
28 paddingTop: theme.spacing.unit * 0.5,
32 marginLeft: theme.spacing.unit
38 title: "Public Pipelines and Data sets",
39 link: "https://dev.arvados.org/projects/arvados/wiki/Public_Pipelines_and_Datasets",
42 title: "Tutorials and User guide",
43 link: "http://doc.arvados.org/user/",
46 title: "API Reference",
47 link: "http://doc.arvados.org/api/",
50 title: "SDK Reference",
51 link: "http://doc.arvados.org/sdk/"
55 export const HelpMenu = withStyles(styles)(
56 ({ classes }: WithStyles<CssRules>) =>
61 <MenuItem disabled>Help</MenuItem>
64 <MenuItem key={link.title}>
65 <a href={link.link} target="_blank" className={classes.link}>
66 <ImportContactsIcon className={classes.icon} />
67 <Typography variant="body1" className={classes.linkTitle}>{link.title}</Typography>