2022-10-24 17:08:32 +02:00
|
|
|
import { OverlayContainer } from '@angular/cdk/overlay';
|
2022-01-19 17:24:11 +01:00
|
|
|
import { CommonModule } from '@angular/common';
|
2022-11-23 13:46:54 +01:00
|
|
|
import { HttpClientModule } from '@angular/common/http';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { ModuleWithProviders, NgModule } from '@angular/core';
|
|
|
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
|
|
import { RouterModule } from '@angular/router';
|
2022-01-19 17:24:11 +01:00
|
|
|
|
2022-10-24 17:08:32 +02:00
|
|
|
import { DeleteDialogComponent } from './components/dialogs/delete-recording.component';
|
|
|
|
import { DialogTemplateComponent } from './components/dialogs/dialog.component';
|
|
|
|
import { RecordingDialogComponent } from './components/dialogs/recording-dialog.component';
|
|
|
|
import { LayoutComponent } from './components/layout/layout.component';
|
2022-02-02 13:44:49 +01:00
|
|
|
import { ChatPanelComponent } from './components/panel/chat-panel/chat-panel.component';
|
2022-01-26 11:30:30 +01:00
|
|
|
import { SessionComponent } from './components/session/session.component';
|
|
|
|
import { StreamComponent } from './components/stream/stream.component';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { ToolbarComponent } from './components/toolbar/toolbar.component';
|
|
|
|
import { VideoComponent } from './components/video/video.component';
|
2022-01-19 17:24:11 +01:00
|
|
|
|
|
|
|
import { LinkifyPipe } from './pipes/linkify.pipe';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { ParticipantStreamsPipe, StreamTypesEnabledPipe } from './pipes/participant.pipe';
|
2022-08-03 18:38:37 +02:00
|
|
|
import { DurationFromSecondsPipe, SearchByStringPropertyPipe, ThumbnailFromUrlPipe } from './pipes/recording.pipe';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { TranslatePipe } from './pipes/translate.pipe';
|
2022-01-19 17:24:11 +01:00
|
|
|
|
|
|
|
import { CdkOverlayContainer } from './config/custom-cdk-overlay';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { OpenViduAngularConfig } from './config/openvidu-angular.config';
|
2022-01-19 17:24:11 +01:00
|
|
|
import { ActionService } from './services/action/action.service';
|
|
|
|
import { ChatService } from './services/chat/chat.service';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { OpenViduAngularConfigService } from './services/config/openvidu-angular.config.service';
|
|
|
|
import { DeviceService } from './services/device/device.service';
|
2022-01-19 17:24:11 +01:00
|
|
|
import { DocumentService } from './services/document/document.service';
|
|
|
|
import { LayoutService } from './services/layout/layout.service';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { LoggerService } from './services/logger/logger.service';
|
|
|
|
import { OpenViduService } from './services/openvidu/openvidu.service';
|
2022-04-05 15:40:43 +02:00
|
|
|
import { PanelService } from './services/panel/panel.service';
|
2022-01-19 17:24:11 +01:00
|
|
|
import { ParticipantService } from './services/participant/participant.service';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { PlatformService } from './services/platform/platform.service';
|
2022-06-02 10:57:47 +02:00
|
|
|
import { RecordingService } from './services/recording/recording.service';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { StorageService } from './services/storage/storage.service';
|
2022-06-02 10:57:47 +02:00
|
|
|
|
2022-10-24 17:08:32 +02:00
|
|
|
import { AudioWaveComponent } from './components/audio-wave/audio-wave.component';
|
|
|
|
import { PanelComponent } from './components/panel/panel.component';
|
2022-02-15 16:30:06 +01:00
|
|
|
import { ParticipantPanelItemComponent } from './components/panel/participants-panel/participant-panel-item/participant-panel-item.component';
|
2022-02-02 13:44:49 +01:00
|
|
|
import { ParticipantsPanelComponent } from './components/panel/participants-panel/participants-panel/participants-panel.component';
|
2022-03-02 11:00:58 +01:00
|
|
|
import { PreJoinComponent } from './components/pre-join/pre-join.component';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { VideoconferenceComponent } from './components/videoconference/videoconference.component';
|
2022-01-19 17:24:11 +01:00
|
|
|
|
2022-10-24 17:08:32 +02:00
|
|
|
import { AdminDashboardComponent } from './admin/dashboard/dashboard.component';
|
|
|
|
import { AdminLoginComponent } from './admin/login/login.component';
|
2022-03-02 11:00:58 +01:00
|
|
|
import { AvatarProfileComponent } from './components/avatar-profile/avatar-profile.component';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { CaptionsComponent } from './components/captions/captions.component';
|
2022-11-16 10:55:36 +01:00
|
|
|
import { ProFeatureDialogTemplateComponent } from './components/dialogs/pro-feature-dialog.component';
|
2022-04-25 16:17:32 +02:00
|
|
|
import { ActivitiesPanelComponent } from './components/panel/activities-panel/activities-panel.component';
|
2023-02-17 17:03:15 +01:00
|
|
|
import { BroadcastingActivityComponent } from './components/panel/activities-panel/broadcasting-activity/broadcasting-activity.component';
|
2022-12-14 13:25:21 +01:00
|
|
|
import { RecordingActivityComponent } from './components/panel/activities-panel/recording-activity/recording-activity.component';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { BackgroundEffectsPanelComponent } from './components/panel/background-effects-panel/background-effects-panel.component';
|
|
|
|
import { SettingsPanelComponent } from './components/panel/settings-panel/settings-panel.component';
|
2022-06-16 14:01:07 +02:00
|
|
|
import { AudioDevicesComponent } from './components/settings/audio-devices/audio-devices.component';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { CaptionsSettingComponent } from './components/settings/captions/captions.component';
|
2022-06-16 14:01:07 +02:00
|
|
|
import { LangSelectorComponent } from './components/settings/lang-selector/lang-selector.component';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { NicknameInputComponent } from './components/settings/nickname-input/nickname-input.component';
|
|
|
|
import { VideoDevicesComponent } from './components/settings/video-devices/video-devices.component';
|
2022-09-07 12:01:04 +02:00
|
|
|
import { CustomBreakPointsProvider, CustomLayoutExtensionDirective } from './config/custom-flexlayout-breakpoints';
|
2022-10-24 17:08:32 +02:00
|
|
|
import { ApiDirectiveModule } from './directives/api/api.directive.module';
|
|
|
|
import { OpenViduAngularDirectiveModule } from './directives/template/openvidu-angular.directive.module';
|
|
|
|
import { AppMaterialModule } from './openvidu-angular.material.module';
|
2022-02-17 17:26:30 +01:00
|
|
|
|
2022-07-11 12:06:38 +02:00
|
|
|
const publicComponents = [
|
|
|
|
AdminDashboardComponent,
|
|
|
|
AdminLoginComponent,
|
|
|
|
VideoconferenceComponent,
|
|
|
|
ToolbarComponent,
|
|
|
|
PanelComponent,
|
2022-07-15 15:20:13 +02:00
|
|
|
ActivitiesPanelComponent,
|
2022-12-23 16:17:04 +01:00
|
|
|
RecordingActivityComponent,
|
2023-02-17 17:03:15 +01:00
|
|
|
BroadcastingActivityComponent,
|
2022-07-11 12:06:38 +02:00
|
|
|
ParticipantsPanelComponent,
|
|
|
|
ParticipantPanelItemComponent,
|
|
|
|
ChatPanelComponent,
|
|
|
|
StreamComponent,
|
|
|
|
LayoutComponent
|
|
|
|
];
|
|
|
|
const privateComponents = [
|
|
|
|
PreJoinComponent,
|
|
|
|
SessionComponent,
|
|
|
|
BackgroundEffectsPanelComponent,
|
|
|
|
SettingsPanelComponent,
|
|
|
|
AudioWaveComponent,
|
|
|
|
CaptionsComponent,
|
|
|
|
DialogTemplateComponent,
|
2022-11-16 10:55:36 +01:00
|
|
|
ProFeatureDialogTemplateComponent,
|
2022-07-11 12:06:38 +02:00
|
|
|
RecordingDialogComponent,
|
|
|
|
DeleteDialogComponent,
|
|
|
|
AvatarProfileComponent,
|
|
|
|
VideoComponent,
|
|
|
|
VideoDevicesComponent,
|
|
|
|
AudioDevicesComponent,
|
|
|
|
NicknameInputComponent,
|
|
|
|
LangSelectorComponent,
|
2022-10-24 17:08:32 +02:00
|
|
|
CaptionsSettingComponent
|
2022-07-11 12:06:38 +02:00
|
|
|
];
|
|
|
|
|
2022-01-19 17:24:11 +01:00
|
|
|
@NgModule({
|
2022-11-02 16:03:07 +01:00
|
|
|
declarations: [
|
|
|
|
publicComponents,
|
|
|
|
privateComponents,
|
|
|
|
LinkifyPipe,
|
|
|
|
ParticipantStreamsPipe,
|
|
|
|
DurationFromSecondsPipe,
|
|
|
|
SearchByStringPropertyPipe,
|
|
|
|
ThumbnailFromUrlPipe,
|
|
|
|
StreamTypesEnabledPipe,
|
|
|
|
TranslatePipe,
|
|
|
|
CustomLayoutExtensionDirective,
|
|
|
|
],
|
|
|
|
imports: [
|
|
|
|
CommonModule,
|
2022-11-23 13:46:54 +01:00
|
|
|
HttpClientModule,
|
2022-11-02 16:03:07 +01:00
|
|
|
FormsModule,
|
|
|
|
ReactiveFormsModule,
|
|
|
|
RouterModule.forRoot([]),
|
|
|
|
AppMaterialModule,
|
|
|
|
OpenViduAngularDirectiveModule,
|
|
|
|
ApiDirectiveModule
|
|
|
|
],
|
|
|
|
providers: [
|
|
|
|
ActionService,
|
|
|
|
CdkOverlayContainer,
|
|
|
|
{ provide: OverlayContainer, useClass: CdkOverlayContainer },
|
|
|
|
CustomBreakPointsProvider,
|
|
|
|
ChatService,
|
|
|
|
PanelService,
|
|
|
|
DeviceService,
|
|
|
|
DocumentService,
|
|
|
|
LayoutService,
|
|
|
|
LoggerService,
|
|
|
|
PlatformService,
|
|
|
|
ParticipantService,
|
|
|
|
StorageService,
|
|
|
|
OpenViduService,
|
|
|
|
RecordingService
|
|
|
|
],
|
|
|
|
exports: [
|
|
|
|
publicComponents,
|
|
|
|
ParticipantStreamsPipe,
|
|
|
|
DurationFromSecondsPipe,
|
|
|
|
StreamTypesEnabledPipe,
|
2023-06-26 13:17:47 +02:00
|
|
|
TranslatePipe,
|
2022-11-02 16:03:07 +01:00
|
|
|
CommonModule,
|
|
|
|
OpenViduAngularDirectiveModule,
|
|
|
|
ApiDirectiveModule
|
|
|
|
]
|
2022-01-19 17:24:11 +01:00
|
|
|
})
|
2022-02-15 16:24:01 +01:00
|
|
|
export class OpenViduAngularModule {
|
|
|
|
static forRoot(config): ModuleWithProviders<OpenViduAngularModule> {
|
2022-01-20 11:53:56 +01:00
|
|
|
// console.log(`${library.name} config: ${environment}`);
|
2022-02-15 16:24:01 +01:00
|
|
|
const libConfig: OpenViduAngularConfig = config;
|
2022-01-20 11:53:56 +01:00
|
|
|
return {
|
2022-02-15 16:24:01 +01:00
|
|
|
ngModule: OpenViduAngularModule,
|
|
|
|
providers: [OpenViduAngularConfigService, { provide: 'OPENVIDU_ANGULAR_CONFIG', useValue: libConfig }]
|
2022-01-20 11:53:56 +01:00
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|