src/ui/index.tsx. The shell renders it in the main content area when a pilot selects your plugin in the sidebar.
What the Shell Provides
The shell injects several libraries at runtime — you don’t need to bundle them, and the build system externalises them automatically. Import them directly:react,react-dom@tanstack/react-query,@tanstack/react-router@skyvexsoftware/stratos-sdk(hooks, UI components, types, helpers)sonner(toast notifications)socket.io-clientmaplibre-gl,react-map-gl/maplibre
lucide-react, your own utilities, third-party libraries — will be bundled into your plugin’s ui/index.js.
Using usePluginContext()
The primary way to access shell state from any component in your plugin:
usePluginContext() can be called in any component in your tree — not just the root. The context is provided by the PluginShellProvider that wraps your entire plugin.
Auth
Config
Read plugin settings declared in your manifest’savailableSettings. Config access in the UI module is synchronous — values are pre-loaded when your plugin mounts:
get() is the default value, returned when the setting has not been explicitly set.
Navigation
Navigate within your plugin or jump to other plugins and shell routes:Toast Notifications
Styling
Plugins share the shell’s Tailwind CSS theme. Use standard Tailwind utility classes:| Class | Usage |
|---|---|
bg-card | Card and panel backgrounds |
bg-muted | Subtle, secondary backgrounds |
text-muted-foreground | Secondary and supporting text |
border | Standard dividers and outlines |
bg-primary / text-primary | Accent colour (configured per-airline) |
bg-background | Page-level background |
text-foreground | Primary text |