feat: Propagate user profile updates to group member details and remove trip code sharing UI.
Some checks failed
Deploy to Play Store / build_and_deploy (push) Has been cancelled
Some checks failed
Deploy to Play Store / build_and_deploy (push) Has been cancelled
This commit is contained in:
@@ -3,9 +3,33 @@ import 'package:travel_mate/components/settings/policies/policies_content.dart';
|
||||
import 'theme/settings_theme_content.dart';
|
||||
import 'profile/profile_content.dart';
|
||||
|
||||
class SettingsContent extends StatelessWidget {
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
|
||||
class SettingsContent extends StatefulWidget {
|
||||
const SettingsContent({super.key});
|
||||
|
||||
@override
|
||||
State<SettingsContent> createState() => _SettingsContentState();
|
||||
}
|
||||
|
||||
class _SettingsContentState extends State<SettingsContent> {
|
||||
String _version = '...';
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_loadVersion();
|
||||
}
|
||||
|
||||
Future<void> _loadVersion() async {
|
||||
final packageInfo = await PackageInfo.fromPlatform();
|
||||
if (mounted) {
|
||||
setState(() {
|
||||
_version = packageInfo.version;
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> changePage(BuildContext context, Widget page) async {
|
||||
Navigator.push(context, MaterialPageRoute(builder: (context) => page));
|
||||
}
|
||||
@@ -70,7 +94,7 @@ class SettingsContent extends StatelessWidget {
|
||||
),
|
||||
const SizedBox(height: 4),
|
||||
Text(
|
||||
'1.0.0',
|
||||
_version,
|
||||
style: TextStyle(fontSize: 14, color: Colors.grey[500]),
|
||||
),
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user