Skip to content

No Theme Detection Hook #5

@JakeLin

Description

@JakeLin

Currently no way to respond to theme changes:

// Current: Manual check
const theme = window.openai?.theme;

// Should have:
import { useTheme } from '@ainativekit/ui';

function MyComponent() {
  const theme = useTheme(); // 'light' | 'dark', updates on change
  
  return <div>Current theme: {theme}</div>;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions