@melony/react 0.1.24 → 0.1.26

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,7 +1,7 @@
1
1
  import * as React$1 from 'react';
2
- import React__default, { ReactNode } from 'react';
2
+ import React__default, { ReactNode, CSSProperties } from 'react';
3
3
  import { ClientState, MelonyClient } from 'melony/client';
4
- import { Role, Event, Config, UINode } from 'melony';
4
+ import { Role, Event, Config, UINode, UIContract } from 'melony';
5
5
  import { QueryClient } from '@tanstack/react-query';
6
6
  import * as react_jsx_runtime from 'react/jsx-runtime';
7
7
 
@@ -73,7 +73,6 @@ interface MelonyClientProviderProps {
73
73
  client: MelonyClient;
74
74
  initialEvents?: Event[];
75
75
  queryClient?: QueryClient;
76
- configApi?: string;
77
76
  }
78
77
  declare const MelonyClientProvider: React__default.FC<MelonyClientProviderProps>;
79
78
 
@@ -132,6 +131,20 @@ declare const useAuth: () => AuthContextValue;
132
131
 
133
132
  declare const useThreads: () => ThreadContextValue;
134
133
 
134
+ interface ScreenSize {
135
+ width: number;
136
+ height: number;
137
+ isMobile: boolean;
138
+ isTablet: boolean;
139
+ isDesktop: boolean;
140
+ }
141
+ /**
142
+ * Hook to detect screen size and breakpoints
143
+ * @param mobileBreakpoint - Breakpoint for mobile (default: 768px, Tailwind's md)
144
+ * @param tabletBreakpoint - Breakpoint for tablet (default: 1024px, Tailwind's lg)
145
+ */
146
+ declare function useScreenSize(mobileBreakpoint?: number, tabletBreakpoint?: number): ScreenSize;
147
+
135
148
  interface ThreadProps {
136
149
  className?: string;
137
150
  placeholder?: string;
@@ -159,11 +172,8 @@ interface ComposerProps {
159
172
  maxFiles?: number;
160
173
  maxFileSize?: number;
161
174
  };
162
- accept?: string;
163
- maxFiles?: number;
164
- maxFileSize?: number;
165
175
  }
166
- declare function Composer({ value, onChange, onSubmit, placeholder, isLoading, className, options, autoFocus, defaultSelectedIds, fileAttachments, accept: legacyAccept, maxFiles: legacyMaxFiles, maxFileSize: legacyMaxFileSize, }: ComposerProps): react_jsx_runtime.JSX.Element;
176
+ declare function Composer({ value, onChange, onSubmit, placeholder, isLoading, className, options, autoFocus, defaultSelectedIds, fileAttachments, }: ComposerProps): react_jsx_runtime.JSX.Element;
167
177
 
