Add tooltips to unfocused work

This commit is contained in:
nickofolas 2022-01-11 17:46:59 -06:00
parent 979d785af6
commit a41104f51a

@ -7,6 +7,7 @@ import createStyles from "@mui/styles/createStyles";
import { numeralWrapper } from "../../ui/numeralFormat"; import { numeralWrapper } from "../../ui/numeralFormat";
import { Reputation } from "./Reputation"; import { Reputation } from "./Reputation";
import { KillScriptsModal } from "./KillScriptsModal"; import { KillScriptsModal } from "./KillScriptsModal";
import { convertTimeMsToTimeElapsedString } from "../../utils/StringHelperFunctions";
import Table from "@mui/material/Table"; import Table from "@mui/material/Table";
import TableBody from "@mui/material/TableBody"; import TableBody from "@mui/material/TableBody";
@ -90,12 +91,14 @@ function Work(): React.ReactElement {
<> <>
<TableRow> <TableRow>
<TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}> <TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}>
<Typography>Work&nbsp;in&nbsp;progress:</Typography> <Tooltip title={'You are ' + player.className}>
<Typography>Work&nbsp;in&nbsp;progress:</Typography>
</Tooltip>
</TableCell> </TableCell>
</TableRow> </TableRow>
<TableRow> <TableRow>
<TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}> <TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}>
<Typography>{player.className}</Typography> <Typography>{convertTimeMsToTimeElapsedString(player.timeWorked)}</Typography>
</TableCell> </TableCell>
</TableRow> </TableRow>
<TableRow> <TableRow>
@ -119,7 +122,9 @@ function Work(): React.ReactElement {
<> <>
<TableRow> <TableRow>
<TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}> <TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}>
<Typography>Work&nbsp;in&nbsp;progress:</Typography> <Tooltip title={`Coding ${player.createProgramName}`}>
<Typography>Work&nbsp;in&nbsp;progress:</Typography>
</Tooltip>
</TableCell> </TableCell>
</TableRow> </TableRow>
<TableRow> <TableRow>
@ -150,7 +155,9 @@ function Work(): React.ReactElement {
<> <>
<TableRow> <TableRow>
<TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}> <TableCell component="th" scope="row" colSpan={2} classes={{ root: classes.cellNone }}>
<Typography>Work&nbsp;in&nbsp;progress:</Typography> <Tooltip title={player.workType}>
<Typography>Work&nbsp;in&nbsp;progress:</Typography>
</Tooltip>
</TableCell> </TableCell>
</TableRow> </TableRow>
<TableRow> <TableRow>