@mindly/ui-components 5.58.0 → 5.59.1

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.
@@ -9,7 +9,7 @@ type ChatListItemProps = {
9
9
  status?: 'sent' | 'viewed';
10
10
  time?: number;
11
11
  timeZone?: string;
12
- lastMessageType?: 'text' | 'file' | 'image' | 'video' | 'system';
12
+ lastMessageType?: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
13
13
  locale?: string;
14
14
  isDisabled?: boolean;
15
15
  t?: WithTranslation['t'];
@@ -4,7 +4,7 @@ export declare const MessageInfo: import("styled-components").StyledComponent<"d
4
4
  export declare const UserName: import("styled-components").StyledComponent<"div", any, {}, never>;
5
5
  export declare const MessageStatus: import("styled-components").StyledComponent<"div", any, {}, never>;
6
6
  type TextMessageProps = {
7
- lastMessageType: 'text' | 'file' | 'image' | 'video' | 'system';
7
+ lastMessageType: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
8
8
  };
9
9
  export declare const LastMessage: import("styled-components").StyledComponent<"div", any, TextMessageProps, never>;
10
10
  export declare const BadgeContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
@@ -1,11 +1,17 @@
1
1
  import React from 'react';
2
2
  type ChatMessageProps = {
3
3
  message: string | File;
4
+ /**
5
+ * This property is specifically for broadcast messages.
6
+ * It allows a separate file (e.g., an image URL) to be associated with the broadcast message,
7
+ * while the 'message' property contains the text content.
8
+ */
9
+ fileUrl?: string;
4
10
  position: 'left' | 'right';
5
11
  time: number;
6
12
  timeZone?: string;
7
13
  status?: 'loading' | 'sent' | 'viewed';
8
- messageType?: 'text' | 'file' | 'image' | 'video' | 'system';
14
+ messageType?: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
9
15
  onFileClick?: (type: 'file' | 'image', link: string) => void;
10
16
  fileInfo?: {
11
17
  originalName: string;
@@ -14,6 +20,10 @@ type ChatMessageProps = {
14
20
  height?: number;
15
21
  };
16
22
  locale?: string;
23
+ buttons?: {
24
+ text: string;
25
+ onClickHandler: () => void;
26
+ }[] | null;
17
27
  };
18
28
  declare const _default: React.NamedExoticComponent<ChatMessageProps>;
19
29
  export default _default;
@@ -1,11 +1,12 @@
1
1
  type MessageWrapperProps = {
2
2
  position: 'left' | 'right';
3
- messageType: 'text' | 'file' | 'image' | 'video' | 'system';
3
+ messageType: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
4
4
  };
5
5
  export declare const MessageWrapper: import("styled-components").StyledComponent<"div", any, MessageWrapperProps, never>;
6
6
  export declare const TextMessageWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
7
7
  type ImageMessageWrapperProps = {
8
8
  position: 'left' | 'right';
9
+ messageType?: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
9
10
  };
10
11
  export declare const ImageMessageWrapper: import("styled-components").StyledComponent<"div", any, ImageMessageWrapperProps, never>;
11
12
  type ImageTimeWrapperProps = {
package/dist/index.d.ts CHANGED
@@ -457,7 +457,7 @@ type ChatListItemProps = {
457
457
  status?: 'sent' | 'viewed';
458
458
  time?: number;
459
459
  timeZone?: string;
460
- lastMessageType?: 'text' | 'file' | 'image' | 'video' | 'system';
460
+ lastMessageType?: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
461
461
  locale?: string;
462
462
  isDisabled?: boolean;
463
463
  t?: WithTranslation['t'];
@@ -466,11 +466,17 @@ declare const _default$Z: React__default.NamedExoticComponent<ChatListItemProps>
466
466
 
467
467
  type ChatMessageProps = {
468
468
  message: string | File;
469
+ /**
470
+ * This property is specifically for broadcast messages.
471
+ * It allows a separate file (e.g., an image URL) to be associated with the broadcast message,
472
+ * while the 'message' property contains the text content.
473
+ */
474
+ fileUrl?: string;
469
475
  position: 'left' | 'right';
470
476
  time: number;
471
477
  timeZone?: string;
472
478
  status?: 'loading' | 'sent' | 'viewed';
473
- messageType?: 'text' | 'file' | 'image' | 'video' | 'system';
479
+ messageType?: 'text' | 'file' | 'image' | 'video' | 'system' | 'broadcast';
474
480
  onFileClick?: (type: 'file' | 'image', link: string) => void;
475
481
  fileInfo?: {
476
482
  originalName: string;
@@ -479,6 +485,10 @@ type ChatMessageProps = {
479
485
  height?: number;
480
486
  };
481
487
  locale?: string;
488
+ buttons?: {
489
+ text: string;
490
+ onClickHandler: () => void;
491
+ }[] | null;
482
492
  };
483
493
  declare const _default$Y: React__default.NamedExoticComponent<ChatMessageProps>;
484
494
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mindly/ui-components",
3
- "version": "5.58.0",
3
+ "version": "5.59.1",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "clean": "rimraf dist",