#9822: New rendering method for content elements (lesser markup, cleaner code) (thank...
authorSteffen Kamper <info@sk-typo3.de>
Thu, 27 Nov 2008 21:06:50 +0000 (21:06 +0000)
committerSteffen Kamper <info@sk-typo3.de>
Thu, 27 Nov 2008 21:06:50 +0000 (21:06 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@4493 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/sysext/css_styled_content/static/constants.txt
typo3/sysext/css_styled_content/static/setup.txt

index 59023e9..bcf0921 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2008-11-27  Steffen Kamper  <info@sk-typo3.de>
 
+       * #9822: New rendering method for content elements (lesser markup, cleaner code) (thanks to Susanne Moog)
+
+2008-11-27  Steffen Kamper  <info@sk-typo3.de>
+
        * Fixed bug RFC #9797: Bug: waste of time in LIST module with LOISmode (thanks to Franz Holzinger)
 
 2008-11-27  Dmitry Dulepov  <dmitry.dulepov@gmail.com>
index b26a2d3..f5b16c4 100755 (executable)
@@ -8,12 +8,18 @@ content {
   pageFrameObj = page
 
   shortcut.tables = tt_content,tt_address,tt_links,tt_guest,tt_board,tt_calender,tt_products,tt_news,tt_rating,tt_poll
-    # cat=content; type=wrap; label= Content Element margins: Space above / below each content element (pixels of a clear-gif).
+    # cat=content/other/c; type=wrap; label= Content Element margins: Space above / below each content element (pixels of a clear-gif) in versions below TYPO3 4.3.0.
   space = 0|0
 
   splash.bgCol = white
 }
 
+[compatVersion = 4.3.0]
+    # cat=content/other/a; type=small; label= Content Element margins (before): Space before each content element.
+content.spaceBefore = 0
+    # cat=content/other/b; type=small; label= Content Element margins (after): Space after each content element.
+content.spaceAfter = 0
+[global]
 
     # cat=advanced; type=int+; label= News Content PID: If your template has a column with "news"-content fetched from another page-id, this is where you enter the id-number of that page!
 styles.content.getNews.newsPid = 0
index 812cd6d..4fabfc9 100755 (executable)
@@ -297,7 +297,121 @@ tt_content.stdWrap {
        }
 
        prefixComment = 1 | CONTENT ELEMENT, uid:{field:uid}/{field:CType}
+
+}
+
+[compatVersion = 4.3.0]
+tt_content.stdWrap {
+       spaceBefore.field >
+       spaceAfter >
+       space >
+       dataWrap >
+       innerWrap.cObject >
+
+       innerWrap.cObject = CASE
+       innerWrap.cObject {
+               key.field = section_frame
+
+               default = COA
+               default {
+                       10 = TEXT
+                       10 {
+                               value = <div id="c{field:uid}"
+                               override.cObject = TEXT
+                               override.cObject {
+                                       value = <div
+                                       if.value = div
+                                       if.equals.field = CType
+                               }
+                               insertData = 1
+                       }
+
+                       15 = TEXT
+                       15 {
+                               value = csc-default
+                               noTrimWrap = | class="|" |
+                               required = 1
+                       }
+
+                       20 = COA
+                       20 {
+                               10 = COA
+                               10 {
+                                       10 = TEXT
+                                       10 {
+                                               value = {$content.spaceBefore}
+                                               wrap = |+
+                                               if.isTrue = {$content.spaceBefore}
+                                       }
+
+                                       20 = TEXT
+                                       20 {
+                                               field = spaceBefore
+                                       }
+
+                                       stdWrap {
+                                               prioriCalc = intval
+                                               wrap = margin-top:|px;
+                                               required = 1
+                                               ifEmpty.value =
+                                       }
+                               }
+
+                               20 = COA
+                               20 {
+                                       10 = TEXT
+                                       10 {
+                                               value = {$content.spaceAfter}
+                                               wrap = |+
+                                               if.isTrue = {$content.spaceAfter}
+                                       }
+
+                                       20 = TEXT
+                                       20 {
+                                               field = spaceAfter
+                                       }
+
+                                       stdWrap {
+                                               prioriCalc = intval
+                                               wrap = margin-bottom:|px; 
+                                               required = 1
+                                               ifEmpty.value =
+                                       }
+                               }
+
+                               stdWrap.noTrimWrap = | style="|" |
+                               stdWrap.required = 1
+                       }
+                       30 = TEXT
+                       30.value = >|</div>
+               }
+
+               1 =< tt_content.stdWrap.innerWrap.cObject.default
+               1.15.value = csc-frame csc-frame-invisible
+
+               5 =< tt_content.stdWrap.innerWrap.cObject.default
+               5.15.value = csc-frame csc-frame-rulerBefore
+
+               6 =< tt_content.stdWrap.innerWrap.cObject.default
+               6.15.value = csc-frame csc-frame-rulerAfter
+
+               10 =< tt_content.stdWrap.innerWrap.cObject.default
+               10.15.value = csc-frame csc-frame-indent
+
+               11 =< tt_content.stdWrap.innerWrap.cObject.default
+               11.15.value = csc-frame csc-frame-indent3366
+
+               12 =< tt_content.stdWrap.innerWrap.cObject.default
+               12.15.value = csc-frame csc-frame-indent6633
+
+               20 =< tt_content.stdWrap.innerWrap.cObject.default
+               20.15.value = csc-frame csc-frame-frame1
+
+               21 =< tt_content.stdWrap.innerWrap.cObject.default
+               21.15.value = csc-frame csc-frame-frame2
+       }
 }
+[end]
 
 
 # *****************