Skip to content
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

Add ability to translate NodeTypes and NodeType groups #122

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.ElementCollection.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'Neos.Form.Builder:ElementCollection':
ui:
label: 'Elements'
label: i18n
icon: 'icon-list'
inlineEditable: true
options:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Finisher.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

'Neos.Form.Builder:FinisherCollection':
ui:
label: 'Finishers'
label: i18n
icon: 'icon-share-square-o'
inlineEditable: true
superTypes:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Finishers.Confirmation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractFinisher': true
ui:
label: 'Confirmation Finisher'
label: i18n
icon: 'icon-comment'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Finishers.Email.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractFinisher': true
ui:
label: 'Email Finisher'
label: i18n
icon: 'icon-envelope-o'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Finishers.Redirect.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractFinisher': true
ui:
label: 'Redirect Finisher'
label: i18n
icon: 'icon-arrow-right'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Form.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
skipPresets:
'neos.setup': true
ui:
label: 'Form'
label: i18n
icon: 'icon-list-alt'
position: 600
inlineEditable: true
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElement.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
label: "${q(node).property('identifier') || q(node).property('label') || ((node.nodeType.label || node.nodeType.name) + ' (' + node.name + ')')}"
ui:
inlineEditable: true
label: 'Form Element'
label: i18n
icon: 'icon-square-o'
group: 'form.elements'
inspector:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.DatePicker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:DefaultValueMixin': false
'Neos.Form.Builder:ValidatorsMixin': true
ui:
label: 'Date picker'
label: i18n
icon: 'icon-calendar'
group: 'form.custom'
inspector:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.FileUpload.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
'Neos.Form.Builder:ResourceCollectionsPostprocessor':
postprocessor: 'Neos\Form\Builder\NodeType\ResourceCollectionsPostprocessor'
ui:
label: 'File upload'
label: i18n
icon: 'icon-upload'
group: 'form.custom'
inspector:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.HiddenField.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:FormElement': true
ui:
label: 'Hidden value'
label: i18n
icon: 'icon-eye-slash'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.ImageUpload.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
'Neos.Form.Builder:FormElement': true
'Neos.Form.Builder:DefaultValueMixin': false
ui:
label: 'Image upload'
label: i18n
icon: 'icon-picture-o'
group: 'form.custom'
inspector:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.MultiLineText.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:PlaceholderMixin': true
'Neos.Form.Builder:MaxlengthMixin': true
ui:
label: 'Multi-line text'
label: i18n
icon: 'icon-pencil-square-o'
inspector:
groups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:SelectionMixin': true
'Neos.Form.Builder:DefaultValueMixin': false
ui:
label: 'Multiple Select (Checkboxes)'
label: i18n
icon: 'icon-list-ol'
inspector:
groups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:SelectionMixin': true
'Neos.Form.Builder:DefaultValueMixin': false
ui:
label: 'Multiple Select (Dropdown)'
label: i18n
icon: 'icon-list-ol'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.Password.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:DefaultValueMixin': false
'Neos.Form.Builder:PlaceholderMixin': true
ui:
label: 'Password field'
label: i18n
icon: 'icon-asterisk'
inspector:
groups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:DefaultValueMixin': false
'Neos.Form.Builder:PlaceholderMixin': true
ui:
label: 'Password field with confirmation'
label: i18n
icon: 'icon-asterisk'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.Section.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
'Neos.Form.Builder:DefaultValueMixin': false
'Neos.Form.Builder:RequiredCheckboxMixin': false
ui:
label: 'Section'
label: i18n
icon: 'icon-folder-open'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.SingleLineText.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
'Neos.Form.Builder:PlaceholderMixin': true
'Neos.Form.Builder:MaxlengthMixin': true
ui:
label: 'Single-line text'
label: i18n
icon: 'icon-pencil-square-o'
inspector:
groups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:SelectionMixin': true
'Neos.Form.Builder:DefaultValueMixin': false
ui:
label: 'Single Select (Dropdown)'
label: i18n
icon: 'icon-list-ol'
inspector:
groups:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'Neos.Form.Builder:SelectionMixin': true
'Neos.Form.Builder:DefaultValueMixin': false
ui:
label: 'Single Select (Radiobuttons)'
label: i18n
icon: 'icon-list-ol'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormElements.StaticText.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
'Neos.Form.Builder:DefaultValueMixin': false
'Neos.Form.Builder:RequiredCheckboxMixin': false
ui:
label: 'Static text'
label: i18n
icon: 'icon-align-left'
group: 'form.custom'
inspector:
Expand Down
4 changes: 2 additions & 2 deletions Configuration/NodeTypes.FormPage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
nodeTypes:
'*': false
ui:
label: 'Form Page'
label: i18n
icon: 'icon-file-o'
group: 'form.pages'
inlineEditable: true
Expand Down Expand Up @@ -45,7 +45,7 @@

