Skip to content

Commit

Permalink
Update bluetooth label when a new device connects/disconnects (Jas-Si…
Browse files Browse the repository at this point in the history
  • Loading branch information
davfsa authored and FerranAD committed Jan 17, 2025
1 parent 441ecf2 commit 9d39092
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/components/bar/modules/bluetooth/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,13 @@ const Bluetooth = (): BarBoxChild => {
);

const componentBinding = Variable.derive(
[bind(options.bar.bluetooth.label), bind(bluetoothService, 'isPowered'), bind(bluetoothService, 'devices')],
[
bind(options.bar.bluetooth.label),
bind(bluetoothService, 'isPowered'),
bind(bluetoothService, 'devices'),

bind(bluetoothService, 'isConnected'),
],
(showLabel: boolean, isPowered: boolean, devices: AstalBluetooth.Device[]): JSX.Element => {
if (showLabel) {
return (
Expand Down

0 comments on commit 9d39092

Please sign in to comment.