Compare commits
2 Commits
84ef980c42
...
4d5bb6cb4b
Author | SHA1 | Date | |
---|---|---|---|
![]() |
4d5bb6cb4b | ||
![]() |
260668d759 |
14
Dockerfile
@ -40,8 +40,18 @@ RUN apt-get -q update \
|
||||
tree \
|
||||
inotify-tools \
|
||||
gettext-base \
|
||||
gh \
|
||||
git \
|
||||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/{apt,dpkg,cache,log}
|
||||
|
||||
# Build dependencies when running npm install
|
||||
RUN apt-get -q update \
|
||||
&& DEBIAN_FRONTEND=noninteractive apt-get install \
|
||||
--no-install-recommends -y \
|
||||
make \
|
||||
python-is-python3 \
|
||||
gcc \
|
||||
g++ \
|
||||
libc-dev \
|
||||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/{apt,dpkg,cache,log}
|
||||
|
||||
|
3601
client/package-lock.json
generated
@ -5,8 +5,8 @@
|
||||
"dependencies": {
|
||||
"@emotion/react": "^11.10.6",
|
||||
"@emotion/styled": "^11.10.6",
|
||||
"@mui/icons-material": "^5.10.16",
|
||||
"@mui/material": "^5.11.10",
|
||||
"@mui/icons-material": "^5.11.11",
|
||||
"@mui/material": "^5.11.15",
|
||||
"@types/jest": "^29.2.3",
|
||||
"@types/node": "^18.11.10",
|
||||
"@types/react": "^18.0.26",
|
||||
|
12
client/src/GlobalContext.js
Normal file
@ -0,0 +1,12 @@
|
||||
import { createContext } from "react";
|
||||
|
||||
const global = {
|
||||
chatId: undefined,
|
||||
ws: undefined,
|
||||
name: "",
|
||||
chat: []
|
||||
};
|
||||
|
||||
const GlobalContext = createContext(global);
|
||||
|
||||
export { GlobalContext, global };
|
@ -1,6 +1,6 @@
|
||||
|
||||
import React from "react";
|
||||
import Avatar from '@material-ui/core/Avatar';
|
||||
import Avatar from '@mui/material/Avatar'
|
||||
|
||||
import { useStyles } from './Styles.js';
|
||||
|
||||
@ -14,4 +14,4 @@ const PlayerColor = ({ color }) => {
|
||||
);
|
||||
};
|
||||
|
||||
export { PlayerColor };
|
||||
export { PlayerColor };
|
||||
|
@ -1,6 +1,5 @@
|
||||
import React, { useState, useEffect, useContext, useRef } from "react";
|
||||
import Paper from '@material-ui/core/Paper';
|
||||
import List from '@material-ui/core/List';
|
||||
import { Paper, List } from '@mui/material';
|
||||
|
||||
import "./PlayerList.css";
|
||||
import { PlayerColor } from './PlayerColor.js';
|
||||
@ -174,4 +173,4 @@ const PlayerList = () => {
|
||||
);
|
||||
}
|
||||
|
||||
export { PlayerList };
|
||||
export { PlayerList };
|
||||
|
@ -1,7 +1,6 @@
|
||||
import React, { useState } from "react";
|
||||
import "./PlayerName.css";
|
||||
import TextField from '@material-ui/core/TextField';
|
||||
import Button from '@material-ui/core/Button';
|
||||
import { TextField, Button } from '@material-ui/core';
|
||||
|
||||
const PlayerName = ({ name, setName }) => {
|
||||
const [edit, setEdit] = useState(name);
|
||||
@ -34,4 +33,4 @@ const PlayerName = ({ name, setName }) => {
|
||||
);
|
||||
};
|
||||
|
||||
export { PlayerName };
|
||||
export { PlayerName };
|
||||
|
30
client/src/Styles.js
Normal file
@ -0,0 +1,30 @@
|
||||
import { makeStyles } from '@mui/material/styles';
|
||||
import { orange, lightBlue, red, grey } from '@mui/material/colors';
|
||||
|
||||
const useStyles = makeStyles((theme) => ({
|
||||
root: {
|
||||
display: 'flex',
|
||||
'& > *': {
|
||||
margin: theme.spacing(1),
|
||||
},
|
||||
},
|
||||
R: {
|
||||
color: theme.palette.getContrastText(red[500]),
|
||||
backgroundColor: red[500],
|
||||
},
|
||||
O: {
|
||||
color: theme.palette.getContrastText(orange[500]),
|
||||
backgroundColor: orange[500],
|
||||
},
|
||||
W: {
|
||||
color: theme.palette.getContrastText(grey[50]),
|
||||
backgroundColor: grey[50],
|
||||
},
|
||||
B: {
|
||||
color: theme.palette.getContrastText(lightBlue[500]),
|
||||
backgroundColor: lightBlue[500],
|
||||
},
|
||||
}));
|
||||
|
||||
|
||||
export { useStyles };
|
BIN
client/src/assets/down.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
client/src/assets/favicon-128.png
Normal file
After Width: | Height: | Size: 16 KiB |
BIN
client/src/assets/favicon-152.png
Normal file
After Width: | Height: | Size: 17 KiB |
BIN
client/src/assets/favicon-167.png
Normal file
After Width: | Height: | Size: 18 KiB |
BIN
client/src/assets/favicon-180.png
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
client/src/assets/favicon-192.png
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
client/src/assets/favicon-256.png
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
client/src/assets/favicon-32.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
client/src/assets/link.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
client/src/assets/man-robber.png
Executable file
After Width: | Height: | Size: 27 KiB |
BIN
client/src/assets/no-network.png
Executable file
After Width: | Height: | Size: 1.4 KiB |
BIN
client/src/assets/raptor-robber.png
Executable file
After Width: | Height: | Size: 29 KiB |
BIN
client/src/assets/tabletop.png
Normal file
After Width: | Height: | Size: 1.4 MiB |
BIN
client/src/assets/up.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
client/src/assets/woman-robber.png
Executable file
After Width: | Height: | Size: 18 KiB |
@ -3,8 +3,6 @@ services:
|
||||
ketr.chat:
|
||||
volumes:
|
||||
- /etc/nginx/ssl:/etc/nginx/ssl:ro # Use host web keys
|
||||
- $HOME/.netrc:/root/.netrc # Use current user .netrc
|
||||
- $HOME/.config/gh:/root/.config/gh # Use current user GH config
|
||||
- ./logs:/home/user/logs #
|
||||
# Hot mount client and server for dynamic changes in DEVELOPMENT
|
||||
- ./scripts:/opt/scripts # Hot update via bind
|
||||
|
@ -13,8 +13,6 @@ services:
|
||||
tty: true # Needed for react-scripts
|
||||
restart: always
|
||||
volumes:
|
||||
- $HOME/.netrc:/root/.netrc # Use current user .netrc
|
||||
- $HOME/.config/gh:/root/.config/gh # GitHub 'gh' credentials for GitHub actions
|
||||
- /etc/nginx/ssl:/etc/nginx/ssl:ro # Use host web keys
|
||||
- ./logs:/home/user/logs #
|
||||
ports:
|
||||
@ -33,8 +31,6 @@ services:
|
||||
tty: true # Needed for react-scripts
|
||||
restart: always
|
||||
volumes:
|
||||
- $HOME/.netrc:/root/.netrc # Use current user .netrc
|
||||
- $HOME/.config/gh:/root/.config/gh # GitHub 'gh' credentials for GitHub actions
|
||||
- /etc/nginx/ssl:/etc/nginx/ssl:ro # Use host web keys
|
||||
- ./scripts:/opt/scripts # Hot update via bind
|
||||
ports:
|
||||
|
@ -4,6 +4,4 @@ services:
|
||||
ketr.chat-production:
|
||||
volumes:
|
||||
- /etc/nginx/ssl:/etc/nginx/ssl:ro # Use host web keys
|
||||
- $HOME/.netrc:/root/.netrc # Use current user .netrc
|
||||
- $HOME/.config/gh:/root/.config/gh # Use current user GH config
|
||||
- ./logs:/home/user/logs #
|
||||
|