feat: ajout de serveurs depuis l'app + charte flamme sombre
Build APK / build (push) Successful in 2m49s
Build APK / build (push) Successful in 2m49s
- backend: GET /api/containers (liste lisible), POST/DELETE /api/servers (serveurs custom persistés en /data/servers.json, mergés aux intégrés), champ custom dans le statut. - app: écran AddServer (form + sélecteur multi-conteneurs filtrable), FAB Ajouter, suppression depuis le détail (serveurs custom only). - thème: palette flamme/chaud sombre (anthracite + orange→rouge), remplace le Material violet/teal par défaut (scaffold, appbar, tabs, boutons, FAB, champs). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
fb4ab95f13
commit
30786f9706
@@ -7,6 +7,7 @@ import '../services/api_service.dart';
|
||||
import '../services/auth_service.dart';
|
||||
import '../services/update_service.dart';
|
||||
import '../widgets/server_card.dart';
|
||||
import 'add_server_screen.dart';
|
||||
import 'server_detail_screen.dart';
|
||||
import 'settings_screen.dart';
|
||||
|
||||
@@ -159,10 +160,21 @@ class _ServersScreenState extends State<ServersScreen> {
|
||||
),
|
||||
),
|
||||
body: _buildBody(),
|
||||
floatingActionButton: FloatingActionButton.extended(
|
||||
onPressed: _openAdd,
|
||||
icon: const Icon(Icons.add),
|
||||
label: const Text('Ajouter'),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Future<void> _openAdd() async {
|
||||
final added = await Navigator.push<bool>(context,
|
||||
MaterialPageRoute(builder: (_) => AddServerScreen(api: widget.api)));
|
||||
if (added == true) _refresh();
|
||||
}
|
||||
|
||||
Widget _buildBody() {
|
||||
if (_error != null && _servers == null) {
|
||||
return ListView(children: [
|
||||
|
||||
Reference in New Issue
Block a user