Documentation
    Preparing search index...

    Interface ThemeServiceOptions

    Configuration for createThemeService.

    const theme = createThemeService({
    initialTheme: { colors: { background: '#fff', text: '#000', primary: '#00f' } },
    onBroadcast: (envelope) => shellBridge.broadcastToAll(envelope),
    });
    interface ThemeServiceOptions {
        initialTheme?: Theme;
        onBroadcast?: (envelope: ThemeChangedMessage) => void;
    }
    Index

    Properties

    initialTheme?: Theme

    Override the default theme payload. If omitted, the service starts with the canonical defaults (#0a0a0a / #e0e0e0 / #7aa2f7).

    onBroadcast?: (envelope: ThemeChangedMessage) => void

    Called synchronously from publishTheme(theme) with a theme.changed envelope. Intended for the shell adapter (Plan 13-02) to fan-out the push to every registered napplet via the runtime's sendToNapplet primitive.

    Keep this callback shape framework-agnostic — the service does NOT import any shell / browser APIs.