feat(KAN-70): integrate native workspace and update settings
CI/CD / preconditions (pull_request) Successful in 1s
Native JavaScript checks / Native launcher and release tests (pull_request) Successful in 1m2s
macOS checks / Native Rust tests and unsigned build (pull_request) Successful in 1m38s
CI/CD / test_and_check_app (pull_request) Successful in 6m47s
CI/CD / Publish immutable image (pull_request) Skipped
CI/CD / preconditions (pull_request) Successful in 1s
Native JavaScript checks / Native launcher and release tests (pull_request) Successful in 1m2s
macOS checks / Native Rust tests and unsigned build (pull_request) Successful in 1m38s
CI/CD / test_and_check_app (pull_request) Successful in 6m47s
CI/CD / Publish immutable image (pull_request) Skipped
This commit is contained in:
+7
@@ -0,0 +1,7 @@
|
||||
import type { NativeBridge } from './native-app';
|
||||
|
||||
declare global {
|
||||
interface Window {
|
||||
kanbanNative?: NativeBridge;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
export type NativeUpdatePhase =
|
||||
| 'idle'
|
||||
| 'checking'
|
||||
| 'available'
|
||||
| 'current'
|
||||
| 'downloading'
|
||||
| 'verifying'
|
||||
| 'installing'
|
||||
| 'restarting'
|
||||
| 'error';
|
||||
export type NativeUpdates = {
|
||||
phase: NativeUpdatePhase;
|
||||
currentVersion: string;
|
||||
build: string;
|
||||
version: string | null;
|
||||
notes: string | null;
|
||||
downloaded: number;
|
||||
total: number | null;
|
||||
error: string | null;
|
||||
preferences: { automatic: boolean; intervalHours: 1 | 6 | 24 };
|
||||
};
|
||||
export type NativeAppState = {
|
||||
apiVersion: 1;
|
||||
platform: 'macos' | 'ios';
|
||||
version: string;
|
||||
workspace: string;
|
||||
capabilities: string[];
|
||||
updates?: NativeUpdates;
|
||||
};
|
||||
export type NativeAction =
|
||||
| 'getState'
|
||||
| 'settingsReady'
|
||||
| 'openSettings'
|
||||
| 'setWorkspace'
|
||||
| 'checkForUpdates'
|
||||
| 'setUpdatePreferences'
|
||||
| 'installUpdate';
|
||||
export type NativeBridge = {
|
||||
version: number;
|
||||
request: (
|
||||
action: NativeAction,
|
||||
payload?: Record<string, unknown>,
|
||||
) => Promise<unknown>;
|
||||
};
|
||||
Reference in New Issue
Block a user