You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
import 'dart:io';
import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; import 'package:loading_animations/loading_animations.dart'; import 'package:lottie/lottie.dart'; import 'package:sonnat/core/extensions/number_extension.dart'; import 'package:sonnat/core/theme/app_colors.dart';
class GlobalLoading extends StatelessWidget { final bool isSmallSize;
const GlobalLoading({super.key, this.isSmallSize = false});
@override Widget build(BuildContext context) { return SizedBox( height: isSmallSize ? 0.25.sw : 1.sh, child: Column( children: [ if (!kIsWeb && Platform.isIOS && !isSmallSize) const Row( mainAxisAlignment: MainAxisAlignment.start, children: [ BackButton( color: Colors.white, ), ], ), Expanded( child: Center( child: Column( mainAxisAlignment: MainAxisAlignment.center, children: [ if (!isSmallSize) Lottie.asset( 'assets/images/loading.json', height: 0.25.sw, fit: BoxFit.scaleDown, ), if (isSmallSize) LoadingBumpingLine.circle( size: 30.h, backgroundColor: AppColors.gray, ), ], ), ), ), ], ), ); } }
|