Central barrel export file for the hooks package, re-exporting all hook modules from a single entry point. ## Key Components | Export Group | Module | Description | |---|---|---| | UI/Platform | `./ui`, `./platform` | Core UI and platform-specific hooks | | Toast | `./use-toast` | Toast notification hook | | Contact | `./use-contact-submission` | Contact form submission hook | | Clipboard | `./use-copy-to-clipboard` | Clipboard interaction hook | | Image Auth | `./use-batch-images`, `./use-authenticated-image`, `./use-authed-image-src` | Authenticated image loading hooks | | URL State | `./state` | URL-based state management hooks | | NATS | `./nats/use-nats-client` | NATS messaging client hook | | Viewport | `./use-near-viewport` | Shared IntersectionObserver lazy-mount primitive | | Access Code | `./use-access-code-integration` | Access code context integration | | OG Placeholder | `./use-og-placeholder-url` | Endpoint-driven OG placeholder URL hook | | Scroll | `./use-scroll-to-hash` | Deep-link scroll-to-hash after data load | | Bot Protection | `./use-humanity-signals` | Honeypot + submit-timing bot protection primitive | ## Usage Example ```typescript // Import any hook directly from the package root import { useToast, useCopyToClipboard, useAuthenticatedImage, useNatsClient, useNearViewport, useScrollToHash, useHumanitySignals, } from '@openframe/hooks' function MyComponent() { const { toast } = useToast() const { copy } = useCopyToClipboard() const { ref: viewportRef } = useNearViewport() useScrollToHash({ prefix: 'ticket', isLoading: false }) return
} ``` ## Notes - **`use-access-code-integration`** is intentionally kept in `hooks/` (not `utils/`) to avoid pulling `EndpointsRuntimeContext` into server-safe bundles. - **`use-humanity-signals`** pairs with the server-side decision function in `utils/humanity-signals` — the hook handles only the client primitive (honeypot ref + timing). - **`use-near-viewport`** uses a shared `IntersectionObserver` singleton for efficient lazy-mounting across many components. **Source:** [`hooks/index.ts`](https://github.com/flamingo-stack/openframe-oss-lib/blob/main/hooks/index.ts)