flutter_clock_example/lib/settings_page.dart
Hubert Chen 524eab7442
chore: 🚚 move tab list
`home`: 🚚 move tab list
`constants`, `settings_page`: 📝 add comments
2023-09-05 22:51:59 +08:00

42 lines
1.0 KiB
Dart

import 'package:flutter/material.dart';
import 'constants.dart';
class SettingsPage extends StatefulWidget {
const SettingsPage({super.key});
@override
_SettingsPageState createState() => _SettingsPageState();
}
class _SettingsPageState extends State<SettingsPage> {
@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const Text(
'General',
style: TextStyle(
fontSize: 18,
fontWeight: FontWeight.bold,
),
),
SwitchListTile(
// Currently unavailable
title: const Text('Dark Mode'),
value: switchTheme,
shape: RoundedRectangleBorder(borderRadius: myBorderRadius),
onChanged: (value) {
setState(() {
switchTheme = value;
});
},
),
],
),
);
}
}