[DOCU-266] Update inheritable components article to 4.5 Created: 27/Mar/12  Updated: 03/Nov/15

Status: Closed
Project: Documentation
Component/s: content
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Neutral
Reporter: Antti Hietala Assignee: Antti Hietala
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoR:
Empty
Date of First Response:

 Description   

The way components are inherited changed in Magnolia CMS 4.5. While the idea is the same, configuration is done differently. Make the Inheritable components article to adhere to the new convention.

Inheritance is now configured in the area definition, see for example Site Definitions > /default/templates/prototype/areas/promos.

+ <area name>
  + inheritance
    - components = <all|filtered|none>
    - enabled = <true|false>

An area that has an inheritance content node can inherit its content from the parent. An enabled data node under it, when set to true, enables inheritance for components inside the area. The components data node defines which components are inherited:

  • all means that all the components from the parent area are inherited.
  • filtered means that only components whose inheritable property is set to true are inherited. The property is set with the "Show in subpage" checkbox.
  • none means that no components are inherited

Validate the article against 4.5. At least the following sections need updating:

  • "Footer, metanavigation and section header" section has outdated text and screenshot of footer area in the prototype. The cms.includeTemplate directive is deprecated. An area loops through its components automatically now so the whole code snippet is irrelevant. The text says the template script ensures that inherited components are rendered without area bars. The script doesn't need to do this anymore. If the component is inherited (Show in subpage checkbox is checked = has inheritable property when viewed in JCR Browser) then the component doesn't get a toolbar. Simple as that.
  • "Automatic inheritance" section. Procedure is incorrect. Replace with a procedure for creating the inheritance configuration under the area definition and setting components to all.
  • "Optional inheritance" section. Exactly the same as "Automatic" except add the Show in subpage control in the component dialog and set components to filtered.

Resources:



 Comments   
Comment by Ruth Stocks [ 02/Apr/12 ]

updated page at - http://docuauthor.magnolia-cms.com/templates/inheritable-components.html

A couple of notes:

  • The sectionHeader area is different from the other areas - see FIXME'S sectionHeader template and model class. Besides a mention that "the area is inheritable", I didn't document how it works as it looks like it may change.
  • The procedure for nested components works except that an editor can still add items on sub pages. The main component and any added items are only editible on the parent page, but they probably shouldn't be able to add new items.
Comment by Ruth Stocks [ 05/Apr/12 ]

Updated page at - http://docuauthor.magnolia-cms.com/templates/inheritable-components.html

Please check the DefaultInheritanceContentDecorator description text and then I will add the ticket.

Comment by Antti Hietala [ 05/Apr/12 ]

The Javadoc comment for DefaultInheritanceContentDecorator is good. Please enter new ticket in MAGNOLIA project.

Generated at Mon Feb 12 01:07:30 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.