From a9ad71ff42656dccc4a69081904cddbdd5806d92 Mon Sep 17 00:00:00 2001 From: davfsa Date: Sat, 11 Jan 2025 09:07:03 +0100 Subject: [PATCH] Update bluetooth label when a new device connects/disconnects (#708) --- src/components/bar/modules/bluetooth/index.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/components/bar/modules/bluetooth/index.tsx b/src/components/bar/modules/bluetooth/index.tsx index 7f55d80..a0b13ec 100644 --- a/src/components/bar/modules/bluetooth/index.tsx +++ b/src/components/bar/modules/bluetooth/index.tsx @@ -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 (