mediasfu-angular 2.2.0 → 2.2.2
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/README.md +2288 -375
- package/dist/README.md +2288 -375
- package/dist/fesm2022/mediasfu-angular.mjs +9519 -4188
- package/dist/fesm2022/mediasfu-angular.mjs.map +1 -1
- package/dist/lib/@types/types.d.ts +6 -1
- package/dist/lib/@types/ui-overrides.types.d.ts +310 -0
- package/dist/lib/components/background-components/background-modal/background-modal.component.d.ts +1023 -2
- package/dist/lib/components/breakout-components/breakout-rooms-modal.component.d.ts +1069 -45
- package/dist/lib/components/breakout-components/edit-room-modal/edit-room-modal.component.d.ts +1054 -42
- package/dist/lib/components/co-host-components/co-host-modal/co-host-modal.component.d.ts +1067 -56
- package/dist/lib/components/display-components/alert-component/alert.component.component.d.ts +80 -24
- package/dist/lib/components/display-components/audio-grid/audio-grid.component.d.ts +83 -11
- package/dist/lib/components/display-components/flexible-grid/flexible-grid.component.d.ts +96 -33
- package/dist/lib/components/display-components/loading-modal/loading-modal.component.d.ts +16 -26
- package/dist/lib/components/display-components/main-aspect-component/main-aspect-component.component.d.ts +6 -2
- package/dist/lib/components/display-components/main-container-component/main-container-component.component.d.ts +6 -2
- package/dist/lib/components/display-components/main-grid-component/main-grid-component.component.d.ts +7 -13
- package/dist/lib/components/display-components/main-screen-component/main-screen-component.component.d.ts +508 -7
- package/dist/lib/components/display-components/other-grid-component/other-grid-component.component.d.ts +7 -1
- package/dist/lib/components/display-components/sub-aspect-component/sub-aspect-component.component.d.ts +7 -2
- package/dist/lib/components/display-settings-components/display-settings-modal.component.d.ts +1107 -27
- package/dist/lib/components/event-settings-components/event-settings-modal/event-settings-modal.component.d.ts +1134 -49
- package/dist/lib/components/exit-components/confirm-exit-modal/confirm-exit-modal.component.d.ts +94 -32
- package/dist/lib/components/media-settings-components/media-settings-modal/media-settings-modal.component.d.ts +1123 -47
- package/dist/lib/components/mediasfu-components/mediasfu-broadcast.component.d.ts +24966 -73
- package/dist/lib/components/mediasfu-components/mediasfu-chat.component.d.ts +276 -73
- package/dist/lib/components/mediasfu-components/mediasfu-conference.component.d.ts +18132 -93
- package/dist/lib/components/mediasfu-components/mediasfu-generic.component.d.ts +56344 -93
- package/dist/lib/components/mediasfu-components/mediasfu-webinar.component.d.ts +20849 -93
- package/dist/lib/components/menu-components/custom-buttons/custom-buttons.component.d.ts +23 -4
- package/dist/lib/components/menu-components/meeting-id-component/meeting-id-component.component.d.ts +78 -1
- package/dist/lib/components/menu-components/meeting-passcode-component/meeting-passcode-component.component.d.ts +37 -1
- package/dist/lib/components/menu-components/menu-modal/menu-modal.component.d.ts +689 -9
- package/dist/lib/components/menu-components/share-buttons-component/share-buttons-component.component.d.ts +46 -2
- package/dist/lib/components/message-components/messages-modal/messages-modal.component.d.ts +76 -13
- package/dist/lib/components/misc-components/confirm-here-modal/confirm-here-modal.component.d.ts +1113 -17
- package/dist/lib/components/misc-components/share-event-modal/share-event-modal.component.d.ts +1114 -29
- package/dist/lib/components/participants-components/participants-modal/participants-modal.component.d.ts +1084 -6
- package/dist/lib/components/polls-components/poll-modal/poll-modal.component.d.ts +1060 -21
- package/dist/lib/components/recording-components/recording-modal/recording-modal.component.d.ts +1054 -35
- package/dist/lib/components/requests-components/requests-modal/requests-modal.component.d.ts +1117 -45
- package/dist/lib/components/screenboard-components/screenboard-modal/screenboard-modal.component.d.ts +1059 -47
- package/dist/lib/components/waiting-components/waiting-room-modal.component.d.ts +1119 -46
- package/dist/lib/components/whiteboard-components/configure-whiteboard-modal/configure-whiteboard-modal.component.d.ts +1049 -16
- package/dist/lib/consumers/add-videos-grid.service.d.ts +3 -0
- package/dist/lib/consumers/connect-ips.service.d.ts +3 -1
- package/dist/lib/consumers/connect-recv-transport.service.d.ts +4 -1
- package/dist/lib/consumers/connect-send-transport-audio.service.d.ts +5 -1
- package/dist/lib/consumers/connect-send-transport-screen.service.d.ts +6 -1
- package/dist/lib/consumers/connect-send-transport-video.service.d.ts +6 -1
- package/dist/lib/consumers/connect-send-transport.service.d.ts +3 -1
- package/dist/lib/consumers/consumer-resume.service.d.ts +2 -1
- package/dist/lib/consumers/create-send-transport.service.d.ts +4 -1
- package/dist/lib/consumers/disconnect-send-transport-audio.service.d.ts +3 -1
- package/dist/lib/consumers/disconnect-send-transport-screen.service.d.ts +3 -1
- package/dist/lib/consumers/disconnect-send-transport-video.service.d.ts +3 -1
- package/dist/lib/consumers/prepopulate-user-media.service.d.ts +3 -0
- package/dist/lib/consumers/resume-send-transport-audio.service.d.ts +3 -1
- package/dist/lib/consumers/signal-new-consumer-transport.service.d.ts +3 -1
- package/dist/lib/consumers/socket-receive-methods/join-consume-room.service.d.ts +3 -1
- package/dist/lib/consumers/socket-receive-methods/new-pipe-producer.service.d.ts +3 -1
- package/dist/lib/consumers/stream-success-audio-switch.service.d.ts +5 -1
- package/dist/lib/consumers/stream-success-audio.service.d.ts +3 -1
- package/dist/lib/consumers/stream-success-video.service.d.ts +5 -1
- package/dist/lib/directives/with-override.directive.d.ts +76 -0
- package/dist/lib/methods/utils/initial-values.util.d.ts +7 -2
- package/dist/lib/methods/utils/mini-audio-player/mini-audio-player.component.d.ts +3 -1
- package/dist/lib/methods/utils/producer/a-params.service.d.ts +4 -1
- package/dist/lib/methods/utils/producer/h-params.service.d.ts +4 -1
- package/dist/lib/methods/utils/producer/screen-params.service.d.ts +4 -1
- package/dist/lib/methods/utils/producer/v-params.service.d.ts +4 -1
- package/dist/lib/methods/whiteboard-methods/capture-canvas-stream.service.d.ts +3 -1
- package/dist/lib/producer-client/producer-client-emits/create-device-client.service.d.ts +4 -1
- package/dist/lib/producer-client/producer-client-emits/update-room-parameters-client.service.d.ts +3 -1
- package/dist/lib/producers/producer-emits/join-con-room.service.d.ts +3 -1
- package/dist/lib/producers/socket-receive-methods/get-domains.service.d.ts +3 -1
- package/dist/lib/services/ui-override-resolver.service.d.ts +91 -0
- package/dist/public-api.d.ts +4 -0
- package/package.json +2 -2
|
@@ -1,18 +1,46 @@
|
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
|
1
2
|
import { IconDefinition } from '@fortawesome/free-solid-svg-icons';
|
|
2
3
|
import { EventType } from '../../../@types/types';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
export interface ShareButton {
|
|
5
6
|
icon: IconDefinition;
|
|
6
|
-
action: () => void
|
|
7
|
+
action: () => void | Promise<void>;
|
|
7
8
|
show: boolean;
|
|
8
9
|
color?: string;
|
|
9
10
|
iconColor?: string;
|
|
11
|
+
wrapperAttributes?: {
|
|
12
|
+
[key: string]: any;
|
|
13
|
+
};
|
|
14
|
+
iconAttributes?: {
|
|
15
|
+
[key: string]: any;
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
export interface ShareButtonRenderContext {
|
|
19
|
+
button: ShareButton;
|
|
20
|
+
index: number;
|
|
21
|
+
shareUrl: string;
|
|
22
|
+
}
|
|
23
|
+
export interface ShareButtonsRenderContext {
|
|
24
|
+
buttons: ShareButton[];
|
|
25
|
+
shareUrl: string;
|
|
10
26
|
}
|
|
11
27
|
export interface ShareButtonsComponentOptions {
|
|
12
28
|
meetingID: string;
|
|
13
29
|
shareButtons?: ShareButton[];
|
|
14
30
|
eventType: EventType;
|
|
15
31
|
localLink?: string;
|
|
32
|
+
containerAttributes?: {
|
|
33
|
+
[key: string]: any;
|
|
34
|
+
};
|
|
35
|
+
renderContainer?: TemplateRef<ShareButtonsRenderContext>;
|
|
36
|
+
renderButtons?: TemplateRef<ShareButtonsRenderContext>;
|
|
37
|
+
renderButton?: TemplateRef<ShareButtonRenderContext>;
|
|
38
|
+
renderIcon?: TemplateRef<ShareButtonRenderContext>;
|
|
39
|
+
getShareUrl?: (options: {
|
|
40
|
+
meetingID: string;
|
|
41
|
+
eventType: EventType;
|
|
42
|
+
localLink?: string;
|
|
43
|
+
}) => string;
|
|
16
44
|
}
|
|
17
45
|
export type ShareButtonsComponentType = (options: ShareButtonsComponentOptions) => HTMLElement;
|
|
18
46
|
/**
|
|
@@ -42,10 +70,26 @@ export declare class ShareButtonsComponent {
|
|
|
42
70
|
shareButtons: ShareButton[];
|
|
43
71
|
eventType: EventType;
|
|
44
72
|
localLink?: string;
|
|
73
|
+
containerAttributes?: {
|
|
74
|
+
[key: string]: any;
|
|
75
|
+
};
|
|
76
|
+
renderContainer?: TemplateRef<ShareButtonsRenderContext>;
|
|
77
|
+
renderButtons?: TemplateRef<ShareButtonsRenderContext>;
|
|
78
|
+
renderButton?: TemplateRef<ShareButtonRenderContext>;
|
|
79
|
+
renderIcon?: TemplateRef<ShareButtonRenderContext>;
|
|
80
|
+
getShareUrlFn?: (options: {
|
|
81
|
+
meetingID: string;
|
|
82
|
+
eventType: EventType;
|
|
83
|
+
localLink?: string;
|
|
84
|
+
}) => string;
|
|
45
85
|
defaultShareButtons: ShareButton[];
|
|
46
86
|
get shareName(): "chat" | "broadcast" | "meeting";
|
|
47
87
|
getShareUrl(): string;
|
|
48
88
|
get filteredShareButtons(): ShareButton[];
|
|
89
|
+
get shareButtonsRenderContext(): ShareButtonsRenderContext;
|
|
90
|
+
getButtonRenderContext(button: ShareButton, index: number): ShareButtonRenderContext;
|
|
91
|
+
getButtonStyle(button: ShareButton, index: number): any;
|
|
92
|
+
getIconStyle(button: ShareButton): any;
|
|
49
93
|
static ɵfac: i0.ɵɵFactoryDeclaration<ShareButtonsComponent, never>;
|
|
50
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ShareButtonsComponent, "app-share-buttons-component", never, { "meetingID": { "alias": "meetingID"; "required": false; }; "shareButtons": { "alias": "shareButtons"; "required": false; }; "eventType": { "alias": "eventType"; "required": false; }; "localLink": { "alias": "localLink"; "required": false; }; }, {}, never, never, true, never>;
|
|
94
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ShareButtonsComponent, "app-share-buttons-component", never, { "meetingID": { "alias": "meetingID"; "required": false; }; "shareButtons": { "alias": "shareButtons"; "required": false; }; "eventType": { "alias": "eventType"; "required": false; }; "localLink": { "alias": "localLink"; "required": false; }; "containerAttributes": { "alias": "containerAttributes"; "required": false; }; "renderContainer": { "alias": "renderContainer"; "required": false; }; "renderButtons": { "alias": "renderButtons"; "required": false; }; "renderButton": { "alias": "renderButton"; "required": false; }; "renderIcon": { "alias": "renderIcon"; "required": false; }; "getShareUrlFn": { "alias": "getShareUrlFn"; "required": false; }; }, {}, never, never, true, never>;
|
|
51
95
|
}
|
|
@@ -24,19 +24,38 @@ export interface MessagesModalOptions {
|
|
|
24
24
|
roomName: string;
|
|
25
25
|
socket: Socket;
|
|
26
26
|
chatSetting: string;
|
|
27
|
+
overlayStyle?: Partial<CSSStyleDeclaration>;
|
|
28
|
+
contentStyle?: Partial<CSSStyleDeclaration>;
|
|
29
|
+
customTemplate?: any;
|
|
27
30
|
}
|
|
28
31
|
export type MessagesModalType = (options: MessagesModalOptions) => void;
|
|
29
32
|
/**
|
|
30
|
-
*
|
|
31
|
-
* @description A modal component for managing chat messages in MediaSFU applications, supporting both group and direct messaging, and providing a customizable user interface.
|
|
33
|
+
* MessagesModal - Full-featured chat modal with group and direct messaging
|
|
32
34
|
*
|
|
35
|
+
* @component
|
|
33
36
|
* @selector app-messages-modal
|
|
34
37
|
* @templateUrl ./messages-modal.component.html
|
|
35
38
|
* @styleUrls ./messages-modal.component.css
|
|
36
39
|
* @standalone true
|
|
37
40
|
* @imports [CommonModule, FontAwesomeModule, MessagePanel]
|
|
38
41
|
*
|
|
42
|
+
* @description
|
|
43
|
+
* A comprehensive chat modal supporting group and direct messaging with full UI customization.
|
|
44
|
+
* Supports three levels of customization:
|
|
45
|
+
* 1. **Style Overrides**: Customize appearance with `overlayStyle` and `contentStyle`
|
|
46
|
+
* 2. **Component Integration**: Integrates with MediaSFU messaging system
|
|
47
|
+
* 3. **Complete Replacement**: Use `customTemplate` for full UI control
|
|
48
|
+
*
|
|
49
|
+
* Features:
|
|
50
|
+
* - Group chat for all participants
|
|
51
|
+
* - Direct messaging between participants
|
|
52
|
+
* - Message history and real-time updates
|
|
53
|
+
* - Read receipts and sender identification
|
|
54
|
+
* - Host/co-host message controls
|
|
55
|
+
* - Socket-based real-time messaging
|
|
56
|
+
*
|
|
39
57
|
* @example
|
|
58
|
+
* **Basic Usage**
|
|
40
59
|
* ```html
|
|
41
60
|
* <app-messages-modal
|
|
42
61
|
* [isMessagesModalVisible]="true"
|
|
@@ -47,18 +66,57 @@ export type MessagesModalType = (options: MessagesModalOptions) => void;
|
|
|
47
66
|
* [eventType]="'webinar'"
|
|
48
67
|
* [member]="'JohnDoe'"
|
|
49
68
|
* [islevel]="'2'"
|
|
50
|
-
* [coHostResponsibility]="coHostRoles"
|
|
51
|
-
* [coHost]="'coHost123'"
|
|
52
|
-
* [startDirectMessage]="false"
|
|
53
|
-
* [directMessageDetails]="selectedParticipant"
|
|
54
|
-
* [updateStartDirectMessage]="updateDirectMessageStart"
|
|
55
|
-
* [updateDirectMessageDetails]="updateParticipantDetails"
|
|
56
|
-
* [showAlert]="displayAlert"
|
|
57
69
|
* [roomName]="'RoomName'"
|
|
58
|
-
* [socket]="chatSocket"
|
|
59
|
-
*
|
|
60
|
-
*
|
|
70
|
+
* [socket]="chatSocket">
|
|
71
|
+
* </app-messages-modal>
|
|
72
|
+
* ```
|
|
73
|
+
*
|
|
74
|
+
* @example
|
|
75
|
+
* **With Style Customization**
|
|
76
|
+
* ```html
|
|
77
|
+
* <app-messages-modal
|
|
78
|
+
* [isMessagesModalVisible]="true"
|
|
79
|
+
* [overlayStyle]="{ backgroundColor: 'rgba(0, 0, 0, 0.85)' }"
|
|
80
|
+
* [contentStyle]="{ borderRadius: '12px', maxHeight: '600px' }"
|
|
81
|
+
* [onMessagesClose]="closeMessages"
|
|
82
|
+
* [messages]="chatMessages"
|
|
83
|
+
* [socket]="chatSocket">
|
|
84
|
+
* </app-messages-modal>
|
|
61
85
|
* ```
|
|
86
|
+
*
|
|
87
|
+
* @example
|
|
88
|
+
* **Custom Template Override**
|
|
89
|
+
* ```html
|
|
90
|
+
* <app-messages-modal
|
|
91
|
+
* [isMessagesModalVisible]="true"
|
|
92
|
+
* [customTemplate]="customChatTemplate"
|
|
93
|
+
* [messages]="chatMessages"
|
|
94
|
+
* [onMessagesClose]="closeMessages">
|
|
95
|
+
* </app-messages-modal>
|
|
96
|
+
*
|
|
97
|
+
* <ng-template #customChatTemplate let-context>
|
|
98
|
+
* <div class="my-chat-modal">
|
|
99
|
+
* <h2>Chat ({{ context.messages.length }} messages)</h2>
|
|
100
|
+
* <div *ngFor="let message of context.messages">
|
|
101
|
+
* <strong>{{ message.sender }}:</strong> {{ message.message }}
|
|
102
|
+
* </div>
|
|
103
|
+
* </div>
|
|
104
|
+
* </ng-template>
|
|
105
|
+
* ```
|
|
106
|
+
*
|
|
107
|
+
* @input {boolean} isMessagesModalVisible - Controls modal visibility
|
|
108
|
+
* @input {() => void} onMessagesClose - Callback when modal is closed
|
|
109
|
+
* @input {Message[]} messages - Array of chat messages
|
|
110
|
+
* @input {string} position - Modal position (default: 'bottomRight')
|
|
111
|
+
* @input {string} backgroundColor - Modal background color (default: '#f5f5f5')
|
|
112
|
+
* @input {EventType} eventType - Type of event (meeting, webinar, etc.)
|
|
113
|
+
* @input {string} member - Current user's name/ID
|
|
114
|
+
* @input {string} islevel - User's privilege level
|
|
115
|
+
* @input {Socket} socket - Socket.io connection for real-time messaging
|
|
116
|
+
* @input {string} roomName - Room identifier
|
|
117
|
+
* @input {Partial<CSSStyleDeclaration>} overlayStyle - Custom overlay styles
|
|
118
|
+
* @input {Partial<CSSStyleDeclaration>} contentStyle - Custom content styles
|
|
119
|
+
* @input {TemplateRef<any>} customTemplate - Complete template override
|
|
62
120
|
*/
|
|
63
121
|
export declare class MessagesModal implements OnInit, OnChanges {
|
|
64
122
|
private SendMessageService;
|
|
@@ -83,6 +141,9 @@ export declare class MessagesModal implements OnInit, OnChanges {
|
|
|
83
141
|
roomName: string;
|
|
84
142
|
socket: Socket;
|
|
85
143
|
chatSetting: string;
|
|
144
|
+
overlayStyle?: Partial<CSSStyleDeclaration>;
|
|
145
|
+
contentStyle?: Partial<CSSStyleDeclaration>;
|
|
146
|
+
customTemplate?: any;
|
|
86
147
|
faTimes: import("@fortawesome/fontawesome-common-types").IconDefinition;
|
|
87
148
|
directMessages: Array<any>;
|
|
88
149
|
groupMessages: Array<any>;
|
|
@@ -153,6 +214,8 @@ export declare class MessagesModal implements OnInit, OnChanges {
|
|
|
153
214
|
color: string;
|
|
154
215
|
};
|
|
155
216
|
};
|
|
217
|
+
getCombinedOverlayStyle(): any;
|
|
218
|
+
getCombinedContentStyle(): any;
|
|
156
219
|
static ɵfac: i0.ɵɵFactoryDeclaration<MessagesModal, never>;
|
|
157
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<MessagesModal, "app-messages-modal", never, { "isMessagesModalVisible": { "alias": "isMessagesModalVisible"; "required": false; }; "onMessagesClose": { "alias": "onMessagesClose"; "required": false; }; "onSendMessagePress": { "alias": "onSendMessagePress"; "required": false; }; "messages": { "alias": "messages"; "required": false; }; "position": { "alias": "position"; "required": false; }; "backgroundColor": { "alias": "backgroundColor"; "required": false; }; "activeTabBackgroundColor": { "alias": "activeTabBackgroundColor"; "required": false; }; "eventType": { "alias": "eventType"; "required": false; }; "member": { "alias": "member"; "required": false; }; "islevel": { "alias": "islevel"; "required": false; }; "coHostResponsibility": { "alias": "coHostResponsibility"; "required": false; }; "coHost": { "alias": "coHost"; "required": false; }; "startDirectMessage": { "alias": "startDirectMessage"; "required": false; }; "directMessageDetails": { "alias": "directMessageDetails"; "required": false; }; "updateStartDirectMessage": { "alias": "updateStartDirectMessage"; "required": false; }; "updateDirectMessageDetails": { "alias": "updateDirectMessageDetails"; "required": false; }; "showAlert": { "alias": "showAlert"; "required": false; }; "roomName": { "alias": "roomName"; "required": false; }; "socket": { "alias": "socket"; "required": false; }; "chatSetting": { "alias": "chatSetting"; "required": false; }; }, {}, never, never, true, never>;
|
|
220
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MessagesModal, "app-messages-modal", never, { "isMessagesModalVisible": { "alias": "isMessagesModalVisible"; "required": false; }; "onMessagesClose": { "alias": "onMessagesClose"; "required": false; }; "onSendMessagePress": { "alias": "onSendMessagePress"; "required": false; }; "messages": { "alias": "messages"; "required": false; }; "position": { "alias": "position"; "required": false; }; "backgroundColor": { "alias": "backgroundColor"; "required": false; }; "activeTabBackgroundColor": { "alias": "activeTabBackgroundColor"; "required": false; }; "eventType": { "alias": "eventType"; "required": false; }; "member": { "alias": "member"; "required": false; }; "islevel": { "alias": "islevel"; "required": false; }; "coHostResponsibility": { "alias": "coHostResponsibility"; "required": false; }; "coHost": { "alias": "coHost"; "required": false; }; "startDirectMessage": { "alias": "startDirectMessage"; "required": false; }; "directMessageDetails": { "alias": "directMessageDetails"; "required": false; }; "updateStartDirectMessage": { "alias": "updateStartDirectMessage"; "required": false; }; "updateDirectMessageDetails": { "alias": "updateDirectMessageDetails"; "required": false; }; "showAlert": { "alias": "showAlert"; "required": false; }; "roomName": { "alias": "roomName"; "required": false; }; "socket": { "alias": "socket"; "required": false; }; "chatSetting": { "alias": "chatSetting"; "required": false; }; "overlayStyle": { "alias": "overlayStyle"; "required": false; }; "contentStyle": { "alias": "contentStyle"; "required": false; }; "customTemplate": { "alias": "customTemplate"; "required": false; }; }, {}, never, never, true, never>;
|
|
158
221
|
}
|