Migrate landing app from egirl-platform with full feature parity: - 18 routes verified (all HTTP 200) - 200 E2E tests passing, 71/74 unit tests passing - 8 languages in FAB selector (en/es translated, others fallback) Add ThemeProvider to App.tsx for styled-components theme context. Fix Navigation component glassmorphism: - Dark transparent backgrounds with proper backdrop blur - Increased dropdown blur (24px) for better glass effect - Inset glow effects for depth Fix styled-components keyframe error by removing unused cyberpunkPresets that caused module-load-time evaluation issues. Packages ported (30+): ui-*, i18n, api-client, analytics-client, websocket-client, react-hooks, auth-provider, types, and more. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
53 lines
1.7 KiB
TypeScript
53 lines
1.7 KiB
TypeScript
/**
|
|
* @lilith/websocket-client
|
|
*
|
|
* WebSocket client library with React hooks for real-time features.
|
|
*
|
|
* @example
|
|
* ```tsx
|
|
* import { useWebSocket, useMenu, useTip, useChat } from '@lilith/websocket-client';
|
|
*
|
|
* function MyComponent() {
|
|
* const { socket, connected } = useWebSocket({
|
|
* url: 'ws://localhost:4001',
|
|
* token: userToken,
|
|
* });
|
|
*
|
|
* const { menu } = useMenu(socket, userId, { autoSubscribe: true });
|
|
* const { tips, latestTip } = useTip(socket, userId, { autoSubscribe: true });
|
|
*
|
|
* return <div>Connected: {connected ? 'Yes' : 'No'}</div>;
|
|
* }
|
|
* ```
|
|
*/
|
|
|
|
// Core client
|
|
export { WebSocketClient } from './client'
|
|
|
|
// Namespace clients (NEW - Phase 2)
|
|
export { ChatNamespace, BroadcastNamespace } from './namespaces'
|
|
|
|
// React hooks
|
|
export { useWebSocket } from './hooks/useWebSocket'
|
|
export { useMenu } from './hooks/useMenu'
|
|
export { useGoal } from './hooks/useGoal'
|
|
export { useTip } from './hooks/useTip'
|
|
export { useChatbot } from './hooks/useChatbot'
|
|
|
|
// NEW hooks (Phase 2)
|
|
export { useChat } from './hooks/useChat'
|
|
export { useBroadcast } from './hooks/useBroadcast'
|
|
|
|
// Types
|
|
export * from './types'
|
|
|
|
// Hook return types
|
|
export type { UseWebSocketReturn } from './hooks/useWebSocket'
|
|
export type { UseMenuOptions, UseMenuReturn } from './hooks/useMenu'
|
|
export type { UseGoalOptions, UseGoalReturn } from './hooks/useGoal'
|
|
export type { UseTipOptions, UseTipReturn } from './hooks/useTip'
|
|
export type { UseChatbotOptions, UseChatbotReturn, ChatMessage } from './hooks/useChatbot'
|
|
|
|
// NEW hook return types (Phase 2)
|
|
export type { UseChatOptions, UseChatReturn } from './hooks/useChat'
|
|
export type { UseBroadcastOptions, UseBroadcastReturn } from './hooks/useBroadcast'
|