feat: integrate invite API and improve notification handling
- Add invite code display and binding functionality via API - Fix notification unread count sync on auth state change - Improve notification mark read with server state validation - Add auth state listener to trigger notification refresh - Add YaoCoinConverter for coin-to-yao type conversion - Remove YaoLegend from divination screens (UI cleanup) - Abbreviate relation labels in yao detail view - Add re-register notice to account delete screen - Update 'coins' terminology to 'points' in localization - Fix backend points consumption to only run in CHAT mode - Add HttpxAuthNoiseFilter to suppress auth endpoint logging - Fix notification static_schema import path - Add test coverage for notification bloc error handling - Update AGENTS.md page header rules and image handling - Delete deprecated run-dev.sh script
This commit is contained in:
@@ -14,7 +14,6 @@ import '../../../../shared/widgets/app_modal_dialog.dart';
|
||||
import '../../../../shared/widgets/gua_icon.dart';
|
||||
import '../../../../shared/widgets/divination/divination_shared_widgets.dart';
|
||||
import '../../../../shared/widgets/divination/divination_terms.dart';
|
||||
import '../../../../shared/widgets/divination/yao_legend.dart';
|
||||
import '../../../../shared/widgets/divination/yao_line_row.dart';
|
||||
import '../../../../shared/widgets/date_time_picker/date_time_picker_bottom_sheet.dart';
|
||||
import '../../../../shared/widgets/toast/toast.dart';
|
||||
@@ -23,6 +22,7 @@ import '../../data/models/divination_backend_models.dart';
|
||||
import '../../data/apis/divination_api.dart';
|
||||
import '../../data/models/divination_params.dart';
|
||||
import '../../data/models/divination_result.dart';
|
||||
import '../../data/models/yao_coin_converter.dart';
|
||||
import '../../data/services/divination_run_service.dart';
|
||||
import 'divination_processing_screen.dart';
|
||||
|
||||
@@ -287,14 +287,8 @@ class _AutoDivinationScreenState extends State<AutoDivinationScreen>
|
||||
final c1 = _random.nextBool();
|
||||
final c2 = _random.nextBool();
|
||||
final c3 = _random.nextBool();
|
||||
final yangCount = [c1, c2, c3].where((v) => v).length;
|
||||
final yao = switch (yangCount) {
|
||||
0 => YaoType.oldYin,
|
||||
1 => YaoType.youngYang,
|
||||
2 => YaoType.youngYin,
|
||||
3 => YaoType.oldYang,
|
||||
_ => YaoType.undetermined,
|
||||
};
|
||||
final ziCount = [c1, c2, c3].where((v) => v).length;
|
||||
final yao = YaoCoinConverter.fromZiCount(ziCount);
|
||||
setState(() {
|
||||
_isSpinning = false;
|
||||
_coin1Yang = c1;
|
||||
@@ -737,7 +731,6 @@ class _HexagramCard extends StatelessWidget {
|
||||
const SizedBox(height: AppSpacing.md),
|
||||
for (int i = 5; i >= 0; i--) _YaoRow(index: i, type: yaoStates[i]),
|
||||
const SizedBox(height: AppSpacing.xs),
|
||||
const Align(alignment: Alignment.centerLeft, child: YaoLegend()),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user