Main update
All checks were successful
Deploy / deploy-staging (push) Successful in 25s
Deploy / deploy-production (push) Has been skipped

This commit is contained in:
2026-06-24 02:24:39 +02:00
parent 5ff4c3fb2b
commit d121f74bd0
34 changed files with 2548 additions and 67 deletions

View File

@@ -29,7 +29,7 @@ final class App
$auth = new KeycloakAuth($keycloakConfig);
$moduleRegistry = new ModuleRegistry($this->projectRoot . '/modules');
$registry = new AppRegistry($this->projectRoot . '/config/apps.php', $moduleRegistry->desktopApps());
$widgetRegistry = new WidgetRegistry($this->projectRoot . '/config/widgets.php');
$widgetRegistry = new WidgetRegistry($this->projectRoot . '/config/widgets.php', $moduleRegistry->widgets());
$skins = SkinResolver::all();
$isAuthenticated = isset($_SESSION['desktop_auth']) && is_array($_SESSION['desktop_auth']);
$authUser = $isAuthenticated && is_array($_SESSION['desktop_auth']['user'] ?? null)
@@ -55,6 +55,11 @@ final class App
);
$apps = AppIconResolver::decorate($enabledApps, $activeSkin);
$windows = (new WindowManager($registry))->defaultWindows();
$enabledAppIds = array_values(array_filter(array_map(
static fn (array $app): string => (string) ($app['app_id'] ?? ''),
$enabledApps
)));
$availableWidgets = $widgetRegistry->availableForApps($enabledAppIds);
$activeWidgetIds = array_values(array_map('strval', (array) ($userSettings['widgets']['active_ids'] ?? DesktopState::defaultWidgetIds())));
$trayItems = DesktopState::trayItems();
foreach ($enabledApps as $app) {
@@ -103,8 +108,8 @@ final class App
'apps' => $apps,
'windows' => $windows,
'widgets' => [
'active' => $widgetRegistry->active($activeWidgetIds),
'registry' => $widgetRegistry->all(),
'active' => $widgetRegistry->active($activeWidgetIds, $enabledAppIds),
'registry' => $availableWidgets,
'active_ids' => $activeWidgetIds,
],
'tray' => $trayItems,