SimpleCloudNotifier/flutter/lib/pages/debug/debug_persistence_hiveentry.dart
2024-05-26 00:20:25 +02:00

30 lines
951 B
Dart

import 'package:flutter/material.dart';
import 'package:simplecloudnotifier/components/layout/scaffold.dart';
import 'package:simplecloudnotifier/state/interfaces.dart';
class DebugHiveEntryPage extends StatelessWidget {
final FieldDebuggable value;
final List<(String, String)> fields;
DebugHiveEntryPage({required this.value}) : fields = value.debugFieldList();
@override
Widget build(BuildContext context) {
return SCNScaffold(
title: 'HiveEntry',
showSearch: false,
showDebug: false,
child: ListView.separated(
itemCount: fields.length,
itemBuilder: (context, listIndex) {
return ListTile(
title: Text(fields[listIndex].$1, style: TextStyle(fontWeight: FontWeight.bold)),
subtitle: Text(fields[listIndex].$2, style: TextStyle(fontFamily: "monospace")),
);
},
separatorBuilder: (context, index) => Divider(),
),
);
}
}