ags: To derivation

This commit is contained in:
2025-01-25 19:38:13 +03:00
parent 290b694877
commit e46c205fe3
15 changed files with 24 additions and 5 deletions
@@ -0,0 +1,11 @@
import { bind } from "astal"
import Wp from "gi://AstalWp"
export default function Audio() {
const speaker = Wp.get_default()?.audio.defaultSpeaker!
return <box className="AudioSlider">
<icon icon={bind(speaker, "volumeIcon")} />
<label label={bind(speaker, "volume").as(v => `${Math.floor(v*100)}%`)} />
</box>
}