merge main into install-app

This commit is contained in:
2026-10-23 21:53:29 +01:00
4 changed files with 53 additions and 1 deletions
+30
View File
@@ -32,6 +32,7 @@ class PipelinesScreen extends StatefulWidget {
this.syncToken = 0,
this.onRunStarted,
this.onViewPipelineRuns,
this.onOpenSchedules,
this.initialPipelineId,
this.initialVersion = 0,
this.initialStageKey,
@@ -54,6 +55,9 @@ class PipelinesScreen extends StatefulWidget {
final ValueChanged<int>? onRunStarted;
final ValueChanged<int>? onViewPipelineRuns;
/// Opens every schedule; shown in the bar while the list is visible.
final VoidCallback? onOpenSchedules;
/// The pipeline a deep link names, opened after the list read starts.
final int? initialPipelineId;
@@ -234,6 +238,8 @@ class _PipelinesScreenState extends State<PipelinesScreen> {
return ShellBar(
actions: [
if (listShown) ...pipelineListActions(context, _controller),
if (listShown && widget.onOpenSchedules != null)
_schedulesButton(context),
_refreshButton(context),
],
child: body,
@@ -250,6 +256,7 @@ class _PipelinesScreenState extends State<PipelinesScreen> {
mainAxisSize: MainAxisSize.min,
children: [
...pipelineListActions(context, _controller),
if (widget.onOpenSchedules != null) _schedulesButton(context),
_refreshButton(context),
],
),
@@ -260,6 +267,27 @@ class _PipelinesScreenState extends State<PipelinesScreen> {
);
}
Widget _schedulesButton(BuildContext context) {
if (useCupertinoControls(context)) {
return Semantics(
button: true,
label: 'Schedules',
child: CupertinoButton(
key: const Key('pipelines-open-schedules'),
padding: EdgeInsets.zero,
onPressed: widget.onOpenSchedules,
child: const Icon(CupertinoIcons.calendar),
),
);
}
return IconButton(
key: const Key('pipelines-open-schedules'),
tooltip: 'Schedules',
onPressed: widget.onOpenSchedules,
icon: const Icon(Icons.schedule),
);
}
Widget _refreshButton(BuildContext context) {
if (useCupertinoControls(context)) {
return Semantics(
@@ -295,6 +323,7 @@ class _PipelinesScreenState extends State<PipelinesScreen> {
title: const Text('Pipelines'),
actions: [
...pipelineListActions(context, _controller),
if (widget.onOpenSchedules != null) _schedulesButton(context),
_refreshButton(context),
],
),
@@ -310,6 +339,7 @@ class _PipelinesScreenState extends State<PipelinesScreen> {
mainAxisSize: MainAxisSize.min,
children: [
...pipelineListActions(context, _controller),
if (widget.onOpenSchedules != null) _schedulesButton(context),
_refreshButton(context),
],
),