Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@bagdock/hive-react

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@bagdock/hive-react - npm Package Compare versions

Comparing version
0.2.0
to
0.4.0
+113
-8
dist/index.d.mts

@@ -79,2 +79,7 @@ import { ClassValue } from 'clsx';

type DashboardRole = "customer" | "operator_owner" | "facility_manager" | "admin";
interface FacilityUnit {
size: string;
sqft: number;
price: number;
}
interface SearchFacility {

@@ -86,5 +91,7 @@ id: string;

price?: number;
priceFrom?: number;
currency?: string;
rating?: number;
reviewCount?: number;
totalReviews?: number;
latitude?: number;

@@ -94,2 +101,4 @@ longitude?: number;

features?: string[];
units?: FacilityUnit[];
unitCount?: number;
}

@@ -172,2 +181,13 @@ interface PricingPlan {

}): react_jsx_runtime.JSX.Element | null;
interface SecurePhoneInputProps {
reason?: string;
onSubmit: (phone: string) => void | Promise<void>;
defaultCountryCode?: string;
countryCodes?: {
code: string;
flag: string;
name: string;
}[];
}
declare function SecurePhoneInput({ reason, onSubmit, defaultCountryCode, countryCodes, }: SecurePhoneInputProps): react_jsx_runtime.JSX.Element;

@@ -206,3 +226,10 @@ declare function ChatMarkdown({ content }: {

}): react_jsx_runtime.JSX.Element;
declare function defaultRenderToolResult(toolName: string, output: unknown): React$1.ReactNode | null;
declare function SearchResultsCard({ data, onSendMessage, }: {
data: Record<string, unknown>;
onSendMessage?: (msg: string) => void;
}): react_jsx_runtime.JSX.Element | null;
declare function FacilityDetailCard({ data }: {
data: Record<string, unknown>;
}): react_jsx_runtime.JSX.Element | null;
declare function defaultRenderToolResult(toolName: string, output: unknown, onSendMessage?: (msg: string) => void): React$1.ReactNode | null;

@@ -218,4 +245,5 @@ interface ComposerProps {

className?: string;
showBranding?: boolean;
}
declare function Composer({ value, onChange, onSubmit, onKeyDown, isLoading, placeholder, inputRef, className, }: ComposerProps): react_jsx_runtime.JSX.Element;
declare function Composer({ value, onChange, onSubmit, onKeyDown, isLoading, placeholder, inputRef, className, showBranding, }: ComposerProps): react_jsx_runtime.JSX.Element;

@@ -244,4 +272,5 @@ declare function RecentThreadsDropdown({ threads, onSelect, onNewChat, }: {

renderToolResult?: ToolResultRenderer;
showBranding?: boolean;
}
declare function HiveChatPanel({ isOpen, onClose, onExpand, messages, onSendMessage, isLoading, suggestions, recentThreads, onLoadThread, onNewChat, className, renderToolResult, }: HiveChatPanelProps): react_jsx_runtime.JSX.Element | null;
declare function HiveChatPanel({ isOpen, onClose, onExpand, messages, onSendMessage, isLoading, suggestions, recentThreads, onLoadThread, onNewChat, className, renderToolResult, showBranding, }: HiveChatPanelProps): react_jsx_runtime.JSX.Element | null;
/** @deprecated Use HiveChatPanel */

@@ -268,4 +297,5 @@ declare const AIChatPanel: typeof HiveChatPanel;

renderToolResult?: ToolResultRenderer;
showBranding?: boolean;
}
declare function HiveFullPage({ messages, onSendMessage, isLoading, suggestions, onCollapse, onClose, className, renderToolResult, }: HiveFullPageProps): react_jsx_runtime.JSX.Element;
declare function HiveFullPage({ messages, onSendMessage, isLoading, suggestions, onCollapse, onClose, className, renderToolResult, showBranding, }: HiveFullPageProps): react_jsx_runtime.JSX.Element;
/** @deprecated Use HiveFullPage */

@@ -389,2 +419,21 @@ declare const CoraFullPage: typeof HiveFullPage;

