mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 19:49:50 +02:00
feat: more styling
This commit is contained in:
1 parent
e9d5de7e97
commit
354be775ad
1 file changed
+7
-5
@@ -1,4 +1,4 @@
|
|||||||
import { Box, Flex, Heading } from '@radix-ui/themes';
|
import { Box, Flex, Heading, Text } from '@radix-ui/themes';
|
||||||
import { use } from 'react';
|
import { use } from 'react';
|
||||||
import { asset } from '../../../../../../core/blitzkit/asset';
|
import { asset } from '../../../../../../core/blitzkit/asset';
|
||||||
import { gameDefinitions } from '../../../../../../core/blitzkit/gameDefinitions';
|
import { gameDefinitions } from '../../../../../../core/blitzkit/gameDefinitions';
|
||||||
@@ -12,17 +12,17 @@ export function GameModeSection() {
|
|||||||
<Flex direction="column" gap="4" align="center">
|
<Flex direction="column" gap="4" align="center">
|
||||||
<Heading size="6">Game mode abilities</Heading>
|
<Heading size="6">Game mode abilities</Heading>
|
||||||
|
|
||||||
<Flex justify="center" gap="4" wrap="wrap">
|
<Flex justify="center" gap="4" wrap="wrap" px="4">
|
||||||
{Object.entries(tank.roles).map(([key, value]) => {
|
{Object.entries(tank.roles).map(([key, value]) => {
|
||||||
const id = Number(key);
|
const id = Number(key);
|
||||||
const gameMode = awaitedGameDefinitions.gameModes[id];
|
const gameMode = awaitedGameDefinitions.gameModes[id];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Flex
|
<Flex
|
||||||
// width="256px"
|
width="256px"
|
||||||
height="256px"
|
|
||||||
overflow="hidden"
|
overflow="hidden"
|
||||||
style={{
|
style={{
|
||||||
|
aspectRatio: '4 / 3',
|
||||||
borderRadius: 'var(--radius-3)',
|
borderRadius: 'var(--radius-3)',
|
||||||
background: `url(${asset(`icons/game_mode_banners/${id}.webp`)})`,
|
background: `url(${asset(`icons/game_mode_banners/${id}.webp`)})`,
|
||||||
backgroundSize: 'cover',
|
backgroundSize: 'cover',
|
||||||
@@ -41,11 +41,13 @@ export function GameModeSection() {
|
|||||||
<Flex
|
<Flex
|
||||||
flexGrow="1"
|
flexGrow="1"
|
||||||
p="3"
|
p="3"
|
||||||
|
direction="column"
|
||||||
style={{
|
style={{
|
||||||
backdropFilter: 'blur(4rem)',
|
backdropFilter: 'blur(4rem)',
|
||||||
|
WebkitBackdropFilter: 'blur(4rem)',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Heading size="4">{gameMode.name}</Heading>
|
<Text align="center">{gameMode.name}</Text>
|
||||||
</Flex>
|
</Flex>
|
||||||
</Flex>
|
</Flex>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in new issue
Block a user