fix: disk size display

This commit is contained in:
lollipopkit
2024-01-25 22:34:11 +08:00
parent 47560173f9
commit 9edbc5cc89
18 changed files with 46 additions and 43 deletions

View File

@@ -432,9 +432,7 @@ class _ServerPageState extends State<ServerPage>
return FadeTransition(opacity: animation, child: child);
},
child: _buildIOData(
isSpeed
? '${l10n.read}:\n$r'
: 'Total:\n${rootDisk?.size.kb2Str}',
isSpeed ? '${l10n.read}:\n$r' : 'Total:\n${rootDisk?.size.kb2Str}',
isSpeed ? '${l10n.write}:\n$w' : 'Used:\n${rootDisk?.usedPercent}%',
onTap: () {
cardNoti.value = cardNoti.value.copyWith(diskIO: !isSpeed);

View File

@@ -163,11 +163,11 @@ class _SnippetEditPageState extends State<SnippetEditPage>
${Snippet.fmtArgs.keys.map((e) => '`$e`').join(', ')}
''',
styleSheet: MarkdownStyleSheet(
codeblockDecoration: const BoxDecoration(
color: Colors.transparent,
),
),
styleSheet: MarkdownStyleSheet(
codeblockDecoration: const BoxDecoration(
color: Colors.transparent,
),
),
).padding(const EdgeInsets.all(13)),
);
}