mirror of
https://github.com/darksaid98/new-phone-who-dis.git
synced 2026-12-04 06:28:51 +00:00
Context Menu!!!
This commit is contained in:
1 parent
b40d00a260
commit
ee560e1984
9 files changed
+115
-10
No files matched your search
@@ -1,10 +1,12 @@
|
||||
import React from "react";
|
||||
import { AppWrapper } from "../../../ui/components";
|
||||
import { makeStyles } from "@material-ui/core";
|
||||
import { makeStyles, List, ListItem } from "@material-ui/core";
|
||||
import { AppTitle } from "../../../ui/components/AppTitle";
|
||||
import { AppContent } from "../../../ui/components/AppContent";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { grey } from "@material-ui/core/colors";
|
||||
import { useContextMenu } from "../../../ui/hooks/useContextMenu";
|
||||
import { useConfig } from "../../../config/hooks/useConfig";
|
||||
|
||||
const useStyles = makeStyles(() => ({
|
||||
root: {
|
||||
@@ -18,10 +20,19 @@ const useStyles = makeStyles(() => ({
|
||||
export const SettingsApp = () => {
|
||||
const classes = useStyles();
|
||||
const { t } = useTranslation();
|
||||
const [config] = useConfig();
|
||||
const [openMenu, closeMenu, ContextMenu, isMenuOpen] = useContextMenu(config.wallpapers.map(w => ({ label: w })));
|
||||
return (
|
||||
<AppWrapper className={classes.root}>
|
||||
<AppTitle className={classes.title}>{t("APPS_SETTINGS")}</AppTitle>
|
||||
<AppContent>{t("COMING_SOON")}</AppContent>
|
||||
<AppContent backdrop={isMenuOpen} onClickBackdrop={closeMenu}>
|
||||
<List>
|
||||
<ListItem onClick={openMenu} button>
|
||||
{t("APPS_SETTINGS_OPTIONS_WALLPAPER")}
|
||||
</ListItem>
|
||||
</List>
|
||||
</AppContent>
|
||||
<ContextMenu handleClickAway={closeMenu} />
|
||||
</AppWrapper>
|
||||
);
|
||||
};
|
||||
Reference in new issue
Block a user