me_page.dart 1.0 KB

1234567891011121314151617181920212223242526272829303132333435
  1. import 'package:flutter/material.dart';
  2. import 'package:auto_route/auto_route.dart';
  3. import 'package:plugin_basic/modules/global_web_page.dart';
  4. import 'package:router/componentRouter/component_service_manager.dart';
  5. @RoutePage()
  6. class MePage extends StatelessWidget {
  7. const MePage({Key? key}) : super(key: key);
  8. @override
  9. Widget build(BuildContext context) {
  10. return Scaffold(
  11. appBar: AppBar(title: Text("Me")),
  12. body:Center(
  13. child: Column(
  14. children: [
  15. ElevatedButton(
  16. onPressed: () {
  17. ComponentServiceManager().profileService.startEditProfilePage(context: context);
  18. },
  19. child: const Text('Go to Edit Profile Page'),
  20. ),
  21. ElevatedButton(
  22. onPressed: () {
  23. GlobalWebPage.startInstance(context: context, title: "baidu", url: "https://www.baidu.com");
  24. },
  25. child: const Text('Go to Global Web Page'),
  26. ),
  27. ],
  28. ),
  29. ),
  30. );
  31. }
  32. }