[CMF-checkins] CVS: CMF/CMFWiki/skins/zpt_wiki - wiki_skeleton.pt:1.2 wikipage_advanced_form.pt:1.2 wikipage_backlinks.pt:1.2 wikipage_comment_form.pt:1.2 wikipage_edit_form.pt:1.2 wikipage_history.pt:1.2 wikipage_toc.pt:1.2 wikipage_view.pt:1.2

Ken Manheimer klm@zope.com
Wed, 31 Oct 2001 10:39:07 -0500


Update of /cvs-repository/CMF/CMFWiki/skins/zpt_wiki
In directory cvs.zope.org:/tmp/cvs-serv4473

Modified Files:
	wiki_skeleton.pt wikipage_advanced_form.pt 
	wikipage_backlinks.pt wikipage_comment_form.pt 
	wikipage_edit_form.pt wikipage_history.pt wikipage_toc.pt 
	wikipage_view.pt 
Log Message:
Provide for site main_template that has separate "header" and "main"
presentation slots, putting the wiki page header in the template
"header" slot if available.  (If there is not header slot, then the
wiki page header will be shown in the "main" section, as it previously
was.)

This can look *really* nice when, eg, the main_template puts the
header beside the actions box, and gives the main body of the page the
entire page width, below the pair.  (I hope) we'll be doing this on
new.zope.org, demonstrating the effect...


=== CMF/CMFWiki/skins/zpt_wiki/wiki_skeleton.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop">
 
-<div tal:replace="structure here/wikipage_header"> </div>
-
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 </div>
 


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_advanced_form.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop"
@@ -10,7 +16,10 @@
                                 or 'Anonymous User' )"
 >
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <table border="1">
 


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_backlinks.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop"
@@ -10,7 +16,10 @@
                  mover       python: here.isAllowed( 'move' )"
 >
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <h2> Backlinks and Nesting Information </h2>
 


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_comment_form.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop">
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <div
   tal:define="commentator python:here.isAllowed('comment', REQUEST=request);


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_edit_form.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop"
      tal:define="editor python:here.isAllowed( 'edit' )">
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <h3> <span tal:condition="python: not editor"> View </span>
      <span tal:condition="editor"> Edit </span>


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_history.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop">
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <div
   tal:define="mode python: request.get( 'mode', 'condensed' );


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_toc.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop"
@@ -11,7 +17,10 @@
                 "
 >
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <h3> <em tal:content="here/getId">PageID</em> Contents</h3>
 


=== CMF/CMFWiki/skins/zpt_wiki/wikipage_view.pt 1.1 => 1.2 ===
        metal:use-macro="here/main_template/macros/master">
 <body>
+<div metal:fill-slot="header"
+     tal:define="global wiki_header_present python:1">
+  <div tal:replace="structure here/wikipage_header">
+  </div>
+</div>
+
 <div metal:fill-slot="main">
 
 <div class="Desktop">
 
-<div tal:replace="structure here/wikipage_header"> </div>
+<div tal:condition="not: wiki_header_present|nothing">
+  <span tal:condition="nothing"> In case master has no "header" macro. </span>
+  <div tal:replace="structure here/wikipage_header"> </div>
+</div>
 
 <div tal:replace="structure here/render"> </div>
 
@@ -14,4 +23,4 @@
 
 </div>
 </body>
-</html>
\ No newline at end of file
+</html>