fix: remove useless tooltips

This commit is contained in:
TrèsAbhi committed 2024-04-02 10:10:15 -05:00
1 parent 78e6b2696c
commit 9ef6eea4a9
1 file changed
+5 -23
@@ -1,13 +1,5 @@
import { Cross1Icon, ShuffleIcon } from '@radix-ui/react-icons'; import { Cross1Icon, ShuffleIcon } from '@radix-ui/react-icons';
import { import { Button, Card, Dialog, Flex, Heading, Tabs } from '@radix-ui/themes';
Button,
Card,
Dialog,
Flex,
Heading,
Tabs,
Tooltip,
} from '@radix-ui/themes';
import { useState } from 'react'; import { useState } from 'react';
import { ModuleButton } from '../../../../../components/ModuleButtons/ModuleButton'; import { ModuleButton } from '../../../../../components/ModuleButtons/ModuleButton';
import { ShellButton } from '../../../../../components/ModuleButtons/ShellButton'; import { ShellButton } from '../../../../../components/ModuleButtons/ShellButton';
@@ -169,13 +161,11 @@ export function AntagonistBar({ floating }: AntagonistBarProps) {
<Flex gap="2" wrap="wrap"> <Flex gap="2" wrap="wrap">
<Flex> <Flex>
{antagonist.tank.turrets.map((turret, index) => ( {antagonist.tank.turrets.map((turret, index) => (
<Tooltip content={turret.name} key={turret.id}>
<ModuleButton <ModuleButton
rowChild rowChild
first={index === 0} first={index === 0}
last={ last={
index === index === antagonist.tank.turrets.length - 1
antagonist.tank.turrets.length - 1
} }
key={turret.id} key={turret.id}
onClick={() => { onClick={() => {
@@ -190,26 +180,21 @@ export function AntagonistBar({ floating }: AntagonistBarProps) {
draft.shot = undefined; draft.shot = undefined;
}); });
}} }}
selected={ selected={antagonist.turret.id === turret.id}
antagonist.turret.id === turret.id
}
discriminator={ discriminator={
TIER_ROMAN_NUMERALS[turret.tier] TIER_ROMAN_NUMERALS[turret.tier]
} }
module="turret" module="turret"
/> />
</Tooltip>
))} ))}
</Flex> </Flex>
<Flex> <Flex>
{antagonist.turret.guns.map((gun, index) => ( {antagonist.turret.guns.map((gun, index) => (
<Tooltip content={gun.name} key={gun.id}>
<ModuleButton <ModuleButton
rowChild rowChild
first={index === 0} first={index === 0}
last={ last={
index === index === antagonist.turret.guns.length - 1
antagonist.turret.guns.length - 1
} }
onClick={() => { onClick={() => {
mutateDuel((draft) => { mutateDuel((draft) => {
@@ -218,12 +203,9 @@ export function AntagonistBar({ floating }: AntagonistBarProps) {
}); });
}} }}
selected={antagonist.gun.id === gun.id} selected={antagonist.gun.id === gun.id}
discriminator={ discriminator={TIER_ROMAN_NUMERALS[gun.tier]}
TIER_ROMAN_NUMERALS[gun.tier]
}
module="gun" module="gun"
/> />
</Tooltip>
))} ))}
</Flex> </Flex>
</Flex> </Flex>