'Neos.Form.Builder:PageCollection':
ui:
label: 'Further Pages'
label: i18n
inlineEditable: true
options:
fusion:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.FormPages.PreviewPage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:FormPage': true
ui:
label: 'Preview Page'
label: i18n
icon: 'icon-file-text-o'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.SelectOption.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
label: "${q(node).property('label') || q(node).property('value') || '[not set]'}"
ui:
inlineEditable: true
label: 'Select option'
label: i18n
icon: 'icon-stop-circle-o'
group: 'form.selectOptions'
inspector:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.SelectOptionCollection.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'Neos.Form.Builder:SelectOptionCollection':
ui:
label: 'Options'
label: i18n
icon: 'icon-list-ul'
inlineEditable: true
options:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.Alphanumeric.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Alphanumeric Validator'
label: i18n
icon: 'icon-font'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.Count.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Count Validator'
label: i18n
icon: 'icon-sort-amount-asc'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.DateTimeRange.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'DateTime range Validator'
label: i18n
icon: 'icon-calendar-check-o'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.EmailAddress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Email address Validator'
label: i18n
icon: 'icon-envelope-o'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.Float.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Floating-point number Validator'
label: i18n
icon: 'icon-sort-numeric-asc'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.Integer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Integer validator'
label: i18n
icon: 'icon-sort-numeric-asc'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.NumberRange.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Number range Validator'
label: i18n
icon: 'icon-sort-numeric-asc'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.RegularExpression.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Regular Expression Validator'
label: i18n
icon: 'icon-terminal'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.StringLength.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'String length Validator'
label: i18n
icon: 'icon-text-width'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.Text.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
superTypes:
'Neos.Form.Builder:AbstractValidator': true
ui:
label: 'Text Validator'
label: i18n
icon: 'icon-font'
inspector:
groups:
Expand Down
2 changes: 1 addition & 1 deletion Configuration/NodeTypes.Validator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
superTypes:
'Neos.Neos:Content': true
ui:
label: 'Form Validator'
label: i18n
icon: 'icon-check'
inlineEditable: true
inspector:
Expand Down
17 changes: 9 additions & 8 deletions Configuration/Settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,33 +10,34 @@ Neos:
translation:
autoInclude:
'Neos.Form.Builder':
- Main
- 'NodeTypes/*'

nodeTypes:
groups:
'form.elements':
label: 'Input Form Elements'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formElements'
collapsed: false
'form.select':
label: 'Select Form Elements'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formSelect'
collapsed: false
'form.custom':
label: 'Custom Form Elements'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formCustom'
collapsed: false
'form.container':
label: 'Container Form Elements'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formContainer'
collapsed: false
'form.pages':
label: 'Form Pages'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formPages'
collapsed: false
'form.finisher':
label: 'Form Finisher'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formFinisher'
collapsed: false
'form.validator':
label: 'Form Validators'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formValidator'
collapsed: false
'form.selectOptions':
label: 'Select options'
label: 'Neos.Form.Builder:Main:nodeTypes.groups.formSelectOptions'
collapsed: false

Ui:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ used:
can be inserted. The following snippet can be added to the sites `NodeTypes.yaml` in order
to disable the Neos.NodeTypes Form:
```yaml
'Neos.NodeTypes:Form': ~
'Neos.NodeTypes.Form:Form': ~
```

Now, *Form Elements* can be added to the Form:
Expand Down
Loading