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:
@@ -10,7 +10,6 @@ import '../../../../shared/theme/app_color_palette.dart';
|
||||
import '../../../../shared/theme/design_tokens.dart';
|
||||
import '../../../../shared/widgets/divination/divination_terms.dart';
|
||||
import '../../../../shared/widgets/divination/yao_glyph.dart';
|
||||
import '../../../../shared/widgets/divination/yao_legend.dart';
|
||||
import '../../../../shared/widgets/toast/toast.dart';
|
||||
import '../../../../shared/widgets/toast/toast_type.dart';
|
||||
import '../../data/apis/divination_api.dart';
|
||||
@@ -926,11 +925,6 @@ class _HexagramDetailCard extends StatelessWidget {
|
||||
showTarget:
|
||||
data.hasChangingYao && idx < data.targetYaoLines.length,
|
||||
),
|
||||
const SizedBox(height: AppSpacing.sm),
|
||||
const Align(
|
||||
alignment: Alignment.centerLeft,
|
||||
child: YaoLegend(),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -1156,7 +1150,10 @@ class _YaoDetailRow extends StatelessWidget {
|
||||
),
|
||||
SizedBox(
|
||||
width: 28,
|
||||
child: Text(data.relation, textAlign: TextAlign.center),
|
||||
child: Text(
|
||||
_abbreviateRelation(data.relation),
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: 18,
|
||||
@@ -1183,4 +1180,15 @@ class _YaoDetailRow extends StatelessWidget {
|
||||
String _changeMark(YaoType type) {
|
||||
return type.changeMark;
|
||||
}
|
||||
|
||||
String _abbreviateRelation(String relation) {
|
||||
return switch (relation) {
|
||||
'子孙' => '孙',
|
||||
'妻财' => '财',
|
||||
'官鬼' => '官',
|
||||
'兄弟' => '兄',
|
||||
'父母' => '父',
|
||||
_ => relation,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user