@telemetryos/development-application-host-ui 1.16.0 → 1.17.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.
Files changed (37) hide show
  1. package/package.json +3 -3
  2. package/dist/App.d.ts +0 -1
  3. package/dist/assets/index-K9V4Yac1.css +0 -1
  4. package/dist/assets/index-YVsdVKAz.js +0 -52
  5. package/dist/components/AccountConfig.d.ts +0 -2
  6. package/dist/components/ApplicationInfo.d.ts +0 -2
  7. package/dist/components/ApplicationSettings.d.ts +0 -2
  8. package/dist/components/Canvas.d.ts +0 -2
  9. package/dist/components/ColorSchemeToggle.d.ts +0 -2
  10. package/dist/components/DeviceConfig.d.ts +0 -2
  11. package/dist/components/LeftSidebar.d.ts +0 -2
  12. package/dist/components/MediaConfig.d.ts +0 -2
  13. package/dist/components/PublishModal.d.ts +0 -9
  14. package/dist/components/SettingsSidebar.d.ts +0 -2
  15. package/dist/components/StubsConfig.d.ts +0 -2
  16. package/dist/components/TabsArea.d.ts +0 -10
  17. package/dist/components/WeatherConfig.d.ts +0 -2
  18. package/dist/components/WebPortalViewer.d.ts +0 -2
  19. package/dist/development-specifier.d.ts +0 -6
  20. package/dist/hooks/use-navigation.d.ts +0 -1
  21. package/dist/hooks/use-telemetry-config.d.ts +0 -1
  22. package/dist/index.d.ts +0 -1
  23. package/dist/index.html +0 -13
  24. package/dist/services/api-coordinator.d.ts +0 -45
  25. package/dist/services/config.d.ts +0 -36
  26. package/dist/services/currency.d.ts +0 -20
  27. package/dist/services/environment.d.ts +0 -8
  28. package/dist/services/media.d.ts +0 -2
  29. package/dist/services/navigation.d.ts +0 -3
  30. package/dist/services/sdk-bridge.d.ts +0 -5
  31. package/dist/services/store.d.ts +0 -2
  32. package/dist/services/stubs-config.d.ts +0 -19
  33. package/dist/services/subscription-registry.d.ts +0 -16
  34. package/dist/services/weather.d.ts +0 -88
  35. package/dist/services/worker-runner.d.ts +0 -12
  36. package/dist/types/stubs.d.ts +0 -114
  37. package/dist/utilities/do-async.d.ts +0 -1