168
178
  interface ChatHeaderProps {
169
179
  /**
@@ -195,7 +205,7 @@ interface ChatHeaderProps {
195
205
  * A shared, customizable header component for chat interfaces.
196
206
  * Used consistently across ChatFull, ChatSidebar, and ChatPopup components.
197
207
  */
198
- declare function ChatHeader({ title, leftContent, rightContent, className, titleClassName, children, }: ChatHeaderProps): react_jsx_runtime.JSX.Element;
208
+ declare function ChatHeader({ leftContent, rightContent, className, children, }: ChatHeaderProps): react_jsx_runtime.JSX.Element;
199
209
 
200
210
  interface ChatPopupProps {
201
211
  title?: string;
@@ -232,6 +242,22 @@ interface ChatSidebarProps {
232
242
  }
233
243
  declare function ChatSidebar({ title, placeholder, starterPrompts, options, className, headerProps, defaultSelectedIds, }: ChatSidebarProps): react_jsx_runtime.JSX.Element;
234
244
 
245
+ interface WelcomeScreenProps {
246
+ title?: string;
247
+ description?: string;
248
+ features?: {
249
+ title: string;
250
+ description: string;
251
+ }[];
252
+ className?: string;
253
+ onLoginClick?: () => void;
254
+ termsUrl?: string;
255
+ privacyUrl?: string;
256
+ imageUrl?: string;
257
+ imageAlt?: string;
258
+ }
259
+ declare function WelcomeScreen({ title, description, features, className, onLoginClick, termsUrl, privacyUrl, imageUrl, imageAlt, }: WelcomeScreenProps): react_jsx_runtime.JSX.Element;
260
+
235
261
  interface ChatFullProps {
236
262
  title?: string;
237
263
  placeholder?: string;
@@ -258,38 +284,6 @@ interface ChatFullProps {
258
284
  * Custom className for the right sidebar container
259
285
  */
260
286
  rightSidebarClassName?: string;
261
- /**
262
- * Whether the left sidebar is collapsible
263
- */
264
- leftSidebarCollapsible?: boolean;
265
- /**
266
- * Whether the right sidebar is collapsible
267
- */
268
- rightSidebarCollapsible?: boolean;
269
- /**
270
- * Default collapsed state for the left sidebar
271
- */
272
- defaultLeftSidebarCollapsed?: boolean;
273
- /**
274
- * Default collapsed state for the right sidebar
275
- */
276
- defaultRightSidebarCollapsed?: boolean;
277
- /**
278
- * Controlled collapsed state for the left sidebar. If provided, component becomes controlled.
279
- */
280
- leftSidebarCollapsed?: boolean;
281
- /**
282
- * Controlled collapsed state for the right sidebar. If provided, component becomes controlled.
283
- */
284
- rightSidebarCollapsed?: boolean;
285
- /**
286
- * Callback when left sidebar collapse state changes
287
- */
288
- onLeftSidebarCollapseChange?: (collapsed: boolean) => void;
289
- /**
290
- * Callback when right sidebar collapse state changes
291
- */
292
- onRightSidebarCollapseChange?: (collapsed: boolean) => void;
293
287
  /**
294
288
  * Whether the composer should be auto focused
295
289
  */
@@ -298,8 +292,34 @@ interface ChatFullProps {
298
292
  * IDs of options to be selected by default
299
293
  */
300
294
  defaultSelectedIds?: string[];
295
+ /**
296
+ * Whether to show a welcome screen when the user is not authenticated.
297
+ * Defaults to false.
298
+ */
299
+ showWelcomeScreen?: boolean;
300
+ /**
301
+ * Props to customize the welcome screen
302
+ */
303
+ welcomeScreenProps?: WelcomeScreenProps;
304
+ }
305
+ declare function ChatFull({ title, placeholder, starterPrompts, options, className, headerProps, leftSidebar, rightSidebar, leftSidebarClassName, rightSidebarClassName, autoFocus, defaultSelectedIds, showWelcomeScreen, welcomeScreenProps, }: ChatFullProps): react_jsx_runtime.JSX.Element;
306
+
307
+ interface SidebarToggleProps {
308
+ side: "left" | "right";
309
+ className?: string;
310
+ }
311
+ declare function SidebarToggle({ side, className }: SidebarToggleProps): react_jsx_runtime.JSX.Element | null;
312
+
313
+ interface ChatSidebarContextValue {
314
+ leftCollapsed: boolean;
315
+ rightCollapsed: boolean;
316
+ setLeftCollapsed: (collapsed: boolean) => void;
317
+ setRightCollapsed: (collapsed: boolean) => void;
318
+ leftCollapsible: boolean;
319
+ rightCollapsible: boolean;
301
320
  }
302
- declare function ChatFull({ title, placeholder, starterPrompts, options, className, headerProps, leftSidebar, rightSidebar, leftSidebarClassName, rightSidebarClassName, leftSidebarCollapsible, rightSidebarCollapsible, defaultLeftSidebarCollapsed, defaultRightSidebarCollapsed, leftSidebarCollapsed: controlledLeftCollapsed, rightSidebarCollapsed: controlledRightCollapsed, onLeftSidebarCollapseChange, onRightSidebarCollapseChange, autoFocus, defaultSelectedIds, }: ChatFullProps): react_jsx_runtime.JSX.Element;
321
+ declare const ChatSidebarContext: React__default.Context<ChatSidebarContextValue | undefined>;
322
+ declare function useChatSidebar(): ChatSidebarContextValue;
303
323
 
304
324
  interface ThreadListProps {
305
325
  className?: string;
@@ -346,6 +366,136 @@ interface UIRendererProps {
346
366
  */
347
367
  declare function UIRenderer({ node }: UIRendererProps): react_jsx_runtime.JSX.Element;
348
368
 
369
+ type Spacing = "xs" | "sm" | "md" | "lg" | "xl" | "xxl";
370
+ type FontSize = "xs" | "sm" | "md" | "lg" | "xl" | "xxl";
371
+ type FontWeight = "normal" | "medium" | "semibold" | "bold";
372
+
373
+ type Size = "sm" | "md" | "lg";
374
+ type Align = "start" | "center" | "end" | "stretch";
375
+ type Justify = "start" | "center" | "end" | "between" | "around";
376
+ type Orientation = "horizontal" | "vertical";
377
+ interface BaseComponentProps {
378
+ className?: string;
379
+ style?: CSSProperties;
380
+ }
381
+ type CardProps = BaseComponentProps & UIContract["card"] & {
382
+ children?: React__default.ReactNode[];
383
+ };
384
+ type RowProps = BaseComponentProps & UIContract["row"] & {
385
+ children?: React__default.ReactNode[];
386
+ };
387
+ type ColProps = BaseComponentProps & UIContract["col"] & {
388
+ children?: React__default.ReactNode[] | React__default.ReactNode;
389
+ overflow?: "visible" | "hidden" | "scroll" | "auto";
390
+ position?: "static" | "relative" | "absolute" | "fixed" | "sticky";
391
+ };
392
+ type BoxProps = BaseComponentProps & UIContract["box"] & {
393
+ children?: React__default.ReactNode | React__default.ReactNode[];
394
+ overflow?: "visible" | "hidden" | "scroll" | "auto";
395
+ };
396
+ type SpacerProps = BaseComponentProps & UIContract["spacer"];
397
+ type DividerProps = BaseComponentProps & UIContract["divider"] & {
398
+ size?: Size;
399
+ };
400
+ type ListProps = BaseComponentProps & {
401
+ children?: React__default.ReactNode;
402
+ width?: string | number;
403
+ };
404
+ type ListItemProps = BaseComponentProps & UIContract["listItem"] & {
405
+ children?: React__default.ReactNode;
406
+ orientation?: Orientation;
407
+ align?: Align;
408
+ justify?: Justify;
409
+ width?: string | number;
410
+ padding?: Spacing;
411
+ };
412
+ type ImageProps = BaseComponentProps & UIContract["image"] & {
413
+ fallbackText?: string;
414
+ showFallbackIcon?: boolean;
415
+ };
416
+ type ChartProps = BaseComponentProps & UIContract["chart"] & {
417
+ size?: Size;
418
+ showValues?: boolean;
419
+ showGrid?: boolean;
420
+ showTooltips?: boolean;
421
+ };
422
+ type BadgeProps = BaseComponentProps & UIContract["badge"];
423
+ type TextProps = BaseComponentProps & UIContract["text"];
424
+ type HeadingProps = BaseComponentProps & UIContract["heading"];
425
+ type FormProps = BaseComponentProps & UIContract["form"] & {
426
+ children?: React__default.ReactNode[];
427
+ };
428
+ type InputProps = BaseComponentProps & UIContract["input"] & {
429
+ disabled?: boolean;
430
+ value?: string;
431
+ };
432
+ type ButtonProps = BaseComponentProps & UIContract["button"] & {
433
+ fullWidth?: boolean;
434
+ };
435
+ type LabelProps = BaseComponentProps & UIContract["label"] & {
436
+ size?: FontSize;
437
+ weight?: FontWeight;
438
+ };
439
+ type TextareaProps = BaseComponentProps & UIContract["textarea"] & {
440
+ value?: string;
441
+ disabled?: boolean;
442
+ };
443
+ type SelectProps = BaseComponentProps & UIContract["select"] & {
444
+ value?: string;
445
+ disabled?: boolean;
446
+ };
447
+ type CheckboxProps = BaseComponentProps & UIContract["checkbox"] & {
448
+ defaultChecked?: boolean;
449
+ disabled?: boolean;
450
+ };
451
+ type RadioGroupProps = BaseComponentProps & UIContract["radioGroup"] & {
452
+ value?: string;
453
+ defaultValue?: string;
454
+ disabled?: boolean;
455
+ };
456
+
457
+ declare const Button: React__default.FC<ButtonProps>;
458
+
459
+ declare const Input: React__default.FC<InputProps>;
460
+
461
+ declare const Textarea: React__default.FC<TextareaProps>;
462
+
463
+ declare const Select: React__default.FC<SelectProps>;
464
+
465
+ declare const Checkbox: React__default.FC<CheckboxProps>;
466
+
467
+ declare const RadioGroup: React__default.FC<RadioGroupProps>;
468
+
469
+ declare const Form: React__default.FC<FormProps>;
470
+
471
+ declare const Heading: React__default.FC<HeadingProps>;
472
+
473
+ declare const Image: React__default.FC<ImageProps>;
474
+
475
+ declare const Label: React__default.FC<LabelProps>;
476
+
477
+ declare const List: React__default.FC<ListProps>;
478
+
479
+ declare const ListItem: React__default.FC<ListItemProps>;
480
+
481
+ declare const Spacer: React__default.FC<SpacerProps>;
482
+
483
+ declare const Divider: React__default.FC<DividerProps>;
484
+
485
+ declare const Box: React__default.FC<BoxProps>;
486
+
487
+ declare const Chart: React__default.FC<ChartProps>;
488
+
489
+ declare const Card: React__default.FC<CardProps>;
490
+
491
+ declare const Row: React__default.FC<RowProps>;
492
+
493
+ declare const Col: React__default.FC<ColProps>;
494
+
495
+ declare const Text: React__default.FC<TextProps>;
496
+
497
+ declare const Badge: React__default.FC<BadgeProps>;
498
+
349
499
  declare function groupEventsToMessages(events: Event[]): Message[];
350
500
 
351
- export { AccountDialog, type AccountDialogProps, AuthContext, type AuthContextValue, AuthProvider, type AuthProviderProps, type AuthService, ChatFull, type ChatFullProps, ChatHeader, type ChatHeaderProps, ChatPopup, type ChatPopupProps, ChatSidebar, type ChatSidebarProps, Composer, type ComposerOption, type ComposerOptionGroup, CreateThreadButton, type CreateThreadButtonProps, MelonyClientProvider, type MelonyClientProviderProps, MelonyContext, type MelonyContextValue, type Message, type StarterPrompt, ThemeProvider, ThemeToggle, Thread, ThreadContext, type ThreadContextValue, type ThreadData, ThreadList, type ThreadListProps, ThreadPopover, type ThreadPopoverProps, ThreadProvider, type ThreadProviderProps, type ThreadService, UIRenderer, type UIRendererProps, type UseMelonyOptions, type User, groupEventsToMessages, useAuth, useMelony, useTheme, useThreads };
501
+ export { AccountDialog, type AccountDialogProps, AuthContext, type AuthContextValue, AuthProvider, type AuthProviderProps, type AuthService, Badge, Box, Button, Card, Chart, ChatFull, type ChatFullProps, ChatHeader, type ChatHeaderProps, ChatPopup, type ChatPopupProps, ChatSidebar, ChatSidebarContext, type ChatSidebarContextValue, type ChatSidebarProps, Checkbox, Col, Composer, type ComposerOption, type ComposerOptionGroup, CreateThreadButton, type CreateThreadButtonProps, Divider, Form, Heading, Image, Input, Label, List, ListItem, MelonyClientProvider, type MelonyClientProviderProps, MelonyContext, type MelonyContextValue, type Message, RadioGroup, Row, type ScreenSize, Select, SidebarToggle, type SidebarToggleProps, Spacer, type StarterPrompt, Text, Textarea, ThemeProvider, ThemeToggle, Thread, ThreadContext, type ThreadContextValue, type ThreadData, ThreadList, type ThreadListProps, ThreadPopover, type ThreadPopoverProps, ThreadProvider, type ThreadProviderProps, type ThreadService, UIRenderer, type UIRendererProps, type UseMelonyOptions, type User, WelcomeScreen, type WelcomeScreenProps, groupEventsToMessages, useAuth, useChatSidebar, useMelony, useScreenSize, useTheme, useThreads };
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import * as React$1 from 'react';
2
- import React__default, { ReactNode } from 'react';
2
+ import React__default, { ReactNode, CSSProperties } from 'react';
3
3
  import { ClientState, MelonyClient } from 'melony/client';
4
- import { Role, Event, Config, UINode } from 'melony';
4
+ import { Role, Event, Config, UINode, UIContract } from 'melony';
5
5
  import { QueryClient } from '@tanstack/react-query';
6
6
  import * as react_jsx_runtime from 'react/jsx-runtime';
7
7
 
@@ -73,7 +73,6 @@ interface MelonyClientProviderProps {
73
73
  client: MelonyClient;
74
74
  initialEvents?: Event[];
75
75
  queryClient?: QueryClient;
76
- configApi?: string;
77
76
  }
78
77
  declare const MelonyClientProvider: React__default.FC<MelonyClientProviderProps>;
79
78
 
@@ -132,6 +131,20 @@ declare const useAuth: () => AuthContextValue;
132
131
 
133
132
  declare const useThreads: () => ThreadContextValue;
134
133
 
134
+ interface ScreenSize {
135
+ width: number;
136
+ height: number;
137
+ isMobile: boolean;
138
+ isTablet: boolean;
139
+ isDesktop: boolean;
140
+ }
141
+ /**
142
+ * Hook to detect screen size and breakpoints
143
+ * @param mobileBreakpoint - Breakpoint for mobile (default: 768px, Tailwind's md)
144
+ * @param tabletBreakpoint - Breakpoint for tablet (default: 1024px, Tailwind's lg)
145
+ */
146
+ declare function useScreenSize(mobileBreakpoint?: number, tabletBreakpoint?: number): ScreenSize;
147
+
135
148
  interface ThreadProps {
136
149
  className?: string;
137
150
  placeholder?: string;
@@ -159,11 +172,8 @@ interface ComposerProps {
159
172
  maxFiles?: number;
160
173
  maxFileSize?: number;
161
174
  };
162
- accept?: string;
163
- maxFiles?: number;
164
- maxFileSize?: number;
165
175
  }
166
- declare function Composer({ value, onChange, onSubmit, placeholder, isLoading, className, options, autoFocus, defaultSelectedIds, fileAttachments, accept: legacyAccept, maxFiles: legacyMaxFiles, maxFileSize: legacyMaxFileSize, }: ComposerProps): react_jsx_runtime.JSX.Element;
176
+ declare function Composer({ value, onChange, onSubmit, placeholder, isLoading, className, options, autoFocus, defaultSelectedIds, fileAttachments, }: ComposerProps): react_jsx_runtime.JSX.Element;
167
177
 
168
178
  interface ChatHeaderProps {
169
179
  /**
@@ -195,7 +205,7 @@ interface ChatHeaderProps {
195
205
  * A shared, customizable header component for chat interfaces.
196
206
  * Used consistently across ChatFull, ChatSidebar, and ChatPopup components.
197
207
  */
198
- declare function ChatHeader({ title, leftContent, rightContent, className, titleClassName, children, }: ChatHeaderProps): react_jsx_runtime.JSX.Element;
208
+ declare function ChatHeader({ leftContent, rightContent, className, children, }: ChatHeaderProps): react_jsx_runtime.JSX.Element;
199
209
 
200
210
  interface ChatPopupProps {
201
211
  title?: string;
@@ -232,6 +242,22 @@ interface ChatSidebarProps {
232
242
  }
233
243
  declare function ChatSidebar({ title, placeholder, starterPrompts, options, className, headerProps, defaultSelectedIds, }: ChatSidebarProps): react_jsx_runtime.JSX.Element;
234
244
 
245
+ interface WelcomeScreenProps {
246
+ title?: string;
247
+ description?: string;
248
+ features?: {
249
+ title: string;
250
+ description: string;
251
+ }[];
252
+ className?: string;
253
+ onLoginClick?: () => void;
254
+ termsUrl?: string;
255
+ privacyUrl?: string;
256
+ imageUrl?: string;
257
+ imageAlt?: string;
258
+ }
259
+ declare function WelcomeScreen({ title, description, features, className, onLoginClick, termsUrl, privacyUrl, imageUrl, imageAlt, }: WelcomeScreenProps): react_jsx_runtime.JSX.Element;
260
+
235
261
  interface ChatFullProps {
236
262
  title?: string;
237
263
  placeholder?: string;
@@ -258,38 +284,6 @@ interface ChatFullProps {
258
284
  * Custom className for the right sidebar container
259
285
  */
260
286
  rightSidebarClassName?: string;
261
- /**
262
- * Whether the left sidebar is collapsible
263
- */
264
- leftSidebarCollapsible?: boolean;
265
- /**
266
- * Whether the right sidebar is collapsible
267
- */
268
- rightSidebarCollapsible?: boolean;
269
- /**
270
- * Default collapsed state for the left sidebar
271
- */
272
- defaultLeftSidebarCollapsed?: boolean;
273
- /**
274
- * Default collapsed state for the right sidebar
275
- */
276
- defaultRightSidebarCollapsed?: boolean;
277
- /**
278
- * Controlled collapsed state for the left sidebar. If provided, component becomes controlled.
279
- */
280
- leftSidebarCollapsed?: boolean;
281
- /**
282
- * Controlled collapsed state for the right sidebar. If provided, component becomes controlled.
283
- */
284
- rightSidebarCollapsed?: boolean;
285
- /**
286
- * Callback when left sidebar collapse state changes
287
- */
288
- onLeftSidebarCollapseChange?: (collapsed: boolean) => void;
289
- /**
290
- * Callback when right sidebar collapse state changes
291
- */
292
- onRightSidebarCollapseChange?: (collapsed: boolean) => void;
293
287
  /**
294
288
  * Whether the composer should be auto focused
295
289
  */
@@ -298,8 +292,34 @@ interface ChatFullProps {
298
292
  * IDs of options to be selected by default
299
293
  */
300
294
  defaultSelectedIds?: string[];
295
+ /**
296
+ * Whether to show a welcome screen when the user is not authenticated.
297
+ * Defaults to false.
298
+ */
299
+ showWelcomeScreen?: boolean;
300
+ /**
301
+ * Props to customize the welcome screen
302
+ */
303
+ welcomeScreenProps?: WelcomeScreenProps;
304
+ }
305
+ declare function ChatFull({ title, placeholder, starterPrompts, options, className, headerProps, leftSidebar, rightSidebar, leftSidebarClassName, rightSidebarClassName, autoFocus, defaultSelectedIds, showWelcomeScreen, welcomeScreenProps, }: ChatFullProps): react_jsx_runtime.JSX.Element;
306
+
307
+ interface SidebarToggleProps {
308
+ side: "left" | "right";
309
+ className?: string;
310
+ }
311
+ declare function SidebarToggle({ side, className }: SidebarToggleProps): react_jsx_runtime.JSX.Element | null;
312
+
313
+ interface ChatSidebarContextValue {
314
+ leftCollapsed: boolean;
315
+ rightCollapsed: boolean;
316
+ setLeftCollapsed: (collapsed: boolean) => void;
317
+ setRightCollapsed: (collapsed: boolean) => void;
318
+ leftCollapsible: boolean;
319
+ rightCollapsible: boolean;
301
320
  }
302
- declare function ChatFull({ title, placeholder, starterPrompts, options, className, headerProps, leftSidebar, rightSidebar, leftSidebarClassName, rightSidebarClassName, leftSidebarCollapsible, rightSidebarCollapsible, defaultLeftSidebarCollapsed, defaultRightSidebarCollapsed, leftSidebarCollapsed: controlledLeftCollapsed, rightSidebarCollapsed: controlledRightCollapsed, onLeftSidebarCollapseChange, onRightSidebarCollapseChange, autoFocus, defaultSelectedIds, }: ChatFullProps): react_jsx_runtime.JSX.Element;
321
+ declare const ChatSidebarContext: React__default.Context<ChatSidebarContextValue | undefined>;
322
+ declare function useChatSidebar(): ChatSidebarContextValue;
303
323
 
304
324
  interface ThreadListProps {
305
325
  className?: string;
@@ -346,6 +366,136 @@ interface UIRendererProps {
346
366
  */
347
367
  declare function UIRenderer({ node }: UIRendererProps): react_jsx_runtime.JSX.Element;
348
368
 
369
+ type Spacing = "xs" | "sm" | "md" | "lg" | "xl" | "xxl";
370
+ type FontSize = "xs" | "sm" | "md" | "lg" | "xl" | "xxl";
371
+ type FontWeight = "normal" | "medium" | "semibold" | "bold";
372
+
373
+ type Size = "sm" | "md" | "lg";
374
+ type Align = "start" | "center" | "end" | "stretch";
375
+ type Justify = "start" | "center" | "end" | "between" | "around";
376
+ type Orientation = "horizontal" | "vertical";
377
+ interface BaseComponentProps {
378
+ className?: string;
379
+ style?: CSSProperties;
380
+ }
381
+ type CardProps = BaseComponentProps & UIContract["card"] & {
382
+ children?: React__default.ReactNode[];
383
+ };
384
+ type RowProps = BaseComponentProps & UIContract["row"] & {
385
+ children?: React__default.ReactNode[];
386
+ };
387
+ type ColProps = BaseComponentProps & UIContract["col"] & {
388
+ children?: React__default.ReactNode[] | React__default.ReactNode;
389
+ overflow?: "visible" | "hidden" | "scroll" | "auto";
390
+ position?: "static" | "relative" | "absolute" | "fixed" | "sticky";
391
+ };
392
+ type BoxProps = BaseComponentProps & UIContract["box"] & {
393
+ children?: React__default.ReactNode | React__default.ReactNode[];
394
+ overflow?: "visible" | "hidden" | "scroll" | "auto";
395
+ };
396
+ type SpacerProps = BaseComponentProps & UIContract["spacer"];
397
+ type DividerProps = BaseComponentProps & UIContract["divider"] & {
398
+ size?: Size;
399
+ };
400
+ type ListProps = BaseComponentProps & {
401
+ children?: React__default.ReactNode;
402
+ width?: string | number;
403
+ };
404
+ type ListItemProps = BaseComponentProps & UIContract["listItem"] & {
405
+ children?: React__default.ReactNode;
406
+ orientation?: Orientation;
407
+ align?: Align;
408
+ justify?: Justify;
409
+ width?: string | number;
410
+ padding?: Spacing;
411
+ };
412
+ type ImageProps = BaseComponentProps & UIContract["image"] & {
413
+ fallbackText?: string;
414
+ showFallbackIcon?: boolean;
415
+ };
416
+ type ChartProps = BaseComponentProps & UIContract["chart"] & {
417
+ size?: Size;
418
+ showValues?: boolean;
419
+ showGrid?: boolean;
420
+ showTooltips?: boolean;
421
+ };
422
+ type BadgeProps = BaseComponentProps & UIContract["badge"];
423
+ type TextProps = BaseComponentProps & UIContract["text"];
424
+ type HeadingProps = BaseComponentProps & UIContract["heading"];
425
+ type FormProps = BaseComponentProps & UIContract["form"] & {
426
+ children?: React__default.ReactNode[];
427
+ };
428
+ type InputProps = BaseComponentProps & UIContract["input"] & {
429
+ disabled?: boolean;
430
+ value?: string;
431
+ };
432
+ type ButtonProps = BaseComponentProps & UIContract["button"] & {
433
+ fullWidth?: boolean;
434
+ };
435
+ type LabelProps = BaseComponentProps & UIContract["label"] & {
436
+ size?: FontSize;
437
+ weight?: FontWeight;
438
+ };
439
+ type TextareaProps = BaseComponentProps & UIContract["textarea"] & {
440
+ value?: string;
441
+ disabled?: boolean;
442
+ };
443
+ type SelectProps = BaseComponentProps & UIContract["select"] & {
444
+ value?: string;
445
+ disabled?: boolean;
446
+ };
447
+ type CheckboxProps = BaseComponentProps & UIContract["checkbox"] & {
448
+ defaultChecked?: boolean;
449
+ disabled?: boolean;
450
+ };
451
+ type RadioGroupProps = BaseComponentProps & UIContract["radioGroup"] & {
452
+ value?: string;
453
+ defaultValue?: string;
454
+ disabled?: boolean;
455
+ };
456
+
457
+ declare const Button: React__default.FC<ButtonProps>;
458
+
459
+ declare const Input: React__default.FC<InputProps>;
460
+
461
+ declare const Textarea: React__default.FC<TextareaProps>;
462
+
463
+ declare const Select: React__default.FC<SelectProps>;
464
+
465
+ declare const Checkbox: React__default.FC<CheckboxProps>;
466
+
467
+ declare const RadioGroup: React__default.FC<RadioGroupProps>;
468
+
469
+ declare const Form: React__default.FC<FormProps>;
470
+
471
+ declare const Heading: React__default.FC<HeadingProps>;
472
+
473
+ declare const Image: React__default.FC<ImageProps>;
474
+
475
+ declare const Label: React__default.FC<LabelProps>;
476
+
477
+ declare const List: React__default.FC<ListProps>;
478
+
479
+ declare const ListItem: React__default.FC<ListItemProps>;
480
+
481
+ declare const Spacer: React__default.FC<SpacerProps>;
482
+
483
+ declare const Divider: React__default.FC<DividerProps>;
484
+
485
+ declare const Box: React__default.FC<BoxProps>;
486
+
487
+ declare const Chart: React__default.FC<ChartProps>;
488
+
489
+ declare const Card: React__default.FC<CardProps>;
490
+
491
+ declare const Row: React__default.FC<RowProps>;
492
+
493
+ declare const Col: React__default.FC<ColProps>;
494
+
495
+ declare const Text: React__default.FC<TextProps>;
496
+
497
+ declare const Badge: React__default.FC<BadgeProps>;
498
+
349
499
  declare function groupEventsToMessages(events: Event[]): Message[];
350
500
 
351
- export { AccountDialog, type AccountDialogProps, AuthContext, type AuthContextValue, AuthProvider, type AuthProviderProps, type AuthService, ChatFull, type ChatFullProps, ChatHeader, type ChatHeaderProps, ChatPopup, type ChatPopupProps, ChatSidebar, type ChatSidebarProps, Composer, type ComposerOption, type ComposerOptionGroup, CreateThreadButton, type CreateThreadButtonProps, MelonyClientProvider, type MelonyClientProviderProps, MelonyContext, type MelonyContextValue, type Message, type StarterPrompt, ThemeProvider, ThemeToggle, Thread, ThreadContext, type ThreadContextValue, type ThreadData, ThreadList, type ThreadListProps, ThreadPopover, type ThreadPopoverProps, ThreadProvider, type ThreadProviderProps, type ThreadService, UIRenderer, type UIRendererProps, type UseMelonyOptions, type User, groupEventsToMessages, useAuth, useMelony, useTheme, useThreads };
501
+ export { AccountDialog, type AccountDialogProps, AuthContext, type AuthContextValue, AuthProvider, type AuthProviderProps, type AuthService, Badge, Box, Button, Card, Chart, ChatFull, type ChatFullProps, ChatHeader, type ChatHeaderProps, ChatPopup, type ChatPopupProps, ChatSidebar, ChatSidebarContext, type ChatSidebarContextValue, type ChatSidebarProps, Checkbox, Col, Composer, type ComposerOption, type ComposerOptionGroup, CreateThreadButton, type CreateThreadButtonProps, Divider, Form, Heading, Image, Input, Label, List, ListItem, MelonyClientProvider, type MelonyClientProviderProps, MelonyContext, type MelonyContextValue, type Message, RadioGroup, Row, type ScreenSize, Select, SidebarToggle, type SidebarToggleProps, Spacer, type StarterPrompt, Text, Textarea, ThemeProvider, ThemeToggle, Thread, ThreadContext, type ThreadContextValue, type ThreadData, ThreadList, type ThreadListProps, ThreadPopover, type ThreadPopoverProps, ThreadProvider, type ThreadProviderProps, type ThreadService, UIRenderer, type UIRendererProps, type UseMelonyOptions, type User, WelcomeScreen, type WelcomeScreenProps, groupEventsToMessages, useAuth, useChatSidebar, useMelony, useScreenSize, useTheme, useThreads };