|
@@ -21,12 +21,12 @@ export interface RechargeContentProps {
|
|
|
type?: "page" | "popup";
|
|
|
}
|
|
|
|
|
|
-export function Timeout(props: { endTime: number; className?: string }) {
|
|
|
- const { endTime, className } = props;
|
|
|
+export function Timeout(props: { endTime: number; className?: string; onEndHandler?: () => void }) {
|
|
|
+ const { endTime, className, onEndHandler } = props;
|
|
|
const [countdown, time] = useCountDown({
|
|
|
targetDate: endTime * 1000,
|
|
|
onEnd: () => {
|
|
|
- console.log(`🚀🚀🚀🚀🚀-> in UserRecharge.tsx on 26 倒计时拘束`);
|
|
|
+ onEndHandler && onEndHandler();
|
|
|
},
|
|
|
});
|
|
|
const cls = clsx(
|