mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-22 03:07:04 +02:00
22 lines
594 B
TypeScript
22 lines
594 B
TypeScript
import { asset } from '@blitzkit/core';
|
|
import { GenericTankComponentButton } from './GenericTankComponentButton';
|
|
import type { 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}
|
|
/>
|
|
);
|
|
}
|