Cluster guest v2 capture controls
This commit is contained in:
@@ -129,6 +129,7 @@ export default function AppShell({ children }: AppShellProps) {
|
|||||||
</YStack>
|
</YStack>
|
||||||
{showFab ? (
|
{showFab ? (
|
||||||
<>
|
<>
|
||||||
|
{isUploadRoute ? null : (
|
||||||
<Button
|
<Button
|
||||||
size="$3"
|
size="$3"
|
||||||
circular
|
circular
|
||||||
@@ -144,12 +145,13 @@ export default function AppShell({ children }: AppShellProps) {
|
|||||||
>
|
>
|
||||||
<Home size={16} color={actionIconColor} />
|
<Home size={16} color={actionIconColor} />
|
||||||
</Button>
|
</Button>
|
||||||
|
)}
|
||||||
<FloatingActionButton
|
<FloatingActionButton
|
||||||
onPress={goTo('/upload')}
|
onPress={goTo('/upload')}
|
||||||
hidden={isUploadRoute}
|
hidden={isUploadRoute}
|
||||||
/>
|
/>
|
||||||
<Button
|
<Button
|
||||||
size="$4"
|
size="$5"
|
||||||
circular
|
circular
|
||||||
position="fixed"
|
position="fixed"
|
||||||
bottom={28}
|
bottom={28}
|
||||||
@@ -158,12 +160,12 @@ export default function AppShell({ children }: AppShellProps) {
|
|||||||
backgroundColor={isDark ? 'rgba(12, 16, 32, 0.75)' : 'rgba(255, 255, 255, 0.9)'}
|
backgroundColor={isDark ? 'rgba(12, 16, 32, 0.75)' : 'rgba(255, 255, 255, 0.9)'}
|
||||||
borderWidth={1}
|
borderWidth={1}
|
||||||
borderColor={isDark ? 'rgba(255,255,255,0.16)' : 'rgba(15,23,42,0.12)'}
|
borderColor={isDark ? 'rgba(255,255,255,0.16)' : 'rgba(15,23,42,0.12)'}
|
||||||
width={54}
|
width={72}
|
||||||
height={54}
|
height={72}
|
||||||
onPress={openCompass}
|
onPress={openCompass}
|
||||||
style={{ boxShadow: isDark ? '0 10px 20px rgba(2, 6, 23, 0.45)' : '0 8px 16px rgba(15, 23, 42, 0.14)' }}
|
style={{ boxShadow: isDark ? '0 10px 20px rgba(2, 6, 23, 0.45)' : '0 8px 16px rgba(15, 23, 42, 0.14)' }}
|
||||||
>
|
>
|
||||||
<Menu size={18} color={actionIconColor} />
|
<Menu size={24} color={actionIconColor} />
|
||||||
</Button>
|
</Button>
|
||||||
</>
|
</>
|
||||||
) : null}
|
) : null}
|
||||||
|
|||||||
@@ -500,13 +500,23 @@ export default function UploadScreen() {
|
|||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
{cameraState === 'ready' && !previewUrl ? (
|
{cameraState === 'ready' && !previewUrl ? (
|
||||||
<XStack
|
<YStack
|
||||||
position="absolute"
|
position="absolute"
|
||||||
bottom="$4"
|
bottom="$4"
|
||||||
left="$4"
|
left="$4"
|
||||||
right="$4"
|
right="$4"
|
||||||
alignItems="center"
|
alignItems="center"
|
||||||
justifyContent="space-between"
|
>
|
||||||
|
<XStack
|
||||||
|
gap="$2"
|
||||||
|
alignItems="center"
|
||||||
|
justifyContent="center"
|
||||||
|
padding="$2"
|
||||||
|
borderRadius={999}
|
||||||
|
borderWidth={1}
|
||||||
|
borderColor={isDark ? 'rgba(255,255,255,0.16)' : 'rgba(15,23,42,0.14)'}
|
||||||
|
backgroundColor={isDark ? 'rgba(12, 16, 32, 0.6)' : 'rgba(255, 255, 255, 0.8)'}
|
||||||
|
style={{ boxShadow: accessoryShadow }}
|
||||||
>
|
>
|
||||||
<Button
|
<Button
|
||||||
size="$3"
|
size="$3"
|
||||||
@@ -516,13 +526,12 @@ export default function UploadScreen() {
|
|||||||
borderColor={flashPreferred ? 'rgba(255,255,255,0.25)' : mutedButtonBorder}
|
borderColor={flashPreferred ? 'rgba(255,255,255,0.25)' : mutedButtonBorder}
|
||||||
onPress={handleToggleFlash}
|
onPress={handleToggleFlash}
|
||||||
disabled={facingMode !== 'environment'}
|
disabled={facingMode !== 'environment'}
|
||||||
style={{ boxShadow: accessoryShadow }}
|
|
||||||
aria-label={t('upload.controls.toggleFlash', 'Toggle flash')}
|
aria-label={t('upload.controls.toggleFlash', 'Toggle flash')}
|
||||||
>
|
>
|
||||||
{flashPreferred ? (
|
{flashPreferred ? (
|
||||||
<Zap size={18} color="#FFFFFF" />
|
<Zap size={20} color="#FFFFFF" />
|
||||||
) : (
|
) : (
|
||||||
<ZapOff size={18} color={iconColor} />
|
<ZapOff size={20} color={iconColor} />
|
||||||
)}
|
)}
|
||||||
</Button>
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
@@ -530,17 +539,17 @@ export default function UploadScreen() {
|
|||||||
circular
|
circular
|
||||||
backgroundColor="$primary"
|
backgroundColor="$primary"
|
||||||
onPress={handleCapture}
|
onPress={handleCapture}
|
||||||
width={90}
|
width={98}
|
||||||
height={90}
|
height={98}
|
||||||
borderRadius={999}
|
borderRadius={999}
|
||||||
shadowColor={isDark ? 'rgba(255, 79, 216, 0.5)' : 'rgba(15, 23, 42, 0.2)'}
|
shadowColor={isDark ? 'rgba(255, 79, 216, 0.5)' : 'rgba(15, 23, 42, 0.2)'}
|
||||||
shadowOpacity={0.5}
|
shadowOpacity={0.5}
|
||||||
shadowRadius={22}
|
shadowRadius={24}
|
||||||
shadowOffset={{ width: 0, height: 10 }}
|
shadowOffset={{ width: 0, height: 12 }}
|
||||||
style={{ boxShadow: fabShadow }}
|
style={{ boxShadow: fabShadow }}
|
||||||
aria-label={t('upload.captureButton', 'Capture')}
|
aria-label={t('upload.captureButton', 'Capture')}
|
||||||
>
|
>
|
||||||
<Camera size={34} color="#FFFFFF" />
|
<Camera size={40} color="#FFFFFF" />
|
||||||
</Button>
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
size="$3"
|
size="$3"
|
||||||
@@ -549,12 +558,12 @@ export default function UploadScreen() {
|
|||||||
borderWidth={1}
|
borderWidth={1}
|
||||||
borderColor={mutedButtonBorder}
|
borderColor={mutedButtonBorder}
|
||||||
onPress={handleSwitchCamera}
|
onPress={handleSwitchCamera}
|
||||||
style={{ boxShadow: accessoryShadow }}
|
|
||||||
aria-label={t('upload.controls.switchCamera', 'Switch camera')}
|
aria-label={t('upload.controls.switchCamera', 'Switch camera')}
|
||||||
>
|
>
|
||||||
<RefreshCcw size={18} color={iconColor} />
|
<RefreshCcw size={20} color={iconColor} />
|
||||||
</Button>
|
</Button>
|
||||||
</XStack>
|
</XStack>
|
||||||
|
</YStack>
|
||||||
) : null}
|
) : null}
|
||||||
{(cameraState === 'ready' || cameraState === 'starting' || cameraState === 'preview') ? (
|
{(cameraState === 'ready' || cameraState === 'starting' || cameraState === 'preview') ? (
|
||||||
<Button
|
<Button
|
||||||
|
|||||||
Reference in New Issue
Block a user