about summary refs log tree commit diff
path: root/src/view/com/util/fab
diff options
context:
space:
mode:
authorSamuel Newman <mozzius@protonmail.com>2025-09-09 18:40:19 +0300
committerGitHub <noreply@github.com>2025-09-09 08:40:19 -0700
commit7574a745d17135b33a31e3fb7da8953ea378fe4c (patch)
treea6401caac8677e5810ceb19695d506bffa3d7dee /src/view/com/util/fab
parent53e43a957c2e0f3f020c34653cbf5029ec6dd8bb (diff)
downloadvoidsky-7574a745d17135b33a31e3fb7da8953ea378fe4c.tar.zst
Fix focus ring shapes (#9005)
* fix user avis being the wrong shape

* fix the fab being the wrong shape
Diffstat (limited to 'src/view/com/util/fab')
-rw-r--r--src/view/com/util/fab/FABInner.tsx15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/view/com/util/fab/FABInner.tsx b/src/view/com/util/fab/FABInner.tsx
index c2d64411a..53dac103f 100644
--- a/src/view/com/util/fab/FABInner.tsx
+++ b/src/view/com/util/fab/FABInner.tsx
@@ -1,5 +1,10 @@
 import {type ComponentProps, type JSX} from 'react'
-import {StyleSheet, type TouchableWithoutFeedback} from 'react-native'
+import {
+  type Pressable,
+  type StyleProp,
+  StyleSheet,
+  type ViewStyle,
+} from 'react-native'
 import Animated from 'react-native-reanimated'
 import {useSafeAreaInsets} from 'react-native-safe-area-context'
 import {LinearGradient} from 'expo-linear-gradient'
@@ -12,14 +17,15 @@ import {clamp} from '#/lib/numbers'
 import {gradients} from '#/lib/styles'
 import {isWeb} from '#/platform/detection'
 import {ios} from '#/alf'
+import {atoms as a} from '#/alf'
 
-export interface FABProps
-  extends ComponentProps<typeof TouchableWithoutFeedback> {
+export interface FABProps extends ComponentProps<typeof Pressable> {
   testID?: string
   icon: JSX.Element
+  style?: StyleProp<ViewStyle>
 }
 
-export function FABInner({testID, icon, onPress, ...props}: FABProps) {
+export function FABInner({testID, icon, onPress, style, ...props}: FABProps) {
   const insets = useSafeAreaInsets()
   const {isMobile, isTablet} = useWebMediaQueries()
   const playHaptic = useHaptics()
@@ -51,6 +57,7 @@ export function FABInner({testID, icon, onPress, ...props}: FABProps) {
           playHaptic('Heavy')
         })}
         targetScale={0.9}
+        style={[a.rounded_full, style]}
         {...props}>
         <LinearGradient
           colors={[gradients.blueLight.start, gradients.blueLight.end]}