@medipha/chat 1.0.25 → 1.0.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.
@@ -2,6 +2,11 @@ import { ChatUser, Conversation, ConversationMember, MessageContent } from './ch
2
2
  export declare const getMemberUser: (member: ConversationMember) => ChatUser;
3
3
  export declare const getMemberUserId: (member: ConversationMember) => string | null;
4
4
  export declare const getMemberRole: (member: ConversationMember | null | undefined) => string;
5
+ /** The person on the other side of a DIRECT conversation, or undefined for a group (and for
6
+ * a direct chat whose roster hasn't loaded, or the note-to-self case where the only member
7
+ * is the viewer). A direct row IS that one account everywhere it's listed — sidebar, forward
8
+ * picker, conversation header — so this is what lets those rows show and open their profile. */
9
+ export declare const getDirectPeerMember: (conversation: Conversation, currentUserId: string | null) => ConversationMember | undefined;
5
10
  /** The group owner's userId, or null when the roster isn't loaded / has no OWNER row.
6
11
  * Drives the key badge shown on their avatar in the timeline and account-info dialog. */
7
12
  export declare const getGroupOwnerId: (members: ConversationMember[] | undefined | null) => string | null;
@@ -104,6 +104,7 @@ export interface MessageReplyPreview {
104
104
  content: MessageContent | null;
105
105
  attachmentName: string | null;
106
106
  attachmentUrl?: string | null;
107
+ createdAt?: string | null;
107
108
  removedAt?: string | null;
108
109
  removedById?: string | null;
109
110
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@medipha/chat",
3
- "version": "1.0.25",
3
+ "version": "1.0.26",
4
4
  "description": "Embeddable Medic-ERP chat module for React applications.",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",
@@ -57,7 +57,7 @@
57
57
  "uuid": "^11.0.5",
58
58
  "yet-another-react-lightbox": "^3.32.2",
59
59
  "zustand": "^5.0.8",
60
- "@medipha/chat-core": "1.0.10"
60
+ "@medipha/chat-core": "1.0.11"
61
61
  },
62
62
  "devDependencies": {
63
63
  "@eslint/js": "^10.0.1",
@@ -1,12 +0,0 @@
1
- import { ChatUser } from '../../../utils/chat';
2
- interface SelectedMembersModalProps {
3
- users: ChatUser[];
4
- onClose: () => void;
5
- onRemove: (user: ChatUser) => void;
6
- onOpenProfile: (userId: string) => void;
7
- }
8
- /** Read-only-ish review of who's picked so far for the new group, opened from the
9
- * "Đã chọn N thành viên" count — each row can also be unchecked without hunting it
10
- * back down in the (possibly filtered/paginated) main list. */
11
- export declare function SelectedMembersModal({ users, onClose, onRemove, onOpenProfile }: SelectedMembersModalProps): import("react/jsx-runtime").JSX.Element;
12
- export {};