@skyvexsoftware/stratos-sdk 0.21.1 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -4
- package/dist/icons.d.ts +1 -20
- package/dist/icons.js +7 -15
- package/dist/index.d.ts +1 -2
- package/dist/index.js +4 -4
- package/dist/types/context.d.ts +0 -7
- package/dist/types/index.d.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -97,7 +97,7 @@ The `vite` option accepts any Vite config to merge in (plugins, resolve, css, et
|
|
|
97
97
|
- `available_settings`: Optional array of setting definitions (boolean, text, number, list, etc.)
|
|
98
98
|
- `min_core_version`: Optional oldest Stratos Core the plugin runs on (e.g. `"2.49.0"`)
|
|
99
99
|
|
|
100
|
-
plugin.json keys are snake_case.
|
|
100
|
+
plugin.json keys are snake_case.
|
|
101
101
|
|
|
102
102
|
## API Reference
|
|
103
103
|
|
|
@@ -203,9 +203,7 @@ import { Plane, Map, Settings, Helicopter } from "lucide-react";
|
|
|
203
203
|
|
|
204
204
|
The SDK's Vite config shims `react`, `react-dom`, and their jsx subpaths so every copy of React in your plugin graph (including lucide-react's internals) resolves to the shell's single instance.
|
|
205
205
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
Earlier SDK versions exposed `STRATOS_ICONS` and `STRATOS_ICON_NAMES` as convenience re-exports of lucide's `icons` object. Those exports are still available but **deprecated** — prefer the patterns above in new code.
|
|
206
|
+
For icons chosen by name at runtime (e.g. from an airline setting), use `DynamicIcon` from `@skyvexsoftware/stratos-sdk/icons`. Stratos loads each icon on demand (core 2.49.0+), so your plugin bundles none of the set.
|
|
209
207
|
|
|
210
208
|
### Types
|
|
211
209
|
|
package/dist/icons.d.ts
CHANGED
|
@@ -1,21 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
* Re-exports of lucide-react's icon registry.
|
|
3
|
-
*
|
|
4
|
-
* @deprecated Since SDK 0.7.2. Import from `lucide-react` directly — static
|
|
5
|
-
* imports tree-shake, and the SDK's Vite config shims `react` so lucide's
|
|
6
|
-
* internals resolve to the shell's React instance (no bundle duplication,
|
|
7
|
-
* no two-React crashes). For genuinely dynamic name→component lookup, use
|
|
8
|
-
* `import { icons } from "lucide-react"` which costs ~60 KB gzipped in your
|
|
9
|
-
* plugin bundle — prefer a curated static map where you can.
|
|
10
|
-
*
|
|
11
|
-
* Retained as a thin re-export so existing plugin bundles that were built
|
|
12
|
-
* against SDK 0.6.x and earlier keep working when core upgrades the SDK.
|
|
13
|
-
* Safe to remove in a future major release once no shipped plugin references
|
|
14
|
-
* these exports.
|
|
15
|
-
*/
|
|
16
|
-
import { icons } from "lucide-react";
|
|
17
|
-
/** @deprecated Import from `lucide-react` directly. See file docstring. */
|
|
18
|
-
export declare const STRATOS_ICONS: typeof icons;
|
|
19
|
-
/** @deprecated Import from `lucide-react` directly. See file docstring. */
|
|
20
|
-
export declare const STRATOS_ICON_NAMES: string[];
|
|
1
|
+
export {};
|
|
21
2
|
//# sourceMappingURL=icons.d.ts.map
|
package/dist/icons.js
CHANGED
|
@@ -1,20 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Re-exports of lucide-react's icon registry
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* no two-React crashes). For genuinely dynamic name→component lookup, use
|
|
8
|
-
* `import { icons } from "lucide-react"` which costs ~60 KB gzipped in your
|
|
9
|
-
* plugin bundle — prefer a curated static map where you can.
|
|
10
|
-
*
|
|
11
|
-
* Retained as a thin re-export so existing plugin bundles that were built
|
|
12
|
-
* against SDK 0.6.x and earlier keep working when core upgrades the SDK.
|
|
13
|
-
* Safe to remove in a future major release once no shipped plugin references
|
|
14
|
-
* these exports.
|
|
2
|
+
* Re-exports of lucide-react's icon registry, kept at runtime for plugin
|
|
3
|
+
* bundles built against SDK 0.6.x and earlier. Left out of the published
|
|
4
|
+
* types (`@internal`): plugins import icons from `lucide-react` or use
|
|
5
|
+
* `DynamicIcon`. Safe to remove in a future major release once no shipped
|
|
6
|
+
* plugin references these exports.
|
|
15
7
|
*/
|
|
16
8
|
import { icons } from "lucide-react";
|
|
17
|
-
/** @
|
|
9
|
+
/** @internal See file docstring. */
|
|
18
10
|
export const STRATOS_ICONS = icons;
|
|
19
|
-
/** @
|
|
11
|
+
/** @internal See file docstring. */
|
|
20
12
|
export const STRATOS_ICON_NAMES = Object.keys(icons).sort();
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type { PluginAuthor, PluginManifest } from "./types/manifest";
|
|
2
|
-
export type { PluginAirline, PluginAirlineAccessor, PluginAuthAccessor, PluginVaApiClient, PluginConfigStore, PluginContext, PluginDatabaseAccessor, PluginIPCRegistrar, PluginLogger, PluginServerRegistrar, PluginFlightAccessor, PluginFlightLogWriter, PluginFlightLogInput, PluginFlightLogPatch, PluginStartGuard, PluginStartContext, PluginStartDecision, PluginPirepSubmissionContext, PluginPirepAttachment, PluginPirepAttachHandler, PluginFileAttachment, PluginNotifier, PluginToastInput, BuiltInSound,
|
|
2
|
+
export type { PluginAirline, PluginAirlineAccessor, PluginAuthAccessor, PluginVaApiClient, PluginConfigStore, PluginContext, PluginDatabaseAccessor, PluginIPCRegistrar, PluginLogger, PluginServerRegistrar, PluginFlightAccessor, PluginFlightLogWriter, PluginFlightLogInput, PluginFlightLogPatch, PluginStartGuard, PluginStartContext, PluginStartDecision, PluginPirepSubmissionContext, PluginPirepAttachment, PluginPirepAttachHandler, PluginFileAttachment, PluginNotifier, PluginToastInput, BuiltInSound, PluginDialogApi, PluginPromptApi, PluginDialogAlertInput, PluginDialogConfirmInput, PluginPromptTextInput, PluginPromptNumberInput, PluginPromptSelectInput, PluginIndicatorType, PluginIndicatorInput, PluginSelfApi, } from "./types/context";
|
|
3
3
|
export type { PluginNavigationHelper, PluginPilotUser, PluginToastAPI, PluginUIContext, } from "./types/context-ui";
|
|
4
4
|
export type { PluginSettingType, PluginSettingOption, PluginSettingDefinition, PluginAvailableSettings, BooleanSettingDef, TextSettingDef, LongtextSettingDef, NumberSettingDef, RangeSettingDef, ListSettingDef, RadioSettingDef, DateSettingDef, JsonSettingDef, } from "./types/settings";
|
|
5
5
|
export type { PluginBackgroundModule, PluginRouteComponent, PluginUIModule, } from "./types/module";
|
|
@@ -39,6 +39,5 @@ export type { AutoStartConfirmPayload, ConnectionState, LogEntryPayload, Notific
|
|
|
39
39
|
export type { PluginDialogKind, PluginDialogSelectOption, PluginDialogSpec, PluginDialogResult, PluginDialogClosePayload, } from "./shared-types/plugin-dialogs";
|
|
40
40
|
export { AlertDialog, AlertDialogPortal, AlertDialogOverlay, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogFooter, AlertDialogTitle, AlertDialogDescription, AlertDialogAction, AlertDialogCancel, Badge, badgeVariants, Button, buttonVariants, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Combobox, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Input, Label, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, RadioGroup, RadioGroupItem, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Slider, Switch, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, } from "./ui";
|
|
41
41
|
export type { BadgeProps, ButtonProps, ComboboxOption, ComboboxProps, } from "./ui";
|
|
42
|
-
export { STRATOS_ICONS, STRATOS_ICON_NAMES } from "./icons";
|
|
43
42
|
export { cn } from "./utils/cn";
|
|
44
43
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.js
CHANGED
|
@@ -28,10 +28,10 @@ export { useSocket, useSimulatorData, useProtocolUrl, useNotifications, useSyste
|
|
|
28
28
|
export { SOCKET_EVENTS } from "./shared-types/socket-events";
|
|
29
29
|
// ── UI Primitives ──────────────────────────────────────────────────────
|
|
30
30
|
export { AlertDialog, AlertDialogPortal, AlertDialogOverlay, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogFooter, AlertDialogTitle, AlertDialogDescription, AlertDialogAction, AlertDialogCancel, Badge, badgeVariants, Button, buttonVariants, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Combobox, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Input, Label, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, RadioGroup, RadioGroupItem, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Slider, Switch, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, } from "./ui";
|
|
31
|
-
// ── Icons (
|
|
32
|
-
// Kept
|
|
33
|
-
//
|
|
34
|
-
|
|
31
|
+
// ── Icons (internal) ──────────────────────────────────────────────────
|
|
32
|
+
// Kept at runtime for plugin bundles that still read them; out of the
|
|
33
|
+
// published types. Plugins import from lucide-react or use DynamicIcon.
|
|
34
|
+
/** @internal */
|
|
35
35
|
export { STRATOS_ICONS, STRATOS_ICON_NAMES } from "./icons";
|
|
36
36
|
// ── Utilities ──────────────────────────────────────────────────────────
|
|
37
37
|
export { cn } from "./utils/cn";
|
package/dist/types/context.d.ts
CHANGED
|
@@ -274,11 +274,6 @@ export type PluginNotifier = {
|
|
|
274
274
|
* ogg, m4a, aac.
|
|
275
275
|
*/
|
|
276
276
|
playCustomSound(assetPath: string): Promise<void>;
|
|
277
|
-
/**
|
|
278
|
-
* @deprecated Use {@link PluginNotifier.playSound}. Retained for back-compat;
|
|
279
|
-
* legacy names (`alert`/`warning`/`chime`) now map onto a real bundled file.
|
|
280
|
-
*/
|
|
281
|
-
sound(name: PluginAlertSound): Promise<void>;
|
|
282
277
|
};
|
|
283
278
|
/** Input for `ctx.notify.toast`. */
|
|
284
279
|
export type PluginToastInput = {
|
|
@@ -290,8 +285,6 @@ export type PluginToastInput = {
|
|
|
290
285
|
};
|
|
291
286
|
/** Built-in shell sound catalogue. Semantic names mapped to bundled files by the shell. */
|
|
292
287
|
export type BuiltInSound = "attention" | "error" | "success";
|
|
293
|
-
/** @deprecated Use {@link BuiltInSound} with `playSound`. */
|
|
294
|
-
export type PluginAlertSound = "alert" | "warning" | "error" | "success" | "chime";
|
|
295
288
|
/** Visual style of a plugin's sidebar indicator. */
|
|
296
289
|
export type PluginIndicatorType = "notification" | "warning";
|
|
297
290
|
/** Input for `ctx.plugin.setIndicator`. */
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type { PluginAuthor, PluginManifest } from "./manifest";
|
|
2
|
-
export type { PluginAirline, PluginAirlineAccessor, PluginAuthAccessor, PluginConfigStore, PluginContext, PluginDatabaseAccessor, PluginIPCRegistrar, PluginLogger, PluginServerRegistrar, PluginFlightAccessor, PluginFlightLogWriter, PluginFlightLogInput, PluginFlightLogPatch, PluginStartGuard, PluginStartContext, PluginStartDecision, PluginPirepSubmissionContext, PluginPirepAttachment, PluginPirepAttachHandler, PluginFileAttachment, PluginNotifier, PluginToastInput, BuiltInSound,
|
|
2
|
+
export type { PluginAirline, PluginAirlineAccessor, PluginAuthAccessor, PluginConfigStore, PluginContext, PluginDatabaseAccessor, PluginIPCRegistrar, PluginLogger, PluginServerRegistrar, PluginFlightAccessor, PluginFlightLogWriter, PluginFlightLogInput, PluginFlightLogPatch, PluginStartGuard, PluginStartContext, PluginStartDecision, PluginPirepSubmissionContext, PluginPirepAttachment, PluginPirepAttachHandler, PluginFileAttachment, PluginNotifier, PluginToastInput, BuiltInSound, } from "./context";
|
|
3
3
|
export type { PluginNavigationHelper, PluginToastAPI, PluginUIContext, } from "./context-ui";
|
|
4
4
|
export type { PluginBackgroundModule, PluginRouteComponent, PluginUIModule, } from "./module";
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|