// TypeScript declarations for the library import {FC} from 'react'; import { TextProps, StyleProp, TextStyle, ViewStyle, ImageSourcePropType, ImageStyle, TouchableOpacityProps, ImageProps, GestureResponderEvent, } from 'react-native'; // PlayyText Props export interface PlayyTextProps extends TextProps { children?: any; color?: string; lightColor?: string; darkColor?: string; useThemeColor?: boolean; themeTextType?: 'primary' | 'secondary' | 'tertiary'; style?: StyleProp; numberOfLines?: number; ellipsizeMode?: 'head' | 'middle' | 'tail' | 'clip' | undefined; marginLeft?: number; letterSpacing?: number; // Font style props LargeTitle_Regular?: boolean; LargeTitle_Emphasized?: boolean; LargeTitle_Condensed?: boolean; Title1_Emphasized?: boolean; Title1_Condensed?: boolean; Title1_Regular?: boolean; Title1_Strong?: boolean; Title2_Regular?: boolean; Title2_Emphasized?: boolean; Title2_Strong?: boolean; Title2_Condensed?: boolean; Title3_Regular?: boolean; Title3_Emphasized?: boolean; Title3_Condensed?: boolean; HeadlineRegular?: boolean; HeadlineItalic?: boolean; BodyRegular?: boolean; BodyEmphasized?: boolean; BodyStrong?: boolean; BodyItalic?: boolean; BodyEmphasizedItalic?: boolean; CalloutRegular?: boolean; CalloutEmphasized?: boolean; CalloutItalic?: boolean; CalloutEmphasizedItalic?: boolean; SubheadRegular?: boolean; SubheadEmphasized?: boolean; SubheadItalic?: boolean; SubheadEmphasizedItalic?: boolean; FootnoteRegular?: boolean; FootnoteEmphasized?: boolean; FootnoteStrong?: boolean; FootnoteItalic?: boolean; FootnoteEmphasizedItalic?: boolean; Caption1Regular?: boolean; Caption1Emphasized?: boolean; Caption1Italic?: boolean; Caption1EmphasizedItalic?: boolean; Caption2Regular?: boolean; Caption2Emphasized?: boolean; Caption2Italic?: boolean; Caption2EmphasizedItalic?: boolean; HeadlineEmphasized?: boolean; } // Icon Props export interface IconProps { name: string; size?: number; width?: number; height?: number; color?: string; } // Icon Item for NavigationHeader export interface IconItem { name: string; size?: number; iconColor?: string; onPress?: () => void; } // SwipeAction interface export interface SwipeAction { comp: React.ReactNode; color?: string; width?: number; onPress?: () => void; } // ListCard Props export interface ListCardProps { isLeftIcon?: boolean; leftIconName?: string; containerStyle?: ViewStyle; title?: string; rightIconName?: string; wrapperStyle?: ViewStyle; handlePressListCard?: () => void; subtitle?: string; tallList?: boolean; showImage?: boolean; imageContainerStyle?: ViewStyle; imageSource?: ImageSourcePropType | undefined; imageStyle?: ImageStyle | undefined; showDetail?: boolean; detail?: string; titleColor?: string; subtitleColor?: string; detailColor?: string; isRightIcon?: boolean; righticonColor?: string; leftIconColor?: string; showToggle?: boolean; toggleValue?: boolean; onToggleChange?: (value: boolean) => void; thumbColor?: string; trackColorFalse?: string; trackColorTrue?: string; switchSize?: 'small' | 'medium' | 'large'; initial?: string; initialColor?: string; rightContainerStyle?: ViewStyle; isButton?: boolean; buttonStyle?: ViewStyle; buttonText?: string; btnColor?: string; handleButtonPress?: () => void; } // Button Props export interface ButtonProps { name: string; handlePressButton: () => void; textColor?: string; containerStyle?: ViewStyle; } // Swipeable Component Props export interface SwipeableComponentProps { children: React.ReactNode; leftSwipeEnabled?: boolean; rightSwipeEnabled?: boolean; leftActions?: SwipeAction[]; rightActions?: SwipeAction[]; } // SwitchView Props export interface SwitchViewProps { toggleValue: boolean; onToggleChange: (value: boolean) => void; switchSize?: 'small' | 'medium' | 'large'; trackColor?: {false: string; true: string}; trackColorFalse?: string; trackColorTrue?: string; thumbColor?: string; thumbColorDisabled?: string; disabled?: boolean; style?: ViewStyle; } // Navigation Header Props export interface NavigationHeaderProps { title?: string; backIcon?: boolean; backIconColor?: string; backIconWidth?: number; backIconHeight?: number; isSearch?: boolean; titlePosition?: 'center' | 'start'; showPrompt?: string; statusBarvalue: number; label?: string; subtitle?: string; showCenterSubtitle?: boolean; handleBack?: () => void; onChangeText?: (data: string) => void; iconsList?: IconItem[]; showLeading?: boolean; leadingSource?: any; leadingContainerStyle?: any; handlePressLeading?: () => void; headerStyle?: any; isButton?: boolean; buttonTitle?: string; handlePressButton?: () => void; buttonStyle?: any; isHeaderContact?: boolean; contactSource?: any; contactName?: string; buttontextColor?: string; labelColor?: string; isOnline?: string; } // Theme Colors Interface export interface ColorsScheme { black: string | undefined; surface_cool: string; border_cool: string; text_cool: string; bg_primary: string; bg_secondary: string; bg_tertiary: string; text_primary: string; text_secondary: string; text_tertiary: string; text_disabled: string; border_light: string; border_medium: string; border_strong: string; border_focus: string; button_primary: string; button_hover: string; button_pressed: string; button_disabled: string; status_success: string; status_error: string; status_warning: string; surface_elevated: string; surface_overlay: string; shadow_color: string; inverse: string; bg_light: string; logo_grad_top: string; overlay_modal: string; gradient_first: string; gradient_second: string; modal_primary: string; modal_secondary: string; modal_title: string; red: string; blue: string; white: string; fill_primary: string; fill_secondary: string; fill_secondary_b: string; fill_secondary_alt: string; fill_tertiary: string; fill_tertiary_alt: string; fill_quaternary: string; fill_quaternary_alt: string; figure_gray: string; border_primary: string; border_secondary: string; card_background: string; figure_secondary: string; figure_tertiary: string; figure_quaternary: string; primary_white: string; soft_red: string; soft_green: string; soft_blue: string; primary_black: string; primary_red: string; primary_green: string; primary_blue: string; primary_orange: string; accents_purple: string; accents_pink: string; accents_teal: string; primary_accent: string; primary_accent_2: string; primary_accent_blue: string; blue_50: string; blue_300: string; border_tertiary: string; primary_accent_blue_create: string; fill_primary_40: string; fill_secondary_t: string; fill_tertiary_t: string; fill_quaternary_t: string; fill_surface: string; fill_message_bubble: string; fill_message_bubble_accent: string; fill_message_bubble_40: string; fill_attachment: string; fill_reaction: string; figure_black: string; figure_secondary_alpha: string; figure_link: string; border_10: string; card_background_active: string; primary_red_10: string; primary_red_20: string; primary_red_30: string; primary_red_60: string; primary_red_80: string; primary_green_10: string; primary_green_20: string; primary_green_30: string; primary_green_60: string; primary_green_80: string; primary_orange_10: string; primary_orange_20: string; primary_orange_30: string; primary_orange_50: string; primary_orange_80: string; primary_yellow: string; primary_yellow_30: string; primary_yellow_80: string; primary_accent_dark: string; primary_accent_semi: string; primary_accent_blue_5: string; primary_accent_blue_15: string; primary_accent_blue_30: string; primary_accent_blue_60: string; primary_accent_blue_80: string; primary_accent_sky: string; // NEW COLORS // labels labels_primary: string; labels_secondary: string; labels_tertiary: string; labels_quaternary: string; labels_primary_inv: string; labels_vibrant_primary: string; labels_vibrant_secondary: string; labels_vibrant_tertiary: string; labels_vibrant_quaternary: string; // fills fills_primary: string; fills_secondary: string; fills_tertiary: string; fills_quaternary: string; fills_quinary: string; fills_vprimary: string; fills_white80: string; fills_white60: string; fills_white40: string; fills_white75: string; fills_white76: string; fills_black3: string; fills_black5: string; fills_black8: string; fills_black12: string; fills_black13: string; fills_black15: string; fills_black20: string; fills_black30: string; fills_black50: string; fills_black80: string; fills_black81: string; fills_solid_primary: string; fills_solid_secondary: string; fills_solid_tertiary: string; fills_vibrant_primary: string; fills_vibrant_secondary: string; fills_vibrant_tertiary: string; // System Background system_background_primary: string; system_background_secondary: string; system_background_tertiary: string; system_background_elevated_primary: string; system_background_elevated_secondary: string; system_background_elevated_tertiary: string; // backgrounds background_primary: string; background_secondary: string; background_tertiary: string; background_thick: string; background_primary_elevated: string; background_secondary_elevated: string; background_tertiary_elevated: string; //Background Cards background_card_primary: string; background_card_secondary: string; // backgrounds (grouped) background_grouped_primary: string; background_grouped_secondary: string; background_grouped_tertiary: string; background_grouped_primary_elevated: string; background_grouped_secondary_elevated: string; background_grouped_tertiary_elevated: string; // Background Control background_control_primary: string; background_control_secondary: string; background_control_tertiary: string; // separators separator_opaque: string; separator_non_opaque: string; separator_vibrant: string; // overlays overlay_default: string; overlay_activity: string; overlay_activity_view_controller: string; overlay_attachment: string; overlay_light: string; // grays gray_black: string; gray_white: string; gray: string; gray_2: string; gray_7: string; gray_3: string; gray_4: string; gray_5: string; gray_6: string; // colors colors_red: string; colors_orange: string; colors_yellow: string; colors_green: string; colors_mint: string; colors_teal: string; colors_cyan: string; colors_blue: string; colors_blue_secondary: string; colors_blue_tertiary: string; colors_blue_quaternary: string; colors_blue2: string; colors_indigo: string; colors_purple: string; colors_pink: string; colors_brown: string; colors_red_2: string; // border border_10_color: string; border_30_color: string; // misc alert_menu: string; bar_border: string; button_disabled_color: string; button_tinted_fill: string; button_tinted_fill2: string; button_destructive_label_disabled: string; button_destructive_bg_prominent: string; button_destructive_bg: string; floatingTab_text_selected: string; floatingTab_text_unselected: string; floatingTab_pill_shadow: string; floatingTab_pill_fill: string; keyboard_accessory_bar_selection: string; keyboard_emoji_mic: string; button_label_disabled: string; button_prominent: string; button_bg: string; button_bg_colors: string; tab_text_selected: string; tab_text_unselected: string; tab_pill_shadow: string; tab_pill_fill: string; menu_large_separator: string; sidebar_fill_selected: string; sidebar_text_selected: string; sidebar_shadow_drag_over: string; tab_unselected: string; text_field_bg: string; text_field_outline: string; kit_section_fill: string; kit_section_stroke: string; bubble_accent: string; bubble_gray: string; link: string; read_receipt: string; pill_active_text: string; pill_bg: string; keyboard_accessory_bar_selection2: string; overlay_comment_modal: string; // Labels Control labels_control_primary: string; labels_control_secondary: string; labels_control_tertiary: string; labels_control_quaternary: string; // Material material_ultra_thick: string; material_thick: string; material_thin: string; material_medium: string; material_ultra_thin: string; material_chrome: string; } // Theme Context export interface ThemeContextType { colors: ColorsScheme; colorScheme: 'light' | 'dark'; toggleTheme: () => void; setSelectedTheme: (theme: 'light' | 'dark' | 'system') => void; } // Icons enum export declare const icons: { search: string; back: string; microphone: string; leftArrow: string; rightArrow: string; online: string; downArrow: string; showCheckmark: string; info: string; symbol: string; notification: string; chat: string; menu: string; snapshot: string; selectIcon: string; auto: string; inActiveAuto: string; brightness: string; inActiveBrightness: string; contrast: string; inActiveContrast: string; blackpoint: string; inActiveBlackpoint: string; warmth: string; inActiveWarmth: string; tint: string; inActiveTint: string; saturation: string; inActiveSaturation: string; highlight: string; inActiveHighlight: string; shadows: string; inActiveShadows: string; vignette: string; inActiveVignette: string; sharpeness: string; inActiveSharpeness: string; remove: string; add: string; filter: string; editFilter: string; }; // Spacing constants export declare const SPACING_2: number; export declare const SPACING_4: number; export declare const SPACING_6: number; export declare const SPACING_8: number; export declare const SPACING_10: number; export declare const SPACING_12: number; export declare const SPACING_14: number; export declare const SPACING_16: number; export declare const SPACING_18: number; export declare const SPACING_20: number; export declare const SPACING_24: number; export declare const SPACING_26: number; export declare const SPACING_30: number; export declare const SPACING_32: number; export declare const SPACING_34: number; export declare const SPACING_36: number; export declare const SPACING_40: number; export declare const SPACING_44: number; export declare const SPACING_46: number; export declare const SPACING_48: number; export declare const SPACING_52: number; export declare const SPACING_54: number; export declare const SPACING_56: number; export declare const SPACING_64: number; export declare const SPACING_72: number; export declare const SPACING_84: number; // Font Configuration export interface FontConfig { regular: string; medium: string; bold: string; SemiCondensedExtraBold?: string; regularItalic?: string; } // Header Compound Component Props export interface HeaderProps { children: React.ReactNode; statusBarValue?: number; style?: StyleProp; showPrompt?: string; } export interface HeaderRowProps { children: React.ReactNode; rowStyle?: ViewStyle; } export interface HeaderLeftProps { children?: React.ReactNode; backIcon?: boolean; backIconColor?: string; label?: string; labelColor?: string; onBackPress?: () => void; showLeading?: boolean; leadingSource?: any; leadingContainerStyle?: StyleProp; onLeadingPress?: () => void; isContact?: boolean; contactSource?: any; contactName?: string; contactTitle?: string; contactSubTitle?: string; isOnline?: boolean; } export interface HeaderCenterProps { children: React.ReactNode; } export interface HeaderRightProps { children?: React.ReactNode; icons?: IconItem[]; isButton?: boolean; buttonTitle?: string; buttonTextColor?: string; buttonStyle?: StyleProp; onButtonPress?: () => void; } export interface HeaderTitleProps { title: string; } export interface HeaderSearchProps { placeholder?: string; onChangeText?: (text: string) => void; } /** * Individual swipe action props (extends TouchableOpacity) */ export interface SwipeActionProps extends TouchableOpacityProps { children: React.ReactNode; backgroundColor?: string; width?: number; } /** * SwipeLeftActions and SwipeRightActions container props */ export interface SwipeLeftActionsProps { children: React.ReactNode; } export interface SwipeRightActionsProps { children: React.ReactNode; } /** * Title component props */ export interface SwipeableListItemTitleProps { children: React.ReactNode; numberOfLines?: number; style?: StyleProp; } /** * SubTitle component props */ export interface SwipeableListItemSubTitleProps { children: React.ReactNode; numberOfLines?: number; style?: StyleProp; } /** * Icon component props for metadata */ export interface SwipeableListItemIconProps { children: React.ReactNode; style?: StyleProp; } /** * Avatar section props for SwipeableListItem.Avatar * Extends all Image props and adds custom size, style, and fallbackName */ export interface SwipeableListItemAvatarProps extends Omit { source?: ImageSourcePropType; fallbackName?: string; size?: number; style?: StyleProp; } /** * Content section props for SwipeableListItem.Content */ export interface SwipeableListItemContentProps { children?: React.ReactNode; name?: string; message?: string; messageIcon?: React.ReactNode; messageIconColor?: string; isTyping?: boolean; isDeleted?: boolean; } /** * Metadata section props for SwipeableListItem.Metadata */ export interface SwipeableListItemMetadataProps { children?: React.ReactNode; timestamp?: string; isPinned?: boolean; pinnedIcon?: React.ReactNode; isMentioned?: boolean; unreadCount?: number; } /** * Swipe actions configuration for SwipeableListItem.SwipeActions (Legacy API) */ export interface SwipeableListItemSwipeActionsProps { // Left swipe actions readStatus?: 'read' | 'unread'; showPinAction?: boolean; onToggleReadStatus?: () => void; onTogglePin?: () => void; leftActionColors?: { read?: string; pin?: string; }; // Right swipe actions onMute?: () => void; onArchive?: () => void; onMore?: () => void; rightActionColors?: { mute?: string; archive?: string; more?: string; }; // Custom actions leftActions?: SwipeAction[]; rightActions?: SwipeAction[]; } /** * Context value shared across SwipeableListItem compound components */ export interface SwipeableListItemContextValue { // Visual state backgroundColor?: string; unreadCount?: number; // Interaction handlers (matching TouchableOpacity signature) onPress?: (event: GestureResponderEvent) => void; onLongPress?: (event: GestureResponderEvent) => void; // Selection state selected?: boolean; onSelectChange?: (nextSelected: boolean) => void; isSelection?: boolean; // Swipe configuration swipeConfig?: SwipeableListItemSwipeActionsProps; } /** * Base props for SwipeableListItem compound component * Extends TouchableOpacityProps to support all touchable behaviors */ export interface SwipeableListItemProps extends Omit { children: React.ReactNode; containerStyle?: StyleProp; backgroundColor?: string; // Selection props selected?: boolean; onSelectChange?: (nextSelected: boolean) => void; isSelection?: boolean; } // Legacy ChatItemProps (maintained for backward compatibility) export interface ChatItemProps { name: string; message?: string; timestamp: string; avatar?: ImageSourcePropType; isPinned?: boolean; pinnedIcon?: React.ReactNode; isMentioned?: boolean; unreadCount?: number; isTyping?: boolean; isDeleted?: boolean; messageIcon?: React.ReactNode; messageIconColor?: string; readStatus?: 'read' | 'unread'; showPinAction?: boolean; onToggleReadStatus?: () => void; onTogglePin?: () => void; onPress?: () => void; onMute?: () => void; onArchive?: () => void; onMore?: () => void; leftActionColors?: { read?: string; pin?: string; }; rightActionColors?: { mute?: string; archive?: string; more?: string; }; chatContainerStyle?: object; selected?: boolean; onSelectChange?: (nextSelected: boolean) => void; isSelection?: boolean; } // Legacy SwipeableListItemLegacyProps (for backward compatibility with chatProps) export interface SwipeableListItemLegacyProps { chatProps: ChatItemProps; } // Component exports export declare const PlayyText: FC; export declare const IconComponent: FC; export declare const NavigationHeader: FC; export declare const ListCard: FC; export declare const Button: FC; export declare const SwipeableComponent: React.ComponentType; export declare const SwitchView: FC; /** * SwipeableListItem Compound Component * * Two ways to use: * * 1. New Compound Component API (v3.8.0+): * ```tsx * {}}> * * * Read * * * * * John Doe * Hey there! * * * * ``` * * 2. Legacy API (v3.6.x - v3.7.x) - Still supported: * ```tsx * {} * }} /> * ``` */ export declare const SwipeableListItem: FC & { Avatar: FC; Content: FC; Metadata: FC; SwipeActions: FC; // Selection compound component Selection: FC<{children?: React.ReactNode}>; Selected: FC<{children: React.ReactNode}>; Unselected: FC<{children: React.ReactNode}>; // New declarative swipe actions API SwipeLeftActions: FC; SwipeRightActions: FC; SwipeLeftAction: FC; SwipeRightAction: FC; // Content sub-components Title: FC; SubTitle: FC; // Metadata sub-components Icon: FC; }; // SwipeableListItem context hook for advanced usage export declare const useSwipeableListItemContext: () => SwipeableListItemContextValue; // Legacy compatibility exports export declare const ChatList: FC; // Header Compound Component export declare const Header: FC & { Row: FC; Left: FC; Center: FC; Right: FC; Title: FC; Search: FC; }; // AvatarListView Props export interface AvatarListViewProps { avatarSource: any; isPinned?: boolean; userName?: string; message?: string; time?: string; userTyping?: boolean; iconName?: string; showIcon?: boolean; typingUser?: string; onPress?: () => void; } // ChatList Props (Legacy - use AvatarListViewProps instead) export interface ChatListProps extends AvatarListViewProps {} // Theme exports export declare const ThemeContext: FC<{children: React.ReactNode}>; export declare const useTheme: () => ThemeContextType; export declare const useThemeColors: ( colorScheme: 'light' | 'dark', ) => ColorsScheme; // Font exports export declare const FontProvider: FC<{ fonts: FontConfig; children: React.ReactNode; }>; export declare const useFontConfig: () => FontConfig; // PlayyTextInput Props export interface PlayyTextInputProps { value: string; onChangeText: (text: string) => void; placeholder?: string; containerStyle?: ViewStyle; inputStyle?: ViewStyle; multiline?: boolean; maxLength?: number; keyboardType?: | 'default' | 'number-pad' | 'decimal-pad' | 'numeric' | 'email-address' | 'phone-pad' | 'url'; autoCapitalize?: 'none' | 'sentences' | 'words' | 'characters'; secureTextEntry?: boolean; editable?: boolean; label?: string; showIcon?: boolean; topSeparator?: boolean; bottomSeparator?: boolean; rightIconName?: string; autoFocus?: boolean; handleIconPress?: () => void; } export declare const PlayyTextInput: FC; // CardView component props export interface CardViewProps { children: ReactNode; cardViewStyle?: ViewStyle; } export declare const CardView: FC; // DateSelector component props export interface DateSelectorProps { selectedDate: Date; onDateChange: (date: Date) => void; minimumDate?: Date; maximumDate?: Date; showHeader?: boolean; headerTitle?: string; locale?: string; cardViewStyle?: object; dateFormat?: string; } export declare const DateSelector: FC;