[MTE-20] Don't store html elements in website workspace, use named/speaking headlineLevels instead Created: 05/May/15  Updated: 09/Jun/15  Resolved: 02/Jun/15

Status: Closed
Project: Magnolia Templating Essentials
Component/s: models
Affects Version/s: None
Fix Version/s: 0.5

Type: Bug Priority: Major
Reporter: Philip Mundt Assignee: Espen Jervidalo
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Demo_TxtImage_CurrentImpl_HeadinLevels.png    
Issue Links:
supersession
supersedes MGNLDEMO-22 Freemarker Scripts: Should be simplif... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:

 Description   

We're currently storing h1-h6 in the website repository. This is not good practice. We should instead store named level, such as big, medium, small, tiny – or similar.



 Comments   
Comment by Christian Ringele [ 06/May/15 ]

Good general change!

Thea reason is preventing mess in maintenance and later re-designs:

Project 1.0:
All h4 are h4 stored in the content and the script just does:

[#assign headingLevel = content.headingLevel!"h2"]
[#if content.headline?has_content]
    <${headingLevel}>${content.headline!}</${headingLevel}>
[/#if]

Project 1.1:
All h4 should now become h5...
This will need:
1. A content migration of all components rendering the h4 stored in the content
2. Or it will have something alike in the script:

[#if content.headingLevel == "h4"]
   [#assign headingLevel = h5]
[#else]
   [#assign headingLevel = content.headingLevel!"h2"]
[/#if]
[#if content.headline?has_content]
    <${headingLevel}>${content.headline!}</${headingLevel}>
[/#if]

And now imagine later more changes to come...

Comment by Philip Mundt [ 02/Jun/15 ]

Integration revealed a flaw with the textImage & jumbotron component. Suggesting to remove headline / image from the jumbotron and introduce a new dialog for it (and also solve MGNLDEMO-52).

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