Merge branch 'main' into worktree-agent-a3cb3553b5c91a345
This commit is contained in:
@@ -28,6 +28,9 @@ import 'dart:convert';
|
||||
|
||||
import 'package:pipelines_app/application/app_url_strategy.dart';
|
||||
import 'package:pipelines_app/application/pipelines_app.dart';
|
||||
import 'package:pipelines_app/application/detached/detached_app.dart';
|
||||
import 'package:pipelines_app/application/detached/detached_platform.dart';
|
||||
import 'package:pipelines_app/application/detached/detached_route.dart';
|
||||
import 'package:pipelines_app/application/bootstrap.dart';
|
||||
import 'package:pipelines_app/core/api_gateway.dart';
|
||||
import 'package:pipelines_app/core/transport/pipelines_client.dart';
|
||||
@@ -1080,25 +1083,43 @@ Future<void> main() async {
|
||||
},
|
||||
)
|
||||
: null;
|
||||
final app = PipelinesApp(
|
||||
serverId: machines?.catalog.active?.id,
|
||||
servers: machines,
|
||||
chatPool: pool,
|
||||
server: fixtureServer(params),
|
||||
webPlatform: params['nativeUpdate'] == null ? kIsWeb : false,
|
||||
androidSupported: params['nativeUpdate'] == null ? null : true,
|
||||
installedVersionReader: () async => 1,
|
||||
androidFeedReader: (base) async => AppUpdate(
|
||||
versionCode: 2,
|
||||
versionName: '0.1.2',
|
||||
apk: base.resolve('Pipelines.zip'),
|
||||
platform: params['nativeUpdate'] ?? 'android',
|
||||
sourceName: 'Home Linux',
|
||||
),
|
||||
client: PipelinesClient(channelFactory: (_) => _FixtureChannel()),
|
||||
routeInformationProvider: fixtureRouteProvider(opensRoute ? route : null),
|
||||
windows: probeWindows(params),
|
||||
);
|
||||
// A detached window (`/window/chat/<id>`, opened by Open in new window)
|
||||
// runs on the same fixture: its URL carries this page's parameters.
|
||||
DetachedPlatform.extraQuery = () => {
|
||||
for (final entry in params.entries)
|
||||
if (entry.key != 'route' && entry.key != 'q') entry.key: entry.value,
|
||||
};
|
||||
final detached = kIsWeb ? DetachedRoute.parse(Uri.base.toString()) : null;
|
||||
final app = detached != null
|
||||
? DetachedWindowApp(
|
||||
route: detached,
|
||||
server: fixtureServer(params),
|
||||
serverId: machines?.catalog.active?.id,
|
||||
servers: machines,
|
||||
chatPool: pool,
|
||||
client: PipelinesClient(channelFactory: (_) => _FixtureChannel()),
|
||||
)
|
||||
: PipelinesApp(
|
||||
serverId: machines?.catalog.active?.id,
|
||||
servers: machines,
|
||||
chatPool: pool,
|
||||
server: fixtureServer(params),
|
||||
webPlatform: params['nativeUpdate'] == null ? kIsWeb : false,
|
||||
androidSupported: params['nativeUpdate'] == null ? null : true,
|
||||
installedVersionReader: () async => 1,
|
||||
androidFeedReader: (base) async => AppUpdate(
|
||||
versionCode: 2,
|
||||
versionName: '0.1.2',
|
||||
apk: base.resolve('Pipelines.zip'),
|
||||
platform: params['nativeUpdate'] ?? 'android',
|
||||
sourceName: 'Home Linux',
|
||||
),
|
||||
client: PipelinesClient(channelFactory: (_) => _FixtureChannel()),
|
||||
routeInformationProvider: fixtureRouteProvider(
|
||||
opensRoute ? route : null,
|
||||
),
|
||||
windows: probeWindows(params),
|
||||
);
|
||||
final brightness = switch (params['theme']) {
|
||||
'dark' => Brightness.dark,
|
||||
'light' => Brightness.light,
|
||||
|
||||
Reference in New Issue
Block a user