import { Awareness } from 'y-protocols/awareness'; import { WorkbookInstance } from '../../sheet-engine/react'; import { CollabUser } from '../../sync-local/types'; /** * Reads remote cursor positions from Yjs awareness and keeps Fortune sheet's * native presence list in sync. Fortune renders colored cell borders + username * labels automatically via context.presences[]. * * Also emits the full collaborator list (including the local user) via * `onCollaboratorsChange` so host apps can render navbar chips. This mirrors * ddoc's editor-layer awareness handler, which maps awareness.states → * `{ clientId, ...user }` and fires on every awareness update + once on mount. */ export declare const useCollabAwareness: (awareness: Awareness | null | undefined, sheetEditorRef: React.MutableRefObject, onCollaboratorsChange?: (collaborators: CollabUser[]) => void) => { localColor: "#30bced" | "#6eeb83" | "#fa69d1" | "#ecd444" | "#ee6352" | "#db3041" | "#0ad7f2" | "#1bff39"; };