-
-
Notifications
You must be signed in to change notification settings - Fork 222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Placeholder "i18n" for string properties in inspector is not replaced anymore #3249
Comments
Seems this is due to 7ecdc07 |
Probably an error, the conversion of i18n labels is all the NodeTypeConfigurationEnrichmentAspect should still do. Wait: Do the editor configurations in the settings use "i18n". I would consider this buggy and rather use a full translation identifier. |
I just checked. The property editor configurations from settings do not use "i18n" at all. I would recommend to use full identifiers in presets that are applied to multiple nodetypes. i18n only works directly in NodeTypes.yaml. |
@mficzel |
@mficzel what do you mean with Settings? |
So full example: Broken placeholder:
Working placeholder:
Working placeholder:
|
I mean the Setting in The problem with the i18n behavior is that it can only be evaluated while the nodetype is prepared as it is relative to the nodetype that it is defined on and not the nodetype that evenually uses it (which is a problem for things that are not in NodeTypes.yaml). That is the reason why this still is in the aspect. In short if the "i18n" is in NodeTypes.yaml it should be replaced. Looking at the "twitterCardCreator" setting i would expect this to work and consider it a bug if not. Probably some refactoring error in the NodeTypeConfigurationEnrichmentAspect. If it is in a Settings and gets merged into the configuration by a postprocessor i18n cannot work and as far as i know did also not work in the past. |
The difference is now that with the mentioned change first the editor defaults were merged and then the labels generated. Now it's the other way around and the label generator doesn't know which editor should be used for simple string props to generate the full id. |
Hmm ... applyEditorLabels looks very specific to me and probably should be removed entirely. I wonder wether something similar to https://github.com/neos/neos-development-collection/blob/master/Neos.Neos/Classes/Aspects/NodeTypeConfigurationEnrichmentAspect.php#L110-L112 for inspectorEditors would be enough already and applyEditorLabels is just obsolete. |
If we generate the id for |
Makes sense to me so let us just add a line to handle |
Description
For string properties usually no editor is defined in the nodetype config and by default Neos uses the
TextFieldEditor
.But in the
NodeTypeConfigurationEnrichmentAspect
thei18n
value is not converted to a translatableid anymore because the
$editorName
doesn't seem to be set yet.I assume it's because
enrichNodeTypeLabelsConfiguration
happens beforeenrichNodeTypeConfiguration
.There were some related changes in Neos 5.
It works again when setting the editor manually to `Neos.Neos/Inspector/Editors/TextFieldEditor´.
Steps to Reproduce
Creator handle
Twitter card fieldExpected behavior
The placeholder in the textfield editor should have been replaced
Actual behavior
The field only says has "i18n" as placeholder
Affected Versions
Neos: 5.x
The text was updated successfully, but these errors were encountered: