feat: plug

This commit is contained in:
TrèsAbhi committed 2026-03-31 21:01:00 -05:00
1 parent fdf8580f5f
commit e063970c58
2 files changed
+48 -2

No files matched your search

@@ -1,5 +1,14 @@
import { asset } from "@blitzkit/core"; import { asset } from "@blitzkit/core";
import { Box, Flex, Heading, Switch, Text } from "@radix-ui/themes"; import { InfoCircledIcon } from "@radix-ui/react-icons";
import {
Box,
Flex,
Heading,
Link,
Popover,
Switch,
Text,
} from "@radix-ui/themes";
import { useLocale } from "../../../../hooks/useLocale"; import { useLocale } from "../../../../hooks/useLocale";
import { Duel } from "../../../../stores/duel"; import { Duel } from "../../../../stores/duel";
import { ConfigurationChildWrapper } from "./ConfigurationChildWrapper"; import { ConfigurationChildWrapper } from "./ConfigurationChildWrapper";
@@ -15,6 +24,7 @@ export function Equalizer() {
</Heading> </Heading>
<Box <Box
mt="2"
onClick={() => { onClick={() => {
Duel.mutate((draft) => { Duel.mutate((draft) => {
draft.protagonist.equalize = !draft.protagonist.equalize; draft.protagonist.equalize = !draft.protagonist.equalize;
@@ -40,12 +50,47 @@ export function Equalizer() {
"linear-gradient(90deg, var(--black-a3), var(--gray-1))", "linear-gradient(90deg, var(--black-a3), var(--gray-1))",
}} }}
> >
<Text> <Text
style={{
textShadow: "0 0 var(--space-1) var(--black-a12)",
}}
>
{strings.website.tools.tankopedia.configuration.equalizer.equalize} {strings.website.tools.tankopedia.configuration.equalizer.equalize}
</Text> </Text>
<Switch checked={equalize} /> <Switch checked={equalize} />
</Flex> </Flex>
</Box> </Box>
<Popover.Root>
<Popover.Trigger>
<Text style={{ cursor: "pointer" }} size="2" color="gray">
<Flex align="center" gap="2">
Brought to your by{" "}
<img
src="/assets/images/third-party/wotb-news.png"
style={{
width: "1rem",
height: "1rem",
objectFit: "cover",
borderRadius: "50%",
}}
/>{" "}
WoTB News <InfoCircledIcon />
</Flex>
</Text>
</Popover.Trigger>
<Popover.Content>
<Text>
This feature was brought to you early, ahead of the release of the
game mode, thanks to{" "}
<Link href="https://discord.gg/WHdER7ZPAD" target="_blank">
WoTB News
</Link>
.
</Text>
</Popover.Content>
</Popover.Root>
</ConfigurationChildWrapper> </ConfigurationChildWrapper>
); );
} }
@@ -5,3 +5,4 @@ import ToolLayout from "../../layouts/ToolLayout.astro";
--- ---
<ToolLayout locale={locales.default} tool={tools.api} /> <ToolLayout locale={locales.default} tool={tools.api} />