opt.: l10n & fix: write script (#514)

This commit is contained in:
lollipopkit🏳️‍⚧️
2024-08-03 22:44:21 +08:00
committed by GitHub
parent 610f46da0d
commit 9db04a60c2
55 changed files with 686 additions and 2201 deletions

View File

@@ -17,9 +17,7 @@ class _ServerDetailOrderPageState extends State<ServerDetailOrderPage> {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: CustomAppBar(
title: Text(l10n.serverDetailOrder),
),
appBar: CustomAppBar(title: Text(l10n.serverDetailOrder)),
body: _buildBody(),
);
}
@@ -52,7 +50,7 @@ class _ServerDetailOrderPageState extends State<ServerDetailOrderPage> {
itemCount: allKeys.length,
onReorder: (o, n) {
if (o >= keys.length || n >= keys.length) {
context.showSnackBar(l10n.disabled);
context.showSnackBar(libL10n.disabled);
return;
}
keys.moveByItem(o, n, property: prop);

View File

@@ -17,9 +17,7 @@ class _ServerDetailOrderPageState extends State<ServerFuncBtnsOrderPage> {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: CustomAppBar(
title: Text(l10n.sequence),
),
appBar: CustomAppBar(title: Text(l10n.sequence)),
body: _buildBody(),
);
}
@@ -57,7 +55,7 @@ class _ServerDetailOrderPageState extends State<ServerFuncBtnsOrderPage> {
itemCount: allKeys.length,
onReorder: (o, n) {
if (o >= keys.length || n >= keys.length) {
context.showSnackBar(l10n.disabled);
context.showSnackBar(libL10n.disabled);
return;
}
keys.moveByItem(o, n, property: prop);

View File

@@ -16,9 +16,7 @@ class _ServerOrderPageState extends State<ServerOrderPage> {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: CustomAppBar(
title: Text(l10n.serverOrder),
),
appBar: CustomAppBar(title: Text(l10n.serverOrder)),
body: _buildBody(),
);
}
@@ -48,7 +46,7 @@ class _ServerOrderPageState extends State<ServerOrderPage> {
Widget _buildBody() {
if (Pros.server.serverOrder.isEmpty) {
return Center(child: Text(l10n.noServerAvailable));
return Center(child: Text(libL10n.empty));
}
return ReorderableListView.builder(
footer: const SizedBox(height: 77),

View File

@@ -17,9 +17,7 @@ class _SSHVirtKeySettingPageState extends State<SSHVirtKeySettingPage> {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: CustomAppBar(
title: Text(l10n.editVirtKeys),
),
appBar: CustomAppBar(title: Text(l10n.editVirtKeys)),
body: Column(
children: [
Padding(
@@ -67,7 +65,7 @@ class _SSHVirtKeySettingPageState extends State<SSHVirtKeySettingPage> {
itemCount: allKeys.length,
onReorder: (o, n) {
if (o >= keys.length || n >= keys.length) {
context.showSnackBar(l10n.disabled);
context.showSnackBar(libL10n.disabled);
return;
}
keys.moveByItem(o, n, property: prop);