A callback method that is invoked immediately after the default change detector has checked the directive's data-bound properties for the first time, and before any of the view or content children have been checked. It is invoked only once when the directive is instantiated.
A callback method that is invoked immediately after the default change detector has checked data-bound properties if at least one has changed, and before the view and content children are checked.
The changed properties.
OptionaloverlayOptionalcontentOptionalcustom
MediaSettingsModal - Modal for selecting audio/video devices and virtual backgrounds
Component
Description
Provides device selection controls for camera, microphone, and audio output. Includes camera switching (front/back), device dropdown selectors, and virtual background access.
Supports three levels of customization:
Key Features:
Example
Basic Usage:
Example
Style Customization:
Example
Custom Template Override:
Selector
app-media-settings-modal
Standalone
true
Imports
CommonModule, FontAwesomeModule, FormsModule
Input
isMediaSettingsModalVisible - Whether the modal is currently visible. Default:
falseInput
onMediaSettingsClose - Callback function to close the modal. Default:
() => {}Input
switchCameraOnPress - Function to switch front/back camera. Default:
switchVideoAltService.switchVideoAltInput
switchVideoOnPress - Function to switch video input device. Default:
switchVideoService.switchVideoInput
switchAudioOnPress - Function to switch audio input device. Default:
switchAudioService.switchAudioInput
parameters - Object containing videoInputs, audioInputs, default devices, and update functions. Default:
{}Input
position - Modal position on screen ('topRight', 'center', etc.). Default:
'topRight'Input
backgroundColor - Background color of the modal content. Default:
'#83c0e9'Input
overlayStyle - Custom CSS styles for the modal overlay backdrop. Default:
undefinedInput
contentStyle - Custom CSS styles for the modal content container. Default:
undefinedInput
customTemplate - Custom TemplateRef to completely replace default modal template. Default:
undefinedMethod
ngOnInit - Initializes component, sets up default services, and ensures default device selections
Method
ngOnChanges - Updates modal settings when visibility or parameters change
Method
setupDefaultServices - Configures default device switching services if not provided
Method
updateParameters - Refreshes parameters from getUpdatedAllParams
Method
ensureDefaultSelections - Sets default selected devices if none selected
Method
initializeModalSettings - Initializes selected device states
Method
handleSwitchCamera - Handles front/back camera toggle
Method
handleVideoSwitch - Handles video device selection change
Method
handleAudioSwitch - Handles audio device selection change
Method
handleModalClose - Closes modal via onMediaSettingsClose callback
Method
showVirtual - Opens virtual background modal
Method
getCombinedOverlayStyle - Merges default and custom overlay styles
Method
getCombinedContentStyle - Merges default and custom content styles
Method
modalContentStyle - Returns computed content styles with positioning