feat: login whatever
This commit is contained in:
@ -12,6 +12,7 @@ import './index.less';
|
||||
interface IProps {
|
||||
title?: string;
|
||||
onCancel: () => void;
|
||||
disableCheck?: boolean;
|
||||
needPhone?: IPhoneButtonProps['needPhone'];
|
||||
onSuccess?: IPhoneButtonProps['onSuccess'];
|
||||
onBindPhone?: IPhoneButtonProps['onBindPhone'];
|
||||
@ -20,8 +21,15 @@ interface IProps {
|
||||
const PREFIX = 'login-dialog';
|
||||
|
||||
export default function LoginDialog(props: IProps) {
|
||||
const { title = '使用播络服务前,请先登录', needPhone, onSuccess, onCancel, onBindPhone } = props;
|
||||
const [checked, setChecked] = useState(false);
|
||||
const {
|
||||
title = '使用播络服务前,请先登录',
|
||||
disableCheck = false,
|
||||
needPhone,
|
||||
onSuccess,
|
||||
onCancel,
|
||||
onBindPhone,
|
||||
} = props;
|
||||
const [checked, setChecked] = useState(disableCheck);
|
||||
|
||||
const handleTipCheck = useCallback(() => {
|
||||
Toast.info('请先阅读并同意协议');
|
||||
@ -50,7 +58,9 @@ export default function LoginDialog(props: IProps) {
|
||||
<Button className={`${PREFIX}__cancel-button`} onClick={onCancel}>
|
||||
跳过,暂不登录
|
||||
</Button>
|
||||
<ProtocolPrivacyCheckbox checked={checked} onChange={setChecked} className={`${PREFIX}__checkbox`} />
|
||||
{!disableCheck && (
|
||||
<ProtocolPrivacyCheckbox checked={checked} onChange={setChecked} className={`${PREFIX}__checkbox`} />
|
||||
)}
|
||||
</div>
|
||||
</Dialog.Content>
|
||||
</Dialog>
|
||||
|
Reference in New Issue
Block a user