feat:参照研听的基础工程

This commit is contained in:
jingyun
2026-06-18 15:02:28 +08:00
commit 364fc837b3
367 changed files with 16495 additions and 0 deletions
@@ -0,0 +1,42 @@
import '../../../common/domain/metal_type.dart';
enum PriceColorMode {
redUpGreenDown('红涨绿跌'),
greenUpRedDown('绿涨红跌');
const PriceColorMode(this.label);
final String label;
}
class ProfileSettings {
const ProfileSettings({
required this.amountHidden,
required this.recycleDiscounts,
required this.purityPresets,
required this.priceColorMode,
required this.mockLoggedIn,
});
final bool amountHidden;
final Map<MetalType, double> recycleDiscounts;
final Map<String, double> purityPresets;
final PriceColorMode priceColorMode;
final bool mockLoggedIn;
ProfileSettings copyWith({
bool? amountHidden,
Map<MetalType, double>? recycleDiscounts,
Map<String, double>? purityPresets,
PriceColorMode? priceColorMode,
bool? mockLoggedIn,
}) {
return ProfileSettings(
amountHidden: amountHidden ?? this.amountHidden,
recycleDiscounts: recycleDiscounts ?? this.recycleDiscounts,
purityPresets: purityPresets ?? this.purityPresets,
priceColorMode: priceColorMode ?? this.priceColorMode,
mockLoggedIn: mockLoggedIn ?? this.mockLoggedIn,
);
}
}