Remove the Runs error counter for now
Keep the running indicator and Needs you flow, but remove the failed-count badge and its tab count plumbing until unseen-state behavior is addressed. Preserve the unfinished seen-state work separately. Verify application, Runs, attention and shell regressions.
This commit is contained in:
@@ -24,7 +24,6 @@ class AdaptiveShell extends StatefulWidget {
|
||||
this.onSearch,
|
||||
this.attentionCount = 0,
|
||||
this.runningRunCount,
|
||||
this.failedRunCount,
|
||||
this.listPaneWidthStore = const SharedPreferencesListPaneWidthStore(),
|
||||
this.barActions = const [],
|
||||
});
|
||||
@@ -53,7 +52,6 @@ class AdaptiveShell extends StatefulWidget {
|
||||
|
||||
/// App-wide counts when available; standalone screens publish their own.
|
||||
final int? runningRunCount;
|
||||
final int? failedRunCount;
|
||||
|
||||
@override
|
||||
State<AdaptiveShell> createState() => _AdaptiveShellState();
|
||||
@@ -130,9 +128,6 @@ class _AdaptiveShellState extends State<AdaptiveShell> {
|
||||
running:
|
||||
widget.runningRunCount ??
|
||||
_bar.badge(destination, ShellBadgeKind.running),
|
||||
failed:
|
||||
widget.failedRunCount ??
|
||||
_bar.badge(destination, ShellBadgeKind.failed),
|
||||
attention: widget.attentionCount,
|
||||
child: icon,
|
||||
);
|
||||
|
||||
@@ -44,49 +44,34 @@ class AttentionDestinationIcon extends StatelessWidget {
|
||||
}
|
||||
}
|
||||
|
||||
/// Both status counts remain visible: failures never hide executing work.
|
||||
/// The Runs tab shows executing work only; its error counter is removed.
|
||||
class RunsDestinationIcon extends StatelessWidget {
|
||||
const RunsDestinationIcon({
|
||||
super.key,
|
||||
required this.running,
|
||||
required this.failed,
|
||||
required this.child,
|
||||
this.attention = 0,
|
||||
});
|
||||
|
||||
final int running;
|
||||
final int failed;
|
||||
final int attention;
|
||||
final Widget child;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final colors = Theme.of(context).colorScheme;
|
||||
final labels = [
|
||||
if (running > 0) '$running runs in progress',
|
||||
if (failed > 0) '$failed failed runs',
|
||||
if (attention > 0) attentionBadgeLabel(attention),
|
||||
];
|
||||
final labels = [if (running > 0) '$running runs in progress'];
|
||||
return Semantics(
|
||||
label: labels.join(', '),
|
||||
child: ExcludeSemantics(
|
||||
child: Tooltip(
|
||||
message: labels.isEmpty ? 'Runs' : 'Runs: ${labels.join(', ')}',
|
||||
excludeFromSemantics: true,
|
||||
child: Badge.count(
|
||||
key: const ValueKey('shell.badge.runs.failed'),
|
||||
count: failed,
|
||||
maxCount: 99,
|
||||
isLabelVisible: failed > 0,
|
||||
backgroundColor: colors.error,
|
||||
textColor: colors.onError,
|
||||
child: ActivityBadge(
|
||||
key: const ValueKey('shell.badge.runs.running'),
|
||||
count: running,
|
||||
label: 'runs in progress',
|
||||
bottom: true,
|
||||
child: child,
|
||||
),
|
||||
child: ActivityBadge(
|
||||
key: const ValueKey('shell.badge.runs.running'),
|
||||
count: running,
|
||||
label: 'runs in progress',
|
||||
bottom: true,
|
||||
child: child,
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
@@ -357,9 +357,6 @@ enum ShellBadgeKind {
|
||||
/// Runs still executing.
|
||||
running,
|
||||
|
||||
/// Runs whose server status is failed, independent of attention dismissal.
|
||||
failed,
|
||||
|
||||
/// Chats with messages not yet seen.
|
||||
unread,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user