import 'package:cpt_auth/modules/sing_up_success/sign_up_success_full_screen.dart';
import 'package:cs_resources/generated/assets.dart';
import 'package:cs_resources/generated/l10n.dart';
import 'package:cs_resources/theme/app_colors_theme.dart';
import 'package:flutter/material.dart';
import 'package:auto_route/auto_route.dart';
import 'package:hooks_riverpod/hooks_riverpod.dart';
import 'package:router/ext/auto_router_extensions.dart';
import 'package:widgets/my_appbar.dart';
import 'package:widgets/responsive_widget.dart';
import '../../router/page/auth_page_router.dart';
import 'sign_up_success_small_screen.dart';

@RoutePage()
class SignUpSuccessPage extends HookConsumerWidget {
  const SignUpSuccessPage({Key? key}) : super(key: key);

  //启动当前页面
  static void startInstance({BuildContext? context}) {
    if (context != null) {
      context.router.popAndPush(const SignUpSuccessPageRoute());
    } else {
      appRouter.popAndPush(const SignUpSuccessPageRoute());
    }
  }

  @override
  Widget build(BuildContext context, WidgetRef ref) {
    return Scaffold(
      appBar: MyAppBar.appBar(context, ""),
      backgroundColor: context.appColors.backgroundDefault,
      body: const ResponsiveWidget(
        smallScreen: SignUpSuccessSmallScreen(),
        smallFullScreen: SignUpSuccessFullScreen(),
      ),
    );
  }
}
