Skip to content

Commit 38b9f96

Browse files
authored
Fix(UI): Boolean fields now correctly display true or false in the Details view (#7378)
1 parent d89aa07 commit 38b9f96

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

changelog/7372.fixed.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fixed an issue where boolean fields in the object Details view always displayed a checkmark, even when the value was false.

frontend/app/src/entities/nodes/getObjectItemDisplayValue.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,11 @@ export const ObjectAttributeValue = ({
202202
);
203203
case ATTRIBUTE_KIND.BOOLEAN:
204204
case ATTRIBUTE_KIND.CHECKBOX:
205-
return attributeValue ? <CheckIcon className="h-4 w-4" /> : <XMarkIcon className="h-4 w-4" />;
205+
return attributeValue.value ? (
206+
<CheckIcon className="size-4" />
207+
) : (
208+
<XMarkIcon className="size-4" />
209+
);
206210
case ATTRIBUTE_KIND.DATETIME:
207211
return <DateDisplay date={getTextValue(attributeValue)} />;
208212
case ATTRIBUTE_KIND.TEXTAREA:

0 commit comments

Comments
 (0)