import { BlurView } from "expo-blur"; import type { ReactNode } from "react"; import { Platform, StyleSheet, View, type StyleProp, type ViewStyle } from "react-native"; import { useAppTheme } from "@/contexts/ThemeContext"; import { blurIntensity, radius, shadowMd, shadowSm } from "@/lib/beenvoice-theme"; type GlassSurfaceProps = { children: ReactNode; style?: StyleProp; radius?: number; variant?: "card" | "stat"; }; export function GlassSurface({ children, style, radius: cornerRadius = radius.lg, variant = "card", }: GlassSurfaceProps) { const { colors, isDark } = useAppTheme(); const flat = StyleSheet.flatten(style); const isStat = variant === "stat"; return ( {Platform.OS === "ios" ? ( ) : null} {children} ); } export function GlassChrome({ children, style, radius: cornerRadius = 0, }: { children?: ReactNode; style?: StyleProp; radius?: number; }) { const { colors, isDark } = useAppTheme(); return ( {Platform.OS === "ios" ? ( ) : null} {children ? {children} : null} ); } const styles = StyleSheet.create({ shell: { overflow: "hidden", borderWidth: StyleSheet.hairlineWidth * 2, backgroundColor: "transparent", }, statShell: { borderWidth: 0, }, chromeShell: { overflow: "hidden", }, fill: { ...StyleSheet.absoluteFill, }, content: { position: "relative", zIndex: 2, }, });