mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-10 09:43:54 +01:00
Further design updates
This commit is contained in:
parent
7853144b18
commit
f12a117f06
@ -16,7 +16,7 @@ import { numeralWrapper } from "../../ui/numeralFormat";
|
|||||||
import { Money } from "../../ui/React/Money";
|
import { Money } from "../../ui/React/Money";
|
||||||
import { Reputation } from "../../ui/React/Reputation";
|
import { Reputation } from "../../ui/React/Reputation";
|
||||||
|
|
||||||
import { CheckBox, CheckBoxOutlineBlank } from "@mui/icons-material";
|
import { CheckBox, CheckBoxOutlineBlank, Verified, Info } from "@mui/icons-material";
|
||||||
import { Augmentation as AugFormat } from "../../ui/React/Augmentation";
|
import { Augmentation as AugFormat } from "../../ui/React/Augmentation";
|
||||||
import { Paper, Button, Typography, Tooltip, Box, TableRow, Container, List, ListItem } from "@mui/material";
|
import { Paper, Button, Typography, Tooltip, Box, TableRow, Container, List, ListItem } from "@mui/material";
|
||||||
import { TableCell } from "../../ui/React/Table";
|
import { TableCell } from "../../ui/React/Table";
|
||||||
@ -93,23 +93,16 @@ export const PurchaseableAugmentations = (props: IPurchaseableAugsProps): React.
|
|||||||
<Container
|
<Container
|
||||||
maxWidth="lg"
|
maxWidth="lg"
|
||||||
disableGutters
|
disableGutters
|
||||||
sx={{ mx: 0, display: "grid", gridTemplateColumns: "repeat(1, 1fr)", gap: 1 }}
|
sx={{ mx: 0, display: "grid", gridTemplateColumns: "repeat(2, 1fr)", gap: 1 }}
|
||||||
>
|
>
|
||||||
{props.augNames.map((augName: string) => {
|
{props.augNames.map((augName: string) => {
|
||||||
const aug = Augmentations[augName];
|
const aug = Augmentations[augName];
|
||||||
|
|
||||||
const info = typeof aug.info === "string" ? <span>{aug.info}</span> : aug.info;
|
const info = typeof aug.info === "string" ? <span>{aug.info}</span> : aug.info;
|
||||||
const description = (
|
const description = aug.stats;
|
||||||
<>
|
|
||||||
{info}
|
|
||||||
<br />
|
|
||||||
<br />
|
|
||||||
{aug.stats}
|
|
||||||
</>
|
|
||||||
);
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Paper key={augName} sx={{ p: 1, display: "grid", gridTemplateColumns: "1fr 3fr", gap: 1 }}>
|
<Paper key={augName} sx={{ p: 1, display: "grid", gridTemplateColumns: "1fr 2fr", gap: 1 }}>
|
||||||
<Box>
|
<Box>
|
||||||
<Button
|
<Button
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
@ -122,6 +115,14 @@ export const PurchaseableAugmentations = (props: IPurchaseableAugsProps): React.
|
|||||||
>
|
>
|
||||||
Buy Augmentation
|
Buy Augmentation
|
||||||
</Button>
|
</Button>
|
||||||
|
|
||||||
|
{aug.factions.length === 1 && (
|
||||||
|
<Typography sx={{ display: "flex", alignItems: "center", color: Settings.theme.info }}>
|
||||||
|
<Verified sx={{ mr: 1 }} />
|
||||||
|
Faction-Exclusive Augmentation
|
||||||
|
</Typography>
|
||||||
|
)}
|
||||||
|
|
||||||
<Typography>
|
<Typography>
|
||||||
<b>Cost:</b>
|
<b>Cost:</b>
|
||||||
</Typography>
|
</Typography>
|
||||||
@ -137,6 +138,7 @@ export const PurchaseableAugmentations = (props: IPurchaseableAugsProps): React.
|
|||||||
valueColor={Settings.theme.rep}
|
valueColor={Settings.theme.rep}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{aug.prereqs.length > 0 && (
|
{aug.prereqs.length > 0 && (
|
||||||
<>
|
<>
|
||||||
<Typography>
|
<Typography>
|
||||||
@ -153,8 +155,14 @@ export const PurchaseableAugmentations = (props: IPurchaseableAugsProps): React.
|
|||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</Box>
|
</Box>
|
||||||
|
|
||||||
<Box>
|
<Box>
|
||||||
<Typography variant="h6">{aug.name}</Typography>
|
<Typography variant="h6" sx={{ display: "flex", alignItems: "center" }}>
|
||||||
|
<Tooltip title={<Typography>{info}</Typography>}>
|
||||||
|
<Info sx={{ mr: 1 }} color="info" />
|
||||||
|
</Tooltip>
|
||||||
|
{aug.name}
|
||||||
|
</Typography>
|
||||||
<Typography>{description}</Typography>
|
<Typography>{description}</Typography>
|
||||||
</Box>
|
</Box>
|
||||||
</Paper>
|
</Paper>
|
||||||
|
@ -3,13 +3,11 @@ import { Sleeve } from "../Sleeve";
|
|||||||
import { findSleevePurchasableAugs } from "../SleeveHelpers";
|
import { findSleevePurchasableAugs } from "../SleeveHelpers";
|
||||||
import { Augmentations } from "../../../Augmentation/Augmentations";
|
import { Augmentations } from "../../../Augmentation/Augmentations";
|
||||||
import { Augmentation } from "../../../Augmentation/Augmentation";
|
import { Augmentation } from "../../../Augmentation/Augmentation";
|
||||||
|
import { PurchaseableAugmentations } from "../../../Augmentation/ui/PurchaseableAugmentations";
|
||||||
import { Money } from "../../../ui/React/Money";
|
import { Money } from "../../../ui/React/Money";
|
||||||
import { Modal } from "../../../ui/React/Modal";
|
import { Modal } from "../../../ui/React/Modal";
|
||||||
import { use } from "../../../ui/Context";
|
import { use } from "../../../ui/Context";
|
||||||
import Typography from "@mui/material/Typography";
|
import { Typography, Tooltip, Paper, Box, Container } from "@mui/material";
|
||||||
import Tooltip from "@mui/material/Tooltip";
|
|
||||||
import Paper from "@mui/material/Paper";
|
|
||||||
import Box from "@mui/material/Box";
|
|
||||||
import Button from "@mui/material/Button";
|
import Button from "@mui/material/Button";
|
||||||
import TableBody from "@mui/material/TableBody";
|
import TableBody from "@mui/material/TableBody";
|
||||||
import Table from "@mui/material/Table";
|
import Table from "@mui/material/Table";
|
||||||
@ -49,17 +47,27 @@ export function SleeveAugmentationsModal(props: IProps): React.ReactElement {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<Modal open={props.open} onClose={props.onClose}>
|
<Modal open={props.open} onClose={props.onClose}>
|
||||||
<>
|
<Container disableGutters maxWidth="lg" sx={{ mx: 0 }}>
|
||||||
<Box sx={{ mx: 1 }}>
|
<Typography>
|
||||||
<Typography>
|
You can purchase Augmentations for your Duplicate Sleeves. These Augmentations have the same effect as they
|
||||||
You can purchase Augmentations for your Duplicate Sleeves. These Augmentations have the same effect as they
|
would for you. You can only purchase Augmentations that you have unlocked through Factions.
|
||||||
would for you. You can only purchase Augmentations that you have unlocked through Factions.
|
<br />
|
||||||
<br />
|
<br />
|
||||||
<br />
|
When purchasing an Augmentation for a Duplicate Sleeve, they are immediately installed. This means that the
|
||||||
When purchasing an Augmentation for a Duplicate Sleeve, they are immediately installed. This means that the
|
Duplicate Sleeve will immediately lose all of its stat experience.
|
||||||
Duplicate Sleeve will immediately lose all of its stat experience.
|
</Typography>
|
||||||
</Typography>
|
<PurchaseableAugmentations
|
||||||
<Box component={Paper} sx={{ my: 1, p: 1 }}>
|
augNames={availableAugs.map((aug) => aug.name)}
|
||||||
|
player={player}
|
||||||
|
canPurchase={(player, aug) => {
|
||||||
|
return player.money > aug.startingCost;
|
||||||
|
}}
|
||||||
|
purchaseAugmentation={(player, aug, _showModal) => {
|
||||||
|
props.sleeve.tryBuyAugmentation(player, aug);
|
||||||
|
rerender();
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
{/* <Box component={Paper} sx={{ my: 1, p: 1 }}>
|
||||||
<Table size="small" padding="none">
|
<Table size="small" padding="none">
|
||||||
<TableBody>
|
<TableBody>
|
||||||
{availableAugs.map((aug) => {
|
{availableAugs.map((aug) => {
|
||||||
@ -85,8 +93,7 @@ export function SleeveAugmentationsModal(props: IProps): React.ReactElement {
|
|||||||
})}
|
})}
|
||||||
</TableBody>
|
</TableBody>
|
||||||
</Table>
|
</Table>
|
||||||
</Box>
|
</Box> */}
|
||||||
</Box>
|
|
||||||
|
|
||||||
{ownedAugNames.length > 0 && (
|
{ownedAugNames.length > 0 && (
|
||||||
<>
|
<>
|
||||||
@ -115,7 +122,7 @@ export function SleeveAugmentationsModal(props: IProps): React.ReactElement {
|
|||||||
</Box>
|
</Box>
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</>
|
</Container>
|
||||||
</Modal>
|
</Modal>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user