mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-22 03:07:04 +02:00
feat: consumable timings
This commit is contained in:
1 parent
8f098d435a
commit
809f807da8
11 files changed
+145
-46
No files matched your search
@@ -12,22 +12,35 @@ interface GenericTankComponentButtonProps extends TankComponentButtonProps {
|
||||
export function GenericTankComponentButton({
|
||||
icon,
|
||||
iconStyles,
|
||||
children,
|
||||
...props
|
||||
}: GenericTankComponentButtonProps) {
|
||||
return (
|
||||
<TankComponentButton disabled={props.disabled} {...props}>
|
||||
<img
|
||||
draggable={false}
|
||||
src={icon}
|
||||
<TankComponentButton {...props}>
|
||||
<div
|
||||
style={{
|
||||
width: 32,
|
||||
height: 32,
|
||||
position: 'absolute',
|
||||
opacity: props.disabled ? 0.5 : 1,
|
||||
transform: 'scale(0.75)',
|
||||
...iconStyles,
|
||||
width: 48,
|
||||
height: 40,
|
||||
position: 'relative',
|
||||
}}
|
||||
/>
|
||||
>
|
||||
<img
|
||||
draggable={false}
|
||||
src={icon}
|
||||
style={{
|
||||
width: 32,
|
||||
height: 32,
|
||||
position: 'absolute',
|
||||
opacity: props.disabled ? 0.5 : 1,
|
||||
transform: 'translate(-50%, -50%) scale(0.75)',
|
||||
top: '50%',
|
||||
left: '50%',
|
||||
...iconStyles,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
|
||||
{children}
|
||||
</TankComponentButton>
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user