Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
Mirrored from https://github.com/Camo67/composio.git
Synced Nov 21, 03:37 UTC
| 1 | "use client" |
| 2 | |
| 3 | import { useTerminalThemeOptional } from "@/components/terminal-theme-provider" |
| 4 | import { useDetectedTerminalTheme } from "@/hooks/use-detected-terminal-theme" |
| 5 | import { |
| 6 | terminalLayoutMode, |
| 7 | type TerminalLayoutMode, |
| 8 | } from "@/lib/terminal-layout" |
| 9 | import type { TerminalTheme } from "@/lib/terminal-themes" |
| 10 | |
| 11 | export function useResolvedTerminalTheme() { |
| 12 | const providerTheme = useTerminalThemeOptional() |
| 13 | const { ref, theme: detectedTheme } = useDetectedTerminalTheme() |
| 14 | const theme: TerminalTheme = providerTheme?.theme ?? detectedTheme |
| 15 | const layoutMode: TerminalLayoutMode = terminalLayoutMode(theme) |
| 16 | |
| 17 | return { |
| 18 | ref, |
| 19 | theme, |
| 20 | layoutMode, |
| 21 | isBubble: layoutMode === "bubble", |
| 22 | isCompact: layoutMode === "compact", |
| 23 | isClaude: layoutMode === "claude", |
| 24 | } |
| 25 | } |