phase3: pinput v5, late field fix, carousel nullable, badges badgeAnimation param. 251->242
This commit is contained in:
@@ -165,7 +165,7 @@ class ShopProductsState extends State<ShopProducts> {
|
|||||||
fontSize: 11.0,
|
fontSize: 11.0,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
animation: BadgeAnimation.scale(),
|
badgeAnimation: const BadgeAnimation.scale(),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -18,8 +18,8 @@ class Carousel extends StatefulWidget {
|
|||||||
animationDuration = animationDuration;
|
animationDuration = animationDuration;
|
||||||
|
|
||||||
final double height;
|
final double height;
|
||||||
final List<Widget> pages;
|
final List<Widget>? pages;
|
||||||
final bool autoPlay;
|
final bool? autoPlay;
|
||||||
final Duration duration;
|
final Duration duration;
|
||||||
final Duration animationDuration;
|
final Duration animationDuration;
|
||||||
|
|
||||||
@@ -106,7 +106,7 @@ class Indicator extends StatefulWidget {
|
|||||||
: count = count,
|
: count = count,
|
||||||
super(key: key);
|
super(key: key);
|
||||||
|
|
||||||
final int count;
|
final int? count;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
createState() => new IndicatorState();
|
createState() => new IndicatorState();
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ class ParabolicAnimationWidget extends AnimatedWidget {
|
|||||||
final Offset startAdjustOffset;
|
final Offset startAdjustOffset;
|
||||||
final Offset endAdjustOffset;
|
final Offset endAdjustOffset;
|
||||||
|
|
||||||
late ParabolicAnimationWidget({
|
ParabolicAnimationWidget({
|
||||||
required Animation<double> animation,
|
required Animation<double> animation,
|
||||||
required this.stackKey,
|
required this.stackKey,
|
||||||
required this.startKey,
|
required this.startKey,
|
||||||
@@ -22,8 +22,8 @@ class ParabolicAnimationWidget extends AnimatedWidget {
|
|||||||
this.endAdjustOffset = Offset.zero,
|
this.endAdjustOffset = Offset.zero,
|
||||||
}) : super(listenable: animation);
|
}) : super(listenable: animation);
|
||||||
|
|
||||||
Offset _startOffset;
|
late Offset _startOffset;
|
||||||
Offset _endOffset;
|
late Offset _endOffset;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
import '../utils/countdown.dart';
|
import '../../utils/countdown.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:pinput/pin_put/pin_put.dart';
|
import 'package:pinput/pinput.dart';
|
||||||
|
|
||||||
import '../../generated/l10n.dart';
|
import '../../generated/l10n.dart';
|
||||||
import '../../models/user.dart';
|
import '../../models/user.dart';
|
||||||
@@ -74,11 +74,11 @@ class PaymentVerificationCodeDialogState extends State<PaymentVerificationCodeDi
|
|||||||
Center(
|
Center(
|
||||||
child: Container(
|
child: Container(
|
||||||
padding: EdgeInsets.only(top: 0.0, bottom: 10.0, left: 0.0, right: 0.0),
|
padding: EdgeInsets.only(top: 0.0, bottom: 10.0, left: 0.0, right: 0.0),
|
||||||
child: PinPut(
|
child: Pinput(
|
||||||
fieldsCount: 4,
|
length: 4,
|
||||||
focusNode: _pinPutFocusNode,
|
focusNode: _pinPutFocusNode,
|
||||||
controller: _pinPutController,
|
controller: _pinPutController,
|
||||||
onSubmit: (String pin) {
|
onCompleted: (String pin) {
|
||||||
String codeString = generateSignature(pin, key: widget.user.id.toString());
|
String codeString = generateSignature(pin, key: widget.user.id.toString());
|
||||||
FocusScope.of(context).unfocus();
|
FocusScope.of(context).unfocus();
|
||||||
if (paymentCodeEncrypt == codeString) {
|
if (paymentCodeEncrypt == codeString) {
|
||||||
@@ -109,15 +109,8 @@ class PaymentVerificationCodeDialogState extends State<PaymentVerificationCodeDi
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
submittedFieldDecoration: _pinPutDecoration.copyWith(
|
defaultPinDecoration: _pinPutDecoration.copyWith(
|
||||||
borderRadius: BorderRadius.circular(20)),
|
borderRadius: BorderRadius.circular(20)),
|
||||||
selectedFieldDecoration: _pinPutDecoration,
|
|
||||||
followingFieldDecoration: _pinPutDecoration.copyWith(
|
|
||||||
borderRadius: BorderRadius.circular(5),
|
|
||||||
border: Border.all(
|
|
||||||
color: Colors.deepPurpleAccent.withOpacity(.5),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ class PopupAnimationWidget extends AnimatedWidget {
|
|||||||
final Offset popupOffset;
|
final Offset popupOffset;
|
||||||
final Animation<double> animation;
|
final Animation<double> animation;
|
||||||
|
|
||||||
late PopupAnimationWidget({
|
PopupAnimationWidget({
|
||||||
required this.animation,
|
required this.animation,
|
||||||
required this.stackKey,
|
required this.stackKey,
|
||||||
required this.startKey,
|
required this.startKey,
|
||||||
@@ -18,7 +18,7 @@ class PopupAnimationWidget extends AnimatedWidget {
|
|||||||
this.popupOffset = Offset.zero,
|
this.popupOffset = Offset.zero,
|
||||||
}) : super(listenable: animation);
|
}) : super(listenable: animation);
|
||||||
|
|
||||||
Offset _startOffset;
|
late Offset _startOffset;
|
||||||
Offset _offset = Offset.zero;
|
Offset _offset = Offset.zero;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
|
|||||||
@@ -1188,7 +1188,7 @@ class ShopState extends State<Shop>
|
|||||||
fontSize: 11.0,
|
fontSize: 11.0,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
animation: BadgeAnimation.scale(),
|
badgeAnimation: const BadgeAnimation.scale(),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user