yangzhang75 commented on code in PR #8318:
URL: https://github.com/apache/texera/pull/8318#discussion_r3920511384


##########
frontend/src/app/workspace/component/property-editor/operator-property-edit-frame/operator-property-edit-frame.component.ts:
##########
@@ -1341,13 +1353,28 @@ export class OperatorPropertyEditFrameComponent 
implements OnInit, OnChanges, On
         };
       }
 
+      // A tick box beside each TOP-LEVEL property only. The map callback runs 
for every
+      // field at every depth, so without this an array-of-objects property 
sprouted one on
+      // the array, each item and each nested field. Membership in the 
schema's own
+      // `properties` distinguishes a top-level field from a same-named nested 
one.
+      const isTopLevel = typeof mappedField.key === "string" && 
rootPropertyNames.has(mappedField.key);

Review Comment:
   Fixed. Moved the tick-box decoration off the per-depth formly map onto the 
root field group, so nested array/object fields can no longer receive a toggle 
(the map ran at every depth and could not tell a nested field from a same-named 
root one). Added a regression test with a nested object whose key collides with 
a root property, asserting only root fields are decorated.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to