remove memflags, update packages

This commit is contained in:
HF 2023-03-13 00:36:09 +01:00
parent 59033b57c9
commit a7e6a49a79
5 changed files with 2077 additions and 1344 deletions

3361
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -68,29 +68,29 @@
"ws": "^8.4.0"
},
"devDependencies": {
"@babel/cli": "^7.18.6",
"@babel/core": "^7.18.6",
"@babel/eslint-parser": "^7.16.5",
"@babel/node": "^7.18.6",
"@babel/plugin-transform-react-constant-elements": "^7.18.6",
"@babel/plugin-transform-react-inline-elements": "^7.18.6",
"@babel/preset-env": "^7.18.6",
"@babel/cli": "^7.21.0",
"@babel/core": "^7.21.0",
"@babel/eslint-parser": "^7.19.1",
"@babel/node": "^7.20.7",
"@babel/plugin-transform-react-constant-elements": "^7.20.2",
"@babel/plugin-transform-react-inline-elements": "^7.21.0",
"@babel/preset-env": "^7.20.2",
"@babel/preset-react": "^7.18.6",
"assets-webpack-plugin": "^7.1.1",
"babel-loader": "^8.2.3",
"babel-plugin-transform-react-pure-class-to-function": "^1.0.1",
"babel-plugin-transform-react-remove-prop-types": "^0.4.24",
"babel-plugin-ttag": "^1.7.30",
"babel-plugin-ttag": "^1.8.5",
"clean-css": "^5.2.2",
"clean-css-loader": "^4.1.1",
"copy-webpack-plugin": "^11.0.0",
"css-loader": "^6.5.1",
"eslint": "^8.22.0",
"eslint": "^8.36.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-plugin-import": "^2.25.3",
"eslint-plugin-jsx-a11y": "^6.6.0",
"eslint-plugin-react": "^7.30.1",
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-jsx-a11y": "^6.7.1",
"eslint-plugin-react": "^7.32.2",
"eslint-plugin-react-hooks": "^4.6.0",
"generate-package-json-webpack-plugin": "^2.6.0",
"ttag-cli": "^1.9.3",

View File

@ -202,6 +202,7 @@ function Converter() {
? null
: (
<option
key={canvas}
value={canvas}
>
{

View File

@ -301,17 +301,17 @@ function ModWatchtools() {
.map((row) => (
<tr key={row[0]}>
{row.slice(1).map((val, ind) => {
if (val === null) {
return (<td>N/A</td>);
}
const type = types[ind + 1];
if (val === null) {
return (<td key={type}>N/A</td>);
}
switch (type) {
case 'ts': {
const date = new Date(val);
let minutes = date.getMinutes();
if (minutes < 10) minutes = `0${minutes}`;
return (
<td title={date.toLocaleDateString()}>
<td key={type} title={date.toLocaleDateString()}>
{`${date.getHours()}:${minutes}`}
</td>
);
@ -323,11 +323,14 @@ function ModWatchtools() {
&& canvases[cid].colors
&& canvases[cid].colors[val];
if (!rgb) {
return (<td>{val}</td>);
return (<td key={type}>{val}</td>);
}
const color = `rgb(${rgb[0]},${rgb[1]},${rgb[2]})`;
return (
<td style={{ backgroundColor: color }}>{val}</td>
<td
key={type}
style={{ backgroundColor: color }}
>{val}</td>
);
}
case 'coord': {
@ -336,7 +339,7 @@ function ModWatchtools() {
const ident = canvases[cid] && canvases[cid].ident;
const coords = `./#${ident},${val},47`;
return (
<td>
<td key={type}>
<a href={coords}>{val}</a>
</td>
);
@ -344,7 +347,7 @@ function ModWatchtools() {
case 'flag': {
const flag = val.toLowerCase();
return (
<td title={val}><img
<td key={type} title={val}><img
style={{
height: '1em',
imageRendering: 'crisp-edges',
@ -356,11 +359,11 @@ function ModWatchtools() {
}
case 'cid': {
const ident = canvases[val] && canvases[val].ident;
return (<td>{ident}</td>);
return (<td key={type}>{ident}</td>);
}
case 'uuid': {
return (
<td>
<td key={type}>
<span
role="button"
tabIndex={-1}
@ -377,10 +380,10 @@ function ModWatchtools() {
case 'user': {
const seperator = val.lastIndexOf(',');
if (seperator === -1) {
return (<td><span>{val}</span></td>);
return (<td key={type}><span>{val}</span></td>);
}
return (
<td title={val.slice(seperator + 1)}>
<td key={type} title={val.slice(seperator + 1)}>
<span>
{val.slice(0, seperator)}
</span>
@ -388,7 +391,7 @@ function ModWatchtools() {
);
}
default: {
return (<td>{val}</td>);
return (<td key={type}>{val}</td>);
}
}
})}

View File

@ -474,8 +474,14 @@ export class ChatProvider {
let displayCountry = country;
if (user.userlvl !== 0) {
displayCountry = 'zz';
/*
* meme names disabled for now
* TODO think about activating it again after fixing accounts and
* mute evasions
*
} else if (name.endsWith('berg') || name.endsWith('stein')) {
displayCountry = 'il';
/ */
} else if (user.id === 2927) {
/*
* hard coded flag for Manchukuo_1940