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 InAppPurchaseService { | |
static const premiumPermissionId = 'premium'; | |
static const androidLifetimeProductId = 'lifetime_access'; | |
static const androidMonthlyProductId = 'android_premium_monthly_3.99_30days_0:0'; | |
static const androidYearlyProductId = 'android_paper_premium_yearly_45_30days_0:0'; | |
static const iosLifetimeProductId = 'lifetime_access'; | |
static const iosMonthlyProductId = 'ios_premium_monthly_3.99_30days_0'; | |
static const iosYearlyProductId = 'ios_paper_premium_yearly_45_30days_0'; |
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
/// packages: | |
/// google_sign_in: ^6.2.1 | |
/// sign_in_with_apple: ^6.1.1 | |
/// crypto: ^3.0.3 | |
const appleAuthProviderID = 'apple.com'; | |
const googleAuthProviderID = 'google.com'; | |
class AuthService { | |
final GoogleSignIn _googleSignIn; |
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 InAppPurchaseService { | |
Future<void> init() async { | |
try { | |
await Glassfy.initialize( | |
Environment.glassfyApiKey, | |
watcherMode: kDebugMode, | |
); | |
} catch (e, trace) { | |
log('Glassfy init failed', error: e); | |
Sentry.captureException(e, stackTrace: trace); |
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'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
final double _progress = .5; | |
@override | |
Widget build(BuildContext context) { |
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:math'; | |
import 'package:flutter/material.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { |
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 'dart:math'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { |
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'; | |
void main() { | |
runApp(const MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
const MyApp({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:async'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/services.dart'; | |
/// Flutter widget to execute asynchronous operations before a page is popped | |
/// Uses Flutter 3.16.x's PopScope attribute | |
class PopConfirm extends StatefulWidget { | |
const PopConfirm({ | |
super.key, |
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'; | |
class LifecycleWatcher extends StatefulWidget { | |
const LifecycleWatcher({ | |
super.key, | |
required this.child, | |
this.onResume, | |
this.onPause, | |
this.onInactive, | |
this.onHide, |
NewerOlder