@algenium/blocks 1.9.1 → 1.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import React__default from 'react';
2
+ import React__default, { ReactNode } from 'react';
3
3
  import * as react_jsx_runtime from 'react/jsx-runtime';
4
4
  import { LucideIcon } from 'lucide-react';
5
5
  import * as class_variance_authority_types from 'class-variance-authority/types';
@@ -247,6 +247,36 @@ type ThemeSwitcherProps = {
247
247
  };
248
248
  declare function ThemeSwitcher({ className, size, shape, variant, align, side, labels: userLabels, }: ThemeSwitcherProps): react_jsx_runtime.JSX.Element;
249
249
 
250
+ type OrgSwitcherTenant = {
251
+ id: string;
252
+ name: string;
253
+ logo?: string | null;
254
+ role?: string;
255
+ statusBadge?: ReactNode;
256
+ };
257
+ type OrgSwitcherLabels = {
258
+ /** Dropdown section heading */
259
+ heading?: string;
260
+ /** Create action label */
261
+ create?: string;
262
+ /** Empty state when no active tenant */
263
+ empty?: string;
264
+ };
265
+ type OrgSwitcherProps = {
266
+ activeTenant: OrgSwitcherTenant | null;
267
+ tenants: OrgSwitcherTenant[];
268
+ onSelectTenant: (id: string) => void;
269
+ createUrl?: string;
270
+ isLoading?: boolean;
271
+ collapsed?: boolean;
272
+ isMobile?: boolean;
273
+ activeSubtitle?: string;
274
+ labels?: OrgSwitcherLabels;
275
+ className?: string;
276
+ triggerClassName?: string;
277
+ };
278
+ declare function OrgSwitcher({ activeTenant, tenants, onSelectTenant, createUrl, isLoading, collapsed, isMobile, activeSubtitle, labels: userLabels, className, triggerClassName: triggerClassNameProp, }: OrgSwitcherProps): react_jsx_runtime.JSX.Element;
279
+
250
280
  type Language = {
251
281
  /** Language key/code (e.g., "en", "es") */
252
282
  key: string;
@@ -899,6 +929,33 @@ interface USAddressInputProps {
899
929
  }
900
930
  declare function USAddressInput({ value, onChange, lookupZip, validateAddress, autocomplete, labels, disabled, largeText, className, onError, }: USAddressInputProps): react_jsx_runtime.JSX.Element;
901
931
 
932
+ type MexicoStateId = "MXAGU" | "MXBCN" | "MXBCS" | "MXCAM" | "MXCHP" | "MXCHH" | "MXCMX" | "MXCOA" | "MXCOL" | "MXDUR" | "MXGUA" | "MXGRO" | "MXHID" | "MXJAL" | "MXMEX" | "MXMIC" | "MXMOR" | "MXNAY" | "MXNLE" | "MXOAX" | "MXPUE" | "MXQUE" | "MXROO" | "MXSLP" | "MXSIN" | "MXSON" | "MXTAB" | "MXTAM" | "MXTLA" | "MXVER" | "MXYUC" | "MXZAC";
933
+ interface MexicoState {
934
+ id: MexicoStateId;
935
+ name: string;
936
+ }
937
+ declare const MEXICO_STATES: MexicoState[];
938
+
939
+ interface MexicoMapProps {
940
+ selected: MexicoStateId[];
941
+ /** Omit to render a read-only display (no interaction, no keyboard handlers). */
942
+ onToggle?: (id: MexicoStateId) => void;
943
+ className?: string;
944
+ }
945
+ declare function MexicoMap({ selected, onToggle, className }: MexicoMapProps): react_jsx_runtime.JSX.Element;
946
+
947
+ type DoctorVerificationStatus = "unverified" | "pending_review" | "verified";
948
+ interface VerifiedDoctorBadgeProps {
949
+ status: DoctorVerificationStatus;
950
+ size?: "sm" | "md";
951
+ /** Icon-only with title/aria-label when false (default). */
952
+ showLabel?: boolean;
953
+ className?: string;
954
+ }
955
+ declare function VerifiedDoctorBadge({ status, size, showLabel, className, }: VerifiedDoctorBadgeProps): react_jsx_runtime.JSX.Element | null;
956
+
957
+ declare const MEXICO_STATE_PATHS: Record<MexicoStateId, string>;
958
+
902
959
  declare function cn(...inputs: ClassValue[]): string;
903
960
 
904
- export { type AddressAutocompleteAdapter, AvatarEditor, AvatarEditorDialog, type AvatarEditorDialogProps, type AvatarEditorProps, BLOCKS_DATA_ENVIRONMENTS, type BlocksDataEnvironment, type BlocksLanguage, type BlocksNotification, Button, CalendarContext, type CalendarContextValue, type CalendarData, type CalendarEvent, CalendarSubscribeButton, type CalendarSubscribeButtonProps, CalendarView, type CalendarViewLabels, type CalendarViewMode, type CalendarViewProps, CalendarWidget, type CalendarWidgetLabels, type CalendarWidgetProps, CardInput, type CardInputLabels, type CardInputProps, type CardTokenResult, type ChatConversation, type ChatConversationRoom, type ChatMessageData, type ChatRoomConfig, ChatRoomView, type ChatRoomViewLabels, type ChatRoomViewProps, ChatSidebar, ChatSidebarContext, type ChatSidebarContextValue, type ChatSidebarLabels, type ChatSidebarProps, ChatSidebarProvider, type ChatSidebarProviderProps, type ChatSidebarView, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EmptyState, type EmptyStateProps, EnvironmentBanner, type EnvironmentBannerLabels, type EnvironmentBannerProps, EnvironmentContext, type EnvironmentContextValue, EnvironmentDot, type EnvironmentDotProps, EnvironmentMiniBadge, type EnvironmentMiniBadgeProps, EnvironmentSwitcher, type EnvironmentSwitcherLabels, type EnvironmentSwitcherProps, ErrorState, EventDialog, type EventDialogLabels, type EventDialogProps, EventRsvpBadge, type EventRsvpBadgeProps, type Language, LanguageContext, type LanguageContextValue, LanguageSwitcher, type LanguageSwitcherLabels, type LanguageSwitcherProps, LoadingState, MiniCalendar, type MiniCalendarProps, type Notification, type NotificationType, NotificationsContext, type NotificationsContextValue, NotificationsWidget, type NotificationsWidgetProps, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, ScrollArea, ScrollBar, Slider, ThemeSwitcher, type ThemeSwitcherLabels, type ThemeSwitcherProps, Toggle, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, USAddressInput, type USAddressInputLabels, type USAddressInputProps, type USAddressValue, UpcomingEvents, type UpcomingEventsProps, type UseChatRoomResult, buttonVariants, cn, defaultLanguages, getEnvironmentDotClass, getEnvironmentLabel, isBlocksDataEnvironment, toggleVariants, useCalendarContext, useChatRoom, useChatSidebar, useDebouncedValue, useDebouncedValueStrict, useEnvironmentContext, useLanguageContext, useNotificationsContext };
961
+ export { type AddressAutocompleteAdapter, AvatarEditor, AvatarEditorDialog, type AvatarEditorDialogProps, type AvatarEditorProps, BLOCKS_DATA_ENVIRONMENTS, type BlocksDataEnvironment, type BlocksLanguage, type BlocksNotification, Button, CalendarContext, type CalendarContextValue, type CalendarData, type CalendarEvent, CalendarSubscribeButton, type CalendarSubscribeButtonProps, CalendarView, type CalendarViewLabels, type CalendarViewMode, type CalendarViewProps, CalendarWidget, type CalendarWidgetLabels, type CalendarWidgetProps, CardInput, type CardInputLabels, type CardInputProps, type CardTokenResult, type ChatConversation, type ChatConversationRoom, type ChatMessageData, type ChatRoomConfig, ChatRoomView, type ChatRoomViewLabels, type ChatRoomViewProps, ChatSidebar, ChatSidebarContext, type ChatSidebarContextValue, type ChatSidebarLabels, type ChatSidebarProps, ChatSidebarProvider, type ChatSidebarProviderProps, type ChatSidebarView, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, type DoctorVerificationStatus, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EmptyState, type EmptyStateProps, EnvironmentBanner, type EnvironmentBannerLabels, type EnvironmentBannerProps, EnvironmentContext, type EnvironmentContextValue, EnvironmentDot, type EnvironmentDotProps, EnvironmentMiniBadge, type EnvironmentMiniBadgeProps, EnvironmentSwitcher, type EnvironmentSwitcherLabels, type EnvironmentSwitcherProps, ErrorState, EventDialog, type EventDialogLabels, type EventDialogProps, EventRsvpBadge, type EventRsvpBadgeProps, type Language, LanguageContext, type LanguageContextValue, LanguageSwitcher, type LanguageSwitcherLabels, type LanguageSwitcherProps, LoadingState, MEXICO_STATES, MEXICO_STATE_PATHS, MexicoMap, type MexicoMapProps, type MexicoState, type MexicoStateId, MiniCalendar, type MiniCalendarProps, type Notification, type NotificationType, NotificationsContext, type NotificationsContextValue, NotificationsWidget, type NotificationsWidgetProps, OrgSwitcher, type OrgSwitcherLabels, type OrgSwitcherProps, type OrgSwitcherTenant, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, ScrollArea, ScrollBar, Slider, ThemeSwitcher, type ThemeSwitcherLabels, type ThemeSwitcherProps, Toggle, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, USAddressInput, type USAddressInputLabels, type USAddressInputProps, type USAddressValue, UpcomingEvents, type UpcomingEventsProps, type UseChatRoomResult, VerifiedDoctorBadge, type VerifiedDoctorBadgeProps, buttonVariants, cn, defaultLanguages, getEnvironmentDotClass, getEnvironmentLabel, isBlocksDataEnvironment, toggleVariants, useCalendarContext, useChatRoom, useChatSidebar, useDebouncedValue, useDebouncedValueStrict, useEnvironmentContext, useLanguageContext, useNotificationsContext };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import React__default from 'react';
2
+ import React__default, { ReactNode } from 'react';
3
3
  import * as react_jsx_runtime from 'react/jsx-runtime';
4
4
  import { LucideIcon } from 'lucide-react';
5
5
  import * as class_variance_authority_types from 'class-variance-authority/types';
@@ -247,6 +247,36 @@ type ThemeSwitcherProps = {
247
247
  };
248
248
  declare function ThemeSwitcher({ className, size, shape, variant, align, side, labels: userLabels, }: ThemeSwitcherProps): react_jsx_runtime.JSX.Element;
249
249
 
250
+ type OrgSwitcherTenant = {
251
+ id: string;
252
+ name: string;
253
+ logo?: string | null;
254
+ role?: string;
255
+ statusBadge?: ReactNode;
256
+ };
257
+ type OrgSwitcherLabels = {
258
+ /** Dropdown section heading */
259
+ heading?: string;
260
+ /** Create action label */
261
+ create?: string;
262
+ /** Empty state when no active tenant */
263
+ empty?: string;
264
+ };
265
+ type OrgSwitcherProps = {
266
+ activeTenant: OrgSwitcherTenant | null;
267
+ tenants: OrgSwitcherTenant[];
268
+ onSelectTenant: (id: string) => void;
269
+ createUrl?: string;
270
+ isLoading?: boolean;
271
+ collapsed?: boolean;
272
+ isMobile?: boolean;
273
+ activeSubtitle?: string;
274
+ labels?: OrgSwitcherLabels;
275
+ className?: string;
276
+ triggerClassName?: string;
277
+ };
278
+ declare function OrgSwitcher({ activeTenant, tenants, onSelectTenant, createUrl, isLoading, collapsed, isMobile, activeSubtitle, labels: userLabels, className, triggerClassName: triggerClassNameProp, }: OrgSwitcherProps): react_jsx_runtime.JSX.Element;
279
+
250
280
  type Language = {
251
281
  /** Language key/code (e.g., "en", "es") */
252
282
  key: string;
@@ -899,6 +929,33 @@ interface USAddressInputProps {
899
929
  }
900
930
  declare function USAddressInput({ value, onChange, lookupZip, validateAddress, autocomplete, labels, disabled, largeText, className, onError, }: USAddressInputProps): react_jsx_runtime.JSX.Element;
901
931
 
932
+ type MexicoStateId = "MXAGU" | "MXBCN" | "MXBCS" | "MXCAM" | "MXCHP" | "MXCHH" | "MXCMX" | "MXCOA" | "MXCOL" | "MXDUR" | "MXGUA" | "MXGRO" | "MXHID" | "MXJAL" | "MXMEX" | "MXMIC" | "MXMOR" | "MXNAY" | "MXNLE" | "MXOAX" | "MXPUE" | "MXQUE" | "MXROO" | "MXSLP" | "MXSIN" | "MXSON" | "MXTAB" | "MXTAM" | "MXTLA" | "MXVER" | "MXYUC" | "MXZAC";
933
+ interface MexicoState {
934
+ id: MexicoStateId;
935
+ name: string;
936
+ }
937
+ declare const MEXICO_STATES: MexicoState[];
938
+
939
+ interface MexicoMapProps {
940
+ selected: MexicoStateId[];
941
+ /** Omit to render a read-only display (no interaction, no keyboard handlers). */
942
+ onToggle?: (id: MexicoStateId) => void;
943
+ className?: string;
944
+ }
945
+ declare function MexicoMap({ selected, onToggle, className }: MexicoMapProps): react_jsx_runtime.JSX.Element;
946
+
947
+ type DoctorVerificationStatus = "unverified" | "pending_review" | "verified";
948
+ interface VerifiedDoctorBadgeProps {
949
+ status: DoctorVerificationStatus;
950
+ size?: "sm" | "md";
951
+ /** Icon-only with title/aria-label when false (default). */
952
+ showLabel?: boolean;
953
+ className?: string;
954
+ }
955
+ declare function VerifiedDoctorBadge({ status, size, showLabel, className, }: VerifiedDoctorBadgeProps): react_jsx_runtime.JSX.Element | null;
956
+
957
+ declare const MEXICO_STATE_PATHS: Record<MexicoStateId, string>;
958
+
902
959
  declare function cn(...inputs: ClassValue[]): string;
903
960
 
904
- export { type AddressAutocompleteAdapter, AvatarEditor, AvatarEditorDialog, type AvatarEditorDialogProps, type AvatarEditorProps, BLOCKS_DATA_ENVIRONMENTS, type BlocksDataEnvironment, type BlocksLanguage, type BlocksNotification, Button, CalendarContext, type CalendarContextValue, type CalendarData, type CalendarEvent, CalendarSubscribeButton, type CalendarSubscribeButtonProps, CalendarView, type CalendarViewLabels, type CalendarViewMode, type CalendarViewProps, CalendarWidget, type CalendarWidgetLabels, type CalendarWidgetProps, CardInput, type CardInputLabels, type CardInputProps, type CardTokenResult, type ChatConversation, type ChatConversationRoom, type ChatMessageData, type ChatRoomConfig, ChatRoomView, type ChatRoomViewLabels, type ChatRoomViewProps, ChatSidebar, ChatSidebarContext, type ChatSidebarContextValue, type ChatSidebarLabels, type ChatSidebarProps, ChatSidebarProvider, type ChatSidebarProviderProps, type ChatSidebarView, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EmptyState, type EmptyStateProps, EnvironmentBanner, type EnvironmentBannerLabels, type EnvironmentBannerProps, EnvironmentContext, type EnvironmentContextValue, EnvironmentDot, type EnvironmentDotProps, EnvironmentMiniBadge, type EnvironmentMiniBadgeProps, EnvironmentSwitcher, type EnvironmentSwitcherLabels, type EnvironmentSwitcherProps, ErrorState, EventDialog, type EventDialogLabels, type EventDialogProps, EventRsvpBadge, type EventRsvpBadgeProps, type Language, LanguageContext, type LanguageContextValue, LanguageSwitcher, type LanguageSwitcherLabels, type LanguageSwitcherProps, LoadingState, MiniCalendar, type MiniCalendarProps, type Notification, type NotificationType, NotificationsContext, type NotificationsContextValue, NotificationsWidget, type NotificationsWidgetProps, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, ScrollArea, ScrollBar, Slider, ThemeSwitcher, type ThemeSwitcherLabels, type ThemeSwitcherProps, Toggle, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, USAddressInput, type USAddressInputLabels, type USAddressInputProps, type USAddressValue, UpcomingEvents, type UpcomingEventsProps, type UseChatRoomResult, buttonVariants, cn, defaultLanguages, getEnvironmentDotClass, getEnvironmentLabel, isBlocksDataEnvironment, toggleVariants, useCalendarContext, useChatRoom, useChatSidebar, useDebouncedValue, useDebouncedValueStrict, useEnvironmentContext, useLanguageContext, useNotificationsContext };
961
+ export { type AddressAutocompleteAdapter, AvatarEditor, AvatarEditorDialog, type AvatarEditorDialogProps, type AvatarEditorProps, BLOCKS_DATA_ENVIRONMENTS, type BlocksDataEnvironment, type BlocksLanguage, type BlocksNotification, Button, CalendarContext, type CalendarContextValue, type CalendarData, type CalendarEvent, CalendarSubscribeButton, type CalendarSubscribeButtonProps, CalendarView, type CalendarViewLabels, type CalendarViewMode, type CalendarViewProps, CalendarWidget, type CalendarWidgetLabels, type CalendarWidgetProps, CardInput, type CardInputLabels, type CardInputProps, type CardTokenResult, type ChatConversation, type ChatConversationRoom, type ChatMessageData, type ChatRoomConfig, ChatRoomView, type ChatRoomViewLabels, type ChatRoomViewProps, ChatSidebar, ChatSidebarContext, type ChatSidebarContextValue, type ChatSidebarLabels, type ChatSidebarProps, ChatSidebarProvider, type ChatSidebarProviderProps, type ChatSidebarView, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, type DoctorVerificationStatus, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EmptyState, type EmptyStateProps, EnvironmentBanner, type EnvironmentBannerLabels, type EnvironmentBannerProps, EnvironmentContext, type EnvironmentContextValue, EnvironmentDot, type EnvironmentDotProps, EnvironmentMiniBadge, type EnvironmentMiniBadgeProps, EnvironmentSwitcher, type EnvironmentSwitcherLabels, type EnvironmentSwitcherProps, ErrorState, EventDialog, type EventDialogLabels, type EventDialogProps, EventRsvpBadge, type EventRsvpBadgeProps, type Language, LanguageContext, type LanguageContextValue, LanguageSwitcher, type LanguageSwitcherLabels, type LanguageSwitcherProps, LoadingState, MEXICO_STATES, MEXICO_STATE_PATHS, MexicoMap, type MexicoMapProps, type MexicoState, type MexicoStateId, MiniCalendar, type MiniCalendarProps, type Notification, type NotificationType, NotificationsContext, type NotificationsContextValue, NotificationsWidget, type NotificationsWidgetProps, OrgSwitcher, type OrgSwitcherLabels, type OrgSwitcherProps, type OrgSwitcherTenant, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, ScrollArea, ScrollBar, Slider, ThemeSwitcher, type ThemeSwitcherLabels, type ThemeSwitcherProps, Toggle, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, USAddressInput, type USAddressInputLabels, type USAddressInputProps, type USAddressValue, UpcomingEvents, type UpcomingEventsProps, type UseChatRoomResult, VerifiedDoctorBadge, type VerifiedDoctorBadgeProps, buttonVariants, cn, defaultLanguages, getEnvironmentDotClass, getEnvironmentLabel, isBlocksDataEnvironment, toggleVariants, useCalendarContext, useChatRoom, useChatSidebar, useDebouncedValue, useDebouncedValueStrict, useEnvironmentContext, useLanguageContext, useNotificationsContext };