type OtpStatus = "idle" | "verifying" | "verified" | "error";
interface OtpInputProps {
length?: number;
onComplete: (code: string) => void;
onResend: () => void;
status: OtpStatus;
error?: string | null;
cooldownSeconds?: number;
startCooldownOnMount?: boolean;
contactDisplay?: string;
disabled?: boolean;
size?: "sm" | "md";
verifiedLabel?: string;
onVerifiedComplete?: () => void;
}
declare function OtpInput({ length, onComplete, onResend, status, error, cooldownSeconds, startCooldownOnMount, contactDisplay, disabled, size, verifiedLabel, onVerifiedComplete, }: OtpInputProps): react_jsx_runtime.JSX.Element;
declare function obfuscatePhone(countryCode: string, number: string): string;
declare function obfuscateEmail(email: string): string;
interface HivePostRentalCardProps {

@@ -482,14 +531,69 @@ facilityName: string;

interface HiveAppearance {
theme?: 'light' | 'dark' | 'auto';
variables?: HiveThemeVariables;
elements?: Partial<HiveElementStyles>;
}
interface HiveThemeVariables {
colorPrimary?: string;
colorPrimaryHover?: string;
colorBackground?: string;
colorSurface?: string;
colorSurfaceUser?: string;
colorSurfaceElevated?: string;
colorText?: string;
colorTextUser?: string;
colorTextSecondary?: string;
colorBorder?: string;
colorSuccess?: string;
colorWarning?: string;
colorDanger?: string;
colorChipBg?: string;
colorChipBorder?: string;
colorChipText?: string;
colorCodeBg?: string;
colorCodeText?: string;
fontFamily?: string;
fontFamilyMono?: string;
borderRadius?: string;
borderRadiusLg?: string;
shadow?: string;
shadowLg?: string;
}
interface HiveElementStyles {
card?: string;
button?: string;
input?: string;
badge?: string;
avatar?: string;
chatBubble?: string;
chatInput?: string;
}
interface ResolvedTheme {
variables: Required<HiveThemeVariables>;
elements: HiveElementStyles;
isDark: boolean;
}
declare const DEFAULT_THEME: Required<HiveThemeVariables>;
declare const DARK_THEME: Required<HiveThemeVariables>;
declare function resolveTheme(appearance?: HiveAppearance, prefersDark?: boolean): ResolvedTheme;
declare function themeToStyle(variables: Required<HiveThemeVariables>): Record<string, string>;
interface HiveProviderConfig {
/** Custom renderer for tool results — takes precedence over built-in cards */
/** Clerk/Stripe-style appearance prop for theming all chat primitives */
appearance?: HiveAppearance;
/** Custom renderer for tool results -- takes precedence over built-in cards */
renderToolResult?: ToolResultRenderer;
/** Operator-specific bot name */
botName?: string;
/** Operator branding color (used for accent in some components) */
/** @deprecated Use appearance.variables.colorPrimary instead */
accentColor?: string;
}
interface HiveContextValue extends HiveProviderConfig {
resolvedTheme?: ResolvedTheme;
}
declare function HiveProvider({ children, ...config }: HiveProviderConfig & {
children: React$1.ReactNode;
}): react_jsx_runtime.JSX.Element;
declare function useHiveConfig(): HiveProviderConfig;
declare function useHiveConfig(): HiveContextValue;

@@ -516,2 +620,3 @@ interface UseHiveChatConfig {

currentAgent: string | null;
showBranding: boolean;
sendMessage: (text: string) => void;

@@ -542,2 +647,2 @@ clearMessages: () => void;

export { AGENT_LABELS, type AIAction, type AIAssistantContext, AIAssistantPanel, type AIAssistantSuggestion, AIBadge, AIChatPanel, AIFloatingButton, type AIMessage, type AIMessageMetadata, type AIMessagePart, type AIMessageSource, type AIRoutingMetadata, AccountProfileCard, type AddOn, AgentCheckoutFlow, AgentHistoryPanel, type AgentNotification, AgentRentalsToolCard, AssistantStrip, type AuthResult, ChatMarkdown, ChatMessage, type ChatMessageProps, Composer, type ComposerProps, CoraFullPage, CoraSearchView, type CountryCode, DashboardPromptBox, type DashboardRole, DashboardSummaryCard, HIDDEN_TOOL_STEPS, type HistorySession, HiveAssistantPanel, type HiveAssistantPanelProps, HiveAssistantStrip, type HiveAssistantStripProps, HiveBadge, HiveChatPanel, type HiveChatPanelProps, HiveCheckoutFlow, type HiveCheckoutFlowProps, HiveDashboardPrompt, type HiveDashboardPromptProps, HiveFloatingButton, type HiveFloatingButtonProps, HiveFullPage, type HiveFullPageProps, HiveHistoryPanel, type HiveHistoryPanelProps, HiveInlineAuth, type HiveInlineAuthProps, HiveInlineHint, type HiveInlineHintProps, HivePostRentalCard, type HivePostRentalCardProps, HiveProvider, type HiveProviderConfig, HiveSearchView, type HiveSearchViewProps, InlineChatAuth, InlineSmartHint, LoadingMessage, LoyaltyCard, PaymentSummaryCard, PostRentalCard, type PricingPlan, type ProtectionPlan, QuickReplyChips, ReasoningBlock, type RecentThread, RecentThreadsDropdown, type SearchFacility, type SendOtpParams, type SendOtpResult, TOOL_STEP_LABELS, ToolExecutionStep, type ToolResultRenderer, type UseHiveChatConfig, type UseHiveChatReturn, VerificationCard, type VerifyOtpParams, type VerifyOtpResult, cn, currencySymbol, defaultRenderToolResult, formatTimeAgo, isToolDone, isToolError, useHiveChat, useHiveConfig };
export { AGENT_LABELS, type AIAction, type AIAssistantContext, AIAssistantPanel, type AIAssistantSuggestion, AIBadge, AIChatPanel, AIFloatingButton, type AIMessage, type AIMessageMetadata, type AIMessagePart, type AIMessageSource, type AIRoutingMetadata, AccountProfileCard, type AddOn, AgentCheckoutFlow, AgentHistoryPanel, type AgentNotification, AgentRentalsToolCard, AssistantStrip, type AuthResult, ChatMarkdown, ChatMessage, type ChatMessageProps, Composer, type ComposerProps, CoraFullPage, CoraSearchView, type CountryCode, DARK_THEME, DEFAULT_THEME, DashboardPromptBox, type DashboardRole, DashboardSummaryCard, FacilityDetailCard, type FacilityUnit, HIDDEN_TOOL_STEPS, type HistorySession, type HiveAppearance, HiveAssistantPanel, type HiveAssistantPanelProps, HiveAssistantStrip, type HiveAssistantStripProps, HiveBadge, HiveChatPanel, type HiveChatPanelProps, HiveCheckoutFlow, type HiveCheckoutFlowProps, HiveDashboardPrompt, type HiveDashboardPromptProps, type HiveElementStyles, HiveFloatingButton, type HiveFloatingButtonProps, HiveFullPage, type HiveFullPageProps, HiveHistoryPanel, type HiveHistoryPanelProps, HiveInlineAuth, type HiveInlineAuthProps, HiveInlineHint, type HiveInlineHintProps, HivePostRentalCard, type HivePostRentalCardProps, HiveProvider, type HiveProviderConfig, HiveSearchView, type HiveSearchViewProps, type HiveThemeVariables, InlineChatAuth, InlineSmartHint, LoadingMessage, LoyaltyCard, OtpInput, type OtpInputProps, type OtpStatus, PaymentSummaryCard, PostRentalCard, type PricingPlan, type ProtectionPlan, QuickReplyChips, ReasoningBlock, type RecentThread, RecentThreadsDropdown, type ResolvedTheme, type SearchFacility, SearchResultsCard, SecurePhoneInput, type SecurePhoneInputProps, type SendOtpParams, type SendOtpResult, TOOL_STEP_LABELS, ToolExecutionStep, type ToolResultRenderer, type UseHiveChatConfig, type UseHiveChatReturn, VerificationCard, type VerifyOtpParams, type VerifyOtpResult, cn, currencySymbol, defaultRenderToolResult, formatTimeAgo, isToolDone, isToolError, obfuscateEmail, obfuscatePhone, resolveTheme, themeToStyle, useHiveChat, useHiveConfig };

@@ -79,2 +79,7 @@ import { ClassValue } from 'clsx';

type DashboardRole = "customer" | "operator_owner" | "facility_manager" | "admin";
interface FacilityUnit {
size: string;
sqft: number;
price: number;
}
interface SearchFacility {

@@ -86,5 +91,7 @@ id: string;

price?: number;
priceFrom?: number;
currency?: string;
rating?: number;
reviewCount?: number;
totalReviews?: number;
latitude?: number;

@@ -94,2 +101,4 @@ longitude?: number;

features?: string[];
units?: FacilityUnit[];
unitCount?: number;
}

@@ -172,2 +181,13 @@ interface PricingPlan {

}): react_jsx_runtime.JSX.Element | null;
interface SecurePhoneInputProps {
reason?: string;
onSubmit: (phone: string) => void | Promise<void>;
defaultCountryCode?: string;
countryCodes?: {
code: string;
flag: string;
name: string;
}[];
}
declare function SecurePhoneInput({ reason, onSubmit, defaultCountryCode, countryCodes, }: SecurePhoneInputProps): react_jsx_runtime.JSX.Element;

@@ -206,3 +226,10 @@ declare function ChatMarkdown({ content }: {

}): react_jsx_runtime.JSX.Element;
declare function defaultRenderToolResult(toolName: string, output: unknown): React$1.ReactNode | null;
declare function SearchResultsCard({ data, onSendMessage, }: {
data: Record<string, unknown>;
onSendMessage?: (msg: string) => void;
}): react_jsx_runtime.JSX.Element | null;
declare function FacilityDetailCard({ data }: {
data: Record<string, unknown>;
}): react_jsx_runtime.JSX.Element | null;
declare function defaultRenderToolResult(toolName: string, output: unknown, onSendMessage?: (msg: string) => void): React$1.ReactNode | null;

@@ -218,4 +245,5 @@ interface ComposerProps {

className?: string;
showBranding?: boolean;
}
declare function Composer({ value, onChange, onSubmit, onKeyDown, isLoading, placeholder, inputRef, className, }: ComposerProps): react_jsx_runtime.JSX.Element;
declare function Composer({ value, onChange, onSubmit, onKeyDown, isLoading, placeholder, inputRef, className, showBranding, }: ComposerProps): react_jsx_runtime.JSX.Element;

@@ -244,4 +272,5 @@ declare function RecentThreadsDropdown({ threads, onSelect, onNewChat, }: {

renderToolResult?: ToolResultRenderer;
showBranding?: boolean;
}
declare function HiveChatPanel({ isOpen, onClose, onExpand, messages, onSendMessage, isLoading, suggestions, recentThreads, onLoadThread, onNewChat, className, renderToolResult, }: HiveChatPanelProps): react_jsx_runtime.JSX.Element | null;
declare function HiveChatPanel({ isOpen, onClose, onExpand, messages, onSendMessage, isLoading, suggestions, recentThreads, onLoadThread, onNewChat, className, renderToolResult, showBranding, }: HiveChatPanelProps): react_jsx_runtime.JSX.Element | null;
/** @deprecated Use HiveChatPanel */

@@ -268,4 +297,5 @@ declare const AIChatPanel: typeof HiveChatPanel;

renderToolResult?: ToolResultRenderer;
showBranding?: boolean;
}
declare function HiveFullPage({ messages, onSendMessage, isLoading, suggestions, onCollapse, onClose, className, renderToolResult, }: HiveFullPageProps): react_jsx_runtime.JSX.Element;
declare function HiveFullPage({ messages, onSendMessage, isLoading, suggestions, onCollapse, onClose, className, renderToolResult, showBranding, }: HiveFullPageProps): react_jsx_runtime.JSX.Element;
/** @deprecated Use HiveFullPage */

@@ -389,2 +419,21 @@ declare const CoraFullPage: typeof HiveFullPage;

type OtpStatus = "idle" | "verifying" | "verified" | "error";
interface OtpInputProps {
length?: number;
onComplete: (code: string) => void;
onResend: () => void;
status: OtpStatus;
error?: string | null;
cooldownSeconds?: number;
startCooldownOnMount?: boolean;
contactDisplay?: string;
disabled?: boolean;
size?: "sm" | "md";
verifiedLabel?: string;
onVerifiedComplete?: () => void;
}
declare function OtpInput({ length, onComplete, onResend, status, error, cooldownSeconds, startCooldownOnMount, contactDisplay, disabled, size, verifiedLabel, onVerifiedComplete, }: OtpInputProps): react_jsx_runtime.JSX.Element;
declare function obfuscatePhone(countryCode: string, number: string): string;
declare function obfuscateEmail(email: string): string;
interface HivePostRentalCardProps {

@@ -482,14 +531,69 @@ facilityName: string;

interface HiveAppearance {
theme?: 'light' | 'dark' | 'auto';
variables?: HiveThemeVariables;
elements?: Partial<HiveElementStyles>;
}
interface HiveThemeVariables {
colorPrimary?: string;
colorPrimaryHover?: string;
colorBackground?: string;
colorSurface?: string;
colorSurfaceUser?: string;
colorSurfaceElevated?: string;
colorText?: string;
colorTextUser?: string;
colorTextSecondary?: string;
colorBorder?: string;
colorSuccess?: string;
colorWarning?: string;
colorDanger?: string;
colorChipBg?: string;
colorChipBorder?: string;
colorChipText?: string;
colorCodeBg?: string;
colorCodeText?: string;
fontFamily?: string;
fontFamilyMono?: string;
borderRadius?: string;
borderRadiusLg?: string;
shadow?: string;
shadowLg?: string;
}
interface HiveElementStyles {
card?: string;
button?: string;
input?: string;
badge?: string;
avatar?: string;
chatBubble?: string;
chatInput?: string;
}
interface ResolvedTheme {
variables: Required<HiveThemeVariables>;
elements: HiveElementStyles;
isDark: boolean;
}
declare const DEFAULT_THEME: Required<HiveThemeVariables>;
declare const DARK_THEME: Required<HiveThemeVariables>;
declare function resolveTheme(appearance?: HiveAppearance, prefersDark?: boolean): ResolvedTheme;
declare function themeToStyle(variables: Required<HiveThemeVariables>): Record<string, string>;
interface HiveProviderConfig {
/** Custom renderer for tool results — takes precedence over built-in cards */
/** Clerk/Stripe-style appearance prop for theming all chat primitives */
appearance?: HiveAppearance;
/** Custom renderer for tool results -- takes precedence over built-in cards */
renderToolResult?: ToolResultRenderer;
/** Operator-specific bot name */
botName?: string;
/** Operator branding color (used for accent in some components) */
/** @deprecated Use appearance.variables.colorPrimary instead */
accentColor?: string;
}
interface HiveContextValue extends HiveProviderConfig {
resolvedTheme?: ResolvedTheme;
}
declare function HiveProvider({ children, ...config }: HiveProviderConfig & {
children: React$1.ReactNode;
}): react_jsx_runtime.JSX.Element;
declare function useHiveConfig(): HiveProviderConfig;
declare function useHiveConfig(): HiveContextValue;

@@ -516,2 +620,3 @@ interface UseHiveChatConfig {

currentAgent: string | null;
showBranding: boolean;
sendMessage: (text: string) => void;

@@ -542,2 +647,2 @@ clearMessages: () => void;

export { AGENT_LABELS, type AIAction, type AIAssistantContext, AIAssistantPanel, type AIAssistantSuggestion, AIBadge, AIChatPanel, AIFloatingButton, type AIMessage, type AIMessageMetadata, type AIMessagePart, type AIMessageSource, type AIRoutingMetadata, AccountProfileCard, type AddOn, AgentCheckoutFlow, AgentHistoryPanel, type AgentNotification, AgentRentalsToolCard, AssistantStrip, type AuthResult, ChatMarkdown, ChatMessage, type ChatMessageProps, Composer, type ComposerProps, CoraFullPage, CoraSearchView, type CountryCode, DashboardPromptBox, type DashboardRole, DashboardSummaryCard, HIDDEN_TOOL_STEPS, type HistorySession, HiveAssistantPanel, type HiveAssistantPanelProps, HiveAssistantStrip, type HiveAssistantStripProps, HiveBadge, HiveChatPanel, type HiveChatPanelProps, HiveCheckoutFlow, type HiveCheckoutFlowProps, HiveDashboardPrompt, type HiveDashboardPromptProps, HiveFloatingButton, type HiveFloatingButtonProps, HiveFullPage, type HiveFullPageProps, HiveHistoryPanel, type HiveHistoryPanelProps, HiveInlineAuth, type HiveInlineAuthProps, HiveInlineHint, type HiveInlineHintProps, HivePostRentalCard, type HivePostRentalCardProps, HiveProvider, type HiveProviderConfig, HiveSearchView, type HiveSearchViewProps, InlineChatAuth, InlineSmartHint, LoadingMessage, LoyaltyCard, PaymentSummaryCard, PostRentalCard, type PricingPlan, type ProtectionPlan, QuickReplyChips, ReasoningBlock, type RecentThread, RecentThreadsDropdown, type SearchFacility, type SendOtpParams, type SendOtpResult, TOOL_STEP_LABELS, ToolExecutionStep, type ToolResultRenderer, type UseHiveChatConfig, type UseHiveChatReturn, VerificationCard, type VerifyOtpParams, type VerifyOtpResult, cn, currencySymbol, defaultRenderToolResult, formatTimeAgo, isToolDone, isToolError, useHiveChat, useHiveConfig };
export { AGENT_LABELS, type AIAction, type AIAssistantContext, AIAssistantPanel, type AIAssistantSuggestion, AIBadge, AIChatPanel, AIFloatingButton, type AIMessage, type AIMessageMetadata, type AIMessagePart, type AIMessageSource, type AIRoutingMetadata, AccountProfileCard, type AddOn, AgentCheckoutFlow, AgentHistoryPanel, type AgentNotification, AgentRentalsToolCard, AssistantStrip, type AuthResult, ChatMarkdown, ChatMessage, type ChatMessageProps, Composer, type ComposerProps, CoraFullPage, CoraSearchView, type CountryCode, DARK_THEME, DEFAULT_THEME, DashboardPromptBox, type DashboardRole, DashboardSummaryCard, FacilityDetailCard, type FacilityUnit, HIDDEN_TOOL_STEPS, type HistorySession, type HiveAppearance, HiveAssistantPanel, type HiveAssistantPanelProps, HiveAssistantStrip, type HiveAssistantStripProps, HiveBadge, HiveChatPanel, type HiveChatPanelProps, HiveCheckoutFlow, type HiveCheckoutFlowProps, HiveDashboardPrompt, type HiveDashboardPromptProps, type HiveElementStyles, HiveFloatingButton, type HiveFloatingButtonProps, HiveFullPage, type HiveFullPageProps, HiveHistoryPanel, type HiveHistoryPanelProps, HiveInlineAuth, type HiveInlineAuthProps, HiveInlineHint, type HiveInlineHintProps, HivePostRentalCard, type HivePostRentalCardProps, HiveProvider, type HiveProviderConfig, HiveSearchView, type HiveSearchViewProps, type HiveThemeVariables, InlineChatAuth, InlineSmartHint, LoadingMessage, LoyaltyCard, OtpInput, type OtpInputProps, type OtpStatus, PaymentSummaryCard, PostRentalCard, type PricingPlan, type ProtectionPlan, QuickReplyChips, ReasoningBlock, type RecentThread, RecentThreadsDropdown, type ResolvedTheme, type SearchFacility, SearchResultsCard, SecurePhoneInput, type SecurePhoneInputProps, type SendOtpParams, type SendOtpResult, TOOL_STEP_LABELS, ToolExecutionStep, type ToolResultRenderer, type UseHiveChatConfig, type UseHiveChatReturn, VerificationCard, type VerifyOtpParams, type VerifyOtpResult, cn, currencySymbol, defaultRenderToolResult, formatTimeAgo, isToolDone, isToolError, obfuscateEmail, obfuscatePhone, resolveTheme, themeToStyle, useHiveChat, useHiveConfig };
+3
-2
{
"name": "@bagdock/hive-react",
"version": "0.2.0",
"version": "0.4.0",
"description": "Bagdock Hive React SDK — embeddable AI chat, rental, and access widgets for self-storage",

@@ -34,3 +34,4 @@ "main": "dist/index.js",

"dependencies": {
"@bagdock/hive": "^0.2.0",
"@bagdock/hive": "^0.3.0",
"@bagdock/pii-patterns": "^0.1.0",
"clsx": "^2.1.0",

@@ -37,0 +38,0 @@ "tailwind-merge": "^2.2.0"

@@ -28,2 +28,14 @@ ```

```bash
yarn add @bagdock/hive-react @bagdock/hive react react-dom lucide-react
```
```bash
pnpm add @bagdock/hive-react @bagdock/hive react react-dom lucide-react
```
```bash
bun add @bagdock/hive-react @bagdock/hive react react-dom lucide-react
```
**Peer dependencies:** `react >= 18`, `react-dom >= 18`, `lucide-react >= 0.300`

@@ -302,2 +314,45 @@

## Appearance theming
Style all Hive components with a declarative `appearance` prop. Supports light, dark, and auto (system) presets with custom variable overrides.
```tsx
import { HiveProvider, DARK_THEME } from '@bagdock/hive-react'
function App() {
return (
<HiveProvider
apiKey="ek_live_..."
appearance={{ theme: 'dark' }}
>
<ChatPage />
</HiveProvider>
)
}
```
Custom variable overrides:
```tsx
<HiveProvider
apiKey="ek_live_..."
appearance={{
theme: 'light',
variables: {
colorPrimary: '#0ea5e9',
colorSurface: '#f0f9ff',
fontFamily: '"Inter", sans-serif',
},
}}
>
```
Available theme variables: `colorPrimary`, `colorBackground`, `colorSurface`, `colorSurfaceUser`, `colorText`, `colorTextSecondary`, `colorBorder`, `colorSuccess`, `colorDanger`, `colorChipBg`, `colorChipText`, `colorCodeBg`, `fontFamily`, `fontFamilyMono`, `borderRadius`, `shadow`, and more.
## PII scrubbing
User messages are automatically scrubbed for PII before leaving the browser via `@bagdock/pii-patterns` — defense-in-depth redaction of emails, SSNs, phone numbers, IBANs, and 11 more patterns. Server-side WASM scrubbing remains authoritative.
---
## Component reference

@@ -332,3 +387,4 @@

| `currentAgent` | `string \| null` | Active agent context |
| `sendMessage` | `(text: string) => void` | Send a user message |
| `showBranding` | `boolean` | Whether to show "powered by Bagdock" (controlled by plan) |
| `sendMessage` | `(text: string) => void` | Send a user message (auto-scrubs PII) |
| `clearMessages` | `() => void` | Reset the conversation |

@@ -354,2 +410,4 @@ | `setMessages` | `Dispatch<SetStateAction>` | Direct state access |

|-----------|------|-------------|
| `SearchResultsCard` | `searchFacilities` | Facility list with chips, unit pills, and pricing |
| `FacilityDetailCard` | `selectFacility` / `openPreview` | Detailed facility preview with features |
| `AgentRentalsToolCard` | `getMyRentals` | List of active rentals |

@@ -383,3 +441,16 @@ | `PaymentSummaryCard` | `getMyNextPayment` | Upcoming payment details |

| `HivePostRentalCard` | Confirmation card after checkout |
| `SecurePhoneInput` | Secure phone capture with country code picker |
| `OtpInput` | OTP verification input with resend cooldown and paste handling |
### Utility exports
| Export | Description |
|--------|-------------|
| `obfuscatePhone(countryCode, number)` | Mask a phone number for display (e.g. `+44 ****1234`) |
| `obfuscateEmail(email)` | Mask an email for display (e.g. `j****n@example.com`) |
| `DEFAULT_THEME` | Default light theme variables |
| `DARK_THEME` | Dark theme preset |
| `resolveTheme(appearance)` | Resolve appearance config to a full theme |
| `themeToStyle(variables)` | Convert theme variables to CSS custom properties |
### Backward compatibility

@@ -442,3 +513,3 @@

Components use Tailwind CSS classes. Include the package in your Tailwind `content` config:
Components use Tailwind CSS with CSS custom properties (`--hive-*`) for theming. Include the package in your Tailwind `content` config:

@@ -455,4 +526,6 @@ ```javascript

All components fall back to sensible defaults when no `HiveProvider` is present, so they work out-of-the-box without theming configuration.
## License
MIT

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display