yangzhang75 opened a new pull request, #8438:
URL: https://github.com/apache/texera/pull/8438

   ### What changes were proposed in this PR?
   
   Closes #8022. Part of the Form View stack (parent issue #8011), stacked on 
#8437 (PR10) and #8436 (PR9).
   
   The render PR (#8437) shows the top-level exposed inputs. This one handles a 
property that carries sub-fields: an object (a nested group) or a repeated 
section (an array). It renders each sub-field and applies the author's 
per-sub-field setup.
   
   - A walk over the built formly field and its sub-fields drops the operator 
schema's own per-field descriptions (author notes about the operator, not 
guidance to a form reader, and shown once per field by formly), and applies the 
author's stored overrides -- rename and hide -- keyed by field path, with array 
indices dropped so one entry covers every row.
   - A repeated section builds its row template on demand, so the walk wraps 
the builder rather than the single object it returns, decorating every row 
formly ever creates.
   - Two small statics, `childPath` (the override path for a child, indices 
dropped) and `arrayItemOf` (a repeated section's row template, whether formly 
gives it as a value or a builder), back the keying and are unit tested directly.
   
   Writing a filled-in value back to its operator is already handled by #8437: 
formly's model carries the nested value, so a sub-field edit persists through 
the same write-back. This slice is the sub-field rendering and overrides only.
   
   ### Any related issues, documentation, discussions?
   
   Closes #8022. Part of the Form View feature (parent issue #8011).
   
   ### How was this PR tested?
   
   Unit tests (vitest). `sub-fields.spec.ts` covers the two statics directly 
(path joining, index dropping, non-name keys; the value/builder/throwing/none 
row-template cases). `workflow-form.component.spec.ts` covers the walk against 
the component: renaming and hiding an overridden sub-field of both an object 
property and a repeated section (per row, through the wrapped builder), 
dropping the schema descriptions, leaving an un-overridden sub-field untouched, 
and a scalar array's leaf row template. 100% statement and function coverage on 
the changed source; the remaining uncovered branches are defensive `??`/`||` 
fallbacks. `ng build gui`, eslint and prettier are clean, and the full 
workflow-form suite (73 tests) is green in both the single-user and 
collaboration paths.
   
   The visible effect (with the flag on) is that an exposed nested or array 
property renders its sub-fields, each renamed or hidden as the author set up. A 
screenshot can be added on request.
   
   ### Was this PR authored or co-authored using generative AI tooling?
   
   Yes. Co-authored with Claude (Anthropic), reviewed line by line by the 
author before submission.
   


-- 
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