mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-23 19:05:51 +00:00
Merge pull request #320 from cypherstack/simplex
Correct Simplex API URL and cleanup
This commit is contained in:
commit
97898d8769
19 changed files with 164 additions and 200 deletions
|
@ -7,19 +7,7 @@ class BuyFormState extends ChangeNotifier {
|
|||
Buy? get buy => _buy;
|
||||
set buy(Buy? value) {
|
||||
_buy = value;
|
||||
// _onBuyTypeChanged();
|
||||
}
|
||||
|
||||
bool reversed = false;
|
||||
|
||||
Future<void> updateEstimate({
|
||||
required bool shouldNotifyListeners,
|
||||
required bool reversed,
|
||||
}) async {
|
||||
// TODO implement updating estimaate based on changed selected crypto, fiat, etc
|
||||
}
|
||||
|
||||
Future<void> swap({dynamic? market}) async {
|
||||
// TODO implement swapping values on FiatOrCrypto toggle (or whatever it's called)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,21 +41,4 @@ class Crypto {
|
|||
|
||||
return map;
|
||||
}
|
||||
|
||||
Crypto copyWith({
|
||||
String? ticker,
|
||||
String? name,
|
||||
}) {
|
||||
return Crypto(
|
||||
ticker: ticker ?? this.ticker,
|
||||
name: name ?? this.name,
|
||||
network: network ?? this.network,
|
||||
contractAddress: contractAddress ?? this.contractAddress,
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return "Crypto: ${toJson()}";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,24 +8,24 @@ class Fiat {
|
|||
final String name;
|
||||
|
||||
/// Fiat name
|
||||
final Decimal min_amount;
|
||||
final Decimal minAmount;
|
||||
|
||||
/// Fiat name
|
||||
final Decimal max_amount;
|
||||
final Decimal maxAmount;
|
||||
|
||||
Fiat(
|
||||
{required this.ticker,
|
||||
required this.name,
|
||||
required this.min_amount,
|
||||
required this.max_amount});
|
||||
required this.minAmount,
|
||||
required this.maxAmount});
|
||||
|
||||
factory Fiat.fromJson(Map<String, dynamic> json) {
|
||||
try {
|
||||
return Fiat(
|
||||
ticker: "${json['ticker']}",
|
||||
name: "${json['name']}", // TODO nameFromTicker
|
||||
min_amount: Decimal.parse("${json['min_amount'] ?? 0}"),
|
||||
max_amount: Decimal.parse("${json['max_amount'] ?? 0}"),
|
||||
minAmount: Decimal.parse("${json['minAmount'] ?? 0}"),
|
||||
maxAmount: Decimal.parse("${json['maxAmount'] ?? 0}"),
|
||||
);
|
||||
} catch (e) {
|
||||
rethrow;
|
||||
|
@ -36,29 +36,10 @@ class Fiat {
|
|||
final map = {
|
||||
"ticker": ticker,
|
||||
"name": name,
|
||||
"min_amount": min_amount,
|
||||
"max_amount": max_amount,
|
||||
"min_amount": minAmount,
|
||||
"max_amount": maxAmount,
|
||||
};
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
Fiat copyWith({
|
||||
String? ticker,
|
||||
String? name,
|
||||
Decimal? min_amount,
|
||||
Decimal? max_amount,
|
||||
}) {
|
||||
return Fiat(
|
||||
ticker: ticker ?? this.ticker,
|
||||
name: name ?? this.name,
|
||||
min_amount: min_amount ?? this.min_amount,
|
||||
max_amount: max_amount ?? this.max_amount,
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return "Fiat: ${toJson()}";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,73 +0,0 @@
|
|||
import 'dart:ui';
|
||||
|
||||
import 'package:stackwallet/utilities/logger.dart';
|
||||
|
||||
class Pair {
|
||||
final String from;
|
||||
final String fromNetwork;
|
||||
|
||||
final String to;
|
||||
final String toNetwork;
|
||||
|
||||
final bool fixedRate;
|
||||
final bool floatingRate;
|
||||
|
||||
Pair({
|
||||
required this.from,
|
||||
required this.fromNetwork,
|
||||
required this.to,
|
||||
required this.toNetwork,
|
||||
required this.fixedRate,
|
||||
required this.floatingRate,
|
||||
});
|
||||
|
||||
factory Pair.fromMap(Map<String, dynamic> map) {
|
||||
try {
|
||||
return Pair(
|
||||
from: map["from"] as String,
|
||||
fromNetwork: map["fromNetwork"] as String,
|
||||
to: map["to"] as String,
|
||||
toNetwork: map["toNetwork"] as String,
|
||||
fixedRate: map["fixedRate"] as bool,
|
||||
floatingRate: map["floatingRate"] as bool,
|
||||
);
|
||||
} catch (e, s) {
|
||||
Logging.instance.log("Pair.fromMap(): $e\n$s", level: LogLevel.Error);
|
||||
rethrow;
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, dynamic> toMap() {
|
||||
return {
|
||||
"from": from,
|
||||
"fromNetwork": fromNetwork,
|
||||
"to": to,
|
||||
"toNetwork": toNetwork,
|
||||
"fixedRate": fixedRate,
|
||||
"floatingRate": floatingRate,
|
||||
};
|
||||
}
|
||||
|
||||
@override
|
||||
bool operator ==(other) =>
|
||||
other is Pair &&
|
||||
from == other.from &&
|
||||
fromNetwork == other.fromNetwork &&
|
||||
to == other.to &&
|
||||
toNetwork == other.toNetwork &&
|
||||
fixedRate == other.fixedRate &&
|
||||
floatingRate == other.floatingRate;
|
||||
|
||||
@override
|
||||
int get hashCode => hashValues(
|
||||
from,
|
||||
fromNetwork,
|
||||
to,
|
||||
toNetwork,
|
||||
fixedRate,
|
||||
floatingRate,
|
||||
);
|
||||
|
||||
@override
|
||||
String toString() => "Pair: ${toMap()}";
|
||||
}
|
|
@ -1,8 +1,8 @@
|
|||
import 'package:decimal/decimal.dart';
|
||||
import 'package:stackwallet/models/buy/response_objects/crypto.dart';
|
||||
import 'package:stackwallet/models/buy/response_objects/fiat.dart';
|
||||
import 'package:stackwallet/models/buy/response_objects/order.dart';
|
||||
import 'package:stackwallet/models/buy/response_objects/quote.dart';
|
||||
// import 'package:stackwallet/models/buy/response_objects/pair.dart';
|
||||
|
||||
class Simplex {
|
||||
List<Crypto> supportedCryptos = [];
|
||||
|
@ -17,6 +17,21 @@ class Simplex {
|
|||
receivingAddress: '',
|
||||
buyWithFiat: true,
|
||||
);
|
||||
SimplexOrder order = SimplexOrder(
|
||||
quote: SimplexQuote(
|
||||
crypto:
|
||||
Crypto.fromJson({'ticker': 'BTC', 'name': 'Bitcoin', 'image': ''}),
|
||||
fiat: Fiat.fromJson(
|
||||
{'ticker': 'USD', 'name': 'United States Dollar', 'image': ''}),
|
||||
youPayFiatPrice: Decimal.parse("100"),
|
||||
youReceiveCryptoAmount: Decimal.parse("1.0238917"),
|
||||
id: "someID",
|
||||
receivingAddress: '',
|
||||
buyWithFiat: true,
|
||||
),
|
||||
orderId: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee',
|
||||
paymentId: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee',
|
||||
userId: 'aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee');
|
||||
|
||||
void updateSupportedCryptos(List<Crypto> newCryptos) {
|
||||
supportedCryptos = newCryptos;
|
||||
|
@ -29,4 +44,8 @@ class Simplex {
|
|||
void updateQuote(SimplexQuote newQuote) {
|
||||
quote = newQuote;
|
||||
}
|
||||
|
||||
void updateOrder(SimplexOrder newOrder) {
|
||||
order = newOrder;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -77,9 +77,8 @@ class _BuyFormState extends ConsumerState<BuyForm> {
|
|||
Fiat? selectedFiat;
|
||||
Crypto? selectedCrypto;
|
||||
SimplexQuote quote = SimplexQuote(
|
||||
crypto: Crypto.fromJson({'ticker': 'BTC', 'name': 'Bitcoin', 'image': ''}),
|
||||
fiat: Fiat.fromJson(
|
||||
{'ticker': 'USD', 'name': 'United States Dollar', 'image': ''}),
|
||||
crypto: Crypto.fromJson({'ticker': 'BTC', 'name': 'Bitcoin'}),
|
||||
fiat: Fiat.fromJson({'ticker': 'USD', 'name': 'United States Dollar'}),
|
||||
youPayFiatPrice: Decimal.parse("100"),
|
||||
youReceiveCryptoAmount: Decimal.parse("1.0238917"),
|
||||
id: "someID",
|
||||
|
@ -685,13 +684,6 @@ class _BuyFormState extends ConsumerState<BuyForm> {
|
|||
.accentColorDark),
|
||||
),
|
||||
),
|
||||
// SvgPicture.asset(
|
||||
// Assets.svg.iconFor(
|
||||
// coin: coinFromTickerCaseInsensitive("BTC"),
|
||||
// ),
|
||||
// height: 18,
|
||||
// width: 18,
|
||||
// ),
|
||||
const SizedBox(
|
||||
width: 8,
|
||||
),
|
||||
|
|
|
@ -29,7 +29,18 @@ class BuyWarningPopup extends StatelessWidget {
|
|||
SimplexOrder? order;
|
||||
|
||||
Future<BuyResponse<SimplexOrder>> newOrder(SimplexQuote quote) async {
|
||||
return SimplexAPI.instance.newOrder(quote);
|
||||
final response = await SimplexAPI.instance.newOrder(quote);
|
||||
|
||||
// if (response.value != null) {
|
||||
// ref.read(simplexProvider).updateOrder(response.value!);
|
||||
// } else {
|
||||
// Logging.instance.log(
|
||||
// "_loadQuote: $response",
|
||||
// level: LogLevel.Warning,
|
||||
// );
|
||||
// }
|
||||
|
||||
return response;
|
||||
}
|
||||
|
||||
Future<BuyResponse<bool>> redirect(SimplexOrder order) async {
|
||||
|
|
|
@ -3,12 +3,11 @@ import 'package:flutter_riverpod/flutter_riverpod.dart';
|
|||
import 'package:stackwallet/pages/exchange_view/sub_widgets/exchange_rate_sheet.dart';
|
||||
import 'package:stackwallet/providers/providers.dart';
|
||||
import 'package:stackwallet/utilities/assets.dart';
|
||||
import 'package:stackwallet/utilities/constants.dart';
|
||||
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
||||
import 'package:stackwallet/utilities/util.dart';
|
||||
import 'package:stackwallet/widgets/toggle.dart';
|
||||
|
||||
import '../../../utilities/constants.dart';
|
||||
|
||||
class RateTypeToggle extends ConsumerWidget {
|
||||
const RateTypeToggle({
|
||||
Key? key,
|
||||
|
@ -37,10 +36,16 @@ class RateTypeToggle extends ConsumerWidget {
|
|||
}
|
||||
},
|
||||
isOn: !estimated,
|
||||
onColor: Theme.of(context).extension<StackColors>()!.textFieldDefaultBG,
|
||||
onColor: isDesktop
|
||||
? Theme.of(context)
|
||||
.extension<StackColors>()!
|
||||
.rateTypeToggleDesktopColorOn
|
||||
: Theme.of(context).extension<StackColors>()!.rateTypeToggleColorOn,
|
||||
offColor: isDesktop
|
||||
? Theme.of(context).extension<StackColors>()!.buttonBackSecondary
|
||||
: Theme.of(context).extension<StackColors>()!.popupBG,
|
||||
? Theme.of(context)
|
||||
.extension<StackColors>()!
|
||||
.rateTypeToggleDesktopColorOff
|
||||
: Theme.of(context).extension<StackColors>()!.rateTypeToggleColorOff,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(
|
||||
Constants.size.circularBorderRadius,
|
||||
|
|
|
@ -162,7 +162,9 @@ class _HomeViewButtonBarState extends ConsumerState<HomeViewButtonBar> {
|
|||
? Theme.of(context)
|
||||
.extension<StackColors>()!
|
||||
.buttonTextPrimary
|
||||
: Theme.of(context).extension<StackColors>()!.textDark,
|
||||
: Theme.of(context)
|
||||
.extension<StackColors>()!
|
||||
.buttonTextSecondary,
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
|
@ -43,15 +43,11 @@ class _DesktopBuyViewState extends State<DesktopBuyView> {
|
|||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
// Text(
|
||||
// "Coming soon",
|
||||
// style: STextStyles.desktopTextExtraExtraSmall(context),
|
||||
// ),
|
||||
const SizedBox(
|
||||
children: const [
|
||||
SizedBox(
|
||||
height: 16,
|
||||
),
|
||||
const RoundedWhiteContainer(
|
||||
RoundedWhiteContainer(
|
||||
padding: EdgeInsets.all(24),
|
||||
child: BuyForm(),
|
||||
),
|
||||
|
|
|
@ -1,44 +1,3 @@
|
|||
abstract class Buy {
|
||||
String get name;
|
||||
|
||||
// Future<BuyResponse<List<Currency>>> getAllCurrencies(bool fixedRate);
|
||||
//
|
||||
// Future<BuyResponse<List<Pair>>> getPairsFor(
|
||||
// String currency,
|
||||
// bool fixedRate,
|
||||
// );
|
||||
//
|
||||
// Future<BuyResponse<List<Pair>>> getAllPairs(bool fixedRate);
|
||||
//
|
||||
// Future<BuyResponse<Trade>> getTrade(String tradeId);
|
||||
// Future<BuyResponse<Trade>> updateTrade(Trade trade);
|
||||
//
|
||||
// Future<BuyResponse<List<Trade>>> getTrades();
|
||||
//
|
||||
// Future<BuyResponse<Range>> getRange(
|
||||
// String from,
|
||||
// String to,
|
||||
// bool fixedRate,
|
||||
// );
|
||||
//
|
||||
// Future<BuyResponse<Estimate>> getEstimate(
|
||||
// String from,
|
||||
// String to,
|
||||
// Decimal amount,
|
||||
// bool fixedRate,
|
||||
// bool reversed,
|
||||
// );
|
||||
//
|
||||
// Future<BuyResponse<Trade>> createTrade({
|
||||
// required String from,
|
||||
// required String to,
|
||||
// required bool fixedRate,
|
||||
// required Decimal amount,
|
||||
// required String addressTo,
|
||||
// String? extraId,
|
||||
// required String addressRefund,
|
||||
// required String refundExtraId,
|
||||
// String? rateId,
|
||||
// required bool reversed,
|
||||
// });
|
||||
}
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
// TODO use _buildUri
|
||||
|
||||
import 'dart:async';
|
||||
import 'dart:convert';
|
||||
|
||||
|
@ -16,7 +14,7 @@ import 'package:stackwallet/utilities/prefs.dart';
|
|||
import 'package:url_launcher/url_launcher.dart';
|
||||
|
||||
class SimplexAPI {
|
||||
static const String authority = "sandbox-api.stackwallet.com";
|
||||
static const String authority = "simplex-sandbox.stackwallet.com";
|
||||
// static const String authority = "localhost";
|
||||
static const String scheme = authority == "localhost" ? "http" : "https";
|
||||
|
||||
|
@ -137,8 +135,8 @@ class SimplexAPI {
|
|||
'ticker': "${fiat['ticker_symbol']}",
|
||||
'name': fiatFromTickerCaseInsensitive("${fiat['ticker_symbol']}")
|
||||
.prettyName,
|
||||
'min_amount': "${fiat['min_amount']}",
|
||||
'max_amount': "${fiat['max_amount']}",
|
||||
'minAmount': "${fiat['min_amount']}",
|
||||
'maxAmount': "${fiat['max_amount']}",
|
||||
'image': "",
|
||||
}));
|
||||
} // TODO handle else
|
||||
|
|
|
@ -220,9 +220,16 @@ abstract class StackColorTheme {
|
|||
Color get textConfirmTotalAmount;
|
||||
Color get textSelectedWordTableItem;
|
||||
|
||||
// rate type toggle
|
||||
Color get rateTypeToggleColorOn;
|
||||
Color get rateTypeToggleColorOff;
|
||||
Color get rateTypeToggleDesktopColorOn;
|
||||
Color get rateTypeToggleDesktopColorOff;
|
||||
|
||||
BoxShadow get standardBoxShadow;
|
||||
BoxShadow? get homeViewButtonBarBoxShadow;
|
||||
}
|
||||
// 0xFFFFD8CE
|
||||
|
||||
class CoinThemeColor {
|
||||
const CoinThemeColor();
|
||||
|
|
|
@ -319,6 +319,16 @@ class DarkColors extends StackColorTheme {
|
|||
@override
|
||||
Color get textSelectedWordTableItem => const Color(0xFF00297A);
|
||||
|
||||
//rate type toggle
|
||||
@override
|
||||
Color get rateTypeToggleColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleColorOff => popupBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOff => buttonBackSecondary;
|
||||
|
||||
@override
|
||||
BoxShadow get standardBoxShadow => BoxShadow(
|
||||
color: shadow,
|
||||
|
|
|
@ -319,6 +319,16 @@ class FruitSorbetColors extends StackColorTheme {
|
|||
@override
|
||||
Color get textSelectedWordTableItem => const Color(0xFF232323);
|
||||
|
||||
//rate type toggle
|
||||
@override
|
||||
Color get rateTypeToggleColorOn => const Color(0xFFFFD8CE);
|
||||
@override
|
||||
Color get rateTypeToggleColorOff => popupBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOn => const Color(0xFFFFD8CE);
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOff => buttonBackSecondary;
|
||||
|
||||
@override
|
||||
BoxShadow get standardBoxShadow => BoxShadow(
|
||||
color: shadow,
|
||||
|
|
|
@ -319,6 +319,16 @@ class LightColors extends StackColorTheme {
|
|||
@override
|
||||
Color get textSelectedWordTableItem => const Color(0xFF232323);
|
||||
|
||||
//rate type toggle
|
||||
@override
|
||||
Color get rateTypeToggleColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleColorOff => popupBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOff => buttonBackSecondary;
|
||||
|
||||
@override
|
||||
BoxShadow get standardBoxShadow => BoxShadow(
|
||||
color: shadow,
|
||||
|
|
|
@ -326,6 +326,16 @@ class OceanBreezeColors extends StackColorTheme {
|
|||
@override
|
||||
Color get textSelectedWordTableItem => const Color(0xFF232323);
|
||||
|
||||
//rate type toggle
|
||||
@override
|
||||
Color get rateTypeToggleColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleColorOff => popupBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOff => buttonBackSecondary;
|
||||
|
||||
@override
|
||||
BoxShadow get standardBoxShadow => BoxShadow(
|
||||
color: shadow,
|
||||
|
|
|
@ -321,6 +321,16 @@ class OledBlackColors extends StackColorTheme {
|
|||
@override
|
||||
Color get textSelectedWordTableItem => const Color(0xFF143D8E);
|
||||
|
||||
//rate type toggle
|
||||
@override
|
||||
Color get rateTypeToggleColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleColorOff => popupBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOn => textFieldDefaultBG;
|
||||
@override
|
||||
Color get rateTypeToggleDesktopColorOff => buttonBackSecondary;
|
||||
|
||||
@override
|
||||
BoxShadow get standardBoxShadow => BoxShadow(
|
||||
color: shadow,
|
||||
|
|
|
@ -178,6 +178,12 @@ class StackColors extends ThemeExtension<StackColors> {
|
|||
final Color textConfirmTotalAmount;
|
||||
final Color textSelectedWordTableItem;
|
||||
|
||||
// rate type toggle
|
||||
final Color rateTypeToggleColorOn;
|
||||
final Color rateTypeToggleColorOff;
|
||||
final Color rateTypeToggleDesktopColorOn;
|
||||
final Color rateTypeToggleDesktopColorOff;
|
||||
|
||||
final BoxShadow standardBoxShadow;
|
||||
final BoxShadow? homeViewButtonBarBoxShadow;
|
||||
|
||||
|
@ -319,6 +325,10 @@ class StackColors extends ThemeExtension<StackColors> {
|
|||
required this.myStackContactIconBG,
|
||||
required this.textConfirmTotalAmount,
|
||||
required this.textSelectedWordTableItem,
|
||||
required this.rateTypeToggleColorOn,
|
||||
required this.rateTypeToggleColorOff,
|
||||
required this.rateTypeToggleDesktopColorOn,
|
||||
required this.rateTypeToggleDesktopColorOff,
|
||||
required this.standardBoxShadow,
|
||||
required this.homeViewButtonBarBoxShadow,
|
||||
});
|
||||
|
@ -465,6 +475,10 @@ class StackColors extends ThemeExtension<StackColors> {
|
|||
myStackContactIconBG: colorTheme.myStackContactIconBG,
|
||||
textConfirmTotalAmount: colorTheme.textConfirmTotalAmount,
|
||||
textSelectedWordTableItem: colorTheme.textSelectedWordTableItem,
|
||||
rateTypeToggleColorOn: colorTheme.rateTypeToggleColorOn,
|
||||
rateTypeToggleColorOff: colorTheme.rateTypeToggleColorOff,
|
||||
rateTypeToggleDesktopColorOn: colorTheme.rateTypeToggleDesktopColorOn,
|
||||
rateTypeToggleDesktopColorOff: colorTheme.rateTypeToggleDesktopColorOff,
|
||||
homeViewButtonBarBoxShadow: colorTheme.homeViewButtonBarBoxShadow,
|
||||
standardBoxShadow: colorTheme.standardBoxShadow,
|
||||
);
|
||||
|
@ -609,6 +623,10 @@ class StackColors extends ThemeExtension<StackColors> {
|
|||
Color? myStackContactIconBG,
|
||||
Color? textConfirmTotalAmount,
|
||||
Color? textSelectedWordTableItem,
|
||||
Color? rateTypeToggleColorOn,
|
||||
Color? rateTypeToggleColorOff,
|
||||
Color? rateTypeToggleDesktopColorOn,
|
||||
Color? rateTypeToggleDesktopColorOff,
|
||||
BoxShadow? homeViewButtonBarBoxShadow,
|
||||
BoxShadow? standardBoxShadow,
|
||||
}) {
|
||||
|
@ -790,6 +808,14 @@ class StackColors extends ThemeExtension<StackColors> {
|
|||
textConfirmTotalAmount ?? this.textConfirmTotalAmount,
|
||||
textSelectedWordTableItem:
|
||||
textSelectedWordTableItem ?? this.textSelectedWordTableItem,
|
||||
rateTypeToggleColorOn:
|
||||
rateTypeToggleColorOn ?? this.rateTypeToggleColorOn,
|
||||
rateTypeToggleColorOff:
|
||||
rateTypeToggleColorOff ?? this.rateTypeToggleColorOff,
|
||||
rateTypeToggleDesktopColorOn:
|
||||
rateTypeToggleDesktopColorOn ?? this.rateTypeToggleDesktopColorOn,
|
||||
rateTypeToggleDesktopColorOff:
|
||||
rateTypeToggleDesktopColorOff ?? this.rateTypeToggleDesktopColorOff,
|
||||
homeViewButtonBarBoxShadow:
|
||||
homeViewButtonBarBoxShadow ?? this.homeViewButtonBarBoxShadow,
|
||||
standardBoxShadow: standardBoxShadow ?? this.standardBoxShadow,
|
||||
|
@ -1483,6 +1509,26 @@ class StackColors extends ThemeExtension<StackColors> {
|
|||
other.textSelectedWordTableItem,
|
||||
t,
|
||||
)!,
|
||||
rateTypeToggleColorOn: Color.lerp(
|
||||
rateTypeToggleColorOn,
|
||||
other.rateTypeToggleColorOn,
|
||||
t,
|
||||
)!,
|
||||
rateTypeToggleColorOff: Color.lerp(
|
||||
rateTypeToggleColorOff,
|
||||
other.rateTypeToggleColorOff,
|
||||
t,
|
||||
)!,
|
||||
rateTypeToggleDesktopColorOn: Color.lerp(
|
||||
rateTypeToggleDesktopColorOn,
|
||||
other.rateTypeToggleDesktopColorOn,
|
||||
t,
|
||||
)!,
|
||||
rateTypeToggleDesktopColorOff: Color.lerp(
|
||||
rateTypeToggleDesktopColorOff,
|
||||
other.rateTypeToggleDesktopColorOff,
|
||||
t,
|
||||
)!,
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue