mirror of
https://github.com/stablyai/orca.git
synced 2026-10-24 16:03:45 +00:00
fix(mobile): align report error icon
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { Component, Fragment, type ErrorInfo, type ReactNode } from 'react'
|
||||
import { AlertTriangle, Bug, House, RefreshCw } from 'lucide-react-native'
|
||||
import { AlertTriangle, House, RefreshCw } from 'lucide-react-native'
|
||||
import { Pressable, StyleSheet, Text, View } from 'react-native'
|
||||
import { colors, radii, spacing, typography } from '../theme/mobile-theme'
|
||||
import {
|
||||
@@ -108,7 +108,7 @@ function MobileRootErrorFallback({
|
||||
style={styles.secondaryButton}
|
||||
onPress={onReport}
|
||||
>
|
||||
<Bug size={16} color={colors.textPrimary} />
|
||||
<AlertTriangle size={16} color={colors.textPrimary} />
|
||||
<Text style={styles.secondaryButtonText}>Report error</Text>
|
||||
</Pressable>
|
||||
</View>
|
||||
|
||||
@@ -24,7 +24,6 @@ vi.mock('react-native', () => ({
|
||||
}))
|
||||
vi.mock('lucide-react-native', () => ({
|
||||
AlertTriangle: 'AlertTriangle',
|
||||
Bug: 'Bug',
|
||||
House: 'House',
|
||||
RefreshCw: 'RefreshCw'
|
||||
}))
|
||||
@@ -126,6 +125,7 @@ describe('mobile root error boundary', () => {
|
||||
expect.objectContaining({ backgroundColor: colors.bgRaised })
|
||||
)
|
||||
expect(buttons[1]?.findByType('House').props.color).toBe(colors.textPrimary)
|
||||
expect(buttons[2]?.findByType('AlertTriangle').props.color).toBe(colors.textPrimary)
|
||||
|
||||
act(() => buttons[2]?.props.onPress())
|
||||
expect(mocks.shareDiagnostics).toHaveBeenCalledOnce()
|
||||
|
||||
Reference in New Issue
Block a user