mediasfu-angular 1.0.2 → 2.0.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.
- package/README.md +686 -578
- package/dist/README.md +677 -578
- package/dist/fesm2022/mediasfu-angular.mjs +5551 -2944
- package/dist/fesm2022/mediasfu-angular.mjs.map +1 -1
- package/dist/lib/@types/types.d.ts +22 -1
- package/dist/lib/components/breakout-components/breakout-rooms-modal.component.d.ts +1 -0
- package/dist/lib/components/mediasfu-components/mediasfu-broadcast.component.d.ts +153 -61
- package/dist/lib/components/mediasfu-components/mediasfu-chat.component.d.ts +154 -66
- package/dist/lib/components/mediasfu-components/mediasfu-conference.component.d.ts +190 -76
- package/dist/lib/components/mediasfu-components/mediasfu-generic.component.d.ts +184 -70
- package/dist/lib/components/mediasfu-components/mediasfu-webinar.component.d.ts +192 -78
- package/dist/lib/components/menu-components/menu-modal/menu-modal.component.d.ts +6 -1
- package/dist/lib/components/menu-components/share-buttons-component/share-buttons-component.component.d.ts +5 -2
- package/dist/lib/components/misc-components/confirm-here-modal/confirm-here-modal.component.d.ts +4 -2
- package/dist/lib/components/misc-components/pre-join-page/pre-join-page.component.d.ts +71 -66
- package/dist/lib/components/misc-components/share-event-modal/share-event-modal.component.d.ts +5 -1
- package/dist/lib/consumers/connect-local-ips.service.d.ts +81 -0
- package/dist/lib/consumers/connect-send-transport-audio.service.d.ts +43 -11
- package/dist/lib/consumers/connect-send-transport-screen.service.d.ts +87 -46
- package/dist/lib/consumers/connect-send-transport-video.service.d.ts +89 -43
- package/dist/lib/consumers/connect-send-transport.service.d.ts +5 -1
- package/dist/lib/consumers/create-send-transport.service.d.ts +130 -40
- package/dist/lib/consumers/disconnect-send-transport-audio.service.d.ts +77 -40
- package/dist/lib/consumers/disconnect-send-transport-screen.service.d.ts +48 -14
- package/dist/lib/consumers/disconnect-send-transport-video.service.d.ts +81 -44
- package/dist/lib/consumers/get-piped-producers-alt.service.d.ts +5 -1
- package/dist/lib/consumers/receive-all-piped-transports.service.d.ts +5 -1
- package/dist/lib/consumers/resume-send-transport-audio.service.d.ts +54 -21
- package/dist/lib/consumers/stream-success-audio-switch.service.d.ts +124 -40
- package/dist/lib/consumers/trigger.service.d.ts +3 -0
- package/dist/lib/methods/exit-methods/confirm-exit.service.d.ts +5 -1
- package/dist/lib/methods/recording-methods/start-recording.service.d.ts +3 -0
- package/dist/lib/methods/recording-methods/stop-recording.service.d.ts +4 -1
- package/dist/lib/methods/recording-methods/update-recording.service.d.ts +3 -0
- package/dist/lib/methods/stream-methods/click-audio.service.d.ts +3 -0
- package/dist/lib/methods/utils/check-limits-and-make-request.service.d.ts +23 -0
- package/dist/lib/methods/utils/create-response-join-room.util.d.ts +33 -0
- package/dist/lib/methods/utils/create-room-on-media-sfu.service.d.ts +25 -0
- package/dist/lib/methods/utils/initial-values.util.d.ts +6 -0
- package/dist/lib/methods/utils/join-room-on-media-sfu.service.d.ts +52 -0
- package/dist/lib/methods/whiteboard-methods/capture-canvas-stream.service.d.ts +37 -20
- package/dist/lib/producers/producer-emits/join-local-room.service.d.ts +125 -0
- package/dist/lib/producers/socket-receive-methods/all-members-rest.service.d.ts +7 -2
- package/dist/lib/producers/socket-receive-methods/all-members.service.d.ts +7 -2
- package/dist/lib/producers/socket-receive-methods/disconnect-user-self.service.d.ts +5 -1
- package/dist/lib/sockets/socket-manager.service.d.ts +90 -0
- package/dist/public-api.d.ts +11 -1
- package/package.json +17 -20
- package/dist/esm2022/lib/@types/types.mjs +0 -2
- package/dist/esm2022/lib/components/background-components/background-modal/background-modal.component.mjs +0 -799
- package/dist/esm2022/lib/components/breakout-components/breakout-rooms-modal.component.mjs +0 -366
- package/dist/esm2022/lib/components/breakout-components/edit-room-modal/edit-room-modal.component.mjs +0 -143
- package/dist/esm2022/lib/components/breakout-components/room-list/room-list.component.mjs +0 -40
- package/dist/esm2022/lib/components/co-host-components/co-host-modal/co-host-modal.component.mjs +0 -245
- package/dist/esm2022/lib/components/display-components/alert-component/alert.component.component.mjs +0 -79
- package/dist/esm2022/lib/components/display-components/audio-card/audio-card.component.mjs +0 -356
- package/dist/esm2022/lib/components/display-components/audio-grid/audio-grid.component.mjs +0 -80
- package/dist/esm2022/lib/components/display-components/card-video-display/card-video-display.component.mjs +0 -129
- package/dist/esm2022/lib/components/display-components/control-buttons-alt-component/control-buttons-alt-component.component.mjs +0 -138
- package/dist/esm2022/lib/components/display-components/control-buttons-component/control-buttons-component.component.mjs +0 -231
- package/dist/esm2022/lib/components/display-components/control-buttons-component-touch/control-buttons-component-touch.component.mjs +0 -282
- package/dist/esm2022/lib/components/display-components/control-widgets/menu-participants-widget.component.mjs +0 -82
- package/dist/esm2022/lib/components/display-components/control-widgets/menu-record-widget.component.mjs +0 -65
- package/dist/esm2022/lib/components/display-components/control-widgets/menu-widget.component.mjs +0 -137
- package/dist/esm2022/lib/components/display-components/control-widgets/message-widget.component.mjs +0 -137
- package/dist/esm2022/lib/components/display-components/control-widgets/record-timer-widget.component.mjs +0 -51
- package/dist/esm2022/lib/components/display-components/control-widgets/screenshare-widget.component.mjs +0 -101
- package/dist/esm2022/lib/components/display-components/flexible-grid/flexible-grid.component.mjs +0 -151
- package/dist/esm2022/lib/components/display-components/flexible-video/flexible-video.component.mjs +0 -250
- package/dist/esm2022/lib/components/display-components/loading-modal/loading-modal.component.mjs +0 -102
- package/dist/esm2022/lib/components/display-components/main-aspect-component/main-aspect-component.component.mjs +0 -140
- package/dist/esm2022/lib/components/display-components/main-container-component/main-container-component.component.mjs +0 -131
- package/dist/esm2022/lib/components/display-components/main-grid-component/main-grid-component.component.mjs +0 -120
- package/dist/esm2022/lib/components/display-components/main-screen-component/main-screen-component.component.mjs +0 -201
- package/dist/esm2022/lib/components/display-components/meeting-progress-timer/meeting-progress-timer.component.mjs +0 -115
- package/dist/esm2022/lib/components/display-components/mini-audio/mini-audio.component.mjs +0 -319
- package/dist/esm2022/lib/components/display-components/mini-card/mini-card.component.mjs +0 -161
- package/dist/esm2022/lib/components/display-components/mini-card-audio/mini-card-audio.component.mjs +0 -230
- package/dist/esm2022/lib/components/display-components/other-grid-component/other-grid-component.component.mjs +0 -126
- package/dist/esm2022/lib/components/display-components/pagination/pagination.component.mjs +0 -334
- package/dist/esm2022/lib/components/display-components/sub-aspect-component/sub-aspect-component.component.mjs +0 -112
- package/dist/esm2022/lib/components/display-components/video-card/video-card.component.mjs +0 -392
- package/dist/esm2022/lib/components/display-settings-components/display-settings-modal.component.mjs +0 -106
- package/dist/esm2022/lib/components/event-settings-components/event-settings-modal/event-settings-modal.component.mjs +0 -199
- package/dist/esm2022/lib/components/exit-components/confirm-exit-modal/confirm-exit-modal.component.mjs +0 -132
- package/dist/esm2022/lib/components/media-settings-components/media-settings-modal/media-settings-modal.component.mjs +0 -220
- package/dist/esm2022/lib/components/mediasfu-components/mediasfu-broadcast.component.mjs +0 -4238
- package/dist/esm2022/lib/components/mediasfu-components/mediasfu-chat.component.mjs +0 -3754
- package/dist/esm2022/lib/components/mediasfu-components/mediasfu-conference.component.mjs +0 -5071
- package/dist/esm2022/lib/components/mediasfu-components/mediasfu-generic.component.mjs +0 -5380
- package/dist/esm2022/lib/components/mediasfu-components/mediasfu-webinar.component.mjs +0 -5068
- package/dist/esm2022/lib/components/menu-components/custom-buttons/custom-buttons.component.mjs +0 -83
- package/dist/esm2022/lib/components/menu-components/meeting-id-component/meeting-id-component.component.mjs +0 -27
- package/dist/esm2022/lib/components/menu-components/meeting-passcode-component/meeting-passcode-component.component.mjs +0 -27
- package/dist/esm2022/lib/components/menu-components/menu-modal/menu-modal.component.mjs +0 -125
- package/dist/esm2022/lib/components/menu-components/share-buttons-component/share-buttons-component.component.mjs +0 -106
- package/dist/esm2022/lib/components/message-components/message-panel/message-panel.component.mjs +0 -228
- package/dist/esm2022/lib/components/message-components/messages-modal/messages-modal.component.mjs +0 -277
- package/dist/esm2022/lib/components/misc-components/confirm-here-modal/confirm-here-modal.component.mjs +0 -130
- package/dist/esm2022/lib/components/misc-components/pre-join-page/pre-join-page.component.mjs +0 -343
- package/dist/esm2022/lib/components/misc-components/share-event-modal/share-event-modal.component.mjs +0 -127
- package/dist/esm2022/lib/components/misc-components/welcome-page/welcome-page.component.mjs +0 -241
- package/dist/esm2022/lib/components/participants-components/participant-list/participant-list.component.mjs +0 -82
- package/dist/esm2022/lib/components/participants-components/participant-list-item/participant-list-item.component.mjs +0 -139
- package/dist/esm2022/lib/components/participants-components/participant-list-others/participant-list-others.component.mjs +0 -40
- package/dist/esm2022/lib/components/participants-components/participant-list-others-item/participant-list-others-item.component.mjs +0 -60
- package/dist/esm2022/lib/components/participants-components/participants-modal/participants-modal.component.mjs +0 -124
- package/dist/esm2022/lib/components/polls-components/poll-modal/poll-modal.component.mjs +0 -201
- package/dist/esm2022/lib/components/recording-components/advanced-panel-component/advanced-panel-components.component.mjs +0 -92
- package/dist/esm2022/lib/components/recording-components/recording-modal/recording-modal.component.mjs +0 -133
- package/dist/esm2022/lib/components/recording-components/standard-panel-component/standard-panel-component.component.mjs +0 -90
- package/dist/esm2022/lib/components/requests-components/render-request-component/render-request-component.component.mjs +0 -81
- package/dist/esm2022/lib/components/requests-components/requests-modal/requests-modal.component.mjs +0 -147
- package/dist/esm2022/lib/components/screenboard-components/screenboard/screenboard.component.mjs +0 -627
- package/dist/esm2022/lib/components/screenboard-components/screenboard-modal/screenboard-modal.component.mjs +0 -391
- package/dist/esm2022/lib/components/waiting-components/waiting-room-modal.component.mjs +0 -201
- package/dist/esm2022/lib/components/whiteboard-components/configure-whiteboard-modal/configure-whiteboard-modal.component.mjs +0 -286
- package/dist/esm2022/lib/components/whiteboard-components/whiteboard/whiteboard.component.mjs +0 -1833
- package/dist/esm2022/lib/consumers/add-videos-grid.service.mjs +0 -345
- package/dist/esm2022/lib/consumers/auto-adjust.service.mjs +0 -109
- package/dist/esm2022/lib/consumers/calculate-rows-and-columns.service.mjs +0 -60
- package/dist/esm2022/lib/consumers/change-vids.service.mjs +0 -551
- package/dist/esm2022/lib/consumers/check-grid.service.mjs +0 -93
- package/dist/esm2022/lib/consumers/check-permission.service.mjs +0 -105
- package/dist/esm2022/lib/consumers/check-screen-share.service.mjs +0 -106
- package/dist/esm2022/lib/consumers/close-and-resize.service.mjs +0 -331
- package/dist/esm2022/lib/consumers/compare-active-names.service.mjs +0 -106
- package/dist/esm2022/lib/consumers/compare-screen-states.service.mjs +0 -98
- package/dist/esm2022/lib/consumers/connect-ips.service.mjs +0 -154
- package/dist/esm2022/lib/consumers/connect-recv-transport.service.mjs +0 -146
- package/dist/esm2022/lib/consumers/connect-send-transport-audio.service.mjs +0 -84
- package/dist/esm2022/lib/consumers/connect-send-transport-screen.service.mjs +0 -102
- package/dist/esm2022/lib/consumers/connect-send-transport-video.service.mjs +0 -99
- package/dist/esm2022/lib/consumers/connect-send-transport.service.mjs +0 -140
- package/dist/esm2022/lib/consumers/consumer-resume.service.mjs +0 -368
- package/dist/esm2022/lib/consumers/control-media.service.mjs +0 -113
- package/dist/esm2022/lib/consumers/create-send-transport.service.mjs +0 -172
- package/dist/esm2022/lib/consumers/disconnect-send-transport-audio.service.mjs +0 -108
- package/dist/esm2022/lib/consumers/disconnect-send-transport-screen.service.mjs +0 -84
- package/dist/esm2022/lib/consumers/disconnect-send-transport-video.service.mjs +0 -101
- package/dist/esm2022/lib/consumers/disp-streams.service.mjs +0 -513
- package/dist/esm2022/lib/consumers/generate-page-content.service.mjs +0 -106
- package/dist/esm2022/lib/consumers/get-estimate.service.mjs +0 -120
- package/dist/esm2022/lib/consumers/get-piped-producers-alt.service.mjs +0 -82
- package/dist/esm2022/lib/consumers/get-producers-piped.service.mjs +0 -79
- package/dist/esm2022/lib/consumers/get-videos.service.mjs +0 -91
- package/dist/esm2022/lib/consumers/mix-streams.service.mjs +0 -95
- package/dist/esm2022/lib/consumers/on-screen-changes.service.mjs +0 -103
- package/dist/esm2022/lib/consumers/prepopulate-user-media.service.mjs +0 -541
- package/dist/esm2022/lib/consumers/process-consumer-transports-audio.service.mjs +0 -101
- package/dist/esm2022/lib/consumers/process-consumer-transports.service.mjs +0 -128
- package/dist/esm2022/lib/consumers/re-port.service.mjs +0 -114
- package/dist/esm2022/lib/consumers/re-update-inter.service.mjs +0 -239
- package/dist/esm2022/lib/consumers/readjust.service.mjs +0 -173
- package/dist/esm2022/lib/consumers/receive-all-piped-transports.service.mjs +0 -87
- package/dist/esm2022/lib/consumers/receive-room-messages.service.mjs +0 -69
- package/dist/esm2022/lib/consumers/reorder-streams.service.mjs +0 -239
- package/dist/esm2022/lib/consumers/request-screen-share.service.mjs +0 -101
- package/dist/esm2022/lib/consumers/resume-pause-audio-streams.service.mjs +0 -150
- package/dist/esm2022/lib/consumers/resume-pause-streams.service.mjs +0 -103
- package/dist/esm2022/lib/consumers/resume-send-transport-audio.service.mjs +0 -91
- package/dist/esm2022/lib/consumers/signal-new-consumer-transport.service.mjs +0 -136
- package/dist/esm2022/lib/consumers/socket-receive-methods/join-consume-room.service.mjs +0 -96
- package/dist/esm2022/lib/consumers/socket-receive-methods/new-pipe-producer.service.mjs +0 -100
- package/dist/esm2022/lib/consumers/socket-receive-methods/producer-closed.service.mjs +0 -78
- package/dist/esm2022/lib/consumers/start-share-screen.service.mjs +0 -120
- package/dist/esm2022/lib/consumers/stop-share-screen.service.mjs +0 -175
- package/dist/esm2022/lib/consumers/stream-success-audio-switch.service.mjs +0 -185
- package/dist/esm2022/lib/consumers/stream-success-audio.service.mjs +0 -210
- package/dist/esm2022/lib/consumers/stream-success-screen.service.mjs +0 -193
- package/dist/esm2022/lib/consumers/stream-success-video.service.mjs +0 -260
- package/dist/esm2022/lib/consumers/switch-user-audio.service.mjs +0 -120
- package/dist/esm2022/lib/consumers/switch-user-video-alt.service.mjs +0 -260
- package/dist/esm2022/lib/consumers/switch-user-video.service.mjs +0 -172
- package/dist/esm2022/lib/consumers/trigger.service.mjs +0 -210
- package/dist/esm2022/lib/consumers/update-mini-cards-grid.service.mjs +0 -135
- package/dist/esm2022/lib/consumers/update-participant-audio-decibels.service.mjs +0 -84
- package/dist/esm2022/lib/methods/background-methods/launch-background.service.mjs +0 -48
- package/dist/esm2022/lib/methods/breakout-room-methods/breakout-room-updated.service.mjs +0 -183
- package/dist/esm2022/lib/methods/breakout-room-methods/launch-breakout-rooms.service.mjs +0 -46
- package/dist/esm2022/lib/methods/co-host-methods/launch-co-host.service.mjs +0 -46
- package/dist/esm2022/lib/methods/co-host-methods/modify-co-host-settings.service.mjs +0 -104
- package/dist/esm2022/lib/methods/display-settings-methods/launch-display-settings.service.mjs +0 -46
- package/dist/esm2022/lib/methods/display-settings-methods/modify-display-settings.service.mjs +0 -194
- package/dist/esm2022/lib/methods/exit-methods/confirm-exit.service.mjs +0 -52
- package/dist/esm2022/lib/methods/exit-methods/launch-confirm-exit.service.mjs +0 -42
- package/dist/esm2022/lib/methods/media-settings-methods/launch-media-settings.service.mjs +0 -85
- package/dist/esm2022/lib/methods/menu-methods/launch-menu-modal.service.mjs +0 -44
- package/dist/esm2022/lib/methods/message-methods/launch-messages.service.mjs +0 -45
- package/dist/esm2022/lib/methods/message-methods/send-message.service.mjs +0 -143
- package/dist/esm2022/lib/methods/participants-methods/launch-participants.service.mjs +0 -47
- package/dist/esm2022/lib/methods/participants-methods/message-participants.service.mjs +0 -98
- package/dist/esm2022/lib/methods/participants-methods/mute-participants.service.mjs +0 -96
- package/dist/esm2022/lib/methods/participants-methods/remove-participants.service.mjs +0 -107
- package/dist/esm2022/lib/methods/polls-methods/handle-create-poll.service.mjs +0 -75
- package/dist/esm2022/lib/methods/polls-methods/handle-end-poll.service.mjs +0 -72
- package/dist/esm2022/lib/methods/polls-methods/handle-vote-poll.service.mjs +0 -83
- package/dist/esm2022/lib/methods/polls-methods/launch-poll.service.mjs +0 -43
- package/dist/esm2022/lib/methods/polls-methods/poll-updated.service.mjs +0 -95
- package/dist/esm2022/lib/methods/recording-methods/check-pause-state.service.mjs +0 -69
- package/dist/esm2022/lib/methods/recording-methods/check-resume-state.service.mjs +0 -56
- package/dist/esm2022/lib/methods/recording-methods/confirm-recording.service.mjs +0 -278
- package/dist/esm2022/lib/methods/recording-methods/launch-recording.service.mjs +0 -125
- package/dist/esm2022/lib/methods/recording-methods/record-pause-timer.service.mjs +0 -67
- package/dist/esm2022/lib/methods/recording-methods/record-resume-timer.service.mjs +0 -130
- package/dist/esm2022/lib/methods/recording-methods/record-start-timer.service.mjs +0 -134
- package/dist/esm2022/lib/methods/recording-methods/record-update-timer.service.mjs +0 -80
- package/dist/esm2022/lib/methods/recording-methods/start-recording.service.mjs +0 -197
- package/dist/esm2022/lib/methods/recording-methods/stop-recording.service.mjs +0 -112
- package/dist/esm2022/lib/methods/recording-methods/update-recording.service.mjs +0 -272
- package/dist/esm2022/lib/methods/requests-methods/launch-requests.service.mjs +0 -51
- package/dist/esm2022/lib/methods/requests-methods/respond-to-requests.service.mjs +0 -84
- package/dist/esm2022/lib/methods/settings-methods/launch-settings.service.mjs +0 -51
- package/dist/esm2022/lib/methods/settings-methods/modify-settings.service.mjs +0 -109
- package/dist/esm2022/lib/methods/stream-methods/click-audio.service.mjs +0 -275
- package/dist/esm2022/lib/methods/stream-methods/click-chat.service.mjs +0 -75
- package/dist/esm2022/lib/methods/stream-methods/click-screen-share.service.mjs +0 -178
- package/dist/esm2022/lib/methods/stream-methods/click-video.service.mjs +0 -271
- package/dist/esm2022/lib/methods/stream-methods/switch-audio.service.mjs +0 -80
- package/dist/esm2022/lib/methods/stream-methods/switch-video-alt.service.mjs +0 -116
- package/dist/esm2022/lib/methods/stream-methods/switch-video.service.mjs +0 -132
- package/dist/esm2022/lib/methods/utils/format-number.service.mjs +0 -57
- package/dist/esm2022/lib/methods/utils/generate-random-messages.service.mjs +0 -120
- package/dist/esm2022/lib/methods/utils/generate-random-participants.service.mjs +0 -126
- package/dist/esm2022/lib/methods/utils/generate-random-polls.service.mjs +0 -78
- package/dist/esm2022/lib/methods/utils/generate-random-request-list.service.mjs +0 -90
- package/dist/esm2022/lib/methods/utils/generate-random-waiting-room-list.service.mjs +0 -59
- package/dist/esm2022/lib/methods/utils/get-modal-position.util.mjs +0 -32
- package/dist/esm2022/lib/methods/utils/get-overlay-position.util.mjs +0 -31
- package/dist/esm2022/lib/methods/utils/initial-values.util.mjs +0 -379
- package/dist/esm2022/lib/methods/utils/meeting-timer/start-meeting-progress-timer.service.mjs +0 -96
- package/dist/esm2022/lib/methods/utils/mini-audio-player/mini-audio-player.component.mjs +0 -315
- package/dist/esm2022/lib/methods/utils/producer/a-params.service.mjs +0 -58
- package/dist/esm2022/lib/methods/utils/producer/h-params.service.mjs +0 -87
- package/dist/esm2022/lib/methods/utils/producer/screen-params.service.mjs +0 -61
- package/dist/esm2022/lib/methods/utils/producer/v-params.service.mjs +0 -87
- package/dist/esm2022/lib/methods/utils/producer/video-capture-constraints.service.mjs +0 -84
- package/dist/esm2022/lib/methods/utils/sleep.util.mjs +0 -17
- package/dist/esm2022/lib/methods/utils/sound-player.service.mjs +0 -63
- package/dist/esm2022/lib/methods/utils/validate-alphanumeric.service.mjs +0 -49
- package/dist/esm2022/lib/methods/waiting-methods/launch-waiting.service.mjs +0 -41
- package/dist/esm2022/lib/methods/waiting-methods/respond-to-waiting.service.mjs +0 -69
- package/dist/esm2022/lib/methods/whiteboard-methods/capture-canvas-stream.service.mjs +0 -98
- package/dist/esm2022/lib/methods/whiteboard-methods/launch-configure-whiteboard.service.mjs +0 -44
- package/dist/esm2022/lib/producer-client/producer-client-emits/create-device-client.service.mjs +0 -74
- package/dist/esm2022/lib/producer-client/producer-client-emits/join-room-client.service.mjs +0 -96
- package/dist/esm2022/lib/producer-client/producer-client-emits/update-room-parameters-client.service.mjs +0 -276
- package/dist/esm2022/lib/producers/producer-emits/join-con-room.service.mjs +0 -152
- package/dist/esm2022/lib/producers/producer-emits/join-room.service.mjs +0 -152
- package/dist/esm2022/lib/producers/socket-receive-methods/all-members-rest.service.mjs +0 -228
- package/dist/esm2022/lib/producers/socket-receive-methods/all-members.service.mjs +0 -218
- package/dist/esm2022/lib/producers/socket-receive-methods/all-waiting-room-members.service.mjs +0 -57
- package/dist/esm2022/lib/producers/socket-receive-methods/ban-participant.service.mjs +0 -76
- package/dist/esm2022/lib/producers/socket-receive-methods/control-media-host.service.mjs +0 -183
- package/dist/esm2022/lib/producers/socket-receive-methods/disconnect-user-self.service.mjs +0 -50
- package/dist/esm2022/lib/producers/socket-receive-methods/disconnect.service.mjs +0 -64
- package/dist/esm2022/lib/producers/socket-receive-methods/get-domains.service.mjs +0 -78
- package/dist/esm2022/lib/producers/socket-receive-methods/host-request-response.service.mjs +0 -150
- package/dist/esm2022/lib/producers/socket-receive-methods/meeting-ended.service.mjs +0 -73
- package/dist/esm2022/lib/producers/socket-receive-methods/meeting-still-there.service.mjs +0 -47
- package/dist/esm2022/lib/producers/socket-receive-methods/meeting-time-remaining.service.mjs +0 -63
- package/dist/esm2022/lib/producers/socket-receive-methods/participant-requested.service.mjs +0 -63
- package/dist/esm2022/lib/producers/socket-receive-methods/person-joined.service.mjs +0 -54
- package/dist/esm2022/lib/producers/socket-receive-methods/producer-media-closed.service.mjs +0 -129
- package/dist/esm2022/lib/producers/socket-receive-methods/producer-media-paused.service.mjs +0 -152
- package/dist/esm2022/lib/producers/socket-receive-methods/producer-media-resumed.service.mjs +0 -99
- package/dist/esm2022/lib/producers/socket-receive-methods/re-initiate-recording.service.mjs +0 -67
- package/dist/esm2022/lib/producers/socket-receive-methods/receive-message.service.mjs +0 -134
- package/dist/esm2022/lib/producers/socket-receive-methods/recording-notice.service.mjs +0 -233
- package/dist/esm2022/lib/producers/socket-receive-methods/room-record-params.service.mjs +0 -121
- package/dist/esm2022/lib/producers/socket-receive-methods/screen-producer-id.service.mjs +0 -86
- package/dist/esm2022/lib/producers/socket-receive-methods/start-records.service.mjs +0 -60
- package/dist/esm2022/lib/producers/socket-receive-methods/stopped-recording.service.mjs +0 -62
- package/dist/esm2022/lib/producers/socket-receive-methods/time-left-recording.service.mjs +0 -57
- package/dist/esm2022/lib/producers/socket-receive-methods/update-consuming-domains.service.mjs +0 -105
- package/dist/esm2022/lib/producers/socket-receive-methods/update-media-settings.service.mjs +0 -66
- package/dist/esm2022/lib/producers/socket-receive-methods/updated-co-host.service.mjs +0 -96
- package/dist/esm2022/lib/producers/socket-receive-methods/user-waiting.service.mjs +0 -52
- package/dist/esm2022/lib/sockets/socket-manager.service.mjs +0 -113
- package/dist/esm2022/mediasfu-angular.mjs +0 -5
- package/dist/esm2022/public-api.mjs +0 -187
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { Injectable } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
/**
|
|
4
|
-
* Mixes video and audio streams and participants based on specified parameters.
|
|
5
|
-
*
|
|
6
|
-
* @param {MixStreamsOptions} options - The options for mixing streams.
|
|
7
|
-
* @param {Array<Stream | Participant>} options.alVideoStreams - The list of audio and video streams to mix.
|
|
8
|
-
* @param {Array<Participant>} options.non_alVideoStreams - The list of non-audio and video streams to mix.
|
|
9
|
-
* @param {Array<Stream | Participant>} options.ref_participants - The list of reference participants to mix.
|
|
10
|
-
* @returns {Promise<Array<Stream | Participant>>} A promise that resolves with the mixed streams.
|
|
11
|
-
*
|
|
12
|
-
* @throws Will throw an error if there is an issue mixing the streams.
|
|
13
|
-
*
|
|
14
|
-
* @example
|
|
15
|
-
* ```typescript
|
|
16
|
-
* const mixedStreams = await mixStreams({
|
|
17
|
-
* alVideoStreams: [stream1, stream2],
|
|
18
|
-
* non_alVideoStreams: [participant1, participant2],
|
|
19
|
-
* ref_participants: [participant1, participant2],
|
|
20
|
-
* });
|
|
21
|
-
*
|
|
22
|
-
* console.log('Mixed streams:', mixedStreams);
|
|
23
|
-
* ```
|
|
24
|
-
*/
|
|
25
|
-
export class MixStreams {
|
|
26
|
-
/**
|
|
27
|
-
* Mixes video and audio streams and participants based on specified parameters.
|
|
28
|
-
*
|
|
29
|
-
* @param {Object} options - The options for mixing streams.
|
|
30
|
-
* @param {Array} options.alVideoStreams - The list of audio and video streams to mix.
|
|
31
|
-
* @param {Array} options.non_alVideoStreams - The list of non-audio and video streams to mix.
|
|
32
|
-
* @param {Array} options.ref_participants - The list of reference participants to mix.
|
|
33
|
-
* @returns {Promise<Array>} A promise that resolves with the mixed streams.
|
|
34
|
-
* @throws Will throw an error if there is an issue mixing the streams.
|
|
35
|
-
* @example
|
|
36
|
-
* ```typescript
|
|
37
|
-
* mixStreams({
|
|
38
|
-
* alVideoStreams: [stream1, stream2],
|
|
39
|
-
* non_alVideoStreams: [participant1, participant2],
|
|
40
|
-
* ref_participants: [participant1, participant2]
|
|
41
|
-
* });
|
|
42
|
-
*
|
|
43
|
-
* ```
|
|
44
|
-
*/
|
|
45
|
-
async mixStreams({ alVideoStreams, non_alVideoStreams, ref_participants, }) {
|
|
46
|
-
try {
|
|
47
|
-
const mixedStreams = [];
|
|
48
|
-
const youyouStream = alVideoStreams.find((obj) => obj.producerId === 'youyou' || obj.producerId === 'youyouyou');
|
|
49
|
-
alVideoStreams = alVideoStreams.filter((obj) => obj.producerId !== 'youyou' && obj.producerId !== 'youyouyou');
|
|
50
|
-
const unmutedAlVideoStreams = alVideoStreams.filter((obj) => {
|
|
51
|
-
const participant = ref_participants.find((p) => p.videoID === obj.producerId);
|
|
52
|
-
return !obj.muted && participant && participant.muted === false;
|
|
53
|
-
});
|
|
54
|
-
const mutedAlVideoStreams = alVideoStreams.filter((obj) => {
|
|
55
|
-
const participant = ref_participants.find((p) => p.videoID === obj.producerId);
|
|
56
|
-
return obj.muted || (participant && participant.muted === true);
|
|
57
|
-
});
|
|
58
|
-
const nonAlVideoStreams = non_alVideoStreams.slice(); // Create a copy of non_alVideoStreams
|
|
59
|
-
// Add unmutedAlVideoStreams to mixedStreams
|
|
60
|
-
mixedStreams.push(...unmutedAlVideoStreams);
|
|
61
|
-
// Interleave the mutedAlVideoStreams and nonAlVideoStreams
|
|
62
|
-
let nonAlIndex = 0;
|
|
63
|
-
for (let i = 0; i < mutedAlVideoStreams.length; i++) {
|
|
64
|
-
if (nonAlIndex < nonAlVideoStreams.length) {
|
|
65
|
-
mixedStreams.push(nonAlVideoStreams[nonAlIndex]);
|
|
66
|
-
nonAlIndex++;
|
|
67
|
-
}
|
|
68
|
-
mixedStreams.push(mutedAlVideoStreams[i]);
|
|
69
|
-
}
|
|
70
|
-
// Handle remaining nonAlVideoStreams (if any)
|
|
71
|
-
for (let i = nonAlIndex; i < nonAlVideoStreams.length; i++) {
|
|
72
|
-
mixedStreams.push(nonAlVideoStreams[i]);
|
|
73
|
-
}
|
|
74
|
-
// Unshift 'youyou' or 'youyouyou' stream to mixedStreams
|
|
75
|
-
if (youyouStream) {
|
|
76
|
-
mixedStreams.unshift(youyouStream);
|
|
77
|
-
}
|
|
78
|
-
return mixedStreams;
|
|
79
|
-
}
|
|
80
|
-
catch (error) {
|
|
81
|
-
// Handle errors during the process of mixing streams
|
|
82
|
-
console.log('Error mixing streams:', error.message);
|
|
83
|
-
throw error;
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MixStreams, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
87
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MixStreams, providedIn: 'root' });
|
|
88
|
-
}
|
|
89
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: MixStreams, decorators: [{
|
|
90
|
-
type: Injectable,
|
|
91
|
-
args: [{
|
|
92
|
-
providedIn: 'root',
|
|
93
|
-
}]
|
|
94
|
-
}] });
|
|
95
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWl4LXN0cmVhbXMuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL21lZGlhc2Z1L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AgIC8vIEhhbmRsZSBlcnJvcnMgZHVyaW5nIHRoZSBwcm9jZXNzIG9mIG1peGluZyBzdHJlYW1zXG4gICAgICBjb25zb2xlLmxvZygnRXJyb3IgbWl4aW5nIHN0cmVhbXM6JywgZXJyb3IubWVzc2FnZSk7XG4gICAgICB0aHJvdyBlcnJvcjtcbiAgICB9XG4gIH1cbn1cbiJdfQ==
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
import { Injectable } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
/**
|
|
4
|
-
* Handles changes in screen events such as broadcast, chat, and conference.
|
|
5
|
-
*
|
|
6
|
-
* @param {OnScreenChangesOptions} options - The options for handling screen changes.
|
|
7
|
-
* @param {boolean} [options.changed=false] - Indicates if the screen has changed.
|
|
8
|
-
* @param {OnScreenChangesParameters} options.parameters - The parameters for handling screen changes.
|
|
9
|
-
* @param {string} options.parameters.eventType - The type of event (e.g., "broadcast", "chat", "conference").
|
|
10
|
-
* @param {boolean} options.parameters.shareScreenStarted - Indicates if screen sharing has started.
|
|
11
|
-
* @param {boolean} options.parameters.shared - Indicates if the screen is shared.
|
|
12
|
-
* @param {boolean} options.parameters.addForBasic - Flag to add basic controls.
|
|
13
|
-
* @param {Function} options.parameters.updateMainHeightWidth - Function to update the main height and width.
|
|
14
|
-
* @param {Function} options.parameters.updateAddForBasic - Function to update the addForBasic flag.
|
|
15
|
-
* @param {number} options.parameters.itemPageLimit - The limit for item pages.
|
|
16
|
-
* @param {Function} options.parameters.updateItemPageLimit - Function to update the item page limit.
|
|
17
|
-
* @param {Function} options.parameters.reorderStreams - Function to reorder streams.
|
|
18
|
-
*
|
|
19
|
-
* @returns {Promise<void>} A promise that resolves when the screen changes have been handled.
|
|
20
|
-
*
|
|
21
|
-
* @throws {Error} Throws an error if there is an issue handling screen changes.
|
|
22
|
-
*
|
|
23
|
-
* @example
|
|
24
|
-
* ```typescript
|
|
25
|
-
* const options = {
|
|
26
|
-
* changed: true,
|
|
27
|
-
* parameters: {
|
|
28
|
-
* eventType: 'broadcast',
|
|
29
|
-
* shareScreenStarted: false,
|
|
30
|
-
* shared: false,
|
|
31
|
-
* addForBasic: false,
|
|
32
|
-
* updateMainHeightWidth: (value) => { console.log(updated) },
|
|
33
|
-
* updateAddForBasic: (value) => { console.log(updated) },
|
|
34
|
-
* itemPageLimit: 1,
|
|
35
|
-
* updateItemPageLimit: (value) => { console.log(updated) },
|
|
36
|
-
* reorderStreams: async (params) => { },
|
|
37
|
-
* },
|
|
38
|
-
* };
|
|
39
|
-
*
|
|
40
|
-
* await onScreenChanges(options);
|
|
41
|
-
* ```
|
|
42
|
-
*/
|
|
43
|
-
export class OnScreenChanges {
|
|
44
|
-
/**
|
|
45
|
-
* Handles changes in screen events such as broadcast, chat, and conference.
|
|
46
|
-
*
|
|
47
|
-
* @param {OnScreenChangesOptions} options - The options for handling screen changes.
|
|
48
|
-
* @param {boolean} options.changed - Indicates if the screen has changed.
|
|
49
|
-
* @param {object} options.parameters - The parameters for handling screen changes.
|
|
50
|
-
* @param {string} options.parameters.eventType - The type of event (e.g., "broadcast", "chat", "conference").
|
|
51
|
-
* @param {boolean} options.parameters.shareScreenStarted - Indicates if screen sharing has started.
|
|
52
|
-
* @param {boolean} options.parameters.shared - Indicates if the screen is shared.
|
|
53
|
-
* @param {boolean} options.parameters.addForBasic - Flag to add basic controls.
|
|
54
|
-
* @param {function} options.parameters.updateMainHeightWidth - Function to update the main height and width.
|
|
55
|
-
* @param {function} options.parameters.updateAddForBasic - Function to update the addForBasic flag.
|
|
56
|
-
* @param {number} options.parameters.itemPageLimit - The limit for item pages.
|
|
57
|
-
* @param {function} options.parameters.updateItemPageLimit - Function to update the item page limit.
|
|
58
|
-
* @param {function} options.parameters.reorderStreams - Function to reorder streams.
|
|
59
|
-
*
|
|
60
|
-
* @returns {Promise<void>} A promise that resolves when the screen changes have been handled.
|
|
61
|
-
*
|
|
62
|
-
* @throws {Error} Throws an error if there is an issue handling screen changes.
|
|
63
|
-
*/
|
|
64
|
-
onScreenChanges = async ({ changed = false, parameters, }) => {
|
|
65
|
-
try {
|
|
66
|
-
// Destructure parameters
|
|
67
|
-
let { eventType, shareScreenStarted, shared, addForBasic, updateMainHeightWidth, updateAddForBasic, itemPageLimit, updateItemPageLimit,
|
|
68
|
-
// mediasfu functions
|
|
69
|
-
reorderStreams, } = parameters;
|
|
70
|
-
// Remove element with id 'controlButtons'
|
|
71
|
-
addForBasic = false;
|
|
72
|
-
updateAddForBasic(addForBasic);
|
|
73
|
-
if (eventType == 'broadcast' || eventType == 'chat') {
|
|
74
|
-
addForBasic = true;
|
|
75
|
-
updateAddForBasic(addForBasic);
|
|
76
|
-
itemPageLimit = eventType == 'broadcast' ? 1 : 2;
|
|
77
|
-
updateItemPageLimit(itemPageLimit);
|
|
78
|
-
updateMainHeightWidth(eventType == 'broadcast' ? 100 : 0);
|
|
79
|
-
}
|
|
80
|
-
else {
|
|
81
|
-
if (eventType == 'conference' && !(shareScreenStarted || shared)) {
|
|
82
|
-
updateMainHeightWidth(0);
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
// Update the mini cards grid
|
|
86
|
-
await reorderStreams({ add: false, screenChanged: changed, parameters });
|
|
87
|
-
}
|
|
88
|
-
catch (error) {
|
|
89
|
-
// Handle errors during the process of handling screen changes
|
|
90
|
-
console.log('Error handling screen changes:', error.message);
|
|
91
|
-
// throw error;
|
|
92
|
-
}
|
|
93
|
-
};
|
|
94
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: OnScreenChanges, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
95
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: OnScreenChanges, providedIn: 'root' });
|
|
96
|
-
}
|
|
97
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: OnSc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