import { describe, expect, it } from 'bun:test';
import { renderToStaticMarkup } from 'react-dom/server';
import { ResearchCanvas } from './ResearchCanvas';

describe('ResearchCanvas', () => {
  it('renders an explicit empty state when no notes or ghosts are visible', () => {
    const html = renderToStaticMarkup(
      <ResearchCanvas
        notes={[]}
        ghosts={[]}
        density="comfortable"
        selectedNoteIds={[]}
        selectedGhostId={null}
        onSelectNote={() => {}}
        onSelectGhost={() => {}}
      />,
    );

    expect(html).toContain('No research items visible');
    expect(html).toContain('No saved notes or ghosts are visible');
  });
});
