Files
odo/preload.js
T
taodengandClaude Opus 4.6 7c107471cf feat: Dashboard stats from OCM API, fix module warnings (v0.10.1)
- Rename postcss.config.js/tailwind.config.js to .cjs to fix ESM warning
- Replace Stats Summary placeholder with real OCM /api/stats data
- Handle loading, error, and offline states gracefully
- Bump version to 0.10.1

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-20 08:07:10 +10:00

22 lines
540 B
JavaScript

'use strict';
const { contextBridge, ipcRenderer } = require('electron');
contextBridge.exposeInMainWorld('odo', {
platform: process.platform,
version: '0.10.1',
isElectron: true,
gateway: {
status: () => ipcRenderer.invoke('gateway:status'),
start: () => ipcRenderer.invoke('gateway:start'),
stop: () => ipcRenderer.invoke('gateway:stop'),
restart: () => ipcRenderer.invoke('gateway:restart'),
},
ocm: {
api: (method, path, body) =>
ipcRenderer.invoke('ocm:api', { method, path, body }),
},
});