[DOCU-2498] Improve description of how to configure transformers in M6 Created: 12/Feb/21 Updated: 15/Jun/22 |
|
| Status: | Open |
| Project: | Documentation |
| Component/s: | None |
| Affects Version/s: | 6.2 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Neutral |
| Reporter: | Šimon Demočko | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | fields, new-UI-framework, new-form | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | 40m | ||
| Original Estimate: | Not Specified | ||
| Description |
|
Currently the nesting in the configuration section is incorrect in https://docs.magnolia-cms.com/product-docs/Templating/Dialog-definition/Field-definition/Magnolia-6-UI-ports-of-5-UI-field-transformer-classes.html. Specifically entries in the column https://git.magnolia-cms.com/projects/DOCUMENTATION/repos/product-docs/browse/modules/ROOT/pages/Templating/Dialog-definition/Field-definition/Magnolia-6-UI-ports-of-5-UI-field-transformer-classes.adoc?useDefaultHandler=true#55. The nesting should follow the configuration in examples, e.g. like this: Use *`info.magnolia.ui.editor.JcrChildNodeProvider` as itemProvider * and set its `supportI18N` property to `false` *The deprecated `info.magnolia.ui.editor.ByLexicographicallyIndexedChildNodes$Definition` as `entryResolution` * and set its `strict` property to `true` *The deprecated `info.magnolia.ui.editor.LexicographicallyIndexedJcrNodeOrderHandler$Definition` as `orderHandler` However, this is basically a wordy explanation of a configuration, which can simply be provided as a YAML like so:
m6ConfigForDelegatingMultiValueSubnodeTransformer:
$type: jcrMultiField
itemProvider:
$type: jcrChildNodeProvider
supportI18N: false
entryResolution:
class: info.magnolia.ui.editor.MultiFieldEntryResolution$Definition
strict: true
propertyNameDecorator: info.magnolia.ui.field.AlwaysEmptyPrefixNameDecorator
field:
# here goes your multi field entry configuration
We do this in the example section, but it is unnecessarily disjointed from the table. I think the examples would be much more useful right there in the table where the transformers are mapped to the human-language explanation. Then one doesn't have to look into the examples, looking for which one is the one they are looking for by switching between M5 and M6, counting which field is the one they are looking for (this is something I had to do now as well when I was looking for the examples to copy here). |