2024-04-20 12:00:48 -05:00
|
|
|
import { asset } from '../../core/blitzrinth/asset';
|
2024-02-12 19:24:34 -06:00
|
|
|
import { GenericTankComponentButton } from './GenericTankComponentButton';
|
|
|
|
|
import { TankComponentButtonProps } from './TankComponentButton';
|
|
|
|
|
|
|
|
|
|
interface ModuleProps extends TankComponentButtonProps {
|
|
|
|
|
module: string;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export function ModuleButton({ module, ...props }: ModuleProps) {
|
|
|
|
|
return (
|
|
|
|
|
<GenericTankComponentButton
|
|
|
|
|
icon={asset(`icons/modules/${module}.webp`)}
|
|
|
|
|
iconStyles={{
|
|
|
|
|
top: '50%',
|
|
|
|
|
left: '50%',
|
|
|
|
|
transform: 'translate(calc(-50% + 2px), calc(-50% + 2px))',
|
|
|
|
|
}}
|
|
|
|
|
{...props}
|
|
|
|
|
/>
|
|
|
|
|
);
|
|
|
|
|
}
|