This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:kartal/kartal.dart'; | |
class AnimatedPageSwitch extends StatelessWidget { | |
const AnimatedPageSwitch( | |
{super.key, | |
required this.isPageLoaded, | |
required this.loaderChild, | |
required this.completedChild}); | |
final bool isPageLoaded; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class BaseFirebaseModel<T> { | |
final String id; | |
final T? data; | |
BaseFirebaseModel({ | |
required this.id, | |
required this.data, | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
enum Durations { | |
low(Duration(milliseconds: 500)), | |
normal(Duration(seconds: 1)), | |
high(Duration(seconds: 3)); | |
final Duration value; | |
const Durations(this.value); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension StringBoolExtension on String { | |
bool get isTrue => bool.fromEnvironment(this); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:dio/dio.dart'; | |
enum QueryValues { | |
version, | |
platform, | |
page, | |
pageSize; | |
MapEntry<String, String> toEntry(String value) { | |
return MapEntry(name, value); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:async/async.dart'; | |
class CancelableCustomOperation<T> { | |
CancelableOperation<T?>? _cancellableOperation; | |
final _delayTime = const Duration(milliseconds: 300); | |
final void Function(T value) onChanged; | |
T? data; | |
CancelableCustomOperation( | |
this.onChanged, { | |
this.data, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if [ "$1" = "force" ] | |
then | |
flutter packages pub run build_runner build --delete-conflicting-outputs | |
else | |
flutter packages pub run build_runner build | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
part 'module/home_appbar.dart'; | |
part 'module/home_body.dart'; | |
part 'module/home_bottom_bar.dart'; | |
class HomeView extends StatelessWidget { | |
const HomeView({super.key}); | |
@override |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:io'; | |
import 'package:url_launcher/url_launcher.dart'; | |
mixin GalleryLaunch { | |
final String _iosPhotoScheme = 'photos-redirect://'; | |
final String _androidPhotoScheme = 'content://media/external/images/media'; | |
/// It'll be open gallery on device | |
/// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
include: package:very_good_analysis/analysis_options.yaml | |
analyzer: | |
exclude: | |
- lib/product/init/language/ | |
- lib/product/init/generation/ | |
- "**/*.g.dart" | |
- "**/*.freezed.dart" | |
- "test/.test_coverage.dart" | |
- "bin/cache/**" |