feat(ui): scope, freshness and jurist-review badges + live empty-state
Adds three dark-first chip badges in the TierBadge pattern: - Jurisdiction (Berlin/DE/EU/International) — derived from the ELI, surfaced on the norms list, detail header and heatmap chips/hover. - Freshness (aktuell/geaendert/ungeprueft) — flags norms amended upstream (standDate + sourceSha256); renders only when stale. - Jurist review — marks evaluations a trusted jurist has confirmed (optional; the figure stands on its own). Models gain Jurisdiction/Freshness enums, Norm.freshness/supersededNote and Evaluation.reviewedBy/reviewedAt; HubRepository parses them from the flow bag (ELI fallback). HeatmapPage shows a real empty-state (hub-down vs no-evaluations) instead of a blank plot, and connect() no longer throws on a failed probe. Signed-off-by: flemming-it <sf@flemming.it>
This commit is contained in:
parent
9dfa418e92
commit
aabff2b140
11 changed files with 604 additions and 26 deletions
|
|
@ -5,8 +5,11 @@ import '../data/repository.dart';
|
|||
import '../theme/reclaim_tokens.dart';
|
||||
import '../widgets/mode_banner.dart';
|
||||
import '../widgets/evidence_sidebar.dart';
|
||||
import '../widgets/freshness_badge.dart';
|
||||
import '../widgets/jurisdiction_badge.dart';
|
||||
import '../widgets/norm_text_card.dart';
|
||||
import '../widgets/reclaim_card.dart';
|
||||
import '../widgets/review_badge.dart';
|
||||
import '../widgets/tier_badge.dart';
|
||||
|
||||
class NormDetailPage extends StatelessWidget {
|
||||
|
|
@ -63,7 +66,27 @@ class NormDetailPage extends StatelessWidget {
|
|||
],
|
||||
),
|
||||
),
|
||||
TierBadge(tier: e.tierLowest),
|
||||
Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.end,
|
||||
children: [
|
||||
JurisdictionBadge(
|
||||
jurisdiction: e.norm.jurisdiction),
|
||||
const SizedBox(height: ReclaimSpace.sm),
|
||||
TierBadge(tier: e.tierLowest),
|
||||
if (e.norm.freshness.needsBadge) ...[
|
||||
const SizedBox(
|
||||
height: ReclaimSpace.sm),
|
||||
FreshnessBadge(
|
||||
freshness: e.norm.freshness,
|
||||
note: e.norm.supersededNote,
|
||||
),
|
||||
],
|
||||
const SizedBox(height: ReclaimSpace.sm),
|
||||
ReviewBadge(
|
||||
evaluation: e, showUnreviewed: true),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: ReclaimSpace.lg),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue