feat : inspection

This commit is contained in:
2025-09-07 17:20:01 +03:30
parent 5281bcbea6
commit d914bf7f36
22 changed files with 10607 additions and 44 deletions

View File

@@ -19,6 +19,7 @@ class RElevated extends StatelessWidget {
this.isLoading = false,
this.child,
this.enabled = true,
this.progress = 0.0, // اضافه شد
}) : assert(text != null || child != null, 'Either text or child must be provided');
final String? text;
@@ -35,7 +36,7 @@ class RElevated extends StatelessWidget {
final TextStyle? textStyle;
final bool isLoading;
final bool enabled;
final double progress; // 0.0 تا 1.0
@override
Widget build(BuildContext context) {
final bool isEnabled = enabled && !isLoading;
@@ -59,6 +60,7 @@ class RElevated extends StatelessWidget {
child: CircularProgressIndicator(
strokeWidth: 2.5,
valueColor: AlwaysStoppedAnimation<Color>(foregroundColor),
value: progress > 0.0 && progress <= 1.0 ? progress : null,
),
)
: child ?? Text(text!),

View File

@@ -6,5 +6,5 @@ void getFileSizeInKB(String filePath, {String? tag}) {
final file = File(filePath);
final bytes = file.lengthSync();
var size = (bytes / 1024).ceil();
iLog('${tag ?? 'Picked'} image Size: $size');
iLog('${tag ?? 'Picked'} image Size: $size , fileName : ${file.path.split('/').last}');
}