| @@ -2,9 +2,9 @@ | ||
| 2 | 2 | /** |
| 3 | 3 | * Plugin Name: OpenStation |
| 4 | 4 | * Plugin URI: https://github.com/WordPress/openstation |
| 5 | 5 | * Description: Renders the WordPress admin as a desktop OS. Admin screens become draggable, resizable, minimizable windows floating on a desktop with a dock. Purely opt-in per user. |
| 6 | - * Version: 1.1.1 | |
| 6 | + * Version: 1.1.10 | |
| 7 | 7 | * Requires at least: 6.0 |
| 8 | 8 | * Requires PHP: 7.4 |
| 9 | 9 | * Author: Daniel López Sánchez |
| 10 | 10 | * Author URI: https://github.com/allterraindeveloper |
| @@ -17,9 +17,9 @@ | ||
| 17 | 17 | */ |
| 18 | 18 | |
| 19 | 19 | defined( 'ABSPATH' ) || exit; |
| 20 | 20 | |
| 21 | -define( 'OPENSTATION_VERSION', '1.1.1' ); | |
| 21 | +define( 'OPENSTATION_VERSION', '1.1.10' ); | |
| 22 | 22 | define( 'OPENSTATION_FILE', __FILE__ ); |
| 23 | 23 | define( 'OPENSTATION_DIR', plugin_dir_path( __FILE__ ) ); |
| 24 | 24 | define( 'OPENSTATION_URL', plugin_dir_url( __FILE__ ) ); |
| 25 | 25 | |
| @@ -95,12 +95,21 @@ | ||
| 95 | 95 | // any payload function is invoked at hook-fire time. |
| 96 | 96 | require_once OPENSTATION_DIR . 'includes/core/payload.php'; |
| 97 | 97 | require_once OPENSTATION_DIR . 'includes/assets.php'; |
| 98 | 98 | require_once OPENSTATION_DIR . 'includes/admin-bar.php'; |
| 99 | +// Loaded before the session: `openstation_sanitize_session()` calls | |
| 100 | +// `openstation_sanitize_workspace_profile()` on every desktop it reads. | |
| 101 | +require_once OPENSTATION_DIR . 'includes/workspaces.php'; | |
| 99 | 102 | require_once OPENSTATION_DIR . 'includes/session.php'; |
| 103 | +require_once OPENSTATION_DIR . 'includes/multisite.php'; | |
| 100 | 104 | require_once OPENSTATION_DIR . 'includes/presence.php'; |
| 101 | 105 | require_once OPENSTATION_DIR . 'includes/nonce-refresh.php'; |
| 102 | 106 | require_once OPENSTATION_DIR . 'includes/os-settings.php'; |
| 107 | +require_once OPENSTATION_DIR . 'includes/mobile.php'; | |
| 108 | +// The About journal is still lazy — this file only registers its authenticated | |
| 109 | +// AJAX action. Load the registration unconditionally so alternate admin-ajax | |
| 110 | +// bootstraps cannot skip it while classifying the request shape. | |
| 111 | +require_once OPENSTATION_DIR . 'includes/about-feed.php'; | |
| 103 | 112 | require_once OPENSTATION_DIR . 'includes/seen-intros.php'; |
| 104 | 113 | // One-time data migrations. After os-settings.php and seen-intros.php, |
| 105 | 114 | // whose meta-key constants and helpers the migrations call. |
| 106 | 115 | // |
| @@ -118,12 +127,18 @@ | ||
| 118 | 127 | // Solo window rendering mode (`?openstation_solo=<id>`). Unconditional |
| 119 | 128 | // because `includes/render/` reads its flag, and because extensions |
| 120 | 129 | // (the Electron adapter) call its helpers from their own hooks. |
| 121 | 130 | require_once OPENSTATION_DIR . 'includes/solo-window.php'; |
| 131 | +// The shell screen (`admin.php?page=openstation`) and the one "this | |
| 132 | +// request paints the shell" predicate. Unconditional because modules | |
| 133 | +// loaded outside the admin block (PWA, native windows, desktop themes) | |
| 134 | +// gate on it. | |
| 135 | +require_once OPENSTATION_DIR . 'includes/shell-screen.php'; | |
| 122 | 136 | require_once OPENSTATION_DIR . 'includes/themes-tabs.php'; |
| 123 | 137 | require_once OPENSTATION_DIR . 'includes/media-query.php'; |
| 124 | 138 | require_once OPENSTATION_DIR . 'includes/accents.php'; |
| 125 | 139 | require_once OPENSTATION_DIR . 'includes/toast-types.php'; |
| 140 | +require_once OPENSTATION_DIR . 'includes/wp-icon-registry.php'; | |
| 126 | 141 | require_once OPENSTATION_DIR . 'includes/registries/native-windows.php'; |
| 127 | 142 | require_once OPENSTATION_DIR . 'includes/registries/window-tabs.php'; |
| 128 | 143 | require_once OPENSTATION_DIR . 'includes/registries/icons.php'; |
| 129 | 144 | require_once OPENSTATION_DIR . 'includes/registries/wallpapers.php'; |
| @@ -139,8 +154,9 @@ | ||
| 139 | 154 | require_once OPENSTATION_DIR . 'includes/window-chrome.php'; |
| 140 | 155 | require_once OPENSTATION_DIR . 'includes/window-notices.php'; |
| 141 | 156 | require_once OPENSTATION_DIR . 'includes/wallpapers.php'; |
| 142 | 157 | require_once OPENSTATION_DIR . 'includes/mio.php'; |
| 158 | +require_once OPENSTATION_DIR . 'includes/mio-portrait.php'; | |
| 143 | 159 | require_once OPENSTATION_DIR . 'includes/widgets/heartbeat.php'; |
| 144 | 160 | require_once OPENSTATION_DIR . 'includes/widgets/widget-comments.php'; |
| 145 | 161 | require_once OPENSTATION_DIR . 'includes/widgets/widget-post-stats.php'; |
| 146 | 162 | require_once OPENSTATION_DIR . 'includes/widgets/widget-site-views.php'; |
| @@ -158,19 +174,36 @@ | ||
| 158 | 174 | require_once OPENSTATION_DIR . 'includes/recycle-bin/bootstrap.php'; |
| 159 | 175 | require_once OPENSTATION_DIR . 'includes/desktop-files/bootstrap.php'; |
| 160 | 176 | require_once OPENSTATION_DIR . 'includes/desktop-themes/bootstrap.php'; |
| 161 | 177 | require_once OPENSTATION_DIR . 'includes/notes/bootstrap.php'; |
| 162 | -require_once OPENSTATION_DIR . 'includes/posts-window/bootstrap.php'; | |
| 163 | -require_once OPENSTATION_DIR . 'includes/pages-window/bootstrap.php'; | |
| 164 | -require_once OPENSTATION_DIR . 'includes/users-window/bootstrap.php'; | |
| 165 | -require_once OPENSTATION_DIR . 'includes/user-edit-window/bootstrap.php'; | |
| 166 | -require_once OPENSTATION_DIR . 'includes/plugins-window/bootstrap.php'; | |
| 167 | -require_once OPENSTATION_DIR . 'includes/comments-window/bootstrap.php'; | |
| 178 | +// Posts, Pages, Users, User Edit, Plugins and Comments are App | |
| 179 | +// Framework apps (`apps/posts/`, `apps/pages/`, `apps/users/`, | |
| 180 | +// `apps/user-edit/`, `apps/plugins/`, `apps/comments/`): each `.os.php` | |
| 181 | +// pulls in its own PHP parts (permissions, REST fields and routes, | |
| 182 | +// AJAX handlers) when the framework loads it on `init`. | |
| 183 | +// Station Home is an App Framework app (`apps/station-home/`); only | |
| 184 | +// its plugin-card registry — a public API plugins call on `init` — | |
| 185 | +// lives here, so it exists before any app loads. | |
| 186 | +require_once OPENSTATION_DIR . 'includes/station-home/cards.php'; | |
| 168 | 187 | require_once OPENSTATION_DIR . 'includes/my-wordpress/bootstrap.php'; |
| 169 | 188 | require_once OPENSTATION_DIR . 'includes/content-graph/bootstrap.php'; |
| 189 | +// The App Framework: `.os.php` windows under `apps/` (Code Blue lives | |
| 190 | +// there) and any directory a plugin adds. Loads after the registries | |
| 191 | +// it registers into and after the feature modules, so an app can | |
| 192 | +// hook them. | |
| 193 | +require_once OPENSTATION_DIR . 'includes/framework/wordpress.php'; | |
| 170 | 194 | require_once OPENSTATION_DIR . 'includes/living-tree/bootstrap.php'; |
| 171 | 195 | require_once OPENSTATION_DIR . 'includes/games/bootstrap.php'; |
| 172 | 196 | require_once OPENSTATION_DIR . 'includes/agents/bootstrap.php'; |
| 197 | +require_once OPENSTATION_DIR . 'includes/network/bootstrap.php'; | |
| 198 | +// First run: the install / first-enable stamps. Loads on every request | |
| 199 | +// because they are written from the AJAX toggle, the portal and the | |
| 200 | +// activation hook, none of them an admin render. | |
| 201 | +require_once OPENSTATION_DIR . 'includes/first-run/bootstrap.php'; | |
| 202 | +// Deactivation feedback: the dialog on the Plugins screen and the | |
| 203 | +// REST route it posts to. Unconditional so the route registers on | |
| 204 | +// REST requests; it stores nothing on the site. | |
| 205 | +require_once OPENSTATION_DIR . 'includes/feedback/bootstrap.php'; | |
| 173 | 206 | require_once OPENSTATION_DIR . 'includes/pwa.php'; |
| 174 | 207 | require_once OPENSTATION_DIR . 'includes/compat/divi.php'; |
| 175 | 208 | |
| 176 | 209 | // Admin-rendering modules — every hook these register (`admin_init`, |