mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-25 03:29:51 +01:00
feat: caliber discriminators for antagonist cannon selector
This commit is contained in:
1 parent
87d01dab3f
commit
a53c20fa6a
3 files changed
+23
-2
No files matched your search
@@ -17,14 +17,12 @@
|
|||||||
"@gltf-transform/functions": "^4.0.10",
|
"@gltf-transform/functions": "^4.0.10",
|
||||||
"csv-parse": "^5.5.6",
|
"csv-parse": "^5.5.6",
|
||||||
"decompress": "^4.2.1",
|
"decompress": "^4.2.1",
|
||||||
"draco3dgltf": "^1.5.7",
|
|
||||||
"fast-xml-parser": "^4.4.1",
|
"fast-xml-parser": "^4.4.1",
|
||||||
"googleapis": "^134.0.0",
|
"googleapis": "^134.0.0",
|
||||||
"progress": "^2.0.3"
|
"progress": "^2.0.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/decompress": "^4.2.7",
|
"@types/decompress": "^4.2.7",
|
||||||
"@types/draco3dgltf": "^1.4.3",
|
|
||||||
"@types/lodash": "^4.17.7",
|
"@types/lodash": "^4.17.7",
|
||||||
"@types/progress": "^2.0.7"
|
"@types/progress": "^2.0.7"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ export interface TankComponentButtonProps
|
|||||||
selected?: boolean;
|
selected?: boolean;
|
||||||
children?: ReactNode;
|
children?: ReactNode;
|
||||||
discriminator?: ReactNode;
|
discriminator?: ReactNode;
|
||||||
|
secondaryDiscriminator?: ReactNode;
|
||||||
disabled?: boolean;
|
disabled?: boolean;
|
||||||
banner?: string;
|
banner?: string;
|
||||||
special?: boolean;
|
special?: boolean;
|
||||||
@@ -16,6 +17,7 @@ export function TankComponentButton({
|
|||||||
variant,
|
variant,
|
||||||
selected,
|
selected,
|
||||||
discriminator,
|
discriminator,
|
||||||
|
secondaryDiscriminator,
|
||||||
special,
|
special,
|
||||||
children,
|
children,
|
||||||
banner,
|
banner,
|
||||||
@@ -73,6 +75,22 @@ export function TankComponentButton({
|
|||||||
{discriminator}
|
{discriminator}
|
||||||
</Text>
|
</Text>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{secondaryDiscriminator !== undefined && (
|
||||||
|
<Text
|
||||||
|
size="1"
|
||||||
|
style={{
|
||||||
|
textShadow: '0 0 4px black',
|
||||||
|
position: 'absolute',
|
||||||
|
bottom: '50%',
|
||||||
|
right: 8,
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
color={variant === 'ghost' ? 'gray' : undefined}
|
||||||
|
>
|
||||||
|
{secondaryDiscriminator}
|
||||||
|
</Text>
|
||||||
|
)}
|
||||||
</Button>
|
</Button>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@@ -176,6 +176,11 @@ export function Options({ thicknessRange, canvas }: OptionsProps) {
|
|||||||
discriminator={
|
discriminator={
|
||||||
TIER_ROMAN_NUMERALS[gun.gun_type!.value.base.tier]
|
TIER_ROMAN_NUMERALS[gun.gun_type!.value.base.tier]
|
||||||
}
|
}
|
||||||
|
secondaryDiscriminator={
|
||||||
|
<Text style={{ fontSize: '0.75em' }}>
|
||||||
|
{gun.gun_type!.value.base.shells[0].caliber}mm
|
||||||
|
</Text>
|
||||||
|
}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
</Flex>
|
</Flex>
|
||||||
|
|||||||
Reference in new issue
Block a user