import React from 'react'; import { View, Text, Modal, ScrollView, TouchableOpacity } from 'react-native'; import { X, Zap, RefreshCw } from 'lucide-react-native'; import { buyPro, restorePro, useProUnlock } from '../utils/proUnlock'; import { PRO_FRAMES } from '../utils/entitlement'; // The paywall. LITE keeps every look previewable and editable; this sheet is // the only place the tier is sold, and Google Play does the selling — the price // shown is the one Play returned for the product. // // Play requires a way back to an existing purchase on any screen that sells // one, so RESTORE is a peer of BUY, not a footnote. const PERKS = [ 'No RECIPESCAM mark on your exports', 'HDF effect', `${PRO_FRAMES.length} printed frames`, 'GPS location watermark', 'Every platform font for your watermark', 'Unlimited recipes and favorites', ]; export default function ProModal({ visible, onClose }: { visible: boolean; onClose: () => void }) { const { owned, price, busy, error } = useProUnlock(); if (!visible) return null; // see PhotoViewerModal return ( RECIPESCAM PRO One payment, kept on your Google account. Nothing to type in, and it comes back on every phone that has the app. {PERKS.map((p) => ( + {p} ))} {owned ? ( PRO ACTIVE Every look exports clean: no mark, no limits. ) : ( {busy ? 'CONTACTING GOOGLE PLAY…' : price ? `UNLOCK PRO — ${price}` : 'UNLOCK PRO'} )} RESTORE PURCHASES {error ? ( {error} ) : null} Bought already but the app still says LITE? Restore, or check that you are signed in to the Google account that paid. ); }