Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

3 Commits

Folders and files

Repository files navigation

JvMTECH.NodeAggregateProperties

Emulates node aggregate-scoped properties on Neos 8. Neos 9 introduces native support for properties scoped to the whole node aggregate instead of a single dimension variant; this package backports that behavior to Neos 8 ahead of the upgrade. The scope: 'nodeAggregate' property configuration is compatible with Neos 9, so NodeTypes configured for this package require no changes once the project upgrades.

Properties marked with scope: 'nodeAggregate' are automatically replicated across all dimension variants of a node whenever one variant is changed, so the property behaves as if it were shared by the whole node aggregate rather than a single variant.

This package is inspired by PunktDe.NodeReplicator.

How it works

  • NodeSignalInterceptor listens for Node::nodePropertyChanged and checks whether the changed property is configured with scope: 'nodeAggregate'.
  • NodeReplicator then propagates the new value to all other dimension variants of that node, guarding against infinite recursion while doing so.
  • NodeTypePostProcessor optionally adds a help message to the backend UI for every nodeAggregate-scoped property, so editors understand that the value applies to all languages/dimensions.

Configuration

'Some.Package:SomeNodeType':
  properties:
    someProperty:
      scope: 'nodeAggregate'

Package settings (Settings.yaml):

JvMTECH:
  NodeAggregateProperties:
    setHelpMessage: true
    overrideHelpMessage: false
    helpMessagePath: 'JvMTECH.NodeAggregateProperties:Main:ui.help.message'
  • setHelpMessage — whether to add the help message to nodeAggregate-scoped properties.
  • overrideHelpMessage — whether to override an existing ui.help.message on the property.
  • helpMessagePath — the translation path used for the help message.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages