[MGNLSTK-422] AllowedBodyClasses in BodyClassResolver.java should probably be configurable within STK? Created: 05/Aug/09  Updated: 25/Mar/13  Resolved: 25/Mar/13

Status: Closed
Project: Magnolia Standard Templating Kit (closed)
Component/s: concept
Affects Version/s: 1.1.1
Fix Version/s: None

Type: New Feature Priority: Minor
Reporter: Christian Ringele Assignee: Christian Ringele
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
dependency
is depended upon by MGNLSTK-436 Make inplace templating more usable Closed
Template:
Acceptance criteria:
Empty

 Description   

In the class info.magnolia.module.templatingkit.style.BodyClassResolver.java the allowed body classes are defined:
private static String[] allowedBodyClasses =

{ "col", "nav-col", "col-subcol", "col-subcol-equal", "col-float3", "col-float2", "nav-col-float2", "col-float2-subcol", "col-subcol-subcol" }

;

If anything is configured by the user which is out of this definitions, a, error is generated in the log:
ERROR nolia.module.templatingkit.style.BodyClassResolver: Is not an allowed body class: nav-col-subcol-subcol

This can be very easily achieved by changing the extrasArea.columns=2 (two extras areas).
This means in consequences, that the used can configure within a site-definition a set which:

  • This error is produced
  • No body class shows on the page
    And the only way to solve this is by subclassing the BodyClassResolver class.

I think it makes no sense, to provide by configuration possibilities which finally drag a need to subclass.
That's why i want to raise here the questions, whether the 'allowedBodyClasses' shouldn't be configurable somwhere (site-def or so)?
And if not the variable should at least be protected for subclassing it better.



 Comments   
Comment by Christian Ringele [ 30/Dec/11 ]

Here the same as with the TemplateAvailability.
There are enough configurations in the STK's prototype.

If needed you can change it easily in hte java class.

Comment by Christian Ringele [ 25/Mar/13 ]

Correct status and fix version to set.

Comment by Christian Ringele [ 25/Mar/13 ]

Already enough configurations in STK.
And a recursive rights configuration is quite confusing and hard to manage.
Will remain in the Java class.

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