This commit is contained in:
chip committed 2020-08-23 00:23:34 +02:00
commit 3bfe50ae7d
7 files changed
+34 -20

No files matched your search

+1
View File
@@ -12,6 +12,7 @@
"lodash": "^4.17.20",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-hotkeys": "^2.0.0",
"react-i18next": "^11.7.1",
"react-router-dom": "^5.2.0",
"react-scripts": "3.4.3",
+3 -3
View File
@@ -5,7 +5,7 @@ import { Route } from "react-router-dom";
import { useSettings } from "./apps/settings/hooks/useSettings";
import { NotificationBar } from "./os/components/NotificationBar";
import { NotificationIcon } from "./os/components/NotificationIcon";
import { NavigationBar } from "./os/components/NavigationBar";
import { Navigation } from "./os/components/Navigation";
import MessageIcon from "@material-ui/icons/Email";
import { HomeApp } from "./apps/home/components/Home";
@@ -34,14 +34,14 @@ function Phone() {
}}
>
<NotificationBar
notifications={[<NotificationIcon Icon={MessageIcon} />]}
notifications={[{ icon: <NotificationIcon Icon={MessageIcon} /> }, { icon: <NotificationIcon Icon={MessageIcon} /> }]}
/>
<div className="PhoneAppContainer">
<Route exact path="/" component={HomeApp} />
<Route exact path="/contacts" component={ContactsApp} />
<Route exact path="/settings" component={SettingsApp} />
</div>
<NavigationBar />
<Navigation />
</div>
</div>
</div>
+7 -4
View File
@@ -1,6 +1,6 @@
import React from "react";
import { AppWrapper } from "../../../ui/components";
import { List, ListItem, ListItemText } from "@material-ui/core";
import { List, ListItem, ListItemText, Divider } from "@material-ui/core";
import { AppTitle } from "../../../ui/components/AppTitle";
import { AppContent } from "../../../ui/components/AppContent";
import { useTranslation } from "react-i18next";
@@ -14,9 +14,12 @@ import { useApps } from "../../appmarket/hooks/useApps";
export const SettingItem = ({ options, label, value, onClick }) => {
return (
<ListItem onClick={() => onClick(options)} button>
<ListItemText primary={label} secondary={value} />
</ListItem>
<>
<ListItem onClick={() => onClick(options)} button>
<ListItemText primary={label} secondary={value} />
</ListItem>
<Divider />
</>
);
};
@@ -15,7 +15,7 @@ const useStyles = makeStyles((theme) => ({
},
}));
export const NavigationBar = ({ notifications = [] }) => {
export const Navigation = () => {
const classes = useStyles();
const history = useHistory();
+13 -10
View File
@@ -1,16 +1,15 @@
import React from "react";
import { makeStyles, Typography, Grid } from "@material-ui/core";
import { grey } from "@material-ui/core/colors";
import { makeStyles, Typography, Grid, IconButton } from "@material-ui/core";
import { fade } from "@material-ui/core/styles/colorManipulator";
import SignalIcon from "@material-ui/icons/SignalCellular3Bar";
const useStyles = makeStyles(() => ({
const useStyles = makeStyles((theme) => ({
root: {
backgroundColor: fade(grey[800], 0.7),
backgroundColor: fade(theme.palette.background.paper, 0.7),
height: "25px",
width: "100%",
color: "white",
zIndex: 2
color: theme.palette.text.primary,
zIndex: 2,
},
item: {
margin: "0 6px",
@@ -18,6 +17,11 @@ const useStyles = makeStyles(() => ({
text: {
position: "relative",
bottom: "2px",
color: theme.palette.text.primary,
},
icon: {
padding: '4px',
color: theme.palette.text.primary,
},
}));
@@ -31,9 +35,9 @@ export const NotificationBar = ({ notifications = [] }) => {
wrap="nowrap"
>
<Grid container item wrap="nowrap">
{notifications.map((n) => (
<Grid item className={classes.item}>
{n}
{notifications.map((notification) => (
<Grid item component={IconButton} className={classes.icon}>
{notification.icon}
</Grid>
))}
</Grid>
@@ -45,7 +49,6 @@ export const NotificationBar = ({ notifications = [] }) => {
<Typography
className={classes.text}
variant="button"
color="white"
>{`AT&T`}</Typography>
</Grid>
</Grid>
+1 -1
View File
@@ -27,8 +27,8 @@ export const ContextMenu = ({ open, onClose, options }) => {
{options.map((option) => (
<ListItem
selected={option.selected}
button
key={option.key || option.label}
button
onClick={(e) => {
option.onClick(e, option);
onClose();
+8 -1
View File
@@ -8676,7 +8676,7 @@ prompts@^2.0.1:
kleur "^3.0.3"
sisteransi "^1.0.4"
prop-types@^15.6.2, prop-types@^15.7.2:
prop-types@^15.6.1, prop-types@^15.6.2, prop-types@^15.7.2:
version "15.7.2"
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5"
integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==
@@ -8887,6 +8887,13 @@ react-error-overlay@^6.0.7:
resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-6.0.7.tgz#1dcfb459ab671d53f660a991513cb2f0a0553108"
integrity sha512-TAv1KJFh3RhqxNvhzxj6LeT5NWklP6rDr2a0jaTfsZ5wSZWHOGeqQyejUp3xxLfPt2UpyJEcVQB/zyPcmonNFA==
react-hotkeys@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/react-hotkeys/-/react-hotkeys-2.0.0.tgz#a7719c7340cbba888b0e9184f806a9ec0ac2c53f"
integrity sha512-3n3OU8vLX/pfcJrR3xJ1zlww6KS1kEJt0Whxc4FiGV+MJrQ1mYSYI3qS/11d2MJDFm8IhOXMTFQirfu6AVOF6Q==
dependencies:
prop-types "^15.6.1"
react-i18next@^11.7.1:
version "11.7.1"
resolved "https://registry.yarnpkg.com/react-i18next/-/react-i18next-11.7.1.tgz#80c993bf7c4f07937ce0e5ff4e2d7d97bfe3f42f"