-
-
Notifications
You must be signed in to change notification settings - Fork 223
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BUGFIX: Sort properties in raw content mode
Previously there was no obvious sorting. With this change the sorting option which is also used for the inspector is used to sort the items and therefore giving an option to the integrator on their arrangement. This changes introduces the sortByPosition method into the Neos.Array Eel helper to make the PositionalArraySorter available in Fusion.
- Loading branch information
Showing
3 changed files
with
25 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 6 additions & 1 deletion
7
Neos.Neos/Resources/Private/Fusion/RawContent/NodeProperties.fusion
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,12 @@ | ||
prototype(Neos.Neos:RawContent.NodeProperties) < prototype(Neos.Fusion:Component) { | ||
@private { | ||
items = ${node.nodeType.properties} | ||
[email protected] = ${Neos.Array.sortByPropertyPath(value, 'ui.inspector.position')} | ||
} | ||
|
||
renderer = afx` | ||
<dl class="neos-raw-content-properties" @if={!String.isBlank(this.content)}> | ||
<Neos.Fusion:Loop items={node.nodeType.properties} itemKey="propertyName" itemName="propertyConfiguration"> | ||
<Neos.Fusion:Loop items={private.items} itemKey="propertyName" itemName="propertyConfiguration"> | ||
<Neos.Neos:RawContent.NodeProperty propertyName={propertyName} propertyConfiguration={propertyConfiguration}/> | ||
</Neos.Fusion:Loop> | ||
</dl> | ||
|