refactor: linting de widgets de layout y utilidades

Ajustes de estilo/linting en los helpers centered* de layout,
appIntroPage, roundedButton, secretLoader y utils (refactor pendiente).
This commit is contained in:
vjrj 2026-07-12 23:26:43 +02:00
parent 9b0fe987f8
commit 51fe8c6431
15 changed files with 141 additions and 126 deletions

View file

@ -5,13 +5,13 @@ import 'package:flutter/services.dart' show rootBundle;
class SecretLoader {
final String secretPath;
SecretLoader({this.secretPath});
SecretLoader({required this.secretPath});
Future<Map<String, dynamic>> load() {
rootBundle.loadString(secretPath, cache: false);
return rootBundle.loadStructuredData<Map<String, dynamic>>(this.secretPath,
return rootBundle.loadStructuredData<Map<String, dynamic>>(secretPath,
(jsonStr) async {
return json.decode(jsonStr);
});
}
}
}

View file

@ -8,4 +8,4 @@ bool notNull(Object o) => o != null;
List<Widget> listWithoutNulls(List<Widget> children) =>
children.where(notNull).toList();
ellipse(String s,[ int end = 4]) => s != null ? s.substring(0, end) + '...' : null;
ellipse(String s,[ int end = 4]) => s.substring(0, end) + '...';