opt: check `private key` size
opt: expand key list in default
This commit is contained in:
lollipopkit
2023-02-17 16:49:41 +08:00
parent 0c198c23fc
commit 558721fa79
6 changed files with 16 additions and 39 deletions

View File

@@ -10,7 +10,6 @@ import '../../data/model/app/dynamic_color.dart';
import '../../data/model/app/navigation_item.dart';
import '../../data/provider/server.dart';
import '../../data/res/build_data.dart';
import '../../data/res/color.dart';
import '../../data/res/font_style.dart';
import '../../data/res/icon.dart';
import '../../data/res/tab.dart';
@@ -284,7 +283,7 @@ class _MyHomePageState extends State<MyHomePage>
ConstrainedBox(
constraints: const BoxConstraints(maxHeight: 53, maxWidth: 53),
child: Container(
color: primaryColor,
color: Colors.white,
),
),
ConstrainedBox(

View File

@@ -244,7 +244,6 @@ class _ServerDetailPageState extends State<ServerDetailPage>
Widget _buildSwapView(ServerStatus ss) {
if (ss.swap.total == 0) return const SizedBox();
final used = ss.swap.used / ss.swap.total * 100;
final free = ss.swap.free / ss.swap.total * 100;
final cached = ss.swap.cached / ss.swap.total * 100;
return RoundRectCard(
Padding(
@@ -264,13 +263,7 @@ class _ServerDetailPageState extends State<ServerDetailPage>
style: textSize13Grey)
],
),
Row(
children: [
_buildDetailPercent(free, 'free'),
width13,
_buildDetailPercent(cached, 'cached')
],
),
_buildDetailPercent(cached, 'cached'),
],
),
height13,

View File

@@ -205,6 +205,7 @@ class _ServerEditPageState extends State<ServerEditPage> with AfterLayoutMixin {
iconColor: primaryColor,
tilePadding: EdgeInsets.zero,
childrenPadding: EdgeInsets.zero,
initiallyExpanded: true,
title: Text(
_s.choosePrivateKey,
style: const TextStyle(fontSize: 14),