Page History
...
The implementing classes may define their own configuration. The classes are in the info.magnolia.ui.api.availability
package and in magnolia-ui-app-pages
package.
Some proposed rules:
IsDeletedRule
- returns true only if the item has been marked for deletion (i.e. has the mgnl:deleted mixin node type).IsNotDeletedRule
AllRulesRule
- works like an AND operator, meaning all the other rules in this configuration must be satisfiedAllNodeTypesRule
- as the default availability nodeTypes configuration uses disjunction (OR) to evaluate, this rule will return true only if the node has all the node types (e.g. mixins) defined in the rule configuration.ActivationStatusRule
- according to its configuration, the rule will return true only if the item has / has not been yet activated, alternatively if it has been (not) changed since the last activation.- ...
PageHasSubPages
Actionbar appearance
The actionbar should only show one section at a time. The section to show depends on the selected node. Therefore we need to configure:
...
If more than one section applies the first one is used. Example use case: in the Pages app, the pageDeletedActions section has a stricter rule (these actions are available only for deleted nodes) than the pageActions section (these actions are available for any nodes). Therefore, the pageDeletedActions section must be first.
Selecting the section to show and evaluating the restrictions/availability is done in BrowserSubApp.updateActionbar(), extending classes can override this method to implement their own behaviour.
...