Added the ability to adjust application specific audio levels. (#608)

* Added a playback volume module in audio menu.

* Finish playback source volume adjuster.
This commit is contained in:
Jas Singh
2024-12-23 14:03:01 -08:00
committed by GitHub
parent a3240e6c6d
commit af88c267f4
18 changed files with 368 additions and 46 deletions

View File

@@ -0,0 +1,25 @@
import { BindableChild } from 'astal/gtk3/astalify';
import { audioService } from 'src/lib/constants/services';
import { SliderItem } from '../sliderItem/SliderItem';
import { ActiveDeviceMenu } from '..';
const ActiveDeviceContainer = ({ children }: ActiveDeviceContainerProps): JSX.Element => {
return (
<box className={'menu-items-section selected'} name={ActiveDeviceMenu.Devices} vertical>
{children}
</box>
);
};
export const ActiveDevices = (): JSX.Element => {
return (
<ActiveDeviceContainer>
<SliderItem type={'playback'} device={audioService.defaultSpeaker} />
<SliderItem type={'input'} device={audioService.defaultMicrophone} />
</ActiveDeviceContainer>
);
};
interface ActiveDeviceContainerProps {
children?: BindableChild | BindableChild[];
}