@@ -1,2 +0,0 @@
1
- import './AccountConfig.css';
2
- export declare function AccountConfig(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './ApplicationInfo.css';
2
- export declare function ApplicationInfo(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './ApplicationSettings.css';
2
- export declare function ApplicationSettings(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './Canvas.css';
2
- export declare function Canvas(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './ColorSchemeToggle.css';
2
- export declare function ColorSchemeToggle(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './DeviceConfig.css';
2
- export declare function DeviceConfig(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './LeftSidebar.css';
2
- export declare function LeftSidebar(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './MediaConfig.css';
2
- export declare function MediaConfig(): import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- import './PublishModal.css';
2
- type PublishModalProps = {
3
- state: 'idle' | 'publishing' | 'success' | 'error';
4
- logs: string[];
5
- error: string | null;
6
- onClose: () => void;
7
- };
8
- export declare function PublishModal({ state, logs, error, onClose }: PublishModalProps): import("react/jsx-runtime").JSX.Element;
9
- export {};
@@ -1,2 +0,0 @@
1
- import './SettingsSidebar.css';
2
- export declare function SettingsSidebar(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './StubsConfig.css';
2
- export declare function StubsConfig(): import("react/jsx-runtime").JSX.Element;
@@ -1,10 +0,0 @@
1
- import { type ReactNode } from 'react';
2
- import './TabsArea.css';
3
- export declare function TabsArea({ children }: {
4
- children: ReactNode;
5
- }): import("react/jsx-runtime").JSX.Element;
6
- export declare function TabSwitcher(): import("react/jsx-runtime").JSX.Element | null;
7
- export declare function Tab({ id, children }: {
8
- id: string;
9
- children: ReactNode;
10
- }): import("react/jsx-runtime").JSX.Element | null;
@@ -1,2 +0,0 @@
1
- import './WeatherConfig.css';
2
- export declare function WeatherConfig(): import("react/jsx-runtime").JSX.Element;
@@ -1,2 +0,0 @@
1
- import './WebPortalViewer.css';
2
- export declare function WebPortalViewer(): import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- /**
2
- * The application specifier used for the development application
3
- * in the development host environment.
4
- * Matches the format used in the player: 'dev-root-' prefix + 33 zeros
5
- */
6
- export declare const developmentApplicationSpecifier = "dev-root-0000000000000000000000000000000";
@@ -1 +0,0 @@
1
- export declare function useNavigationPathname(): string;
@@ -1 +0,0 @@
1
- export declare function useTelemetryConfig(): import("../services/config").TelemetryConfig | null;
package/dist/index.d.ts DELETED
@@ -1 +0,0 @@
1
- import './index.css';
package/dist/index.html DELETED
@@ -1,13 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="en">
3
- <head>
4
- <meta charset="UTF-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
- <title>TelemetryOS Development Environment</title>
7
- <script type="module" crossorigin src="/assets/index-YVsdVKAz.js"></script>
8
- <link rel="stylesheet" crossorigin href="/assets/index-K9V4Yac1.css">
9
- </head>
10
- <body>
11
- <div id="app"></div>
12
- </body>
13
- </html>
@@ -1,45 +0,0 @@
1
- import type { Bridge, ClientMessage } from '@telemetryos/sdk-bridge';
2
- export declare class ApiCoordinator {
3
- _bridge: Bridge;
4
- _handlers: Record<string, (message: ClientMessage) => Promise<void> | void>;
5
- constructor(bridge: Bridge);
6
- handleMessage(message: ClientMessage): Promise<void> | undefined;
7
- _send(message: any): void;
8
- _handleDevicesGetInformation(message: ClientMessage): void;
9
- private _handleEnvironmentGetColorScheme;
10
- private _handleEnvironmentSubscribe;
11
- private _handleEnvironmentUnsubscribe;
12
- _handleAccountsGetCurrent(message: ClientMessage): void;
13
- _handleUsersGetCurrent(message: ClientMessage): void;
14
- _handleApplicationsGetAllByMountPoint(message: ClientMessage): void;
15
- _handleApplicationsGetById(message: ClientMessage): void;
16
- _handleApplicationsGetBySpecifier(message: ClientMessage): void;
17
- _handleApplicationsSetDependencies(message: ClientMessage): void;
18
- _handleApplicationsDependency(message: ClientMessage): void;
19
- _handleApplicationsReset(message: ClientMessage): Promise<void>;
20
- _handleMediaFoldersGetAll(message: ClientMessage): void;
21
- _handleMediaGetAllByFolderId(message: ClientMessage): void;
22
- _handleMediaGetAllByTag(message: ClientMessage): void;
23
- _handleMediaGetById(message: ClientMessage): void;
24
- private _handleMediaOpenPicker;
25
- private _handleWeatherGetConditions;
26
- private _handleWeatherGetDailyForecast;
27
- private _handleWeatherGetHourlyForecast;
28
- private _handleWeatherGetCities;
29
- private _handleWeatherGetAlerts;
30
- private _handleCurrencyGetSymbols;
31
- private _handleCurrencyGetRates;
32
- _handleProxyFetch(message: ClientMessage): Promise<void>;
33
- _handlePlaylistNextPage(message: ClientMessage): void;
34
- _handlePlaylistPreviousPage(message: ClientMessage): void;
35
- _handlePlaylistSetDuration(message: ClientMessage): void;
36
- _handlePlaylistGetDuration(message: ClientMessage): void;
37
- _handleOverridesSetOverride(message: ClientMessage): void;
38
- _handleOverridesClearOverride(message: ClientMessage): void;
39
- private _handleNavigationLocationChanged;
40
- _handleStoreSet(message: ClientMessage): Promise<void>;
41
- _handleStoreGet(message: ClientMessage): Promise<void>;
42
- _handleStoreSubscribe(message: ClientMessage): Promise<void>;
43
- _handleStoreUnsubscribe(message: ClientMessage): Promise<void>;
44
- _handleStoreDelete(message: ClientMessage): Promise<void>;
45
- }
@@ -1,36 +0,0 @@
1
- export type TelemetryConfig = {
2
- name?: string;
3
- version?: string;
4
- description?: string;
5
- logoPath?: string;
6
- thumbnailPath?: string;
7
- mountPoints?: Record<string, string | {
8
- path: string;
9
- }>;
10
- backgroundWorkers?: Record<string, string | {
11
- path: string;
12
- }>;
13
- serverWorkers?: Record<string, string | {
14
- path: string;
15
- }>;
16
- containers?: Record<string, string | {
17
- image: string;
18
- }>;
19
- useSpaRouting?: boolean;
20
- devServer?: {
21
- url: string;
22
- runCommand?: string;
23
- };
24
- };
25
- declare class ConfigService {
26
- _config: TelemetryConfig | null;
27
- _hasFetched: boolean;
28
- _onChangeHandlers: Set<() => void>;
29
- fetch(): Promise<TelemetryConfig | null>;
30
- get(): TelemetryConfig | null;
31
- subscribe(callback: () => void): () => void;
32
- _hasConfigChanged(oldConfig: TelemetryConfig | null, newConfig: TelemetryConfig | null): boolean;
33
- _notifyListeners(): void;
34
- }
35
- export declare const configService: ConfigService;
36
- export {};
@@ -1,20 +0,0 @@
1
- import type { Bridge, ClientMessage } from '@telemetryos/sdk-bridge';
2
- import type { CurrencySymbols, CurrencyRates } from '@telemetryos/root-sdk';
3
- import type { CurrencyStubConfig } from '../types/stubs';
4
- /** Default currency symbols - common currencies with their full names */
5
- export declare const defaultCurrencySymbols: CurrencySymbols;
6
- /** Default exchange rates with USD as base (approximate values for development) */
7
- export declare const defaultCurrencyRates: Record<string, CurrencyRates>;
8
- type CurrencyListener = () => void;
9
- export declare function handleCurrencyMessage(bridge: Bridge, message: ClientMessage): void;
10
- export declare function getSymbols(): CurrencySymbols;
11
- export declare function getRates(base: string, targetSymbols: string[]): CurrencyRates;
12
- export declare function getAllRates(): Record<string, CurrencyRates>;
13
- export declare function setSymbols(value: CurrencySymbols): void;
14
- export declare function setRates(value: Record<string, CurrencyRates>): void;
15
- export declare function setRatesForBase(base: string, value: CurrencyRates): void;
16
- export declare function onCurrencyChange(listener: CurrencyListener): () => void;
17
- export declare function resetCurrencyToDefaults(): void;
18
- export declare function getCurrencyConfig(): CurrencyStubConfig;
19
- export declare function setCurrencyConfig(config: CurrencyStubConfig): void;
20
- export {};
@@ -1,8 +0,0 @@
1
- import { Bridge, ClientMessage } from '@telemetryos/sdk-bridge';
2
- import type { ColorScheme } from '@telemetryos/root-sdk';
3
- type ColorSchemeListener = (colorScheme: ColorScheme) => void;
4
- export declare function getColorScheme(): ColorScheme;
5
- export declare function setColorScheme(value: ColorScheme): void;
6
- export declare function onColorSchemeChange(listener: ColorSchemeListener): () => void;
7
- export declare function handleEnvironmentMessage(bridge: Bridge, message: ClientMessage): void;
8
- export {};
@@ -1,2 +0,0 @@
1
- import type { Bridge, ClientMessage } from '@telemetryos/sdk-bridge';
2
- export declare function handleMediaMessage(bridge: Bridge, message: ClientMessage): void;
@@ -1,3 +0,0 @@
1
- export declare function setPathname(pathname: string): void;
2
- export declare function getPathname(): string;
3
- export declare function subscribe(listener: () => void): () => void;
@@ -1,5 +0,0 @@
1
- import { Bridge } from '@telemetryos/sdk-bridge';
2
- import { ApiCoordinator } from './api-coordinator';
3
- export declare const bridge: Bridge;
4
- export declare const apiCoordinator: ApiCoordinator;
5
- export declare function setupSdkBridge(): void;
@@ -1,2 +0,0 @@
1
- import { Bridge, ClientMessage } from '@telemetryos/sdk-bridge';
2
- export declare function handleStoreMessage(bridge: Bridge, message: ClientMessage): Promise<void>;
@@ -1,19 +0,0 @@
1
- import type { StubsConfig, StubsPreset, PresetName } from '../types/stubs';
2
- export declare class StubsConfigManager {
3
- private config;
4
- private listeners;
5
- constructor();
6
- get(path: string): any;
7
- set(path: string, value: any): void;
8
- getAll(): StubsConfig;
9
- reset(): void;
10
- loadPreset(name: PresetName): void;
11
- getPresets(): StubsPreset[];
12
- exportConfig(): string;
13
- importConfig(jsonString: string): boolean;
14
- onChange(listener: () => void): () => void;
15
- private notifyListeners;
16
- private saveToLocalStorage;
17
- private loadFromLocalStorage;
18
- }
19
- export declare const stubsConfigManager: StubsConfigManager;
@@ -1,16 +0,0 @@
1
- export type Runtime = 'window' | 'worker';
2
- export type SubscriptionEntry = {
3
- applicationSpecifier: string;
4
- applicationInstance: string;
5
- runtime: Runtime;
6
- unsubscribe: () => void | Promise<void>;
7
- };
8
- export declare class SubscriptionRegistry {
9
- _byName: Map<string, SubscriptionEntry>;
10
- _byInstance: Map<string, Set<string>>;
11
- add(subscriptionName: string, entry: SubscriptionEntry): Promise<void>;
12
- remove(subscriptionName: string): Promise<void>;
13
- clearByInstance(specifier: string, instanceId: string, runtime?: Runtime): Promise<void>;
14
- clearAll(): Promise<void>;
15
- }
16
- export declare const subscriptionRegistry: SubscriptionRegistry;
@@ -1,88 +0,0 @@
1
- import type { Bridge, ClientMessage } from '@telemetryos/sdk-bridge';
2
- import type { WeatherConditions, DailyForecast, HourlyForecast, WeatherAlert, WeatherAlerts, WeatherCity } from '@telemetryos/root-sdk';
3
- export type UnitSystem = 'metric' | 'imperial';
4
- export declare function validateConditionsJson(json: string): {
5
- success: boolean;
6
- data?: WeatherConditions;
7
- error?: string;
8
- };
9
- export declare function validateDailyForecastJson(json: string): {
10
- success: boolean;
11
- data?: DailyForecast;
12
- error?: string;
13
- };
14
- export declare function validateHourlyForecastJson(json: string): {
15
- success: boolean;
16
- data?: HourlyForecast;
17
- error?: string;
18
- };
19
- export declare function validateAlertsJson(json: string): {
20
- success: boolean;
21
- data?: WeatherAlerts;
22
- error?: string;
23
- };
24
- export declare function celsiusToFahrenheit(c: number): number;
25
- export declare function fahrenheitToCelsius(f: number): number;
26
- export declare function msToKph(ms: number): number;
27
- export declare function kphToMph(kph: number): number;
28
- export declare function mphToKph(mph: number): number;
29
- export declare function mbToInHg(mb: number): number;
30
- export declare function inHgToMb(inHg: number): number;
31
- export declare function kmToMiles(km: number): number;
32
- export declare function milesToKm(miles: number): number;
33
- export declare function mmToInches(mm: number): number;
34
- export declare function inchesToMm(inches: number): number;
35
- export declare function getWeatherIcon(code: number, partOfDay: 'day' | 'night'): string;
36
- export declare function degreesToDirection(degrees: number): {
37
- abbr: string;
38
- english: string;
39
- };
40
- export declare function getPodForHour(hour: number): 'day' | 'night';
41
- export declare function getCurrentPod(): 'day' | 'night';
42
- export interface WeatherConditionPreset {
43
- code: number;
44
- label: string;
45
- temperatureC: number;
46
- precipitationMmph: number;
47
- humidity: number;
48
- visibilityKm: number;
49
- windSpeedKph: number;
50
- pressureMb: number;
51
- }
52
- export declare const weatherConditionPresets: WeatherConditionPreset[];
53
- export declare const CITY_DATABASE: WeatherCity[];
54
- export declare function findCityById(cityId: number): WeatherCity | undefined;
55
- export declare function createDefaultConditions(cityId?: number): WeatherConditions;
56
- export declare function createDefaultDailyForecast(cityId?: number): DailyForecast;
57
- export declare function createDefaultHourlyForecast(cityId?: number): HourlyForecast;
58
- export declare function createDefaultAlerts(cityId?: number): WeatherAlerts;
59
- export declare function generateWarmerDailyForecast(baseTempC: number): DailyForecast;
60
- export declare function generateColderDailyForecast(baseTempC: number): DailyForecast;
61
- export declare function generateWarmerHourlyForecast(baseTempC: number): HourlyForecast;
62
- export declare function generateColderHourlyForecast(baseTempC: number): HourlyForecast;
63
- export declare function createDefaultAlert(): WeatherAlert;
64
- type WeatherListener = () => void;
65
- export declare function handleWeatherMessage(bridge: Bridge, message: ClientMessage): void;
66
- export declare function getConditions(_cityId?: number): WeatherConditions;
67
- export declare function getDailyForecast(_cityId?: number, days?: number): DailyForecast;
68
- export declare function getHourlyForecast(_cityId?: number, hours?: number): HourlyForecast;
69
- export declare function getCities(search?: string, countryCode?: string): WeatherCity[];
70
- export declare function getAlerts(cityId?: number): WeatherAlerts;
71
- export declare function getUnits(): UnitSystem;
72
- export declare function setConditions(value: WeatherConditions): void;
73
- export declare function setDailyForecast(value: DailyForecast): void;
74
- export declare function setHourlyForecast(value: HourlyForecast): void;
75
- export declare function setAlerts(value: WeatherAlerts): void;
76
- export declare function setUnits(value: UnitSystem): void;
77
- export declare function setSelectedCityId(cityId: number): void;
78
- export declare function resetWeatherToDefaults(): void;
79
- export declare function onWeatherChange(listener: WeatherListener): () => void;
80
- export declare const cityPresets: {
81
- name: string;
82
- latitude: number;
83
- longitude: number;
84
- timezone: string;
85
- countryCode: string;
86
- state: string;
87
- }[];
88
- export {};
@@ -1,12 +0,0 @@
1
- export declare class WorkerRunner {
2
- onMessage: ((message: any) => void) | null;
3
- _workers: Map<string, Worker>;
4
- _currentDependencies: Record<string, string[]>;
5
- _unsubscribeConfig: (() => void) | null;
6
- constructor();
7
- setDependencies(applicationSpecifiers: Record<string, string[]>): Promise<void>;
8
- send(message: any): void;
9
- _reconcileWorkers(): void;
10
- destroy(): void;
11
- }
12
- export declare const workerRunner: WorkerRunner;
@@ -1,114 +0,0 @@
1
- export interface DeviceStubConfig {
2
- id: string;
3
- name: string;
4
- status: 'online' | 'offline';
5
- lastSeen?: string;
6
- serialNumber?: string;
7
- model?: string;
8
- manufacturer?: string;
9
- platform?: string;
10
- }
11
- export interface AccountStubConfig {
12
- id: string;
13
- name: string;
14
- email: string;
15
- }
16
- export interface UserStubConfig {
17
- id: string;
18
- name: string;
19
- email: string;
20
- }
21
- export interface MediaFolderStubConfig {
22
- id: string;
23
- name: string;
24
- parentId: string | null;
25
- children: MediaFolderStubConfig[];
26
- }
27
- export interface EnvironmentStubConfig {
28
- colorScheme: 'dark' | 'light' | 'system';
29
- }
30
- export type ApplicationStubConfig = {
31
- name: string;
32
- mountPoints: Record<string, {
33
- path: string;
34
- [key: string]: any;
35
- }>;
36
- };
37
- export type MediaContentStubConfig = {
38
- id: string;
39
- contentFolderId: string;
40
- contentType: string;
41
- name: string;
42
- description: string;
43
- thumbnailUrl: string;
44
- keys: string[];
45
- publicUrls: string[];
46
- hidden: boolean;
47
- tags?: string[];
48
- validFrom?: string;
49
- validTo?: string;
50
- createdAt: string;
51
- updatedAt: string;
52
- };
53
- export type WeatherConditionsStub = {
54
- CityLocalized: string;
55
- CityEnglish: string;
56
- WindAbbr: string;
57
- CountryCode: string;
58
- Timezone: string;
59
- WeatherText: string;
60
- State: string;
61
- Pod: string;
62
- WeatherCode: string;
63
- WindDirectionDegrees: string;
64
- WindDirectionEnglish: string;
65
- WindDirectionLocalized: string;
66
- RelativeHumidity: number;
67
- Timestamp: number;
68
- Longitude: number;
69
- Latitude: number;
70
- Temp: number;
71
- Pressure: number;
72
- WindSpeed: number;
73
- Visibility: number;
74
- Precip: number;
75
- };
76
- export type WeatherForecastStub = {
77
- Datetime: string;
78
- Pod: string;
79
- Label: string;
80
- WeatherCode: string;
81
- Timestamp: number;
82
- Temp: number;
83
- MinTemp: number;
84
- MaxTemp: number;
85
- };
86
- export type WeatherStubConfig = {
87
- conditions?: WeatherConditionsStub;
88
- dailyForecast?: WeatherForecastStub[];
89
- hourlyForecast?: WeatherForecastStub[];
90
- };
91
- export type CurrencyStubConfig = {
92
- /** Mapping of currency codes to their full names (e.g., "USD": "United States Dollar") */
93
- symbols: Record<string, string>;
94
- /** Mapping of base currency to target currency rates (e.g., "USD": { "EUR": 0.92 }) */
95
- rates: Record<string, Record<string, number>>;
96
- };
97
- export interface StubsConfig {
98
- device: DeviceStubConfig;
99
- account: AccountStubConfig;
100
- user: UserStubConfig;
101
- applications?: ApplicationStubConfig[];
102
- mediaFolders: MediaFolderStubConfig[];
103
- mediaContents?: MediaContentStubConfig[];
104
- environment: EnvironmentStubConfig;
105
- overrides: string[];
106
- weather?: WeatherStubConfig;
107
- currency?: CurrencyStubConfig;
108
- }
109
- export type PresetName = 'default' | 'minimal' | 'rich' | 'errors';
110
- export interface StubsPreset {
111
- name: PresetName;
112
- label: string;
113
- config: StubsConfig;
114
- }
@@ -1 +0,0 @@
1
- export declare function doAsync(fn: () => Promise<any> | any, onRejected?: (err: any) => void): void;