import { Button } from '@tarojs/components'; import { Popup } from '@taroify/core'; import { useCallback } from 'react'; import { BindPhoneStatus } from '@/components/login-button'; import PhoneButton from '@/components/phone-button'; import { ProtocolPrivacy } from '@/components/protocol-privacy'; import SafeBottomPadding from '@/components/safe-bottom-padding'; import './index.less'; interface IProps { open: boolean; onCancel: () => void; onConfirm: () => void; needPhone?: boolean; } const PREFIX = 'agreement-popup'; export function AgreementPopup({ open, onCancel, onConfirm, needPhone }: IProps) { const handleBindPhone = useCallback( status => { if (status === BindPhoneStatus.Success) { onConfirm(); } else { onCancel(); } }, [onCancel, onConfirm] ); if (!open) { return null; } return (
提示
你好,以下是播络隐私协议与用户协议
同意后可使用全部功能,不同意你也可以浏览
{needPhone ? ( 同意 ) : ( )}
); }