feat: 分享的文案 + 点击头像看模卡 + 提现文案 + 协议弹窗 + 进群限制

This commit is contained in:
chashaobao
2025-06-17 00:03:58 +08:00
parent 828497fcd6
commit 0ec366cc2e
14 changed files with 140 additions and 100 deletions

View File

@ -1,4 +1,4 @@
import { Button } from '@tarojs/components';
import { Button, ITouchEvent } from '@tarojs/components';
import { Popup } from '@taroify/core';
import { useCallback } from 'react';
@ -13,17 +13,18 @@ import './index.less';
interface IProps {
open: boolean;
onCancel: () => void;
onConfirm: () => void;
onConfirm: (e: ITouchEvent) => void;
needPhone?: boolean;
needBindPhone?: boolean;
}
const PREFIX = 'agreement-popup';
export function AgreementPopup({ open, onCancel, onConfirm, needPhone }: IProps) {
export function AgreementPopup({ open, onCancel, onConfirm, needPhone, needBindPhone }: IProps) {
const handleBindPhone = useCallback(
status => {
(status: BindPhoneStatus, e: ITouchEvent) => {
if (status === BindPhoneStatus.Success) {
onConfirm();
onConfirm(e);
} else {
onCancel();
}
@ -48,8 +49,8 @@ export function AgreementPopup({ open, onCancel, onConfirm, needPhone }: IProps)
<Button className={`${PREFIX}__cancel-button`} onClick={onCancel}>
</Button>
{needPhone ? (
<PhoneButton className={`${PREFIX}__confirm-button`} needPhone onBindPhone={handleBindPhone}>
{needBindPhone ? (
<PhoneButton className={`${PREFIX}__confirm-button`} needPhone={needPhone} onBindPhone={handleBindPhone}>
</PhoneButton>
) : (