@skyvexsoftware/stratos-sdk 0.14.0 → 0.15.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/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, PluginNotifier, PluginToastInput, PluginAlertSound, PluginDialogApi, PluginPromptApi, PluginDialogAlertInput, PluginDialogConfirmInput, PluginPromptTextInput, PluginPromptNumberInput, PluginPromptSelectInput, PluginIndicatorType, PluginIndicatorInput, PluginSelfApi, } from "./types/context";
|
|
2
|
+
export type { PluginAirline, PluginAirlineAccessor, PluginAuthAccessor, PluginVaApiClient, PluginConfigStore, PluginContext, PluginDatabaseAccessor, PluginIPCRegistrar, PluginLogger, PluginServerRegistrar, PluginFlightAccessor, PluginFlightLogWriter, PluginFlightLogInput, PluginFlightLogPatch, PluginStartGuard, PluginStartContext, PluginStartDecision, PluginNotifier, PluginToastInput, BuiltInSound, PluginAlertSound, 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";
|
|
@@ -34,7 +34,7 @@ export { useShellNavigation } from "./hooks/useShellNavigation";
|
|
|
34
34
|
export { useShellToast } from "./hooks/useShellToast";
|
|
35
35
|
export { useSocket, useSimulatorData, useProtocolUrl, useNotifications, useSystemMetrics, } from "./hooks/useSimulatorData";
|
|
36
36
|
export { SOCKET_EVENTS } from "./shared-types/socket-events";
|
|
37
|
-
export type { AutoStartConfirmPayload, ConnectionState, LogEntryPayload, NotificationPayload, ProtocolUrlPayload, SimulatorDataPayload, SimulatorStatusPayload, SocketEventName, SystemMetricsPayload, } from "./shared-types/socket-events";
|
|
37
|
+
export type { AutoStartConfirmPayload, ConnectionState, LogEntryPayload, NotificationPayload, ProtocolUrlPayload, SimulatorDataPayload, SimulatorStatusPayload, SocketEventName, SoundPayload, SystemMetricsPayload, } from "./shared-types/socket-events";
|
|
38
38
|
export type { PluginDialogKind, PluginDialogSelectOption, PluginDialogSpec, PluginDialogResult, PluginDialogClosePayload, } from "./shared-types/plugin-dialogs";
|
|
39
39
|
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";
|
|
40
40
|
export type { BadgeProps, ButtonProps, ComboboxOption, ComboboxProps, } from "./ui";
|
|
@@ -8,6 +8,6 @@ export { ADDITIONAL_FIELD_PHASES, toPhaseKey } from "./additional-fields";
|
|
|
8
8
|
export type { AdditionalFieldsConfig, FieldDelivery, } from "./additional-fields";
|
|
9
9
|
export type { FlightPlan, FlightStatus, CurrentFlight, FlightComment, PreflightCheck, PreflightCheckResult, StartFlightOptions, FlightManagerPayload, StartFlightResult, RecoverableFlight, } from "./flight-manager";
|
|
10
10
|
export { SOCKET_EVENTS } from "./socket-events";
|
|
11
|
-
export type { ConnectionState, LogEntryPayload, NotificationPayload, ProtocolUrlPayload, SimulatorDataPayload, SimulatorStatusPayload, SocketEventName, SystemMetricsPayload, } from "./socket-events";
|
|
11
|
+
export type { ConnectionState, LogEntryPayload, NotificationPayload, ProtocolUrlPayload, SimulatorDataPayload, SimulatorStatusPayload, SocketEventName, SoundPayload, SystemMetricsPayload, } from "./socket-events";
|
|
12
12
|
export type { PluginDialogKind, PluginDialogSelectOption, PluginDialogSpec, PluginDialogResult, PluginDialogClosePayload, } from "./plugin-dialogs";
|
|
13
13
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -60,7 +60,7 @@ export declare const SOCKET_EVENTS: {
|
|
|
60
60
|
readonly SYSTEM_METRICS: "system:metrics";
|
|
61
61
|
/** Toast / notification push. Payload: NotificationPayload */
|
|
62
62
|
readonly NOTIFICATION: "notification";
|
|
63
|
-
/** Play a sound in the renderer. Payload:
|
|
63
|
+
/** Play a sound in the renderer. Payload: SoundPayload */
|
|
64
64
|
readonly SOUND: "sound";
|
|
65
65
|
/** Flight lifecycle state change. Payload: FlightManagerPayload */
|
|
66
66
|
readonly FLIGHT_MANAGER: "flight:manager";
|
|
@@ -138,6 +138,18 @@ export type NotificationPayload = {
|
|
|
138
138
|
/** Stable ID for deduplication — toasts with the same ID replace each other. */
|
|
139
139
|
id?: string;
|
|
140
140
|
};
|
|
141
|
+
/**
|
|
142
|
+
* Payload for `sound` events.
|
|
143
|
+
*
|
|
144
|
+
* Either a built-in shell sound (by `name`) or a plugin-bundled sound asset
|
|
145
|
+
* (`pluginId` + plugin-root-relative `path`, served via /api/plugin-files).
|
|
146
|
+
*/
|
|
147
|
+
export type SoundPayload = {
|
|
148
|
+
name: string;
|
|
149
|
+
} | {
|
|
150
|
+
pluginId: string;
|
|
151
|
+
path: string;
|
|
152
|
+
};
|
|
141
153
|
/**
|
|
142
154
|
* Payload for `system:metrics` events.
|
|
143
155
|
*
|
|
@@ -34,7 +34,7 @@ export const SOCKET_EVENTS = {
|
|
|
34
34
|
// Notification events
|
|
35
35
|
/** Toast / notification push. Payload: NotificationPayload */
|
|
36
36
|
NOTIFICATION: "notification",
|
|
37
|
-
/** Play a sound in the renderer. Payload:
|
|
37
|
+
/** Play a sound in the renderer. Payload: SoundPayload */
|
|
38
38
|
SOUND: "sound",
|
|
39
39
|
// Flight manager events
|
|
40
40
|
/** Flight lifecycle state change. Payload: FlightManagerPayload */
|
package/dist/types/context.d.ts
CHANGED
|
@@ -188,7 +188,20 @@ export type PluginStartGuard = (ctx: PluginStartContext) => PluginStartDecision
|
|
|
188
188
|
export type PluginNotifier = {
|
|
189
189
|
/** Show a toast in the renderer. */
|
|
190
190
|
toast(n: PluginToastInput): Promise<void>;
|
|
191
|
-
/** Play a
|
|
191
|
+
/** Play a built-in shell sound by name. */
|
|
192
|
+
playSound(name: BuiltInSound): Promise<void>;
|
|
193
|
+
/**
|
|
194
|
+
* Play a sound file bundled inside this plugin. `assetPath` is relative to
|
|
195
|
+
* the plugin root (e.g. "assets/DepGateAlert.wav"). Anything under the
|
|
196
|
+
* plugin's `assets/` directory is shipped with the plugin automatically.
|
|
197
|
+
* Obeys the user's notification-sound setting. Allowed file types: wav, mp3,
|
|
198
|
+
* ogg, m4a, aac.
|
|
199
|
+
*/
|
|
200
|
+
playCustomSound(assetPath: string): Promise<void>;
|
|
201
|
+
/**
|
|
202
|
+
* @deprecated Use {@link PluginNotifier.playSound}. Retained for back-compat;
|
|
203
|
+
* legacy names (`alert`/`warning`/`chime`) now map onto a real bundled file.
|
|
204
|
+
*/
|
|
192
205
|
sound(name: PluginAlertSound): Promise<void>;
|
|
193
206
|
};
|
|
194
207
|
/** Input for `ctx.notify.toast`. */
|
|
@@ -199,7 +212,9 @@ export type PluginToastInput = {
|
|
|
199
212
|
durationMs?: number;
|
|
200
213
|
id?: string;
|
|
201
214
|
};
|
|
202
|
-
/**
|
|
215
|
+
/** Built-in shell sound catalogue. Semantic names mapped to bundled files by the shell. */
|
|
216
|
+
export type BuiltInSound = "attention" | "error" | "success";
|
|
217
|
+
/** @deprecated Use {@link BuiltInSound} with `playSound`. */
|
|
203
218
|
export type PluginAlertSound = "alert" | "warning" | "error" | "success" | "chime";
|
|
204
219
|
/** Visual style of a plugin's sidebar indicator. */
|
|
205
220
|
export type PluginIndicatorType = "notification" | "warning";
|
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, PluginNotifier, PluginToastInput, PluginAlertSound, } from "./context";
|
|
2
|
+
export type { PluginAirline, PluginAirlineAccessor, PluginAuthAccessor, PluginConfigStore, PluginContext, PluginDatabaseAccessor, PluginIPCRegistrar, PluginLogger, PluginServerRegistrar, PluginFlightAccessor, PluginFlightLogWriter, PluginFlightLogInput, PluginFlightLogPatch, PluginStartGuard, PluginStartContext, PluginStartDecision, PluginNotifier, PluginToastInput, BuiltInSound, PluginAlertSound, } 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
|