mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-29 13:39:50 +01:00
feat: better ratios of hero
This commit is contained in:
1 parent
ea7f40a808
commit
a961643c76
2 files changed
+36
-25
No files matched your search
@@ -1,4 +1,5 @@
|
|||||||
import { Flex, Heading } from '@radix-ui/themes';
|
import { Flex, Heading } from '@radix-ui/themes';
|
||||||
|
import { useWideFormat } from '../../../../../../hooks/useWideFormat';
|
||||||
import { Characteristics } from '../Characteristics';
|
import { Characteristics } from '../Characteristics';
|
||||||
import { Consumables } from '../Characteristics/components/Consumables';
|
import { Consumables } from '../Characteristics/components/Consumables';
|
||||||
import { Equipment } from '../Characteristics/components/Equipment';
|
import { Equipment } from '../Characteristics/components/Equipment';
|
||||||
@@ -8,8 +9,10 @@ import { Provisions } from '../Characteristics/components/Provisions';
|
|||||||
import { Skills } from '../Characteristics/components/Skills';
|
import { Skills } from '../Characteristics/components/Skills';
|
||||||
|
|
||||||
export function CharacteristicsSection() {
|
export function CharacteristicsSection() {
|
||||||
|
const wideFormat = useWideFormat(720);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Flex justify="center" mt="4">
|
<Flex justify="center" mt="4" direction={wideFormat ? 'row' : 'column'}>
|
||||||
<Flex gap="4">
|
<Flex gap="4">
|
||||||
<Flex style={{ flex: 1, maxWidth: 320 }} direction="column" gap="4">
|
<Flex style={{ flex: 1, maxWidth: 320 }} direction="column" gap="4">
|
||||||
<Heading>Configure</Heading>
|
<Heading>Configure</Heading>
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ export function HeroSection() {
|
|||||||
return (
|
return (
|
||||||
<Flex
|
<Flex
|
||||||
justify="center"
|
justify="center"
|
||||||
pl={wideFormat ? '9' : undefined}
|
// pl={wideFormat ? '9' : undefined}
|
||||||
p={wideFormat ? '0' : '6'}
|
p={wideFormat ? '0' : '6'}
|
||||||
pb={wideFormat ? '0' : '6'}
|
pb={wideFormat ? '0' : '6'}
|
||||||
style={{
|
style={{
|
||||||
@@ -53,7 +53,7 @@ export function HeroSection() {
|
|||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
height: 512,
|
height: 512,
|
||||||
flex: wideFormat ? 3 : undefined,
|
flex: wideFormat ? 2 : undefined,
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@@ -61,31 +61,39 @@ export function HeroSection() {
|
|||||||
style={{
|
style={{
|
||||||
width: '100%',
|
width: '100%',
|
||||||
height: '100%',
|
height: '100%',
|
||||||
}}
|
|
||||||
>
|
|
||||||
<TankSandbox />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<Flex
|
|
||||||
style={{
|
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
bottom: 16,
|
|
||||||
left: '50%',
|
|
||||||
transform: 'translateX(-50%)',
|
|
||||||
cursor: 'default',
|
|
||||||
userSelect: 'none',
|
|
||||||
}}
|
|
||||||
align="center"
|
|
||||||
gap="2"
|
|
||||||
onClick={() => {
|
|
||||||
mutateTankopediaPersistent((draft) => {
|
|
||||||
draft.mode = draft.mode === 'armor' ? 'model' : 'armor';
|
|
||||||
});
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Checkbox checked={mode === 'armor'} />
|
<div
|
||||||
Armor
|
style={{
|
||||||
</Flex>
|
width: '100%',
|
||||||
|
height: '100%',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<TankSandbox />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<Flex
|
||||||
|
style={{
|
||||||
|
position: 'absolute',
|
||||||
|
bottom: 16,
|
||||||
|
left: '50%',
|
||||||
|
transform: 'translateX(-50%)',
|
||||||
|
cursor: 'default',
|
||||||
|
userSelect: 'none',
|
||||||
|
}}
|
||||||
|
align="center"
|
||||||
|
gap="2"
|
||||||
|
onClick={() => {
|
||||||
|
mutateTankopediaPersistent((draft) => {
|
||||||
|
draft.mode = draft.mode === 'armor' ? 'model' : 'armor';
|
||||||
|
});
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<Checkbox checked={mode === 'armor'} />
|
||||||
|
Armor
|
||||||
|
</Flex>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</Flex>
|
</Flex>
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user