From b1e6c52783162dcede37507fcbd370a206a9b0a4 Mon Sep 17 00:00:00 2001 From: Mike Wu Date: Thu, 16 Oct 2025 16:20:44 +0900 Subject: [PATCH 1/2] fix: offline lock device missing details --- .../DeviceDetails/LockDeviceDetails.tsx | 16 +++++++--------- src/styles/_device-details.scss | 7 ++++++- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/src/lib/seam/components/DeviceDetails/LockDeviceDetails.tsx b/src/lib/seam/components/DeviceDetails/LockDeviceDetails.tsx index cfc741a6c..0ae8a1d9e 100644 --- a/src/lib/seam/components/DeviceDetails/LockDeviceDetails.tsx +++ b/src/lib/seam/components/DeviceDetails/LockDeviceDetails.tsx @@ -62,11 +62,7 @@ export function LockDeviceDetails({ const lockStatus = device.properties.locked ? t.locked : t.unlocked const toggleLockLabel = device.properties.locked ? t.unlock : t.lock - const accessCodeCount = accessCodes?.length - - if (accessCodes == null) { - return null - } + const accessCodeCount = accessCodes?.length ?? 0 if (accessCodesOpen) { return ( @@ -152,13 +148,15 @@ export function LockDeviceDetails({
- {accessCodeCount} {t.accessCodes} + {accessCodes != null ? accessCodeCount : '–'} {t.accessCodes} - + {accessCodes != null && }
diff --git a/src/styles/_device-details.scss b/src/styles/_device-details.scss index 66b5fed87..3ee025805 100644 --- a/src/styles/_device-details.scss +++ b/src/styles/_device-details.scss @@ -25,7 +25,12 @@ display: flex; align-items: center; justify-content: space-between; - cursor: pointer; + cursor: pointer; + + &.disabled { + opacity: 0.6; + cursor: not-allowed; + } &:hover { background: colors.$item-hover-bg; From a65d661d505a0dc309f7bafcfd841b40746b7cdf Mon Sep 17 00:00:00 2001 From: Seam Bot Date: Thu, 16 Oct 2025 07:22:17 +0000 Subject: [PATCH 2/2] ci: Format code --- src/styles/_device-details.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/styles/_device-details.scss b/src/styles/_device-details.scss index 3ee025805..0d01d0149 100644 --- a/src/styles/_device-details.scss +++ b/src/styles/_device-details.scss @@ -25,7 +25,7 @@ display: flex; align-items: center; justify-content: space-between; - cursor: pointer; + cursor: pointer; &.disabled { opacity: 0.6;