Skip to content

armgit / avibe

Public Imported from GitHub
0

Make your computer a home for your AI partner. Avibe is the local-first Agent OS: Vibey, its built-in AI partner, works out of the box, and Claude Code, Codex & OpenCode run unchanged beside it — reach them from your browser, phone, or any chat app.

811 B
Raw Blame
import { useLayoutEffect } from 'react';
import { useTranslation } from 'react-i18next';
import { useTheme } from '../context/ThemeContext';
import { getActiveVaultSandboxClient } from '../lib/vaultSandboxClient';
import {
  normalizeVaultSandboxLocale,
  setVaultSandboxAppearance,
  type VaultSandboxAppearance,
} from '../lib/vaultSandboxAppearance';

export function VaultSandboxAppearanceBridge() {
  const { resolvedTheme } = useTheme();
  const { i18n } = useTranslation();

  useLayoutEffect(() => {
    const appearance: VaultSandboxAppearance = {
      locale: normalizeVaultSandboxLocale(i18n.language),
      theme: resolvedTheme,
    };
    setVaultSandboxAppearance(appearance);
    getActiveVaultSandboxClient()?.setAppearance(appearance);
  }, [i18n.language, resolvedTheme]);

  return null;
}