make parent tickets and decision refs clickable throughlinks

Clicking a parent ticket in the tree publishes
builtin.tickets/selection — loads that ticket in the detail view.
Clicking a decision ref publishes builtin.decisions/selection —
switches context panel to the decision detail. Both show hover
highlight. Enables full cross-reference navigation without
leaving the context panel.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-23 17:02:18 +02:00
co-authored by Claude Opus 4.6
parent de321bfe92
commit dad2d0ad52
@@ -206,12 +206,14 @@ class _CompactCard extends StatelessWidget {
final typeColor = typeColors.forType(type); final typeColor = typeColors.forType(type);
return Padding( return Padding(
padding: EdgeInsets.only(left: indent * 12.0, bottom: 4), padding: EdgeInsets.only(left: indent * 12.0, bottom: 4),
child: Container( child: ClideTappable(
onTap: () => ClideKernel.of(context).messages.publish('builtin.tickets', 'selection', {'id': id}),
builder: (ctx, hovered, _) => Container(
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 6), padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 6),
decoration: BoxDecoration( decoration: BoxDecoration(
color: tokens.panelBackground, color: hovered ? tokens.sidebarItemHover : tokens.panelBackground,
borderRadius: BorderRadius.circular(4), borderRadius: BorderRadius.circular(4),
border: Border.all(color: tokens.panelBorder), border: Border.all(color: hovered ? tokens.panelActiveBorder : tokens.panelBorder),
), ),
child: Row( child: Row(
children: [ children: [
@@ -223,6 +225,7 @@ class _CompactCard extends StatelessWidget {
], ],
), ),
), ),
),
); );
} }
} }
@@ -246,12 +249,14 @@ class _DecisionRefCard extends StatelessWidget {
}; };
return Padding( return Padding(
padding: const EdgeInsets.only(bottom: 4), padding: const EdgeInsets.only(bottom: 4),
child: Container( child: ClideTappable(
onTap: () => ClideKernel.of(context).messages.publish('builtin.decisions', 'selection', {'id': id}),
builder: (ctx, hovered, _) => Container(
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 6), padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 6),
decoration: BoxDecoration( decoration: BoxDecoration(
color: tokens.panelBackground, color: hovered ? tokens.sidebarItemHover : tokens.panelBackground,
borderRadius: BorderRadius.circular(4), borderRadius: BorderRadius.circular(4),
border: Border.all(color: tokens.panelBorder), border: Border.all(color: hovered ? tokens.panelActiveBorder : tokens.panelBorder),
), ),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
@@ -270,6 +275,7 @@ class _DecisionRefCard extends StatelessWidget {
], ],
), ),
), ),
),
); );
} }
} }