From 6632c755d60cb1488925d775b139a790bab1f00d Mon Sep 17 00:00:00 2001 From: Katherine Date: Wed, 2 Apr 2025 11:32:33 +0800 Subject: [PATCH] fix: x-disabled property not taking effect on form fields (#6610) --- .../src/data-source/collection-field/CollectionField.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/core/client/src/data-source/collection-field/CollectionField.tsx b/packages/core/client/src/data-source/collection-field/CollectionField.tsx index 4bb5f6df4f..d9aa8ec998 100644 --- a/packages/core/client/src/data-source/collection-field/CollectionField.tsx +++ b/packages/core/client/src/data-source/collection-field/CollectionField.tsx @@ -108,6 +108,9 @@ const CollectionFieldInternalField = (props) => { if (fieldSchema['x-read-pretty'] === true && !field.readPretty) { field.readPretty = true; } + if (fieldSchema['x-disabled'] === true) { + field.disabled = true; + } }, [field, fieldSchema]); if (!uiSchema) return null;